邻居发现 - ND
ND 允许同一链路上的不同设备向其邻居宣告自己的存在并了解其邻居的存在。ND 是 IPv6 中第 2 层地址解析的 IPv4 ARP 等效协议。
ND 默认启用。Cumulus Linux 提供了一组配置选项来支持 IPv6 网络并调整您的安全设置。
Cumulus Linux 提供了以下配置选项
- 路由器通告
- IPv6 前缀
- 递归 DNS 服务器
- DNS 搜索列表
- 家乡代理
- 邻居发现消息的 MTU
- 全局计时器设置
路由器通告
路由器通告默认禁用。要为接口启用路由器通告
cumulus@leaf01:mgmt:~$ nv set interface swp1 ip neighbor-discovery router-advertisement enable on
cumulus@leaf01:mgmt:~$ nv config apply
cumulus@leaf01:mgmt:~$ sudo vtysh
...
leaf01# configure terminal
leaf01(config)# interface swp1
leaf01(config-if)# no ipv6 nd suppress-ra
- 对于无状态地址自动配置 (SLAAC),您必须在接口上启用路由器通告。路由器通告中通告的前缀必须属于 /64 子网。
- 如果您在物理接口是带有 VLAN 的桥接一部分的网络中配置 IPv6 路由器通告,则必须在 VLAN 接口而不是物理接口上启用 IPv6 路由器通告。
您可以配置以下可选设置
- 允许连续的路由器通告数据包以高于每三秒一次的频率传输(快速重传)。您可以将此参数设置为
on
或off
。默认设置为on
。 - 设置路由器通告消息中通告的跳数限制值。您可以设置一个介于 0 到 255 之间的值。默认值为 64。
- 设置来自接口的未经请求的组播路由器通告之间的间隔。您可以设置一个介于 70 到 1800000 毫秒之间的值。默认值为 600000 毫秒。
- 设置路由器通告消息可以在路由上存在的最长时间。您可以设置一个介于 0 到 9000 秒之间的值。默认值为 1800 秒。
- 允许动态主机使用托管协议(例如 DHCPv6)自动配置 IP 地址(托管配置)。您可以将此参数设置为
on
或off
。默认情况下,此参数未设置。 - 允许动态主机使用托管协议通过 DHCPv6 配置其他信息。您可以将此参数设置为
on
或off
。默认情况下,此参数未设置。 - 设置 IPv6 节点可达的时间量。您可以设置一个介于 0 到 3600000 毫秒之间的值。默认值为 0。
- 设置邻居请求消息重新传输的间隔。您可以设置一个介于 0 到 4294967295 毫秒之间的值。默认值为 0。
- 允许主机使用路由器首选项来选择默认路由器。您可以设置 high、medium 或 low 值。默认值为 medium。
以下示例命令设置
- 路由器通告间隔为 60000 毫秒(60 秒)。
- 路由器首选项为 high。
- IPv6 节点可达的时间量为 3600000。
- 邻居请求消息重新传输的间隔为 4294967295。
- 路由器通告消息中的跳数限制值为 100。
- 路由器通告消息在路由上存在的最长时间为 4000。
cumulus@leaf01:mgmt:~$ nv set interface swp1 ip neighbor-discovery router-advertisement interval 60000
cumulus@leaf01:mgmt:~$ nv set interface swp1 ip neighbor-discovery router-advertisement router-preference high
cumulus@leaf01:mgmt:~$ nv set interface swp1 ip neighbor-discovery router-advertisement reachable-time 3600000
cumulus@leaf01:mgmt:~$ nv set interface swp1 ip neighbor-discovery router-advertisement retransmit-time 4294967295
cumulus@leaf01:mgmt:~$ nv set interface swp1 ip neighbor-discovery router-advertisement hop-limit 100
cumulus@leaf01:mgmt:~$ nv set interface swp1 ip neighbor-discovery router-advertisement lifetime 4000
cumulus@leaf01:mgmt:~$ nv config apply
cumulus@leaf01:mgmt:~$ sudo vtysh
...
leaf01# configure terminal
leaf01(config)# interface swp1
leaf01(config-if)# ipv6 nd ra-interval 60
leaf01(config-if)# ipv6 nd router-preference high
leaf01(config-if)# ipv6 nd reachable-time 3600000
leaf01(config-if)# ipv6 nd ra-retrans-interval 4294967295
leaf01(config-if)# ipv6 nd ra-hop-limit 100
leaf01(config-if)# ipv6 nd ra-lifetime 4000
leaf01(config-if)# end
leaf01# write memory
leaf01# exit
cumulus@leaf01:mgmt:~$
vtysh 命令将配置保存在 etc/frr/frr.conf
文件中
cumulus@leaf01:mgmt:~$ sudo cat etc/frr/frr.conf
...
interface swp1
ipv6 nd ra-hop-limit 100
ipv6 nd ra-interval 60
ipv6 nd ra-lifetime 4000
ipv6 nd ra-retrans-interval 4294967295
ipv6 nd reachable-time 3600000
ipv6 nd router-preference high
以下示例命令将快速重传设置为 off,并将托管配置设置为 on
cumulus@leaf01:mgmt:~$ nv set interface swp1 ip neighbor-discovery router-advertisement fast-retransmit off
cumulus@leaf01:mgmt:~$ nv set interface swp1 ip neighbor-discovery router-advertisement managed-config on
cumulus@leaf01:mgmt:~$ nv config apply
cumulus@leaf01:mgmt:~$ sudo vtysh
...
leaf01# configure terminal
leaf01(config)# interface swp1
leaf01(config-if)# ipv6 nd ra-fast-retrans
leaf01(config-if)# ipv6 nd managed-config-flag
leaf01(config-if)# end
leaf01# write memory
leaf01# exit
cumulus@leaf01:mgmt:~$
vtysh 命令将配置保存在 etc/frr/frr.conf
文件中
cumulus@leaf01:mgmt:~$ sudo cat etc/frr/frr.conf
...
interface swp1
ipv6 nd ra-fast-retrans
ipv6 nd managed-config-flag
IPv6 前缀
要配置 IPv6 前缀,您必须指定要包含在路由器通告中的 IPv6 前缀。此外,您可以配置以下可选设置
- 设置前缀对于链路本地确定有效的时长。您可以设置一个介于 0 到 4294967295 秒之间的值。默认值为 2592000。
- 设置从前缀生成的地址保持首选状态的时长。您可以设置一个介于 0 到 4294967295 秒之间的值。默认值为 604800。
- 启用通告,不对前缀的链路本地或非链路本地属性进行声明。默认情况下,此设置处于关闭状态。
- 启用指定的前缀以使用 IPv6 自动配置。默认情况下,此设置处于启用状态。
- 通过设置 R 标志,向本地链路上的主机指示指定的前缀包含完整的 IP 地址。默认情况下,此设置处于关闭状态。
以下示例命令将 IPv6 前缀设置为 2001:db8:1::100/32,将前缀对于链路本地确定有效的时长设置为 2000000000,并将从前缀生成的地址保持首选状态的时长设置为 1000000000。
cumulus@leaf01:mgmt:~$ nv set interface swp1 ip neighbor-discovery prefix 2001:db8:1::100/32 valid-lifetime 2000000000
cumulus@leaf01:mgmt:~$ nv set interface swp1 ip neighbor-discovery prefix 2001:db8:1::100/32 preferred-lifetime 1000000000
cumulus@leaf01:mgmt:~$ nv config apply
cumulus@leaf01:mgmt:~$ sudo vtysh
...
leaf01# configure terminal
leaf01(config)# interface swp1
leaf01(config-if)# ipv6 nd prefix 2001:db8:1::100/32 2000000000 1000000000
leaf01(config-if)# end
leaf01# write memory
leaf01# exit
cumulus@leaf01:mgmt:~$
vtysh 命令写入 /etc/frr/frr.conf
文件
cumulus@leaf01:mgmt:~$ sudo cat /etc/frr/frr.conf
...
interface swp1
ipv6 nd prefix 2001:db8::/32 2000000000 1000000000
...
以下示例命令将通告设置为不对前缀的链路本地或非链路本地属性进行声明,启用指定的前缀以使用 IPv6 自动配置,并通过设置 R 标志向本地链路上的主机指示指定的前缀包含完整的 IP 地址。具有 router-address on
的前缀必须是链路本地且可自动配置的。
cumulus@leaf01:mgmt:~$ nv set interface swp1 ip neighbor-discovery prefix 2001:db8:1::100/32 off-link off
cumulus@leaf01:mgmt:~$ nv set interface swp1 ip neighbor-discovery prefix 2001:db8:1::100/32 autoconfig on
cumulus@leaf01:mgmt:~$ nv set interface swp1 ip neighbor-discovery prefix 2001:db8:1::100/32 router-address on
cumulus@leaf01:mgmt:~$ nv config apply
cumulus@leaf01:mgmt:~$ sudo vtysh
...
leaf01# configure terminal
leaf01(config)# interface swp1
leaf01(config-if)# ipv6 nd prefix 2001:db8:1::100/32 router-address
leaf01(config-if)# end
leaf01# write memory
leaf01# exit
cumulus@leaf01:mgmt:~$
vtysh 命令写入 /etc/frr/frr.conf
文件
cumulus@leaf01:mgmt:~$ sudo cat /etc/frr/frr.conf
...
interface swp1
ipv6 nd prefix 2001:db8::/32 router-address
...
递归 DNS 服务器
要配置递归 DNS 服务器 (RDNSS),您必须指定要通告的每个 RDNSS 的 IPv6 地址。
一个可选参数允许您设置要将 RDNSS 用于域名解析的最长时间。您可以设置一个介于 0 到 4294967295 秒之间的值,或者使用关键字 infinite
将时间设置为永不过期。如果您将值设置为 0,则 Cumulus Linux 不再通告 RDNSS 地址。
以下示例命令将 RDNSS 地址设置为 2001:db8:1::100,并将生存时间设置为 infinite
cumulus@leaf01:mgmt:~$ nv set interface swp1 ip neighbor-discovery rdnss 2001:db8:1::100 lifetime infinite
cumulus@leaf01:mgmt:~$ nv config apply
cumulus@leaf01:mgmt:~$ sudo vtysh
...
leaf01# configure terminal
leaf01(config)# interface swp1
leaf01(config-if)# ipv6 nd rdnss 2001:db8:1::100 infinite
leaf01(config-if)# end
leaf01# write memory
leaf01# exit
cumulus@leaf01:mgmt:~$
vtysh 命令写入 /etc/frr/frr.conf
文件
cumulus@leaf01:mgmt:~$ sudo cat /etc/frr/frr.conf
...
interface swp1
ipv6 nd rdnss 2001:db8:1::100 infinite
...
DNS 搜索列表
要配置 DNS 搜索列表 (DNSSL),您必须指定要通告的域后缀。
一个可选参数允许您设置要将域后缀用于域名解析的最长时间。您可以设置一个介于 0 到 4294967295 秒之间的值,或者使用关键字 infinite
将时间设置为永不过期。如果您将值设置为 0,则主机不使用 DNSSL。
以下示例命令将域后缀设置为 accounting.nvidia.com
,并将要使用域后缀的最长时间设置为 infinite
cumulus@leaf01:mgmt:~$ nv set interface swp1 ip neighbor-discovery dnssl accounting.nvidia.com lifetime infinite
cumulus@leaf01:mgmt:~$ nv config apply
cumulus@leaf01:mgmt:~$ sudo vtysh
...
leaf01# configure terminal
leaf01(config)# interface swp1
leaf01(config-if)# ipv6 nd dnssl accounting.nvidia.com infinite
leaf01(config-if)# end
leaf01# write memory
leaf01# exit
cumulus@leaf01:mgmt:~$
vtysh 命令写入 /etc/frr/frr.conf
文件
cumulus@leaf01:mgmt:~$ sudo cat /etc/frr/frr.conf
...
interface swp1
ipv6 nd dnssl accounting.nvidia.com infinite
...
家乡代理
移动 IPv6 在路由器通告消息中定义了一个附加标志,指示通告路由器是否能够作为家乡代理。主链路上的每个家乡代理在发送路由器通告时都会设置此标志。
您可以使用以下设置将交换机配置为家乡代理
- 设置您希望路由器充当家乡代理的最长时间。您可以设置一个介于 0 到 65520 秒之间的值。默认值为 0(路由器不是家乡代理)。
- 设置家乡代理路由器首选项。您可以设置一个介于 0 到 65535 之间的值。默认值为 0(最低首选项)。
以下示例命令通过将路由器充当家乡代理的最长时间设置为 20000 秒并将路由器首选项设置为 100,将交换机配置为家乡代理
cumulus@leaf01:mgmt:~$ nv set interface swp1 ip neighbor-discovery home-agent preference 100
cumulus@leaf01:mgmt:~$ nv set interface swp1 ip neighbor-discovery home-agent lifetime 20000
cumulus@leaf01:mgmt:~$ nv config apply
当您运行上述命令时,除了 ipv6 nd home-agent-preference
和 ipv6 nd home-agent-lifetime
行之外,NVUE 还在 /etc/network/interfaces
文件中的接口 stanza 下添加了 ipv6 nd home-agent-config-flag
行。
cumulus@leaf01:mgmt:~$ sudo vtysh
...
leaf01# configure terminal
leaf01(config)# interface swp1
leaf01(config-if)# ipv6 nd home-agent-config-flag
leaf01(config-if)# ipv6 nd home-agent-preference 100
leaf01(config-if)# ipv6 nd home-agent-lifetime 0
leaf01(config-if)# end
leaf01# write memory
leaf01# exit
cumulus@leaf01:mgmt:~$
vtysh 命令写入 /etc/frr/frr.conf
文件
cumulus@leaf01:mgmt:~$ sudo cat /etc/frr/frr.conf
...
interface swp1
ipv6 nd home-agent-config-flag
ipv6 nd home-agent-lifetime 0
ipv6 nd home-agent-preference 100
...
MTU
您可以为接口上的邻居发现消息设置 MTU。您可以配置一个介于 1 到 65535 之间的值。
以下示例命令将 swp1 上的 MTU 设置为 1500
cumulus@leaf01:mgmt:~$ nv set interface swp1 ip neighbor-discovery mtu 1500
cumulus@leaf01:mgmt:~$ nv config apply
cumulus@leaf01:mgmt:~$ sudo vtysh
...
leaf01# configure terminal
leaf01(config)# interface swp1
leaf01(config-if)# ipv6 nd mtu 1500
leaf01(config-if)# end
leaf01# write memory
leaf01# exit
cumulus@leaf01:mgmt:~$
vtysh 命令写入 /etc/frr/frr.conf
文件
cumulus@leaf01:mgmt:~$ sudo cat /etc/frr/frr.conf
...
interface swp1
ipv6 nd mtu 1500
...
邻居基本可达计时器
您可以使用 NVUE nv set system global nd base-reachable-time
命令设置邻居缓存条目的有效时长。条目的有效时间至少为基本可达时间除以 2 和基本可达时间除以 2 的三倍之间的值。您可以指定一个介于 30 到 2147483 秒之间的值。默认值为 auto
;NVUE 从 /etc/sysctl.d/neigh.conf
文件中派生出 auto
的值。
以下示例将邻居基本可达计时器配置为 50 秒。
cumulus@leaf01:~$ nv set system global nd base-reachable-time 50
cumulus@leaf01:~$ nv config apply
要将邻居基本可达计时器重置为默认设置,请运行 nv unset system global nd base-reachable-time
命令。
NVIDIA 建议您运行 NVUE 命令来更改邻居基本可达计时器,而不是手动修改 /etc/sysctl.d/neigh.conf
文件。
要显示邻居基本可达计时器设置,请运行 nv show system global nd
命令
cumulus@leaf01:~$ nv show system global nd
operational applied
---------------------------- ----------- -------
base-reachable-time 50 50
garbage-collection-threshold
effective 17920
maximum 20480
minimum 128
禁用 ND
要禁用 ND,请运行 NVUE nv set interface <interface> ip neighbor-discovery enable off
命令
cumulus@leaf01:mgmt:~$ nv set interface swp1 ip neighbor-discovery enable off
cumulus@leaf01:mgmt:~$ nv config apply
添加静态 IP 邻居表条目
您可以添加静态 IPv6 邻居表条目,以便于管理或作为一种安全措施来防止欺骗和其他恶意活动。
要为具有与 MAC 地址关联的 IPv6 地址的接口创建静态邻居条目,请运行 nv set interface <interface> neighbor ipv6 <ip-address> lladdr <mac-address>
命令。
cumulus@leaf01:mgmt:~$ nv set interface swp51 neighbor ipv6 fe80::4ab0:2dff:fea2:4c79 lladdr 00:00:5E:00:53:51
cumulus@leaf01:mgmt:~$ nv config apply
您还可以设置一个标志来指示邻居是路由器 (is-router
) 还是外部学习的 (ext_learn
),并设置邻居状态(delay
、failed
、incomplete
、noarp
、permanent
、probe
、reachable
或 stale
)。
cumulus@leaf01:mgmt:~$ nv set interface swp51 neighbor ipv6 fe80::4ab0:2dff:fea2:4c79 lladdr 00:00:5E:00:53:51 flag is-router
cumulus@leaf01:mgmt:~$ nv set interface swp51 neighbor ipv6 fe80::4ab0:2dff:fea2:4c79 lladdr 00:00:5E:00:53:51 state permanent
cumulus@leaf01:mgmt:~$ nv config apply
要删除 IP 邻居表中的条目,请运行 nv unset interface <interface> neighbor ipv6 <ip-address>
命令
cumulus@leaf01:mgmt:~$ nv unset interface swp51 neighbor ipv6 fe80::4ab0:2dff:fea2:4c79
cumulus@leaf01:mgmt:~$ nv config apply
要为具有与 MAC 地址关联的 IPv6 地址的接口创建静态邻居条目,请将 post-up ip neigh add <ipv6-address> lladdr <mac-address>
添加到 /etc/network/interfaces
文件的接口 stanza,然后运行 ifreload -a
命令
cumulus@leaf01:mgmt:~$ sudo nano /etc/network/interfaces
...
auto swp51
iface swp51
post-up ip neigh add fe80::4ab0:2dff:fea2:4c79 lladdr 00:00:5E:00:53:51 dev swp51
...
cumulus@leaf01:mgmt:~$ sudo ifreload -a
您还可以设置一个标志来指示 IPv6 邻居是路由器 (router
) 还是外部学习的 (extern_learn
),并设置邻居状态(delay
、failed
、incomplete
、noarp
、permanent
、probe
、reachable
或 stale
)。
cumulus@leaf01:mgmt:~$ sudo nano /etc/network/interfaces
...
auto swp51
iface swp51
post-up ip neigh add fe80::4ab0:2dff:fea2:4c79 lladdr 00:00:5E:00:53:51 dev swp51 nud permanent router
...
cumulus@leaf01:mgmt:~$ sudo ifreload -a
要删除静态邻居条目,请从 /etc/network/interfaces
文件的接口 stanza 中删除 post-up ip neigh add
行。
显示 IP 邻居表
要显示 IP 邻居表中的所有条目,请运行 nv show interface neighbor
命令或 Linux ip neighbor
命令
cumulus@leaf01:mgmt:~$ nv show interface neighbor
Interface IP/IPV6 LLADR(MAC) State Flag
------------- ------------------------- ----------------- --------- ----------
eth0 192.168.200.251 48:b0:2d:00:00:01 stale
192.168.200.1 48:b0:2d:aa:8b:45 reachable
fe80::4ab0:2dff:fe00:1 48:b0:2d:00:00:01 reachable router
peerlink.4094 169.254.0.1 48:b0:2d:3f:69:d6 permanent
fe80::4ab0:2dff:fe3f:69d6 48:b0:2d:3f:69:d6 reachable router
swp51 169.254.0.1 48:b0:2d:a2:4c:79 permanent
fe80::4ab0:2dff:fea2:4c79 48:b0:2d:a2:4c:79 reachable router
swp52 169.254.0.1 48:b0:2d:48:f1:ae permanent
fe80::4ab0:2dff:fe48:f1ae 48:b0:2d:48:f1:ae reachable router
swp53 169.254.0.1 48:b0:2d:2d:de:93 permanent
fe80::4ab0:2dff:fe2d:de93 48:b0:2d:2d:de:93 reachable router
swp54 169.254.0.1 48:b0:2d:80:8c:21 permanent
fe80::4ab0:2dff:fe80:8c21 48:b0:2d:80:8c:21 reachable router
vlan10 10.1.10.3 44:38:39:22:01:78 permanent
10.1.10.101 48:b0:2d:a1:3f:4b reachable
10.1.10.104 48:b0:2d:1d:d7:e8 noarp |ext_learn
fe80::4ab0:2dff:fea1:3f4b 48:b0:2d:a1:3f:4b reachable
fe80::4ab0:2dff:fe1d:d7e8 48:b0:2d:1d:d7:e8 noarp |ext_learn
fe80::4638:39ff:fe22:178 44:38:39:22:01:78 permanent
vlan10-v0 10.1.10.101 48:b0:2d:a1:3f:4b stale
fe80::4ab0:2dff:fea1:3f4b 48:b0:2d:a1:3f:4b stale
fe80::4ab0:2dff:fe1d:d7e8 48:b0:2d:1d:d7:e8 stale
vlan20 10.1.20.105 48:b0:2d:75:bf:9e noarp |ext_learn
10.1.20.102 48:b0:2d:00:e9:05 reachable
10.1.20.3 44:38:39:22:01:78 permanent
fe80::4638:39ff:fe22:178 44:38:39:22:01:78 permanent
fe80::4ab0:2dff:fe75:bf9e 48:b0:2d:75:bf:9e noarp |ext_learn
fe80::4ab0:2dff:fe00:e905 48:b0:2d:00:e9:05 reachable
...
要仅显示 IPv6 条目,请运行 Linux ip -6 neighbor
命令
cumulus@leaf01:mgmt:~$ ip -6 neighbor
fe80::4ab0:2dff:fe4e:c76a dev vlan30 lladdr 48:b0:2d:4e:c7:6a extern_learn NOARP proto zebra
fe80::4ab0:2dff:fea1:3f4b dev vlan10 lladdr 48:b0:2d:a1:3f:4b REACHABLE
fe80::4ab0:2dff:fee9:d399 dev vlan30-v0 lladdr 48:b0:2d:e9:d3:99 STALE
fe80::4ab0:2dff:fe75:bf9e dev vlan20-v0 lladdr 48:b0:2d:75:bf:9e STALE
fe80::4638:39ff:fe22:178 dev vlan20 lladdr 44:38:39:22:01:78 PERMANENT
fe80::4ab0:2dff:fea2:4c79 dev swp51 lladdr 48:b0:2d:a2:4c:79 router REACHABLE
fe80::4ab0:2dff:fe00:1 dev eth0 lladdr 48:b0:2d:00:00:01 router REACHABLE
fe80::4ab0:2dff:fee9:d399 dev vlan30 lladdr 48:b0:2d:e9:d3:99 REACHABLE
fe80::4ab0:2dff:fe48:f1ae dev swp52 lladdr 48:b0:2d:48:f1:ae router REACHABLE
fe80::4ab0:2dff:fe1d:d7e8 dev vlan10 lladdr 48:b0:2d:1d:d7:e8 extern_learn NOARP proto zebra
fe80::4ab0:2dff:fea1:3f4b dev vlan10-v0 lladdr 48:b0:2d:a1:3f:4b STALE
fe80::4ab0:2dff:fe80:8c21 dev swp54 lladdr 48:b0:2d:80:8c:21 router REACHABLE
fe80::4ab0:2dff:fe75:bf9e dev vlan20 lladdr 48:b0:2d:75:bf:9e extern_learn NOARP proto zebra
fe80::4638:39ff:fe22:178 dev vlan4024_l3 lladdr 44:38:39:22:01:78 PERMANENT
fe80::4ab0:2dff:fe00:e905 dev vlan20-v0 lladdr 48:b0:2d:00:e9:05 STALE
fe80::4ab0:2dff:fe3f:69d6 dev peerlink.4094 lladdr 48:b0:2d:3f:69:d6 router REACHABLE
...
要显示特定接口的所有表条目,请运行 nv show interface <interface_id> neighbor
命令
cumulus@leaf01:mgmt:~$ nv show interface swp51 neighbor
ipv4
=========
IPV4 LLADR(MAC) State Flag
----------- ----------------- --------- ----
10.5.5.51 00:00:5e:00:53:51 permanent
169.254.0.1 48:b0:2d:a2:4c:79 permanent
ipv6
=========
IPV6 LLADR(MAC) State Flag
------------------------- ----------------- --------- ---------
fe80::4ab0:2dff:fea2:4c79 48:b0:2d:a2:4c:79 reachable is-router
要显示接口的所有 IPv6 表条目,请运行 nv show interface <interface> neighbor ipv6
命令
cumulus@leaf01:mgmt:~$ nv show interface swp1 neighbor ipv6
IPV6 LLADR(MAC) State Flag
------------------------- ----------------- --------- ---------
fe80::1e34:daff:fe6c:dd8 1c:34:da:6c:0d:d8 stale
fe80::3e2c:30ff:fe4b:800 3c:2c:30:4b:08:00 reachable
要显示具有特定 IPv6 地址的接口的表条目,请运行 nv show interface <interface_id> neighbor ipv6 <ip-address>
命令
cumulus@leaf01:mgmt:~$ nv show interface swp51 neighbor ipv6 fe80::4ab0:2dff:fea2:4c79
lladdr
=========
LLADR(MAC) State Flag
----------------- --------- ----
00:00:5E:00:53:51 permanent
故障排除
要显示接口的 ND 配置设置,请运行 NVUE nv show interface <interface-id> ip neighbor-discovery
命令
cumulus@leaf01:mgmt:~$ nv show interface swp1 ip neighbor-discovery
applied description
-------------------- ------------------ ----------------------------------------------------------------------
enable on Turn the feature 'on' or 'off'. The default is 'on'.
home-agent
lifetime 0 Lifetime of a home agent in seconds
preference 0 Home agent's preference value that is used to order the addresses r...
[prefix] 2001:db8:1::100/32 IPv6 prefix configuration
router-advertisement
enable on Turn the feature 'on' or 'off'. The default is 'on'.
fast-retransmit off Allow consecutive RA packets more frequently than every 3 seconds
hop-limit 100 Value in hop count field in IP header of the outgoing router advert...
interval 6000 Maximum time in milliseconds allowed between sending unsolicited mu...
interval-option on Indicates hosts that the router will use advertisement interval to...
lifetime 4000 Maximum time in seconds that the router can be treated as default g...
managed-config on Knob to allow dynamic host to use managed (stateful) protocol for a...
other-config off Knob to allow dynamic host to use managed (stateful) protocol for a...
reachable-time 3600000 Time in milliseconds that a IPv6 node is considered reachable
retransmit-time 4294967295 Time in milliseconds between retransmission of neighbor solicitatio...
router-preference high Hosts use router preference in selection of the default router
要显示接口的前缀配置,请运行 nv show interface <interface> ip neighbor-discovery prefix <prefix>
命令。
cumulus@leaf01:mgmt:~$ nv show interface swp1 ip neighbor-discovery prefix 2001:db8:1::100/32
applied description
------------------ ------- ----------------------------------------------------------------------
autoconfig on Indicates to hosts on the local link that the specified prefix can...
off-link on Indicates that adverisement makes no statement about on-link or off...
preferred-lifetime 1000000000 Time in seconds that addresses generated from a prefix remain prefe...
router-address on Indicates to hosts on the local link that the specified prefix cont...
valid-lifetime 2000000000 Time in seconds the prefix is valid for on-link determination
要显示接口的家乡代理配置,请运行 nv show interface <interface> ip neighbor-discovery home-agent
命令
cumulus@leaf01:mgmt:~$ nv show interface swp1 ip neighbor-discovery home-agent
applied description
---------- ------- ----------------------------------------------------------------------
lifetime 20000 Lifetime of a home agent in seconds
preference 100 Home agent's preference value that is used to order the addresses r...
要显示接口的路由器通告配置,请运行 nv show interface <interface> ip neighbor-discovery router-advertisement
命令。该命令还显示接口上发送的路由器通告数据包的数量以及接口上接收的路由器通告和路由器请求数据包的数量。
cumulus@leaf01:mgmt:~$ nv show interface swp1 ip neighbor-discovery router-advertisement
applied
----------------- -----------------
enable on
interval 10000
interval-option off
fast-retransmit on
lifetime 1800
reachable-time 0
retransmit-time 0
managed-config off
other-config off
hop-limit 64
router-preference medium
ra-sent 218
ra-received 2
rs-received 1
要显示接口的 RDNSS 配置,请运行 nv show interface <interface> ip neighbor-discovery rdnss <address>
命令
cumulus@leaf01:mgmt:~$ nv show interface swp1 ip neighbor-discovery rdnss 2001:db8:1::100
applied description
-------- -------- ----------------------------------------------------------------------
lifetime infinite Maximum time in seconds for which the server may be used for domain...
要显示接口的 DNSSL 配置,请运行 nv show interface <interface> ip neighbor-discovery dnssl <domain-suffix>
命令
cumulus@leaf01:mgmt:~$ nv show interface swp1 ip neighbor-discovery dnssl accounting.nvidia.com
applied description
-------- -------- ----------------------------------------------------------------------
lifetime infinite Maximum time in seconds for which the domain suffix may be used for...