NDP(8) | Maintenance Commands and Procedures | NDP(8) |
ndp
— manipulate
IPv6 Neighbor Discovery Protocol mappings
ndp |
[-n ] -a |
ndp |
[-n ] -A
period |
ndp |
[-n ] [-i
iface] hostname |
ndp |
[-n ] [-i
iface] -d
hostname |
ndp |
[-n ] [-i
iface] -f
filename |
ndp |
[-n ] [-i
iface] -s
hostname lladdr [temp ]
[any ] [router ] |
The ndp
command displays and modifies the
IPv6-to-MAC address translation tables used by the Neighbor Discovery
Protocol (see ndp(4P)).
Given just a hostname, ndp
will display
the current entry. Note that when getting, setting or deleting, if a
hostname refers to multiple IPv6 addresses, the operation will apply to all
of them.
The NDP translation tables can be
modified with -d
, -s
, or
-f
. These flags can only be used when
ndp
is given the
PRIV_SYS_NET_CONFIG
privilege. See privileges(7) for
further information.
Note that NDP entries for IPMP (IP Network Multipathing) data and test addresses are managed by the kernel and therefore cannot be modified or deleted.
-a
Entries also exist in one of the following states:
Using the -a
flag is equivalent
to:
# netstat -p -f
inet6
If -n
is passed to
ndp
, then it will be passed along to
netstat
.
-A
-d
-f
-s
. Lines beginning with `#' will be ignored.-i
ndp
will use the routing table to
determine the appropriate interface to place the mapping on. This flag
allows forcing a specific interface iface. This
argument will be ignored when using the -a
or
-A
flags.-n
-s
temp
ndp
command are static, and will not be
deleted. To make a static entry temporary, it should be deleted and
recreated with the temp
flag.any
router
To create a temporary mapping for an address:
# ndp -s fd00::1 90:b8:d0:4b:c7:3b temp
An entry can be fetched via its IP address:
# ndp fd00::1 fd00::1 (fd00::1) at 90:b8:d0:4b:c7:3b temp
Or via a name that resolves to that address:
# echo fd00::1 epicac >> /etc/hosts # echo fd00::2 epicac >> /etc/hosts # ndp epicac fd00::1 (epicac) at 90:b8:d0:4b:c7:3b temp fd00::2 (epicac) -- no entry
An entry can be removed with the -d
flag:
# ndp -d fd00::1
Attempting to remove it again will print an error message:
# ndp -d fd00::1 ndp: No entry for fd00::1
The command line options for this command are stable, but the output format and diagnostic messages are not.
ndp(4P), attributes(7), privileges(7), arp(8), ifconfig(8), netstat(8)
September 2, 2015 | OmniOS |