3 Connecting to a Real Network 3.2 Connection Types
Ethernet Networking Technology Guide  /  3 Connecting to a Real Network  / 

3.1 Preparing for the Examples

All the examples in section 3.2 use the simulated QSP-x86 machine from the First Steps tutorial. Start the firststeps-no-network.simics configuration and boot the machine. Then, to save time when trying several examples, save a checkpoint. This checkpoint can be used instead of launching and booting QSP-x86 for each example. When idling, QSP-x86 runs faster than real time, which means that it can time out faster than expected, unless real time mode is turned on with enable-real-time-mode.

Not all kinds of connections with real network, or with real file systems, will continue to work properly if you pause the simulation for a shorter or lengthier time. This applies to most stateful connections, for example NFS, TCP, etc.

For the same reason, not all kinds of connections with the real world can be saved in a checkpoint and successfully restored at a later time. Hence, make a habit to disconnect such services before pausing the simulation, or before saving a checkpoint.

Some of the examples involve using telnet to connect to the simulated machine. On both Linux and Windows, a telnet binary is provided and can be used directly respectively in a terminal or in a Command-Line prompt. The output on Windows may be slightly different from the output given in the examples.

In the examples, the simulated machine sometimes needs to be reconfigured. Since it is running Linux, the appropriate Linux configuration commands are indicated. Other operating systems should be configured similarly, but the commands may of course differ.

Finally, in all examples, the host machine where Simics is running has the IP address 10.0.0.129 and the real host that communicates with the simulated network has the IP address 10.0.0.240. These addresses should be replaced as necessary. QSP-x86 uses its default IP address 10.10.0.40.

The examples assume that there is a host on the real network that accepts telnet connections. Check that it is possible to telnet from the simulation host to the other real host. Just run telnet ip at a command-line, where ip is the IP address of the other real host. If that does not work, the simulated machine will not be able to connect to the real host either.

If there is no host that accepts telnet connections on the network, the connection can be tested with a web server on port 80 instead, by entering GET / HTTP/1.0 and a blank line. This should return the HTML content of the start page of the server. Here www.google.com is used:

~# telnet www.google.com 80
Trying 64.233.161.104...
Connected to 64.233.161.104.
Escape character is '^]'.
GET / HTTP/1.0

HTTP/1.0 302 Found
Location: http://www.google.se/cxfer?c=PREF%3D:TM%3D1118841789:S%3DumCVbug84n5uBWAo&prev=/
Set-Cookie: PREF=ID=a5e237e2402bdcac:CR=1:TM=1118841789:LM=1118841789:S=HQ3jOc8_1peVGj98; expires=Sun, 17-Jan-2038 19:14:07 GMT; path=/; domain=.google.com
Content-Type: text/html
Server: GWS/2.1
Content-Length: 214
Date: Wed, 15 Jun 2005 13:23:09 GMT
Connection: Keep-Alive

<HTML><HEAD><TITLE>302 Moved</TITLE></HEAD><BODY>
<H1>302 Moved</H1>
The document has moved
<A HREF="http://www.google.se/">here</A>.
</BODY></HTML>
Connection closed by foreign host.
~#

Make sure that the telnet or web server is on the same IP subnet as the simulation host, since it may not be possible to access other subnets, depending on what real-network connection is in use.

3 Connecting to a Real Network 3.2 Connection Types