如下图,我在R1路由器上设置一条静态路由 ip route 200.1.1.0 255.255.255.0 100.1.1.2 实现R1的100网段可以ping通R2的200网段,
R2路由器上不做静态路由,所以192.168.100.0网段只可以ping到R1的100.1.1.1
这时我在R1做上nat端口复用
access-list 1 permit 192.168.100.0 0.0.0.255
ip nat source list 1 interface f1/0 overload
在R1的f0/0配置 ip nat inside 在f1/0配置 ip nat outside
这时如果用192.168.100. 0网段ping R2 IP地址应转化成100.1.1.1 因为R2的路由表有100.1.1.1
所以应该会ping通,可是为什么我就ping不通呢??请大家帮我排一下错.
模拟实验工具:模拟器:GNS3 0.8.2
IOS : 3600 Software (C3640-IK9O3S-M), Version 12.4(10)
模拟PC:vpcs
以下是R1的路由器配置:
R1#show running-config
Building configuration...
Current configuration : 864 bytes
!
version 12.4
service timestamps debug datetime msec
service timestamps log datetime msec
no service password-encryption
!
hostname R1
!
boot-start-marker
boot-end-marker
!
!
no aaa new-model
memory-size iomem 5
!
!
ip cef
no ip domain lookup
!
interface FastEthernet0/0
ip address 192.168.100.1 255.255.255.0
ip nat inside
ip virtual-reassembly
duplex auto
speed auto
!
interface FastEthernet1/0
ip address 100.1.1.1 255.255.255.0
ip nat outside
ip virtual-reassembly
duplex auto
speed auto
!
no ip http server
no ip http secure-server
!
ip route 200.1.1.0 255.255.255.0 100.1.1.2
!
ip nat source list 1 interface FastEthernet1/0 overload
!
access-list 1 permit 192.168.100.0 0.0.0.255
!
control-plane
!
line con 0
exec-timeout 0 0
logging synchronous
line aux 0
line vty 0 4
!
end
111.bmp
(1.21 MB)
2012-9-11 15:21
本帖最后由 小侠唐在飞 于 2012-9-12 10:47 编辑
分享至: