11 result
=`cat $PGDEV | fgrep "Result: OK:"`
12 if [ "$result" = "" ]; then
13 cat $PGDEV | fgrep Result
:
17 # Config Start Here -----------------------------------------------------------
21 # One CPU means one thread. One CPU example. We add eth1, eth2 respectivly.
23 PGDEV
=/proc
/net
/pktgen
/kpktgend_0
24 echo "Removing all devices"
25 pgset
"rem_device_all"
27 pgset
"add_device eth1"
29 pgset
"add_device eth2"
33 # delay 0 means maximum speed.
35 CLONE_SKB
="clone_skb 1000000"
36 # NIC adds 4 bytes CRC
37 PKT_SIZE
="pkt_size 60"
39 # COUNT 0 means forever
41 COUNT
="count 10000000"
44 PGDEV
=/proc
/net
/pktgen
/eth1
45 echo "Configuring $PGDEV"
50 pgset
"dst 10.10.11.2"
51 pgset
"dst_mac 00:04:23:08:91:dc"
53 PGDEV
=/proc
/net
/pktgen
/eth2
54 echo "Configuring $PGDEV"
59 pgset
"dst 192.168.2.2"
60 pgset
"dst_mac 00:04:23:08:91:de"
63 PGDEV
=/proc
/net
/pktgen
/pgctrl
65 echo "Running... ctrl^C to stop"
69 cat /proc
/net
/pktgen
/eth1
/proc
/net
/pktgen
/eth2