netmap-ipfw on em0 em1
Evandro Nunes
evandronunes12 at gmail.com
Tue Nov 4 14:37:50 UTC 2014
btw,
I am generating traffic via pkt-gen which I can see os received on the
other side:
# /usr/src/tools/tools/netmap/netmap-7e9e5e7602f5/examples/pkt-gen -i em1
-f tx -l 60 -d 172.16.250.10
643.417060 main [1649] interface is em1
643.417344 extract_ip_range [287] range is 10.0.0.1:0 to 10.0.0.1:0
643.417386 extract_ip_range [287] range is 172.16.250.10:0 to
172.16.250.10:0
643.433773 main [1840] mapped 334980KB at 0x801800000
Sending on netmap:em1: 1 queues, 1 threads and 1 cpus.
10.0.0.1 -> 172.16.250.10 (00:00:00:00:00:00 -> ff:ff:ff:ff:ff:ff)
643.433885 main [1924] Sending 512 packets every 0.000000000 s
643.433895 main [1926] Wait 2 secs for phy reset
645.434799 main [1928] Ready...
645.435012 nm_open [456] overriding ifname em1 ringid 0x0 flags 0x1
645.435315 sender_body [1014] start, fd 4 main_fd 3
646.100734 sender_body [1083] drop copy
646.436332 main_thread [1446] 149811 pps (149967 pkts in 1001041 usec)
647.437206 main_thread [1446] 148782 pps (148912 pkts in 1000875 usec)
648.438209 main_thread [1446] 148795 pps (148944 pkts in 1001002 usec)
649.439233 main_thread [1446] 50812 pps (50864 pkts in 1001024 usec)
Sent 498687 packets, 60 bytes each, in 3.35 seconds.
Speed: 148.81 Kpps Bandwidth: 71.43 Mbps (raw 100.00 Mbps)
anyway ipfw does not seem to see this netmap-aware traffic:
# ipfw/ipfw show
connected to 127.0.0.1:5555
nalloc 2248 nbytes 112 ptr 0x0
00100 0 0 count ip from any to any
65535 0 0 allow ip from any to any
while it's still running:
# ps wauxw | grep ipfw
root 40820 0.4 0.0 14648 1744 2 R 12:32PM 0:04.95
./kipfw em1 em2 lo0
root 40886 0.0 0.0 14708 1552 2 DL+ 12:34PM 0:00.00
grep ipfw
I am using latest netmap and netmap-ipfw source code, not the code from
freebsd base system.
everywhere I see examples, on readme files, luigi's papers and videos, it's
related to vale interfaces, but what I want is to use it in phisical NIC
not a vale NIC
any further help is much appreciated
thank you in advance
On Tue, Nov 4, 2014 at 11:56 AM, Evandro Nunes <evandronunes12 at gmail.com>
wrote:
> hello,
> I am trying to do some basic stateless filtering with netmap-ipfw.
>
> what i have running is:
>
> ./kipfw em1 em2 lo0
>
> and when i do ipfw/ipfw show:
>
> ipfw/ipfw show
> connected to 127.0.0.1:5555
> nalloc 2248 nbytes 136 ptr 0x0
> 00100 0 0 allow ip from any to any via lo0
> 65535 0 0 allow ip from any to any
>
> it's not counting any packet, including loopback
>
> i have seem people using something similar but with ix(4) driver, what I
> am doing wrong?
>
More information about the freebsd-net
mailing list