Static Routing Exercise u Unix network interface configuration u Cisco network interface...
-
Upload
harriet-ford -
Category
Documents
-
view
239 -
download
2
Transcript of Static Routing Exercise u Unix network interface configuration u Cisco network interface...
![Page 1: Static Routing Exercise u Unix network interface configuration u Cisco network interface configuration u Static routes u Default route u Testing.](https://reader036.fdocuments.net/reader036/viewer/2022082517/56649e425503460f94b34960/html5/thumbnails/1.jpg)
Static Routing Exercise
Unix network interface configuration Cisco network interface configuration Static routes Default route Testing
![Page 2: Static Routing Exercise u Unix network interface configuration u Cisco network interface configuration u Static routes u Default route u Testing.](https://reader036.fdocuments.net/reader036/viewer/2022082517/56649e425503460f94b34960/html5/thumbnails/2.jpg)
A
C
B
FE
I
G
D
H
J
RouterPC
HUB
RouterPC
HUB
RouterPC
HUB
RouterPC
HUB
RouterPC
HUB
Router PC
HUB
Router PC
HUB
Router PC
HUB
Router PC
HUB
Router PC
HUB
SWITCH
Classroom Layout
![Page 3: Static Routing Exercise u Unix network interface configuration u Cisco network interface configuration u Static routes u Default route u Testing.](https://reader036.fdocuments.net/reader036/viewer/2022082517/56649e425503460f94b34960/html5/thumbnails/3.jpg)
A
C
B
FE
I
G
D
H
J
SWITCH
213.172.133.96/28
213.172.133.128/28
213.172.133.160/28
213.172.133.192/28
213.172.133.224/28
213.172.133.112/28
213.172.133.144/28
213.172.133.176/28
213.172.133.208/28
213.172.133.240/28
Address Allocation
213.
172.
133.
16/2
8
.17
.19
.21
.23
.25
.18
.20
.22
.24
.26
![Page 4: Static Routing Exercise u Unix network interface configuration u Cisco network interface configuration u Static routes u Default route u Testing.](https://reader036.fdocuments.net/reader036/viewer/2022082517/56649e425503460f94b34960/html5/thumbnails/4.jpg)
Address Allocation
You already have an IP address for your router’s backbone link (A=.17, B=.18, …)
You have a /28 for your local network (PC and router connected to hub)
Allocate your own host addresses from your local /28 network
![Page 5: Static Routing Exercise u Unix network interface configuration u Cisco network interface configuration u Static routes u Default route u Testing.](https://reader036.fdocuments.net/reader036/viewer/2022082517/56649e425503460f94b34960/html5/thumbnails/5.jpg)
Network interface configuration - FreeBSD
configure interface on Unix hostifconfig fxp0 inet n.n.n.n netmask m.m.m.m
– fxp0 is interface name– n.n.n.n is IP address– m.m.m.m is netmask
![Page 6: Static Routing Exercise u Unix network interface configuration u Cisco network interface configuration u Static routes u Default route u Testing.](https://reader036.fdocuments.net/reader036/viewer/2022082517/56649e425503460f94b34960/html5/thumbnails/6.jpg)
Connect PC to router console
Connect cable to console port on router, serial port on FreeBSD box
Use the tip command to connect your keyboard and screen to the serial port
You may have to edit /etc/remote See man pages for tip(1) and remote(5)
![Page 7: Static Routing Exercise u Unix network interface configuration u Cisco network interface configuration u Static routes u Default route u Testing.](https://reader036.fdocuments.net/reader036/viewer/2022082517/56649e425503460f94b34960/html5/thumbnails/7.jpg)
Network interface configuration - Cisco
configure backbone interface on cisco routerconf t
interface ethernet0/0
ip address n.n.n.n m.m.m.m
– ethernet0/0 is interface name– n.n.n.n is IP address– m.m.m.m is netmask
configure local interface on cisco router– ethernet0/1
![Page 8: Static Routing Exercise u Unix network interface configuration u Cisco network interface configuration u Static routes u Default route u Testing.](https://reader036.fdocuments.net/reader036/viewer/2022082517/56649e425503460f94b34960/html5/thumbnails/8.jpg)
Network interface configuration - Cisco
Cisco global config should always include:ip classless
ip subnet-zero
Cisco interface config should usually include:
no shutdown
no ip proxy-arp
no ip redirects
![Page 9: Static Routing Exercise u Unix network interface configuration u Cisco network interface configuration u Static routes u Default route u Testing.](https://reader036.fdocuments.net/reader036/viewer/2022082517/56649e425503460f94b34960/html5/thumbnails/9.jpg)
Test connectivity
PC can ping local interface of router Router can ping PC PC cannot ping backbone interface of
router Router can ping other routers PC cannot ping other routers or other PCs
![Page 10: Static Routing Exercise u Unix network interface configuration u Cisco network interface configuration u Static routes u Default route u Testing.](https://reader036.fdocuments.net/reader036/viewer/2022082517/56649e425503460f94b34960/html5/thumbnails/10.jpg)
Add default route
Add route on PCroute add default g.g.g.g
– g.g.g.g is IP address of gateway (which is on cisco router)
Display forwarding tablenetstat -f inet -rn
![Page 11: Static Routing Exercise u Unix network interface configuration u Cisco network interface configuration u Static routes u Default route u Testing.](https://reader036.fdocuments.net/reader036/viewer/2022082517/56649e425503460f94b34960/html5/thumbnails/11.jpg)
Test connectivity
All PCs can now reach backbone IP address of own row
Still can’t reach other rows– why?
![Page 12: Static Routing Exercise u Unix network interface configuration u Cisco network interface configuration u Static routes u Default route u Testing.](https://reader036.fdocuments.net/reader036/viewer/2022082517/56649e425503460f94b34960/html5/thumbnails/12.jpg)
Add static routes to other rows
On router, add static routes to other rows– next hop is backbone interface of other row’s
routerip route n.n.n.n m.m.m.m g.g.g.g
Repeat many times
![Page 13: Static Routing Exercise u Unix network interface configuration u Cisco network interface configuration u Static routes u Default route u Testing.](https://reader036.fdocuments.net/reader036/viewer/2022082517/56649e425503460f94b34960/html5/thumbnails/13.jpg)
Test connectivity
All routers can reach all PCs All PCs can reach all backbone IP
addresses All PCs can reach PCs in other rows Test with traceroute
![Page 14: Static Routing Exercise u Unix network interface configuration u Cisco network interface configuration u Static routes u Default route u Testing.](https://reader036.fdocuments.net/reader036/viewer/2022082517/56649e425503460f94b34960/html5/thumbnails/14.jpg)
Edit FreeBSD /etc/rc.conf
Don’t do this on classroom machines On production machines, add lines to
/etc/rc.conf to configure network on reboothostname="porcupine.tomato.example"
ifconfig_fxp0="inet 192.0.2.5 netmask 255.255.255.224"
defaultrouter="192.0.2.1"
See /etc/default/rc.conf for more information