thanks a lot for the reply.
Now im able to run the simhost application and ping it from another 
terminal window. But my curiosity has put  me into doubt again. I opened 
another window and did a ifconfig to view the stats and to my suprise saw 
that the bytes received is 0 for the tap0 device. But it keeps on 
increasing for the loopback address. Is this a normal response or is it 
indicating another problem(Im not that strong with networking concept)

Regards,
Deepak Gopalakrishnan





Jeff Barber <[email protected]> 
05/04/2009 06:47 PM

To
Mailing list for lwIP users <[email protected]>, 
[email protected]
cc

Subject
Re: [lwip-users] lwip on linux(ubuntu 8.04)






The MAC address you're seeing is being created by the kernel tap
interface each time you bring simhost up.  If this is your machine
before you run simhost (use a fixed width font for best results):

 ------------------
 | Linux host     |
 |                |
 |          eth0 [|--------- (Your existing network interface)
 |                |
 |                |
 ------------------

This is what it looks like afterward (logically that is; in reality
the simulated lwip host is actually a process running inside your
linux machine):

 ------------------
 | Linux host     |
 |                |
 |          eth0 [|--------- (Your existing network interface)
 |                |
 |                |        ---------------
 |          tap0 [|--------| (simulated) |
 |                |        |  lwip host  |
 ------------------        |             |
                           ---------------

tap0 has the "gateway" address you specified on the simhost command
line (192.168.0.1 by default), the primary IP address specified is the
address of the simulated lwip host (192.168.0.2 by default).

If you use the "-p xx.xx.xx.xx" option, you're pinging out from within
the lwip host.  So the only thing you can really ping is the tap0
"gateway" address (although due to linux idiosyncrasies, it also lets
you ping local interface addresses like the one attached to eth0).

Several things you can try:
Bring up the simhost program (as root).  (For example, "sudo ./simhost")
Then from another shell window, you can ping the lwip simulation with
"ping 192.168.0.2".
You can also telnet to it with "telnet 192.168.0.2" (note that you do
not get a bash shell, you get a limited shell implemented entirely
within the 'fake' lwip host).
Finally, if you have a web browser, you can connect to
http://192.168.0.2 which connects you to the web server implemented
inside the lwip host.


Jeff

On Mon, May 4, 2009 at 7:52 AM, Deepak Gopalakrishnan
<[email protected]> wrote:
>
> yes as you have mentioned there is a entry file for the examples 
provided for
> unix port.
> contrib/ports/unix/proj/unixsim/simhost.c
>
> but im not sure how to use this application.
> i tried the ping option provided but this is the response i got..
> Using <some addr1> to ping
> Host at <some addr2> mask <some addr3> gateway <some addr4>
> System initialized
> TCP/IP initializes
> sending ping
> Applications started
>
> How can i find out if this is working?
> yes im breaking my head to find out where the MAC address is being set 
cause
> im getting a new MAC address each time i run this application...did you 
find
> a solution to get around this problem..?
>
> --
> View this message in context: 
http://www.nabble.com/lwip-on-linux%28ubuntu-8.04%29-tp23363680p23366704.html

> Sent from the lwip-users mailing list archive at Nabble.com.
>
>
>
> _______________________________________________
> lwip-users mailing list
> [email protected]
> http://lists.nongnu.org/mailman/listinfo/lwip-users
>

_______________________________________________
lwip-users mailing list
[email protected]
http://lists.nongnu.org/mailman/listinfo/lwip-users

Reply via email to