Most people don’t need this. If you’re sending untagged traffic, skip the page. It’s here because tagged frames have one surprise (the 68-byte minimum) and one common mistake (binding the wrong interface), both worth having written down.
--vlan and Wireblast builds the 802.1Q tag into every frame itself.
0 means untagged, which is the default.
Bind the physical NIC, not the sub-interface
This is the thing everyone gets wrong once. AF_XDP attaches to the real device. If your host has avlan.100 sub-interface, don’t point --interface at it. Point at the parent NIC and let Wireblast do the tagging:
Addressing comes from the sub-interface
If a matching sub-interface exists, Wireblast uses it for the things that need an IP stack: picking a source address, looking up the route, resolving the next-hop MAC.--src-ip and --dst-mac explicitly. That’s a perfectly normal way to run a test: you’re generating traffic, not participating in the network.
The 68-byte minimum
The 64-byte Ethernet minimum is measured on the untagged frame. Add a 4-byte tag and the smallest legal frame becomes 68 bytes. Ask for less and the NIC silently pads it, which means the frame on the wire isn’t the size you asked for and every rate Wireblast reported would be short by the difference. So it refuses instead:--packet-size 64, 66 and 68 with a tag all left the NIC as 68-byte frames.
IMIX handles this for you. On a tagged link its 64-byte component becomes 68, so the mix reads 68/594/1518B and the mean rises from 362 to 364 bytes, which is exactly what the receiver counts. Nothing to set; it just reports honestly.
Comparing tagged and untagged runs? Use 68 for both. Comparing a 64-byte untagged run against a 68-byte tagged one is a 6% difference in frame size before you’ve measured anything.
The tag is inside --packet-size
--packet-size 512 with a tag means 512 bytes total on the wire: 14 bytes of Ethernet header, 4 of tag, 490 of IP packet, 4 of FCS. The payload gets 4 bytes smaller; the frame doesn’t get bigger.
This also means the tag doesn’t count against the MTU. A 1500-byte MTU accepts --packet-size 1522 when tagged, because the MTU governs the IP packet, not the Ethernet framing.
Watching it on the far end
If you’re checking withbwm-ng or similar, point it at the physical NIC, not the VLAN sub-interface. Pointed at a sub-interface, the kernel has already stripped the Ethernet header and the tag, so the byte counter reads about 18 bytes per packet lower:
Full explanation in reading the numbers.
Limitations
- One tag. No QinQ, no stacked tags.
- No tag on PCAP replay. Captures are replayed byte for byte, so tags come from the capture itself.
- IPv6 works too. A tagged IPv6 UDP frame just starts at 70 bytes (the 66-byte v6 minimum plus the 4-byte tag).