CSC
41200 Computer Networks (Section T)
Last
Updated: Sunday,
May 08, 2005
Instructor: T.
Rahman
Announcements:
·
Networking Lab is open from Monday
to Thursday, 2pm-4pm. Room: NAC 7/309.
·
Send me an email if you are
interested to work in the lab and also if you have participated on the lab.
Lab Notes:
·
Send me an email if the lab
setup does not work or you find the configurations changed.
·
Please login your lab activities and
send me an email of your lab.
·
The figure below shows the lab
connectivity. Do not touch the Ethernet cables for whatever reasons.

Figure 1: Lab Network Connectivity Diagram
Lab Prerequisites:
Lab users are expected to have UNIX
user level experience. (login / logout / edit files using
vi)
If you do not have user level
experience please learn UNIX first. It is really easy. (See introduction in http://www.tldp.org/guides.html)
Lab #1: Routing
- Login
into Router1 as root.
- Type #/sbin/ifconfig
to see configurations for all the interfaces.
- Type #ping 100.10.10.1 to test the
local address. #Ctrl-c to
stop pinging.
- Type #ping 200.10.10.1 to test the
local address. #Ctrl-c to
stop pinging.
- Type #ping 12.1.1.1 to test the local
address. #Ctrl-c to stop
pinging.
- Try to
ping Router2. How are you going to reach Router2? Which IP address? Try
reaching both.
- Type
#ping 150.10.10.3. Ctrl-c to stop pinging.
- Type
#ping 200.10.10.3. Ctrl-c to stop pinging.
- Why do
you think 150.10.10.3 does not respond?
- Does
Router1 know how to get to 150.10.10.x subnet? Let us find out.
- Type
#netstat
–nr. This will print out the routing table (-r option) in number
format (-n option).
- Ok
so Router1 does not know about 150.10.10.x subnet. We shall update its
routing table then.
- Type
#route add -net 150.10.10.0 netmask 255.255.255.0 dev eth1 (We tell it to
go via 200.10.10.0 subnet).
- Type
#ping 150.10.10.3. Ctrl-c to stop pinging. Does it
respond? Why not?
- Does
Router3 know for to forward IP packets from one interface to another? Let
us check.
- Login
into Router3 as root.
- Type
#/sbin/ifconfig
to see configurations for all the interfaces.
- Type
#ping 100.10.10.3 to test
the local address. #Ctrl-c
to stop pinging.
- Type
#ping 150.10.10.3 to test
the local address. #Ctrl-c
to stop pinging.
- Type
#ping 24.1.1.3 to test the
local address. #Ctrl-c to
stop pinging.
- Type
#cat /proc/sys/net/ipv4/ip_forward
(You should see 0 meaning no IP forwarding.)
- Type
#echo “1” /proc/sys/net/ipv4/ip_forward
(Now it should be forwarding packets.)
- Type
#cat /proc/sys/net/ipv4/ip_forward
(You should see 1 meaning IP forwarding ok.)
- Go
back to Router1 and try to ping 150.10.10.3 again. Does it work?