GN3模拟主机

R1#conf t

Enter configuration commands, one per line.  End with CNTL/Z.
R1(config)#int f0/0
R1(config-if)#no shutdown 
R1(config-if)#ip address 192.168.1.254 255.255.255.0
R1(config-if)#end
R1#
R1#conf t
Enter configuration commands, one per line.  End with CNTL/Z.
R1(config)#int f1/0
R1(config-if)#no shutdown 
R1(config-if)#ip address 192.168.2.254 255.255.255.0
R1(config-if)#end
R1#
*Mar  1 00:03:39.059: %SYS-5-CONFIG_I: Configured from console by console
R1#show ip int brief 
Interface                  IP-Address      OK? Method Status                Protocol
FastEthernet0/0            192.168.1.254   YES manual up                    up      
FastEthernet1/0            192.168.2.254   YES manual up                    up      

R1#

PC1端配置:

PC1#show version 

Cisco Internetwork Operating System Software 
IOS (tm) 3600 Software (C3640-JK9S-M), Version 12.3(20), RELEASE SOFTWARE (fc2)
Technical Support: http://www.cisco.com/techsupport
Copyright (c) 1986-2006 by cisco Systems, Inc.
Compiled Tue 08-Aug-06 16:37 by kesnyder

Image text-base: 0x60008B00, data-base: 0x620DC000

关闭路由镜像:

PC1#conf t
Enter configuration commands, one per line.  End with CNTL/Z.

PC1(config)#no ip routing 

PC1(config)#int f0/0
PC1(config-if)#no shutdown
*Mar  1 00:10:25.811: %LINK-3-UPDOWN: Interface FastEthernet0/0, changed state to up
*Mar  1 00:10:26.811: %LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/0, changed state to up
PC1(config-if)#ip address 192.168.1.1 255.255.255.0

PC1(config-if)#end

PC1#conf t
Enter configuration commands, one per line.  End with CNTL/Z.
PC1(config)#ip default-gateway 192.168.1.254
PC1(config)#end
PC1#show ip route 
Default gateway is 192.168.1.254
Host               Gateway           Last Use    Total Uses  Interface
ICMP redirect cache is empty


PC2#conf t
Enter configuration commands, one per line.  End with CNTL/Z.
PC2(config)#no ip routing
PC2(config)#int f0/0
PC2(config-if)#no shutdown 
*Mar  1 00:13:57.919: %LINK-3-UPDOWN: Interface FastEthernet0/0, changed state to up
*Mar  1 00:13:58.919: %LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/0, changed state to up
PC2(config-if)#ip address 192.168.2.1 255.255.255.0
PC2(config-if)#end
PC2#
*Mar  1 00:14:13.179: %SYS-5-CONFIG_I: Configured from console by console


PC2#conf t

Enter configuration commands, one per line.  End with CNTL/Z.
PC2(config)#ip default-gateway 192.168.2.254
PC2(config)#end
PC2#show ip route 
Default gateway is 192.168.2.254
Host               Gateway           Last Use    Total Uses  Interface

ICMP redirect cache is empty

验证:

PC2#ping 192.168.1.1

Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 192.168.1.1, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 40/306/1372 ms

PC2#ping 192.168.1.254
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 192.168.1.254, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 20/978/1700 ms

相关文章: