Hi, Sean,

On Oct 28, 2010, at 3:05 PM, [email protected] wrote:

> s = socket.socket(socket.AF_INET, socket.SOCK_DGRAM)
> s.bind(('10.0.0.30', 60000))
> data = s.recv(5000)
> 
> [r...@arcons controlScripts]# /usr/sbin/tcpdump -xx -i eth1 -c 1
> tcpdump: verbose output suppressed, use -v or -vv for full protocol decode
> listening on eth1, link-type EN10MB (Ethernet), capture size 96 bytes
> 14:51:17.089028 IP 10.0.0.30.60000 > 10.0.0.20.60000: UDP, length 4104
> 
> [r...@arcons controlScripts]# /sbin/ifconfig eth1
> eth1      Link encap:Ethernet  HWaddr 00:07:43:06:DA:32
>          inet addr:10.0.0.30  Bcast:10.0.0.255  Mask:255.255.255.0
> 
> Note, the design I'm running has the roach sending 4104 byte packets.

tcpdump shows data going from 10.0.0.30 to 10.0.0.20 (which I assume is the 
ROACH sending data to what it thinks is your server's IP address), yet ifconfig 
shows that your server's eth1 IP address is 10.0.0.30.  Based on what tcpdump 
shows the ROACH to be doing, it seems that eth1 needs to have IP address 
10.0.0.20.  Likewise, I think the python code needs to bind to 10.0.0.20.  I 
think this is why you get data using raw sockets (which ignores IP addressing), 
but not using UDP/IP (which heeds IP addressing).

Hope this helps,
Dave


Reply via email to