New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Live filtering by VLAN fails in Linux 2.6 #390
Comments
Yes, that seems to work, thanks. At least on my target machine with CentOS 6.5 and kernel 2.6.32-431.29.2.el6.x86_64. |
Hmm this looks like a kernel bug to me. Kernel is removing vlan tag but doesn't provide userspace a way how to get the vlan tag information. |
Prior to 3.0, the VLAN auxiliary information for packets included a VLAN TCI field but did not include a flag to indicate whether the packet originally had a VLAN tag or not. If it didn't, the VLAN TCI field was set to 0, which meant that packets in VLAN 0 couldn't be distinguished from packets without a VLAN tag. In this Linux kernel commit, the In this Linux kernel commit, the If a kernel-headers package for a 2.x kernel has |
We have a capture system running CentOS 6 connected to a mirror port on a Juniper router, capturing VLAN tagged packets with a Mellanox card.
If I use tcpdump or tethereal to view packets live, I cannot filter by VLAN, but I can by host, e.g.
tethereal -i eth2 -n host www.example.com works, while
tethereal -i eth2 -n vlan 123 and host www.example.com does not (it captures no data)
If I record a pcap file, e.g.
tethereal -i eth2 -w my.cap -c 400
then I can replay it with e.g.
tcpdump -r my.cap -n vlan and host www.example.com
or
tcpdump -r my.cap -n vlan 123 host www.example.com
but not
tcpdump -r my.cap -n host www.example.com
It is particularly annoying that we cannot filter live by VLAN, e.g.
tethereal -i eth2 -n vlan 123
On an older router (Nortel Passport), this worked.
We have libpcap-1.4.0 on CentOS 6 (Linux 2.6.32-431) with a Mellanox driver v2.0 and a MT26448 card, connected to a Juniper EX9008 router.
I tried installing the latest libpcap 1.6.2 but that made no difference.
The text was updated successfully, but these errors were encountered: