实验要求:
1、R1和R2之间使用静态IPV6地址互联
2、R2作为DHCPIPV6服务器给R3分配全球单薄地址
3、R4接口通过R2的RA进行无状态地址自动分配
4、配置静态路由,实现设备直接互访。
R1:
ipv6 #系统视图使设备能够处理IPV6报文
interface GigabitEthernet0/0/0
ipv6 enable
ipv6 address 2001::1/64
R2:
ipv6
interface GigabitEthernet0/0/0
ipv6 enable
ipv6 address 2001::2/64
interface GigabitEthernet0/0/1
ipv6 enable
ipv6 address 2002::2/64
interface GigabitEthernet0/0/2
ipv6 enable
ipv6 address 2003::2/64
q
dhcp enable
dhcpv6 pool pool1 #开启ipv6池和名字
address prefix 2002::/64 #开启的地址ipv6前缀
excluded-address 2002::2 #排除的ipv6地址
q
interface GigabitEthernet0/0/1
dhcpv6 server pool1 #调用pool1池
R3:
ipv6
dhcp enable
interface GigabitEthernet0/0/0
ipv6 enable
ipv6 address auto link-local
ipv6 address auto dhcp
#R4无状态配置
int g/0/0/2
undo ipv6 nd ra halt
interface GigabitEthernet0/0/0
ipv6 enable
ipv6 address auto global #开启无状态配置
```bash
配置静态路由:
R4:
ipv6 route-static 2001:: 64 2003::2
ipv6 route-static 2002:: 64 2003::2
R1:配置回包路由
ipv6 route-static 2002:: 15 2001::2 #15位包含2003段
R3:ipv6静态路由配置,:: 0 表示默认路由,g0/0/0 出接口, MAC表示下一跳地址接口MAC
ipv6 route-static :: 0 GigabitEthernet0/0/0 FE80::2E0:FCFF:FE6E:7C74