锐捷IPv6 NAT

实验环境

要求: IPv6终端有访问互联网LoopBack18-20.20.20.20地址需求,为此在R2路由器部署NAT-PT实现IPv6地址的动态转换,具体规划内网IPv6地址转换地址池为10.1.0.3-10.1.0.5,20.20.20.20转换为2005:20:20:20::20

 R1配置

interface GigabitEthernet 0/0
 ip address 10.0.1.1 255.255.255.248
!
interface Loopback 0
 ip address 1.1.1.1 255.255.255.255
!
interface Loopback 18
 ip address 20.20.20.20 255.255.255.255

R2配置!!!

interface GigabitEthernet 0/0
 ip address 10.0.1.2 255.255.255.248
 ipv6 nat
!
interface GigabitEthernet 0/1
 ip ospf network point-to-point
 ip address 10.0.0.1 255.255.255.252
 ipv6 address 2006:10:1::1/64
 ipv6 enable
 ipv6 ospf network point-to-point
 ipv6 ospf 21 area 0
 ipv6 nat
!
interface Loopback 0
 ip address 2.2.2.2 255.255.255.255
!
ipv6 access-list ipv6acl
 10 permit ipv6 2006:10:1::/64 any 
!
ipv6 route ::/0 GigabitEthernet 0/0       ---默认路由指向出接口,若没有此默认无法通信
!
!
ipv6 router ospf 21
 default-information originate metric-type 1   ---要想内网客户可以访问IPv6互联网,就要下发默认路由
!
ipv6 nat prefix 2005:20:20:20::/96      ---匹配目的地址前缀
ipv6 nat v6v4 pool v6pool 10.0.1.3 10.0.1.5 prefix-length 29
ipv6 nat v6v4 source list ipv6acl pool v6pool overload
ipv6 nat v4v6 source 20.20.20.20 2005:20:20:20::20
!
router ospf 20
 network 2.2.2.2 0.0.0.0 area 0
 network 10.0.0.1 0.0.0.0 area 0
 default-information originate metric-type 1    ---
!
ip route 0.0.0.0 0.0.0.0 10.0.1.1     ---IPv6可以通的前提是出口路由器IPv4可以通信

R3配置

interface GigabitEthernet 0/0
 ip ospf network point-to-point
 ip address 10.0.0.2 255.255.255.252
 ipv6 address 2006:10:1::2/64
 ipv6 enable
 ipv6 ospf network point-to-point
 ipv6 ospf 21 area 0
!
interface Loopback 0
 ip address 3.3.3.3 255.255.255.255
!
router ospf 20
 network 3.3.3.3 0.0.0.0 area 0
 network 10.0.0.2 0.0.0.0 area 0

路由表

R2

 

R3 

 

 成果验证

 

作者声明:实验仅供参考娱乐,一切责任行为与本人无关 
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值