雏鹰部落

 找回密码
 立即注册

QQ登录

只需一步,快速开始

搜索
查看: 3643|回复: 5

[讨论/求助] 双向NAT如何做?

[复制链接]
发表于 2010-7-8 11:40:57 | 显示全部楼层 |阅读模式
R1#Building configuration...
Current configuration : 867 bytes
!
version 12.4
service password-encryption
!
hostname Router
!
!
!
!
!
ip ssh version 1
no ip domain-lookup
!
!
interface FastEthernet0/0
ip address 192.168.1.1 255.255.255.0
ip nat inside
duplex auto
speed auto
!
interface FastEthernet0/1
no ip address
duplex auto
speed auto
shutdown
!
interface Serial1/0
ip address 192.168.2.1 255.255.255.0
ip nat outside
clock rate 64000
!
interface Serial1/1
no ip address
shutdown
!
interface Serial1/2
no ip address
shutdown
!
interface Serial1/3
no ip address
shutdown
!
interface Vlan1
no ip address
shutdown
!
ip nat pool qin 192.168.2.10 192.168.2.20 netmask 255.255.255.0
ip nat inside source list 1 pool qin overload
ip classless
ip route 0.0.0.0 0.0.0.0 192.168.2.2
!
!
access-list 1 permit 192.168.1.0 0.0.0.255
!
!
!
line con 0
exec-timeout 0 0
logging synchronous
line vty 0 4
login
!
!
end




R2#Building configuration...
Current configuration : 795 bytes
!
version 12.4
no service password-encryption
!
hostname Router
!
!
!
!
!
ip ssh version 1
!
!
interface FastEthernet0/0
ip address 192.168.3.1 255.255.255.0
ip nat inside
duplex auto
speed auto
!
interface FastEthernet0/1
no ip address
duplex auto
speed auto
shutdown
!
interface Serial1/0
ip address 192.168.2.2 255.255.255.0
ip nat outside
!
interface Serial1/1
no ip address
shutdown
!
interface Serial1/2
no ip address
shutdown
!
interface Serial1/3
no ip address
shutdown
!
interface Vlan1
no ip address
shutdown
!
ip nat pool gang 192.168.2.40 192.168.2.50 netmask 255.255.255.0
ip nat inside source list 2 pool gang overload
ip classless
ip route 0.0.0.0 0.0.0.0 192.168.2.1
!
!
access-list 2 permit 192.168.3.0 0.0.0.255
!
!
!
line con 0
line vty 0 4
login
!
!
end
不懂这个实验要怎么做,请高手帮看看,谢谢

本帖子中包含更多资源

您需要 登录 才可以下载或查看,没有账号?立即注册

x
 楼主| 发表于 2010-7-8 15:11:55 | 显示全部楼层
补充一下路由器0为R1,另一个为R2
发表于 2010-7-8 15:30:59 | 显示全部楼层
请LZ描述一下你的需求和疑惑。
如果是说两台PCping不通,那是正常的,两边都配置了PAT,内网地址无法被外网所ping通。
发表于 2010-7-9 15:27:23 | 显示全部楼层
你的需求和疑惑
 楼主| 发表于 2010-7-12 17:42:40 | 显示全部楼层
其实题目不是这样的,我改了一下下,不知道会不会有影响原题是两个公司合并,老板叫你把两个公司连起来,可以直接访问,但两个公司的IP都一样,而你又不想去改,所以就得做双向NAT,就这样了
 楼主| 发表于 2010-7-12 17:43:48 | 显示全部楼层
回复 3# 林原静羽


    我描述了,你看下吧,谢谢啦
您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

QQ|熊猫同学技术论坛|小黑屋| 网络工程师论坛 ( 沪ICP备09076391 )

GMT+8, 2024-10-6 06:52 , Processed in 0.079637 second(s), 19 queries , Gzip On.

快速回复 返回顶部 返回列表