[ECOS] TAP device not created on running "ping_test"

Mandeep Sandhu mandeepsandhu.chd@gmail.com
Fri Jul 24 09:39:00 GMT 2009


Hi all,

So after my ordeal with the Hello world app...I've jumped onto to a
more audacious task! :)
...to get some basic networking working with the virt TAP device.

This is what I did:

$ mkdir net
$ cd net
$ ecosconfig new linux
$ ecosconfig add fileio net freebsd_net eth_drivers
$ ecosconfig tree

(alter the usual suspects i.e command prefix, GCC switch fno-statck-... etc)
$ make

(fix libgcc_eh.a thingy)
$ make tests

I've configured static IP for eth0 on ecos
Self IP=10.0.0.2
netmask=255.255.255.0
gw=10.0.0.1
server=10.0.0.10

I used the tdf file given here:
http://dsl.ee.unsw.edu.au/dsl-cdrom/unsw/projects/ecos/ecos/packages/devs/eth/synth/ecosynth/current/host/ethernet.tdf

This file creates a TAP device tap3 with MAC=00:FE:42:63:84:A5

I've also built the rawether app (this has the suid bit set):
$ ls -l /usr/local/libexec/ecos/devs/eth/synth/ecosynth/v3_0/rawether
-rwsr-xr-x 1 root root 19339 2009-07-23 16:04
/usr/local/libexec/ecos/devs/eth/synth/ecosynth/v3_0/rawether

My system also has the tun device:
$ ls -l /dev/net/tun
crw-rw-rw- 1 root root 10, 200 2009-07-17 09:57 /dev/net/tun

Now when I run the ping_test app, I see both the "ecossynth" and
"rawether" process's running, but no
tap device is created! Shouldn't the rawether proc open the tun device
which will result in the tap3
device being created?

The ping test does not succeed though but thats because there's no
other interface on the 10 network.

Test run o/p attached.

Thanks,
-mandeep
-------------- next part --------------
[cyg_net_init] Init: mbinit(0x00000000) 
[cyg_net_init] Init: cyg_net_init_devs(0x00000000) 
Init device 'synth_eth0' 
[cyg_net_init] Init: loopattach(0x00000000) 
[cyg_net_init] Init: ifinit(0x00000000) 
[cyg_net_init] Init: domaininit(0x00000000) 
[cyg_net_init] Init: cyg_net_add_domain(0x02001700) 
New domain internet at 0x00000000 
[cyg_net_init] Init: cyg_net_add_domain(0x02001140) 
New domain route at 0x00000000 
[cyg_net_init] Init: call_route_init(0x00000000) 
[cyg_net_init] Done 
Start PING test 
BOOTP[eth0] op: REPLY 
       htype: Ethernet 
        hlen: 6 
        hops: 0 
         xid: 0x0 
        secs: 0 
       flags: 0x0 
       hw_addr: 00:fe:42:63:84:a5 
     client IP: 10.0.0.2 
         my IP: 10.0.0.2 
     server IP: 10.0.0.10 
    gateway IP: 10.0.0.1 
  options: 
        subnet mask: 255.255.255.0 
       IP broadcast: 10.0.0.255 
            gateway: 10.0.0.1 
PING server 10.0.0.10 
recvfrom: Operation timed out 
recvfrom: Operation timed out 
recvfrom: Operation timed out 
recvfrom: Operation timed out 
recvfrom: Operation timed out 
recvfrom: Operation timed out 
recvfrom: Operation timed out 
sendto: Host is down 
sendto: Host is down 
sendto: Host is down 
sendto: Host is down 
sendto: Host is down 
sendto: Host is down 
sendto: Host is down 
sendto: Host is down 
sendto: Host is down 
Sent 16 packets, received 0 OK, 0 bad 
PING server 10.0.0.42 
recvfrom: Operation timed out 
recvfrom: Operation timed out 
recvfrom: Operation timed out 
recvfrom: Operation timed out 
recvfrom: Operation timed out 
recvfrom: Operation timed out 
sendto: Host is down 
sendto: Host is down 
sendto: Host is down 
sendto: Host is down 
sendto: Host is down 
sendto: Host is down 
sendto: Host is down 
sendto: Host is down 
sendto: Host is down 
sendto: Host is down 
Sent 16 packets, received 0 OK, 0 bad 
PASS:<Ping test OK> 
EXIT:<done> 

-------------- next part --------------
-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss


More information about the Ecos-discuss mailing list