I never had any problem reading the data with UDP sockets. Can you post some code that doesn't work, the output of 'ip addr' (you're on Linux, right?), Wireshark output (a .pcap file, perhaps) containing a couple packets (not tons -- one or two will suffice), and the output of 'iptables -L -n -v'? (You'll need to be root for the iptables command to work.)
The first thing to check is that you programmed something vaguely intelligent into the MAC table. (Note: tgtap supposedly does this for you, but I wrote my stuff back when tgtap was somewhere between mostly and completely nonfunctional, at least when controlled via katcp.) --Andy On Thu, Oct 28, 2010 at 5:17 PM, <[email protected]> wrote: > Hi all, > > This a follow-up to an old thread, in case anyone runs into a similar > problem. > > I can see the data coming in from the roach via the 10gbe using Tcpdump > and Wireshark with the correct IP address and port, but I never was able > to get data using this Python socket. Still puzzled. However, I returned > to this problem recently, and managed to get data using a raw socket with > the following Python code: > > from socket import * > s = socket(AF_PACKET, SOCK_RAW, htons(3)) > s.setsockopt(SOL_SOCKET, SO_RCVBUF, 2**30) > s.bind(('eth1', 3) > # my packet is 4096 B > data = s.recv(4138) > > This gives you the data packet as well as the 42 byte packet header. > > > Sean > > >

