tcpdump mailing list archives

Cannot catch vlan frames with tcpdump


From: "Ian Brown" <ianbrn () gmail com>
Date: Sun, 27 Jan 2008 17:04:48 +0200

Hello,
  - I am using pktgen on Linux to generate vlan traffic.

  - I am sniffing with tcpdump on both sides (src and dest) and cannot
catch VLAN traffic.

  - I tried sniffing in various ways , like by "tcpdump -f vlan" and
"tcpdump -f vlan and net 192.168.0.0" and  "tcpdump -f vlan and udp
port 9" and many other ways . on both sides,
(192.168.0.10 and the source machine , where pktgen runs) but I could
not catch any VLAN frames.

The script I am using for pktgen is this:

function pgset() {
    local result

    echo $1 > $PGDEV

    result=`cat $PGDEV | fgrep "Result: OK:"`
    if [ "$result" = "" ]; then
         cat $PGDEV | fgrep Result:
    fi
}

function pg() {
    echo inject > $PGDEV
    cat $PGDEV
}

echo "Adding devices to run".

PGDEV=/proc/net/pktgen/kpktgend_0
pgset "rem_device_all"
pgset "add_device eth0"
pgset "max_before_softirq 10"


PGDEV=/proc/net/pktgen/eth0

pgset "clone_skb 10"
pgset "min_pkt_size 64"
pgset "max_pkt_size 64"
pgset "dst 192.168.0.10"
pgset "dst_mac 00:0D:60:9A:26:D2"
pgset "count 10"
pgset "vlan_id 45"       #set VLAN ID 0-4095


# Next dev
# Time to run

pgset "start"
echo "Done"


Any ideas ?
Does anyone have any exoerience with tcpdump and pktgen ?


Regards,
Ian
-
This is the tcpdump-workers list.
Visit https://cod.sandelman.ca/ to unsubscribe.


Current thread: