配置文件:
拓扑图:
(1) net文件:
autostart = False
[localhost:7200]
workingdir = /home/chen/gns3workdir
udp = 10000
[[7200]]
image = /mnt/e/study/cisco/Cisco/Others/c7200/c7200-advipservicesk9-mz.124-2.T.bin
idlepc = 0x610eaf20
ghostios = True
[[ROUTER R5]]
console = 2006
slot1 = PA-4T+
s1/0 = R0 s1/0
s1/1 = R2 s1/1
x = -198.0
y = -112.0
[[ROUTER R0]]
console = 2000
f0/0 = NIO_udp:5004:127.0.0.1:5005
slot1 = PA-4T+
s1/0 = R5 s1/0
slot2 = PA-FE-TX
x = -384.0
y = -122.0
[localhost:7201]
workingdir = /home/chen/gns3workdir
udp = 10100
[[7200]]
image = /mnt/e/study/cisco/Cisco/Others/c7200/c7200-advipservicesk9-mz.124-2.T.bin
idlepc = 0x610eaf20
ghostios = True
[[ROUTER R2]]
console = 2002
slot1 = PA-4T+
s1/0 = R3 s1/0
s1/1 = R5 s1/1
slot2 = PA-FE-TX
x = -25.0
y = -126.0
hx = 27.0
hy = -27.0
[[ROUTER R3]]
console = 2003
f0/0 = NIO_udp:5006:127.0.0.1:5007
slot1 = PA-4T+
s1/0 = R2 s1/0
slot2 = PA-FE-TX
x = 163.0
y = -118.0
[GNS3-DATA]
[[Cloud C2]]
x = -499.5
y = 30.0
connections = R0:f0/0:nio_udp:5004:127.0.0.1:5005
[[Cloud C3]]
x = 157.5
y = 33.0
connections = R3:f0/0:nio_udp:5006:127.0.0.1:5007
[[NOTE 1]]
text = 172.16.4.4/24
x = 235.0
y = -25.0
rotate = 0
[[NOTE 2]]
text = 61.0.0.4/24
x = 132.0
y = -157.0
rotate = 0
[[NOTE 3]]
text = 172.16.1.1/24
x = -420.0
y = -42.0
rotate = 0
[[NOTE 4]]
text = 61.0.0.3/24
x = 13.0
y = -50.0
rotate = 0
[[NOTE 5]]
text = 218.30.1.3/24
x = -67.0
y = -170.0
rotate = 0
[[NOTE 6]]
text = 218.30.1.2/24
x = -189.0
y = -163.0
rotate = 0
[[NOTE 7]]
text = 202.96.134.2/24
x = -225.0
y = -40.0
rotate = 0
[[NOTE 8]]
text = 202.96.134.1/24
x = -384.0
y = -180.0
rotate = 0
(2)路由配置文件:
R0.cfg:
!
version 12.4
service timestamps debug datetime msec
service timestamps log datetime msec
no service password-encryption
!
hostname Router
!
boot-start-marker
boot-end-marker
!
no logging console
!
no aaa new-model
!
resource policy
!
ip subnet-zero
ip cef
!
!
no ip dhcp use vrf connected
!
!
no ip ips deny-action ips-interface
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
interface Tunnel0
ip address 172.16.14.1 255.255.255.0
tunnel source Serial1/0
tunnel destination 61.0.0.4
!
interface FastEthernet0/0
ip address 172.16.1.1 255.255.255.0
ip nat inside
ip virtual-reassembly
duplex half
!
interface Serial1/0
ip address 202.96.134.1 255.255.255.0
ip nat outside
ip virtual-reassembly
serial restart-delay 0
!
interface Serial1/1
no ip address
shutdown
serial restart-delay 0
!
interface Serial1/2
no ip address
shutdown
serial restart-delay 0
!
interface Serial1/3
no ip address
shutdown
serial restart-delay 0
!
interface FastEthernet2/0
no ip address
shutdown
duplex half
!
router rip
version 2
network 172.16.0.0
!
ip classless
ip route 0.0.0.0 0.0.0.0 Serial1/0
no ip http server
no ip http secure-server
!
!
ip nat inside source list 10 interface Serial1/0 overload
!
access-list 10 permit 172.16.1.0 0.0.0.255
!
!
!
!
control-plane
!
!
!
!
!
!
gatekeeper
shutdown
!
!
line con 0
stopbits 1
line aux 0
line vty 0 4
!
!
end
R2.cfg:
!
version 12.4
service timestamps debug datetime msec
service timestamps log datetime msec
no service password-encryption
!
hostname Router
!
boot-start-marker
boot-end-marker
!
no logging console
!
no aaa new-model
!
resource policy
!
ip subnet-zero
ip cef
!
!
no ip dhcp use vrf connected
!
!
no ip ips deny-action ips-interface
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
interface FastEthernet0/0
no ip address
shutdown
duplex half
!
interface Serial1/0
ip address 61.0.0.3 255.255.255.0
serial restart-delay 0
clock rate 64000
!
interface Serial1/1
ip address 218.30.1.3 255.255.255.0
serial restart-delay 0
clock rate 64000
!
interface Serial1/2
no ip address
shutdown
serial restart-delay 0
!
interface Serial1/3
no ip address
shutdown
serial restart-delay 0
!
interface FastEthernet2/0
no ip address
shutdown
duplex half
!
router rip
version 2
network 61.0.0.0
network 218.30.1.0
!
ip classless
no ip http server
no ip http secure-server
!
!
!
!
!
!
!
control-plane
!
!
!
!
!
!
gatekeeper
shutdown
!
!
line con 0
stopbits 1
line aux 0
line vty 0 4
!
!
end
-----------------------------------
R3.cfg:
-----------------------------------
!
version 12.4
service timestamps debug datetime msec
service timestamps log datetime msec
no service password-encryption
!
hostname Router
!
boot-start-marker
boot-end-marker
!
no logging console
!
no aaa new-model
!
resource policy
!
ip subnet-zero
ip cef
!
!
no ip dhcp use vrf connected
!
!
no ip ips deny-action ips-interface
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
interface Tunnel0
ip address 172.16.14.4 255.255.255.0
tunnel source Serial1/0
tunnel destination 202.96.134.1
!
interface FastEthernet0/0
ip address 172.16.4.4 255.255.255.0
ip nat inside
ip virtual-reassembly
duplex half
!
interface Serial1/0
ip address 61.0.0.4 255.255.255.0
ip nat outside
ip virtual-reassembly
serial restart-delay 0
!
interface Serial1/1
no ip address
shutdown
serial restart-delay 0
!
interface Serial1/2
no ip address
shutdown
serial restart-delay 0
!
interface Serial1/3
no ip address
shutdown
serial restart-delay 0
!
interface FastEthernet2/0
no ip address
shutdown
duplex half
!
router rip
version 2
network 172.16.0.0
!
ip classless
ip route 0.0.0.0 0.0.0.0 Serial1/0
no ip http server
no ip http secure-server
!
!
ip nat inside source list 10 interface Serial1/0 overload
!
access-list 10 permit 172.16.4.0 0.0.0.255
!
!
!
!
control-plane
!
!
!
!
!
!
gatekeeper
shutdown
!
!
line con 0
stopbits 1
line aux 0
line vty 0 4
!
!
end
------------------------------
R5.cfg:
-----------------------------
!
version 12.4
service timestamps debug datetime msec
service timestamps log datetime msec
no service password-encryption
!
hostname Router
!
boot-start-marker
boot-end-marker
!
no logging console
!
no aaa new-model
!
resource policy
!
ip subnet-zero
ip cef
!
!
no ip dhcp use vrf connected
!
!
no ip ips deny-action ips-interface
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
interface FastEthernet0/0
no ip address
shutdown
duplex half
!
interface Serial1/0
ip address 202.96.134.2 255.255.255.0
serial restart-delay 0
clock rate 64000
!
interface Serial1/1
ip address 218.30.1.2 255.255.255.0
serial restart-delay 0
clock rate 64000
!
interface Serial1/2
no ip address
shutdown
serial restart-delay 0
!
interface Serial1/3
no ip address
shutdown
serial restart-delay 0
!
router rip
version 2
network 202.96.134.0
network 218.30.1.0
no auto-summary
!
ip classless
no ip http server
no ip http secure-server
!
!
!
!
!
!
!
control-plane
!
!
!
!
!
!
gatekeeper
shutdown
!
!
line con 0
stopbits 1
line aux 0
line vty 0 4
!
!
end
-------------------------------------------------
结果:
----------------------------------------------------------------------------------------------------------