用 Cisco 路由器和 Microsoft Windows PC 排除 IPv6 动态地址分配故障 目录 简介先决条件要求使用的组件背景信息 IPv6 动态地址分配的方法 SLAAC 排除 SLAAC 故障从 Cisco IOS 从 Microsoft Windows PC 无状态的 DHCPv6 在 Cisco IOS 配置示例的 DHCPv6 无状态的服务器从 Cisco IOS 从微软视窗有状态的 DHCPv6 在 Cisco IOS 配置示例的 DHCPv6 有状态的服务器从 Cisco IOS 从微软视窗功能失效 Windows 随机地生成的接口 ID 功能失效 Windows 临时 IPv6 地址相关信息 简介 本文描述动态 IPv6 地址分配的可用的选项 排除故障无状态的地址自动配置 (SLAAC), 并且动态主机配置协议版本 6 (DHCPv6) 报道 先决条件 要求 Cisco 建议您了解以下主题 : IPv6 地址体系结构 操作系统的微软视窗 基本的 Wireshark 使用方法 使用的组件
本文的信息根据此硬件 / 软件版本 : 有 Cisco IOS 的 Cisco 路由器 微软视窗 7 PC 本文档中的信息都是基于特定实验室环境中的设备编写的 本文档中使用的所有设备最初均采用原始 ( 默认 ) 配置 如果您的网络实际, 请保证您了解所有命令的潜在影响 背景信息 IPv6 终端主机类似管理微软视窗的计算机和膝上型计算机能面对 IPv6 地址没有动态地收到也没有显示正如所料的情况 被建议排除 Cisco IOS 故障, 并且微软视窗操作系统对保证正确的配置到位 Note: 不同的操作系统能不同运行 这在 IPv6 如何取决于实现用他们的代码 本文打算提供读者在微软视窗是必需的配置的示例对于 IPv6 在微软视窗的配置在本文提交了在实验室里测试了并且被发现工作正如所料 Cisco 技术支持中心 (TAC) 不支持微软视窗配置帮助 IPv6 动态地址分配的方法 SLAAC 无状态的 DHCPv6 有状态的 DHCPv6 SLAAC 是本地 IPv6 使用的方法动态地提供终端主机 IPv6 地址和默认网关信息 它使用互联网控制消息协议版本 6 (ICMPv6) 信息包 ICMPv6 路由器垦请 (RS) 和 ICMPv6 路由器通告 (RA) 信息包被交换在 IPv6 可用的路由器 路由器周期地发送 RA 信息包 ( 默认情况下在 Cisco IOS 的每 200 秒 ) 到发送一个 RS 信息据要求 当接收到 RA 信息包后, 终端主机必须派生 IPv6 地址 ( 通过使用 EUI-64 主机部分的方法关 无状态的 DHCPv6 用于得到更多的配置参数 ( 没提供由 SLAAC) 类似 DNS 域名等等 DHCPv6 有状态的数据库能提供 IPv6 地址给终端主机和记录被出租的地址 信息类似 DNS, 域名等等, 可能用 DHCPv6 有状态的方法也提供 一旦发送在本地网络的 RA 信息包必须由路由器仍然提供默认网关信息 此选项最类似于 IPv4 的 DHCP Note: 唯一方法终端主机能动态地得到 IPv6 默认网关信息是从本地路由器产生的 ICMPv6 路由器通告 (RA) 信息包 DHCPv6 信息包当前不传播任何 IPv6 默认网关信息 SLAAC 在路由器和终端主机之间的信息包交换其次显示 : 步骤 1. 终端主机最初发送 ICMPv6 RS 信息包 步骤 2. 与 ICMPv6 RA 信息包的路由器再放
为了看到交换, 请运行在计算机的自由和开放源信息包分析程序 Wireshark 并且请使用这些过滤器 : ICMPv6 RS icmpv6.type == 133 ICMPv6 RA icmpv6.nd.ra.flag
终端主机必须派生根据信息和默认网关信息的 IPv6 地址包含在收到的 ICMPv6 RA 信息包 ICMPv6 RA 信息包示例获得与 Wireshark : Frame 187: 118 bytes on wire (944 bits), 118 bytes captured (944 bits) on interface 0 Ethernet II, Src: ca:01:b9:f0:00:08 (ca:01:b9:f0:00:08), Dst: IPv6mcast_01 (33:33:00:00:00:01) Internet Protocol Version 6, Src: fe80::c801:b9ff:fef0:8, Dst: ff02::1! Default Gateway. Internet Control Message Protocol v6 Type: Router Advertisement (134) Code: 0 Checksum: 0x4ce1 [correct] Cur hop limit: 64 Flags: 0x00 Router lifetime (s): 1800 Reachable time (ms): 0 Retrans timer (ms): 0 ICMPv6 Option (Source link-layer address : ca:01:b9:f0:00:08) ICMPv6 Option (MTU : 1500)
ICMPv6 Option (Prefix information : 2001:abcd::/64)! Prefix information. 1) ICMPv6 选项 ( 前缀信息 ) 字段 这是他们的 IPv6 地址的网络部分的终端主机使用的前缀信息 使用 EUI-64 方法的接口标识 ( 主机部分 ) 在结束时是被创建的主机 微软视窗能随机地创建主机部分 2) 互联网协议版本 6, Source 字段 终端主机使用 RA 信息包的 IPv6 源地址配置其 IPv6 默认网关 排除 SLAAC 故障 从 Cisco IOS Step1 保证 IPv6 单播路由命令从全局配置模式被配置 第 2. 步 保证在本地网络的接口配置有一个有效 IPv6 地址 ipv6 unicast-routing! Enable IPv6 Routing. In absence of this command!! the Router does not send any ICMPv6 RA packet. interface GigabitEthernet0/0/0 ipv6 address 2001:ABCD::1/64 end 第 3. 步 保证在 ICMPv6 RA 信息包做通告的前缀是前缀长度 /64 否则, 终端主机不能通过 SLAAC 创建任何 IPv6 地址 : ipv6 unicast-routing! interface GigabitEthernet0/0/0 ipv6 address 2001:ABCD::1/64 end ICMPv6 RA 信息包获取 :! Prefix length defined as /64 on the Router. ipv6 unicast-routing! interface GigabitEthernet0/0/0 ipv6 address 2001:ABCD::1/64! Prefix length defined as /64 on the Router. end 第 4. 步 debug 命令 IPv6 nd 在实时显示 ICMPv6 RS 信息包和 ICMPv6 RA 的通告的接收在本地网络的 Router# debug ipv6 nd ICMP Neighbor Discovery events debugging is on Router# Router# show logging include RS ICMPv6-ND: Received RS on GigabitEthernet0/0/0 from FE80::5850:6D61:1FB:EF3A R1#
Router# show logging include RA ICMPv6-ND: Sending solicited RA on GigabitEthernet0/0/0 ICMPv6-ND: Request to send RA for FE80::C801:EFFF:FE5A:8 ICMPv6-ND: Setup RA from FE80::C801:EFFF:FE5A:8 to FF02::1 on GigabitEthernet0/0/0 Router# 从 Microsoft Windows PC Step1 保证终端主机收到 RA 信息包 这可以执行与 Wireshark 和一个捕获用 icmpv6.nd.ra.flag 过滤器 第 2. 步 请使用 ipconfig 命令验证 IPv6 地址 如果 IPv6 地址仍然没有显示, 请遵从以下步骤 第 3. 步 保证网络适配器有互联网协议在 Windows 计算机激活的版本 6 (TCP/IPv6) 复选框
在 Windows, 您能找到此配置这里 : 步骤 1. 连接对 Control Panel > Network 和共享中心 > 更改适配器设置 步骤 2. 用鼠标右键单击在您的选择 >Properties 的网络适配器 网络适配器没有 6 (TCP/IPv6) 被启用的互联网协议版本, 当您收到在 Windows Prompt 命令 (CMD) 时的下个消息与 netsh 命令接口 IPv6 show interface 本地区域的连接 Note: 在此命令, 您能替换与网络适配器微软视窗用途的名字的本地区域的连接连接到网络 提示 : 打开 Prompt 命令 按在您的打开运行机箱的关键董事会的 Windows + R 运行 cmd 命令并且按 OK
第 3. 步 保证路由器发现参数设置对启用 运行 netsh 命令接口 IPv6 show interface 本地区域的连接 在 CMD 当设置路由器发现参数失效时, 微软视窗能忽略收到的 ICMPv6 RA 信息包的内容 这能造成微软视窗不生成任何 IPv6 地址 请使用此命令对对 enable (event) 路由器发现 : C:\> netsh interface ipv6 set interface "Local Area Connection" routerdiscovery=enabled 第 4. 步 保证通告的参数设置失效
运行 netsh 命令接口 IPv6 show interface 本地区域的连接 在 CMD 如果通告的参数设置对启用, 微软视窗能忽略收到的 ICMPv6 RA 信息包的内容 通告的参数被启用的原因微软视窗正常运行作为 IPv6 路由器, 生成并且发送其自己的 ICMPv6 RA 信息包到本地网络 通告的参数的默认状态一定是失效的 请使用此命令禁用做通告 : C:\> netsh interface ipv6 set interface "Local Area Connection" advertise=disabled 无状态的 DHCPv6 终端主机能请求另外的 IPv6 配置参数类似 DNS, 域名等等, 与无状态的使用 DHCPv6 对于此, ICMPv6 RA 信息包必须有 (O 位 ) 设置的另一个配置标志位 当 ipv6 nd other-config-flag 命令是存在 Cisco IOS 接口配置模式下时, 路由器设置 O 标志位
Router# interface GigabitEthernet0/0/0 ipv6 address 2001:ABCD::1/64 ipv6 nd other-config-flag! 如镜像所显示, 在路由器和终端主机之间的信息包交换发生 步骤 1. 终端主机最初发送 ICMPv6 RS 步骤 2. 与 ICMPv6 RA 的路由器再放和包括 O 标志设置步骤 3. 终端主机发送 DHCPv6 Information-request 步骤 4. 与 DHCPv6 回复的路由器再放与其他配置标志设置信息包获取的 ICMPv6 RA : Frame 9: 118 bytes on wire (944 bits), 118 bytes captured (944 bits) on interface 0 Ethernet II, Src: ca:01:b9:f0:00:08 (ca:01:b9:f0:00:08), Dst: IPv6mcast_01 (33:33:00:00:00:01) Internet Protocol Version 6, Src: fe80::c801:b9ff:fef0:8, Dst: ff02::1 Internet Control Message Protocol v6 Type: Router Advertisement (134) Code: 0 Checksum: 0x4ca1 [correct] Cur hop limit: 64 Flags: 0x40 0...... = Managed address configuration: Not set.1..... = Other configuration: Set! Cisco IOS command ipv6 nd other-
config-flag sets the O flag..0.... = Home Agent: Not set...0 0... = Prf (Default Router Preference): Medium (0)....0.. = Proxy: Not set.....0. = Reserved: 0 Router lifetime (s): 1800 Reachable time (ms): 0 Retrans timer (ms): 0 ICMPv6 Option (Source link-layer address : ca:01:b9:f0:00:08) ICMPv6 Option (MTU : 1500) ICMPv6 Option (Prefix information : 2001:abcd::/64) 在 Wireshark, 请使用 dhcpv6 过滤器显示 DHCPv6 信息包交换 : Source Destination Protocol Length Info PC IPv6 link local ff02::1:2 DHCPv6 120 Information-request XID: 0x8018f9 CID: 000100011f3e8772000c29806ccc Frame 3884: 120 bytes on wire (960 bits), 120 bytes captured (960 bits) on interface 0 Ethernet II, Src: Vmware_80:6c:cc (00:0c:29:80:6c:cc), Dst: IPv6mcast_01:00:02 (33:33:00:01:00:02) Internet Protocol Version 6, Src: PC IPv6 link local (fe80::5850:6d61:1fb:ef3a), Dst: ff02::1:2 (ff02::1:2) User Datagram Protocol, Src Port: 546 (546), Dst Port: 547 (547) DHCPv6 Message type: Information-request (11) Transaction ID: 0x8018f9 Elapsed time Client Identifier Vendor Class Option Request Source Destination Protocol Length Info Router IPv6 link local PC IPv6 link local DHCPv6 136 Reply XID: 0x8018f9 CID: 000100011f3e8772000c29806ccc Frame 3887: 136 bytes on wire (1088 bits), 136 bytes captured (1088 bits) on interface 0 Ethernet II, Src: ca:01:b9:f0:00:08 (ca:01:b9:f0:00:08), Dst: Vmware_80:6c:cc (00:0c:29:80:6c:cc) Internet Protocol Version 6, Src: Router IPv6 link local (fe80::c801:b9ff:fef0:8), Dst: PC IPv6 link local (fe80::5850:6d61:1fb:ef3a) User Datagram Protocol, Src Port: 547 (547), Dst Port: 546 (546) DHCPv6 Message type: Reply (7) Transaction ID: 0x8018f9 Server Identifier Client Identifier DNS recursive name server Domain Search List 在 Cisco IOS 配置示例的 DHCPv6 无状态的服务器 从 Cisco IOS 此示例在 Cisco IOS 显示 DHCPv6 无状态的服务器的配置 Step1 从全局配置模式请运行命令 ipv6 dhcp pool NAME 第 2. 步 请使用 dns-server 和多曼 NAME 子命令定义被发送到终端主机通过 DHCPv6 的参数 步骤 3. 应用在 Interface Configuration 模式定义的池与命令 IPv6 dhcp 服务器名 步骤 4. 添加在 Interface Configuration 模式的命令 ipv6 nd other-config-flag ipv6 unicast-routing! ipv6 dhcp pool LAN_POOL dns-server 2001:4860:4860::8888 domain-name lab-test.net! interface GigabitEthernet0/0/0 ipv6 address 2001:ABCD::1/64 ipv6 nd other-config-flag! Sets the Other Configuration flag in the RA packet. ipv6 dhcp server LAN_POOL! 为了验证在 Cisco IOS 的配置是正确的, 使用这些命令 :
第 1. 步显示 ipv6 dhcp pool 必须确认在配置运用的参数 第 2. 步显示 IPv6 dhcp 捆绑不能显示任何信息, 因为无状态的 DHCPv6 不记录 IPv6 客户端 第 3. 步显示 IPv6 dhcp interface 必须显示池被应用于在本地网络的接口 Router#show ipv6 dhcp pool DHCPv6 pool: LAN_POOL DNS server: 2001:4860:4860::8888 Domain name: lab-test.net Active clients: 0! DHCPv6 Stateless does not keep track of IPv6 clients. Router# Router#show ipv6 dhcp binding Router# Router#show ipv6 dhcp interface FastEthernet0/0 is in server mode Using pool: LAN_POOL Preference value: 0 Hint from client: ignored Rapid-Commit: disabled Router# debug 命令 IPv6 dhcp 必须显示在路由器和终端主机之间的消息交换 : Router#debug ipv6 dhcp IPv6 DHCP debugging is on IPv6 DHCP: Received INFORMATION-REQUEST from FE80::5850:6D61:1FB:EF3A on FastEthernet0/0 IPv6 DHCP: Option VENDOR-CLASS(16) is not processed IPv6 DHCP: Using interface pool LAN_POOL IPv6 DHCP: Source Address from SAS FE80::C801:B9FF:FEF0:8 IPv6 DHCP: Sending REPLY to FE80::5850:6D61:1FB:EF3A on FastEthernet0/0 Router# 从微软视窗 从 prompt 命令, 请运行 ipconfig 命令 /all 保证微软视窗接受了 DNS 服务器信息和域名 : C:\Users\ >ipconfig /all Windows IP Configuration Host Name............ : MY-LAPTOP Primary Dns Suffix....... : Node Type............ : Hybrid IP Routing Enabled........ : No WINS Proxy Enabled........ : No DNS Suffix Search List...... : lab-test.net Ethernet adapter Local Area Connection: Connection-specific DNS Suffix. : lab-test.net Description........... : Intel(R) PRO/1000 MT Network Connection Physical Address......... : 00-0C-29-80-6C-CC DHCP Enabled........... : No Autoconfiguration Enabled.... : Yes IPv6 Address........... : 2001:abcd::5850:6d61:1fb:ef3a(Preferred) Temporary IPv6 Address...... : 2001:abcd::7151:b553:1a0a:80bb(Preferred)
Link-local IPv6 Address..... : fe80::5850:6d61:1fb:ef3a%11(preferred) Default Gateway......... : fe80::c801:b9ff:fef0:8%11 DHCPv6 IAID........... : 234884137 DHCPv6 Client DUID........ : 00-01-00-01-1F-3E-87-72-00-0C-29-80-6C-CC DNS Servers........... : 2001:4860:4860::8888 NetBIOS over Tcpip........ : Disabled Connection-specific DNS Suffix Search List : lab-test.net C:\Users\ > 有状态的 DHCPv6 终端主机能请求 IPv6 地址和另外的参数与有状态的使用 DHCPv6 对于此, ICMPv6 RA 信息包必须有被管理的地址配置标志位 (M 标志位 ) 设置 当 IPv6 nd 管理设置标志位命令是存在 Cisco IOS 接口配置模式下时, 路由器设置 M 标志位 Router# interface GigabitEthernet0/0/0 ipv6 address 2001:ABCD::1/64 ipv6 nd managed-config-flag! 如镜像所显示, 在路由器和终端主机之间的信息包交换发生
步骤 1. 终端主机最初发送 ICMPv6 RS 步骤 2. 与 ICMPv6 RA 的路由器再放与 M 标志设置 步骤 3. 终端主机发送 DHCPv6 请求 步骤 4. 与 DHCPv6 的路由器再放做通告 步骤 5. 终端主机发送 DHCPv6 请求 步骤 6. 与 DHCPv6 回复的路由器再放 与管理的地址配置标志设置信息包获取的 ICMPv6 RA : Frame 1190: 118 bytes on wire (944 bits), 118 bytes captured (944 bits) on interface 0
Ethernet II, Src: ca:01:b9:f0:00:08 (ca:01:b9:f0:00:08), Dst: IPv6mcast_01 (33:33:00:00:00:01) Internet Protocol Version 6, Src: Router IPv6 link local (fe80::c801:b9ff:fef0:8), Dst: ff02::1 (ff02::1) Internet Control Message Protocol v6 Type: Router Advertisement (134) Code: 0 Checksum: 0x0642 [correct] Cur hop limit: 64 Flags: 0x80 1...... = Managed address configuration: Set.0..... = Other configuration: Not set..0.... = Home Agent: Not set...0 0... = Prf (Default Router Preference): Medium (0)....0.. = Proxy: Not set.....0. = Reserved: 0 Router lifetime (s): 1800 Reachable time (ms): 0 Retrans timer (ms): 0 ICMPv6 Option (Source link-layer address : ca:01:b9:f0:00:08) ICMPv6 Option (MTU : 1500) ICMPv6 Option (Prefix information : 2001:abcd::/64) Type: Prefix information (3) Length: 4 (32 bytes) Prefix Length: 64 Flag: 0x80 1...... = On-link flag(l): Set.0..... = Autonomous address-configuration flag(a): Not set..0.... = Router address flag(r): Not set...0 0000 = Reserved: 0 Valid Lifetime: 1800 Preferred Lifetime: 1800 Reserved Prefix: 2001:abcd:: (2001:abcd::) 在 Wireshark, 请使用 dhcpv6 过滤器显示 DHCPv6 信息包交换 : Source Destination Protocol Length Info PC IPv6 link local ff02::1:2 DHCPv6 157 Solicit XID: 0x328090 CID: 000100011f3e8772000c29806ccc Frame 965: 157 bytes on wire (1256 bits), 157 bytes captured (1256 bits) on interface 0 Ethernet II, Src: Vmware_80:6c:cc (00:0c:29:80:6c:cc), Dst: IPv6mcast_01:00:02 (33:33:00:01:00:02) Internet Protocol Version 6, Src: PC IPv6 link local (fe80::5850:6d61:1fb:ef3a), Dst: ff02::1:2 (ff02::1:2) User Datagram Protocol, Src Port: 546 (546), Dst Port: 547 (547) DHCPv6 Message type: Solicit (1) Transaction ID: 0x328090 Elapsed time Client Identifier Identity Association for Non-temporary Address Fully Qualified Domain Name Vendor Class Option Request Source Destination Protocol Length Info Router IPv6 link localpc IPv6 link local DHCPv6 180 Advertise XID: 0x328090 CID: 000100011f3e8772000c29806ccc IAA: 2001:abcd::70a1:36a7:3e72:fa95 Frame 966: 180 bytes on wire (1440 bits), 180 bytes captured (1440 bits) on interface 0 Ethernet II, Src: ca:01:b9:f0:00:08 (ca:01:b9:f0:00:08), Dst: Vmware_80:6c:cc (00:0c:29:80:6c:cc) Internet Protocol Version 6, Src: Router IPv6 link local (fe80::c801:b9ff:fef0:8), Dst: PC IPv6 link local (fe80::5850:6d61:1fb:ef3a) User Datagram Protocol, Src Port: 547 (547), Dst Port: 546 (546) DHCPv6 Message type: Advertise (2) Transaction ID: 0x328090 Server Identifier Client Identifier Identity Association for Non-temporary Address
DNS recursive name server Domain Search List Source Destination Protocol Length Info PC IPv6 link local ff02::1:2 DHCPv6 199 Request XID: 0x328090 CID: 000100011f3e8772000c29806ccc IAA: 2001:abcd::70a1:36a7:3e72:fa95 Frame 967: 199 bytes on wire (1592 bits), 199 bytes captured (1592 bits) on interface 0 Ethernet II, Src: Vmware_80:6c:cc (00:0c:29:80:6c:cc), Dst: IPv6mcast_01:00:02 (33:33:00:01:00:02) Internet Protocol Version 6, Src: PC IPv6 link local (fe80::5850:6d61:1fb:ef3a), Dst: ff02::1:2 (ff02::1:2) User Datagram Protocol, Src Port: 546 (546), Dst Port: 547 (547) DHCPv6 Message type: Request (3) Transaction ID: 0x328090 Elapsed time Client Identifier Server Identifier Identity Association for Non-temporary Address Fully Qualified Domain Name Vendor Class Option Request Source Destination Protocol Length Info Router IPv6 link localpc IPv6 link local DHCPv6 180 Reply XID: 0x328090 CID: 000100011f3e8772000c29806ccc IAA: 2001:abcd::70a1:36a7:3e72:fa95 Frame 968: 180 bytes on wire (1440 bits), 180 bytes captured (1440 bits) on interface 0 Ethernet II, Src: ca:01:b9:f0:00:08 (ca:01:b9:f0:00:08), Dst: Vmware_80:6c:cc (00:0c:29:80:6c:cc) Internet Protocol Version 6, Src: Router IPv6 link local (fe80::c801:b9ff:fef0:8), Dst: PC IPv6 link local (fe80::5850:6d61:1fb:ef3a) User Datagram Protocol, Src Port: 547 (547), Dst Port: 546 (546) DHCPv6 Message type: Reply (7) Transaction ID: 0x328090 Server Identifier Client Identifier Identity Association for Non-temporary Address DNS recursive name server Domain Search List 在 Cisco IOS 配置示例的 DHCPv6 有状态的服务器 从 Cisco IOS 此示例在 Cisco IOS 显示 DHCPv6 有状态的服务器的配置 Step1 从全局配置模式请运行命令 ipv6 dhcp pool NAME 第 2. 步 请使用地址前缀 dns-server 和多曼 NAME 子命令定义被发送到终端主机通过 DHCPv6 的参数 步骤 3. 应用在 Interface Configuration 模式定义的池与命令 IPv6 dhcp 服务器名 步骤 4. 添加在 Interface Configuration 模式的命令 IPv6 nd 管理设置标志位
步骤 5. 添加在 Interface Configuration 模式的命令 IPv6 nd 前缀默认 1800 1800 NO- 自动设定禁用自动地址配置 (A) 在 ICMPv6 RA 信息包的标志位 Note: 当您使用 DHCPv6 有状态的服务器方法时, 终端主机能为本身配置两个不同的 IPv6 地址 第一个与在 ICMPv6 RA 信息包包含的信息 第二个与在 DHCPv6 信息包包含的信息 要避免此, ICMPv6 RA 信息包能禁用 A 标志位指示终端主机不生成根据信息的 IPv6 地址包含在它 Note: 前缀信息可以从 ICMPv6 RA 信息包的内容被取消与在 Interface Configuration 模式的命令 IPv6 nd 前缀默认无广告 ipv6 unicast-routing!ipv6 dhcp pool LAN_POOL address prefix 2001:ABCD::/64! Includes the IPv6 prefix in the DHCPv6 packet exchange. dns-server 2001:4860:4860::8888 domain-name lab-test.net! interface GigabitEthernet0/0/0 ipv6 address 2001:ABCD::/64 eui-64 ipv6 nd prefix default 1800 1800 no-autoconfig! Disables the Autonomous addressconfiguration(a) flag in the ICMPv6 RA packet. ipv6 nd managed-config-flag! Sets the Managed address configuration flag in the ICMPv6 RA packet. ipv6 dhcp server LAN_POOL end 为了验证在 Cisco IOS 的配置是正确的, 使用这些命令 : 第 1. 步显示 ipv6 dhcp pool 必须确认在配置运用的参数 第 2. 步显示 IPv6 dhcp 捆绑必须 IPv6 地址信息被出租对终端主机 第 3. 步显示 IPv6 dhcp interface 必须显示池被应用于在本地网络的接口 Router#show ipv6 dhcp pool DHCPv6 pool: LAN_POOL Address allocation prefix: 2001:ABCD::/64 valid 172800 preferred 86400 (1 in use, 0 conflicts) DNS server: 2001:4860:4860::8888 Domain name: lab-test.net Active clients: 1 Router# Router#show ipv6 dhcp binding Client: FE80::5850:6D61:1FB:EF3A DUID: 000100011F3E8772000C29806CCC Username : unassigned IA NA: IA ID 0x0E000C29, T1 43200, T2 69120 Address: 2001:ABCD::3DD4:77BB:E035:9375 preferred lifetime 86400, valid lifetime 172800 expires at Dec 28 2016 10:44 PM (172488 seconds) Router# Router#show ipv6 dhcp interface FastEthernet0/0 is in server mode Using pool: LAN_POOL Preference value: 0
Hint from client: ignored Rapid-Commit: disabled Router# debug 命令 IPv6 dhcp 必须显示在路由器和终端主机之间的消息交换 : Router#debug ipv6 dhcp IPv6 DHCP debugging is on Router#IPv6 DHCP: Received SOLICIT from FE80::5850:6D61:1FB:EF3A on FastEthernet0/0 IPv6 DHCP: Option UNKNOWN(39) is not processed IPv6 DHCP: Option VENDOR-CLASS(16) is not processed IPv6 DHCP: Using interface pool LAN_POOL IPv6 DHCP: Creating binding for FE80::5850:6D61:1FB:EF3A in pool LAN_POOL IPv6 DHCP: Binding for IA_NA 0E000C29 not found IPv6 DHCP: Allocating IA_NA 0E000C29 in binding for FE80::5850:6D61:1FB:EF3A IPv6 DHCP: Looking up pool 2001:ABCD::/64 entry with username '000100011F3E8772000C29806CCC0E000C29' IPv6 DHCP: Poolentry for user not found IPv6 DHCP: Allocated new address 2001:ABCD::D9F7:61C:D803:DCF1 IPv6 DHCP: Allocating address 2001:ABCD::D9F7:61C:D803:DCF1 in binding for FE80::5850:6D61:1FB:EF3A, IAID 0E000C29 IPv6 DHCP: Updating binding address entry for address 2001:ABCD::D9F7:61C:D803:DCF1 IPv6 DHCP: Setting timer on 2001:ABCD::D9F7:61C:D803:DCF1 for 60 seconds IPv6 DHCP: Source Address from SAS FE80::C801:B9FF:FEF0:8 IPv6 DHCP: Sending ADVERTISE to FE80::5850:6D61:1FB:EF3A on FastEthernet0/0 IPv6 DHCP: Received REQUEST from FE80::5850:6D61:1FB:EF3A on FastEthernet0/0 IPv6 DHCP: Option UNKNOWN(39) is not processed IPv6 DHCP: Option VENDOR-CLASS(16) is not processed IPv6 DHCP: Using interface pool LAN_POOL IPv6 DHCP: Looking up pool 2001:ABCD::/64 entry with username '000100011F3E8772000C29806CCC0E000C29' IPv6 DHCP: Poolentry for user found IPv6 DHCP: Found address 2001:ABCD::D9F7:61C:D803:DCF1 in binding for FE80::5850:6D61:1FB:EF3A, IAID 0E000C29 IPv6 DHCP: Updating binding address entry for address 2001:ABCD::D9F7:61C:D803:DCF1 IPv6 DHCP: Setting timer on 2001:ABCD::D9F7:61C:D803:DCF1 for 172800 seconds IPv6 DHCP: Source Address from SAS FE80::C801:B9FF:FEF0:8 IPv6 DHCP: Sending REPLY to FE80::5850:6D61:1FB:EF3A on FastEthernet0/0 Router# 从微软视窗 运行 ipconfig 命令 /all 保证微软视窗接受了 IPv6 地址 默认网关 DNS 服务器信息和域名 : C:\Users\ >ipconfig /all Windows IP Configuration Host Name............ : MY-LAPTOP Primary Dns Suffix....... : Node Type............ : Hybrid IP Routing Enabled........ : No WINS Proxy Enabled........ : No DNS Suffix Search List...... : lab-test.net Ethernet adapter Local Area Connection: Connectionspecific DNS Suffix. : lab-test.net Description........... : Intel(R) PRO/1000 MT Network Connection Physical Address......... : 00-0C-29-80-6C-CC DHCP Enabled........... : No Autoconfiguration Enabled.... : Yes IPv6 Address........... : 2001:abcd::3dd4:77bb:e035:9375(Preferred) Lease Obtained.......... : Sunday, January 01, 2017 4:47:02 PM
Lease Expires.......... : Tuesday, January 03, 2017 4:47:02 PM Link-local IPv6 Address..... : fe80::5850:6d61:1fb:ef3a%11(preferred) Default Gateway......... : fe80::c801:b9ff:fef0:8%11 DHCPv6 IAID........... : 234884137 DHCPv6 Client DUID........ : 00-01-00-01-1F-3E-87-72-00-0C-29-80-6C-CC DNS Servers........... : 2001:4860:4860::8888 NetBIOS over Tcpip........ : Disabled Connection-specific DNS Suffix Search List : lab-test.net C:\Users\ > 禁用 Windows 随机地生成的接口 ID 默认情况下微软视窗生成自动配置的 IPv6 地址的随机的接口 ID ( 与 SLAAC) 而不是使用 EUI-64 方法 C:\Users\ >ipconfig Windows IP Configuration Ethernet adapter Local Area Connection: Connection-specific DNS Suffix. : IPv6 Address........... : 2001:abcd::5850:6d61:1fb:ef3a! Randomly generated interface ID. Temporary IPv6 Address...... : 2001:abcd::8d1:8bbb:14e4:658e Link-local IPv6 Address..... : fe80::5850:6d61:1fb:ef3a%11 Default Gateway......... : fe80::c801:b9ff:fef0:8%11 可以更改此工作情况做 Windows 使用 EUI-64 进程 netsh interface ipv6 set global randomizeidentifiers=disabled 您能当前看到看到接口 ID 生成了与使用 EUI-64 进程 C:\Users\ >ipconfigwindows IP Configuration Ethernet adapter Local Area Connection: Connection-specific DNS Suffix. : IPv6 Address........... : 2001:abcd::20c:29ff:fe80:6ccc! Interface ID now generated by EUI-64 method. Temporary IPv6 Address...... : 2001:abcd::9818:d729:fadb:8812 Link-local IPv6 Address..... : fe80::20c:29ff:fe80:6ccc%11 Default Gateway......... : fe80::c801:b9ff:fef0:8%11 要使用随机的接口 ID 进程您能再运行命令 : netsh interface ipv6 set global randomizeidentifiers=enabled 功能失效 Windows 临时 IPv6 地址 由于安全原因, Windows 能临时地创建 IPv6 地址和使用那些作为来源出局连接 这能创建在方案的混乱, 当所需的是时来源终端主机使用某一 IPv6 的地址通信喜欢, 当防火墙规则在网络时被定义 临时 IPv6 地址是由于 RFC 4941 的 Windows 实施 C:\Users\ >ipconfig
Windows IP Configuration Ethernet adapter Local Area Connection: Connection-specific DNS Suffix. : IPv6 Address........... : 2001:abcd::5850:6d61:1fb:ef3a Temporary IPv6 Address...... : 2001:abcd::8d1:8bbb:14e4:658e Link-local IPv6 Address..... : fe80::5850:6d61:1fb:ef3a%11 Default Gateway......... : fe80::c801:b9ff:fef0:8%11 C:\Users\ >netsh interface ipv6 show privacy Querying active state... Temporary Address Parameters --------------------------------------------- Use Temporary Addresses : enabled Duplicate Address Detection Attempts: 5 Maximum Valid Lifetime : 7d Maximum Preferred Lifetime : 1d Regenerate Time : 5s Maximum Random Time : 10m Random Time : 0s C:\Users\Gus> 要禁用临时 IPv6 地址的自动创建请运行命令 : C:\Users\ >ipconfig Windows IP Configuration Ethernet adapter Local Area Connection: Connection-specific DNS Suffix. : IPv6 Address........... : 2001:abcd::5850:6d61:1fb:ef3a Temporary IPv6 Address...... : 2001:abcd::8d1:8bbb:14e4:658e Link-local IPv6 Address..... : fe80::5850:6d61:1fb:ef3a%11 Default Gateway......... : fe80::c801:b9ff:fef0:8%11 C:\Users\ >netsh interface ipv6 show privacy Querying active state... Temporary Address Parameters --------------------------------------------- Use Temporary Addresses : enabled Duplicate Address Detection Attempts: 5 Maximum Valid Lifetime : 7d Maximum Preferred Lifetime : 1d Regenerate Time : 5s Maximum Random Time : 10m Random Time : 0s C:\Users\Gus> 当命令实施, 输出显示 : C:\Users\ >ipconfig Windows IP Configuration Ethernet adapter Local Area Connection: Connection-specific DNS Suffix. : IPv6 Address........... : 2001:abcd::5850:6d61:1fb:ef3a Link-local IPv6 Address..... : fe80::5850:6d61:1fb:ef3a%11 Default Gateway......... : fe80::c801:b9ff:fef0:8%11 C:\Users\ >netsh interface ipv6 show privacy Querying active state... Temporary Address Parameters ---------------------------------------------
Use Temporary Addresses : disabled Duplicate Address Detection Attempts: 5 Maximum Valid Lifetime : 7d Maximum Preferred Lifetime : 1d Regenerate Time : 5s Maximum Random Time : 10m Random Time : 0s 要使用临时 IPv6 地址您能再运行命令 : C:\Users\ >ipconfig Windows IP Configuration Ethernet adapter Local Area Connection: Connection-specific DNS Suffix. : IPv6 Address........... : 2001:abcd::5850:6d61:1fb:ef3a Link-local IPv6 Address..... : fe80::5850:6d61:1fb:ef3a%11 Default Gateway......... : fe80::c801:b9ff:fef0:8%11 C:\Users\ >netsh interface ipv6 show privacy Querying active state... Temporary Address Parameters --------------------------------------------- Use Temporary Addresses : disabled Duplicate Address Detection Attempts: 5 Maximum Valid Lifetime : 7d Maximum Preferred Lifetime : 1d Regenerate Time : 5s Maximum Random Time : 10m Random Time : 0s IPv6 动态地址分配比在 IPv4 的 DHCP 提供更多选项 认识主要配置点是必要的, 并且检查什么, 当进程不完成得正如所料 基本配置命令为此提供在 Cisco IOS 和微软视窗整体进程的一张完全视图的 相关信息 Cisco IOS IPv6 命令参考 使用得到 Windows 的工具 IPv6 配置信息