RH358 manage DHCP and IP address assignment -- configure IPv6 address assignment

Posted by mattd123 on Fri, 31 Dec 2021 17:17:53 +0100

RH358 manage DHCP and IP address assignment – configure IPv6 address assignment

This chapter describes how to configure DHCP to allocate IPv6 addresses. Although it is still a bit weak, it can be used for understanding and learning.

Column address: https://blog.csdn.net/qq_41765918/category_11532281.html

1. Overview of IPv6 address automatic configuration

IPv6 has many ways to configure network interfaces. In this section, you will learn two of them:

  • Stateless Address Autoconfiguration (SLAAC)

  • Dynamic Host Configuration Protocol for IPv6 (DHCPv6)

2. View IPv6 link local address assignment

Each IPv6 interface is automatically configured with a link local unicast address with fe80::/64 prefix.

In IPv6, the link local address is a non routable address, which can only be used by the system to communicate with other systems on the same network link. In order to ensure the uniqueness of the IP address, the interface ID of the link local address is calculated according to a specific method.

You can use the ip addr show command to obtain the local IPv6 address of the link, as shown in the following example.

[user@host ~]$ ip addr show dev eth0
3: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP group
default qlen 1000
link/ether 52:54:00:01:fa:0a brd ff:ff:ff:ff:ff:ff
inet 10.42.0.1/16 brd 10.42.255.255 scope global noprefixroute eth0
valid_lft forever preferred_lft forever
inet6 fe80::7418:cf98:c742:3681/64 scope link noprefixroute
valid_lft forever preferred_lft forever

For proper operation, IPv6 depends on the link local address. Even if you manually or automatically assign a routable IPv6 address, the interface always maintains that address.

3. Describe IPv6 stateless address automatic configuration

The link local address is not routable. To deploy IPv6 infrastructure, you need to assign routing addresses to your system. For IPv6, there are several configuration mechanisms that can automatically attribute IPv6 addresses to the system.

The stateless address auto configuration (SLAAC) method relies on the router to provide network configuration for the client system. This can include the prefix of the IPv6 network (which clients can use to create addresses) and DNS information. For this approach, your network team must activate and configure the neighbor discovery protocol (NDP) on the router.

In SLAAC, when the client system starts up or you activate the network connection, the interface uses its link local address to send a Router Solicitation message to the ffo2::2 multicast address. The router responds to the router notification message and provides network parameters.

The router also regularly sends Router Advertisement router notification messages on the subnet to inform the client system of their existence and information updates.

The router notification message can provide the following network configuration parameters:

  • IPv6 prefix

  • IPv6 address of DNS server

  • DNS search list

In addition to these parameters, client systems always configure their IPv6 default gateway with the link local address of the router.

Important: the router notification message does not provide the interface ID of IPv6 address; They only provide network prefixes. The client system calculates its interface ID according to the NetworkManager settings of its connection (by default, the same stable privacy algorithm used to link the local address is used).

Monitor router advertisement messages

In order to troubleshoot or discover the parameters being published by the router, you can monitor the network to obtain the Router Advertisement message.

The radvd package provides a radvdump utility that can be used on client systems to capture Router Advertisement messages. Routers usually send these messages at a lower frequency, sometimes one message every 10 minutes. Therefore, you may need to wait a few minutes for the radvdump command to capture its first message.

[root@host ~]# radvdump
#
# radvd configuration generated by radvdump 2.17
# based on Router Advertisement from fe80::30d6:2d6b:6e68:dce5
# The radvdump command is used to view the link local IPv6 address of the router sending the message. Clients configured with this router advertisement message will use this IPv6 address as their default gateway.
# received by interface eth0
#
interface eth0
{
AdvSendAdvert on;
# Note: {Min,Max}RtrAdvInterval cannot be obtained with radvdump
AdvManagedFlag off;
AdvOtherConfigFlag off;

...output omitted...

prefix fde2:6494:1e09:2::/64    # Route advertisement message provides IPv6 prefix.
{
...output omitted...
}; # End of prefix definition

RDNSS fde2:6494:1e09:2::1    # The recursive DNS server (RDNSS) section gives the IPv6 address of the DNS server. This section is optional and not all routers provide this information.
{
...output omitted...
}; # End of RDNSS definition

DNSSL example.com example.net   # The DNS search list (DNSSL) section provides a search list. This section is also optional.
{
...output omitted...
}; # End of DNSSL definition
}; # End of interface definition

Configure Linux router to provide SLAAC

If you use a Linux system for routers, you can configure them to send router notification messages and reply to router request messages.

The radvd package provides radvd services through / etc / radvd Conf configuration file. Configuring this service is beyond the scope of this course. For more information, refer to radvd Conf (5) man page.

4. Implement DHCPv6

Router advertisement messages can only provide a limited set of network configuration parameters. For example, older routers typically do not (or cannot) publish DNS parameters.

By deploying DHCPv6 server, you can provide these missing parameters. You can control the interface ID part of the client IPv6 address by defining the address range to be distributed, rather than letting the client system calculate it. You can also assign a fixed IPv6 address to a specific client.

For enterprise networks that need to strictly control IPv6 addresses and network parameters, it is particularly important to use DHCPv6.

Compared with DHCPv6, the network parameters provided by the route advertisement message are shown in the following table

Compare router notification message with DHCPv6

Note that DHCPv6 cannot provide a default gateway for clients. The client relies on the Router Advertisement message to obtain this information.

In fact, router notifications and DHCPv6 work together. The router notification message can provide IPv6 prefix and default gateway, and can instruct the client to use DHCPv6 to retrieve other network configuration parameters.

The following Router Advertisement messages were collected using the radvdump utility, which shows the configuration.

[root@host ~]# radvdump
#
# radvd configuration generated by radvdump 2.17
# based on Router Advertisement from fe80::30d6:2d6b:6e68:dce5  # The client system uses the link local IPv6 address of the router as the default gateway.
# received by interface eth0
#

interface eth0
{
AdvSendAdvert on;
# Note: {Min,Max}RtrAdvInterval cannot be obtained with radvdump
AdvManagedFlag on;    # When set to on, the AdvManagedFlag parameter instructs the client to retrieve the interface ID of the IPv6 address from DHCPv6. The client no longer calculates this part of the address.

AdvOtherConfigFlag on;  # When set to on, the advanterconfigflag parameter instructs the client to retrieve other network configuration parameters from DHCPv6, such as DNS server and search list.
...output omitted...
}; # End of interface definition

Deploy DHCPv6 server

The IPv6 address of the system where the DHCPv6 server is located must be the same as the prefix of the IPv6 address managed by the DHCPv6 server.

In addition to DHCPv4, the DHCP Server package also provides DHCPv6 services.

[root@host ~]# yum install dhcp-server

It is necessary to add dhcpv6 service in the firewall, which controls the access to 547/ UDP port

[root@host ~]# firewall-cmd --permanent --add-service=dhcpv6

[root@host ~]# firewall-cmd --reload

**Note: * * the network communication of DHCPv6 is similar to that of DHCPv4. One difference is that all DHCPv6 servers and relays listen for requests from the client link local address on the link local multicast address ff02::1:2, because IPv6 does not support broadcast messages.

Configure DHCPv6 server

The dhcpd6 service uses / etc / DHCP / dhcpd6 Conf configuration file. The DHCP Server package provides / usr / share / Doc / DHCP server / DHCP PD6 Conf file to use as a configuration example. You can use this file as a starting point for configuration.

The following is a typical DHCPv6 configuration example.

authoritative;    # The authoritative directive indicates that the server is authoritative for the IPv6 prefix it manages.

subnet6 fde2:6494:1e09:2::/64 {    # The subnet6 location provides subnet details.

	range6 fde2:6494:1e09:2::20 fde2:6494:1e09:2::60;   # The server assigns IPv6 addresses in this range.

	option dhcp6.name-servers fde2:6494:1e09:2::cc;    # The server also provides a DNS name server.
	option dhcp6.domain-search "example.net";        # The server provides DNS domain search parameters.

	default-lease-time 600;  # If the client does not require any specific lease length, the default lease time parameter provides a default value in seconds.
	max-lease-time 7200;   # Max lease time indicates the maximum lease time that the server can accept client requests.
}

Reserved IPv6 address

Like DHCPv4 for IPv4 addresses, you can assign fixed IPv6 addresses to specific systems. However, unlike DHCPv4, DHCPv6 does not use the client MAC address for association; It relies on the DHCP unique identifier (DUID) of the client.

DHCP represents DUID as a series of colon separated bytes, as follows:

By default, the network manager calculates the DUID based on the unique machine ID in / etc / machine ID

Important:

When you deploy multiple virtual systems from the same disk image, ensure that the / etc / machine ID file is regenerated after the first boot. Otherwise, all these systems will get the same machine ID and therefore the same DUID. To generate a new machine ID, use the following command:

[root@host ~]# rm /etc/machine-id
[root@host ~]# systemd-machine-id-setup
[root@host ~]# systemctl restart NetworkManager

There is no easy way to retrieve the DUID generated by network manager on the client system itself. One method is to temporarily configure the client network interface of DHCPv6. On the DHCPv6 server, the system D-JOURNAL service captures the DUID of the client. Use journalctl - u dhcpd6 The service command accesses this information:

[root@host ~]# journalctl -u dhcpd6.service
...output omitted...
Apr 03 02:52:27 host dhcpd[1992]: Advertise NA: address fde2:6494:1e09:2::60 to
client with duid 00:04:cf:e4:cf:3b:19:63:60:27:08:e8:d5:67:58:e8:57:00 iaid =
1079403426 valid for 600 seconds
...output omitted...

Generate a DUID

As an alternative, you can force DUID on the client system instead of having network manager compute it. You can use the uuidgen command and reformat the generated string to generate a DUID.

[user@host ~]$ uuidgen
6857c6fd-5b9b-4a51-8840-6f4b23e6c34a
[user@host ~]$ echo 6857c6fd-5b9b-4a51-8840-6f4b23e6c34a | sed -e 's/-//g' -e 's/\(..\)/:\1/g' -e 's/^://'
68:57:c6:fd:5b:9b:4a:51:88:40:6f:4b:23:e6:c3:4a

Then, when you use nmcli Command creation NetworkManager When connecting, use ipv6.dhcp-duid The options are as follows:
[root@host ~]# nmcli con add con-name dhcp-conn type ethernet ifname eth0 \
ipv6.dhcp-duid "68:57:c6:fd:5b:9b:4a:51:88:40:6f:4b:23:e6:c3:4a" \
ipv6.method auto

Configure DHCP server

With DUID, it can be found in / etc / DHCP / dhcpd6 Add a host declaration to the conf configuration file to assign a fixed IPv6 address to the client.

In the following example, the server always assigns the system address fde2:6494:1e09:2::0451 with 00:04:cf:e4:cf:3b:19:63:60:27:08:e8:d5:67:58:e8:57:00 DUID.

authoritative;

subnet6 fde2:6494:1e09:2::/64 {
...output omitted...
}
host web {
  host-identifier option
	dhcp6.client-id 00:04:cf:e4:cf:3b:19:63:60:27:08:e8:d5:67:58:e8:57:00;
  fixed-address6 fde2:6494:1e09:2::0451;
}

Verify configuration

Before starting the dhcpd6 systemd service, use dhcpd - t - 6 - CF / etc / DHCP / dhcpd6 The conf command tests the configuration. When an error is detected, the command returns a non-zero value.

[root@host ~]# dhcpd -t -6 -cf /etc/dhcp/dhcpd6.conf
Internet Systems Consortium DHCP Server 4.3.6
Copyright 2004-2017 Internet Systems Consortium.
All rights reserved.
For info, please visit https://www.isc.org/software/dhcp/
ldap_gssapi_principal is not set,GSSAPI Authentication for LDAP will not be used
Not searching LDAP since ldap-server, ldap-port and ldap-base-dn were not
specified in the config file
Config file: /etc/dhcp/dhcpd6.conf
Database file: /var/lib/dhcpd/dhcpd6.leases
PID file: /var/run/dhcpd6.pid

[root@host ~]# echo $?
0

Use the systemctl command to start and enable the service.

[root@host ~]# systemctl enable --now dhcpd6

5. Configure the automatic address allocation method

If automatic configuration is required in the client configuration interface, use ipv6.0 of nmcli command Method parameter.

[root@host ~]# nmcli con add con-name dhcp-connection type ethernet \
ifname eth0 ipv6.method auto

To automatically configure the client network interface, you must be in IPv6 Select from two options in the method parameter:

auto

The auto method uses IPv6 stateless address auto configuration (SLAAC). The interface sends a Router Solicitation message, and then processes the generated Router Advertisement message to set its IPv6 prefix and default gateway. If the AdvManagedFlag or advotherconfiqfaq parameter is set to on in the Router Advertisement message, the client sends aDHCPv6 to request the configuration of interface ID and other network parameters.

dhcp

For the dhcp mode, the client directly sends a DHCPv6 request to configure its own interface. It does not send any router request messages, nor does it process router advertisement messages. This method is very useful when the router is not configured with NDP and is not recommended. Remember that DHCPv6 does not provide default gateway parameters to the client system.

6. Textbook exercises

[student@workstation ~]$ lab dhcp-ipv6config start

In this exercise, you will deploy DHCPv6 server on servera to provide IPv6 network configuration for systems connected to the secondary network.

The DHCPv6 server manages the fde2:6494:1e09:2::/64 prefix and distributes IPv6 addresses from fde2:6494:1e09:2::20 to fde2:6494:1e09:2::60. It also provides DNS parameters to the client system.

The lab command configures the server to provide prefix and default gateway through neighbor discovery protocol (NDP), and instructs the client to query DHCPv6 server for other configurations.

1. Prepare the preliminary work before deployment.

Before deploying DHCPv6 server, you need to configure a network port on the server. The network port address is static IPv6 and the prefix is the IPv6 address managed by DHCPv6 server.

[root@servera ~]# nmcli con add con-name ge-conn type ethernet ifname eth1 ipv6.addresses fde2:6494:1e09:2::a/64 ipv6.method manual
Connection 'ge-conn' (fab73faa-f7e0-496f-8c14-3de740aa727e) successfully added.

[root@servera ~]# nmcli con up ge-conn
Connection successfully activated (D-Bus active path: /org/freedesktop/NetworkManager/ActiveConnection/3)

[root@servera ~]# ip -6 addr show dev eth1
3: eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 state UP qlen 1000
    inet6 fde2:6494:1e09:2::a/64 scope global noprefixroute 
       valid_lft forever preferred_lft forever
    inet6 fe80::ba51:41f:5ebe:61b9/64 scope link noprefixroute 
       valid_lft forever preferred_lft forever

2. Set to get NDP notification.

In deployment DHCP Before the server, the network needs to be monitored to obtain IPv6 Router regularly sends NDP announcement.
[root@servera ~]# yum -y install radvd

use radvdump The command captures the message that the router is sending NDP announcement. You may need to wait a minute to capture the message.
[root@servera ~]# radvdump
#
# radvd configuration generated by radvdump 2.17
# based on Router Advertisement from fe80::23d7:22c9:c317:b038
# received by interface eth1
#

interface eth1
{
	AdvSendAdvert on;
	# Note: {Min,Max}RtrAdvInterval cannot be obtained with radvdump
	AdvManagedFlag on;
	AdvOtherConfigFlag on;
	AdvReachableTime 0;
	AdvRetransTimer 0;
	AdvCurHopLimit 64;
	AdvDefaultLifetime 180;
	AdvHomeAgentFlag off;
	AdvDefaultPreference medium;
	AdvSourceLLAddress on;
}; # End of interface definition

3. Install the DHCP Server package.

[root@servera ~]# yum -y install dhcp-server

4. Please configure DHCPv6 server according to the following table.

DHCPv6 server parameters

If there is any problem in writing, please refer to / root / dhcp-ipv6 config / DHCP PD-1 Configuration in conf.

[root@servera ~]# vim /etc/dhcp/dhcpd6.conf 
#
# DHCPv6 Server Configuration file.
#   see /usr/share/doc/dhcp-server/dhcpd6.conf.example
#   see dhcpd.conf(5) man page
#
authoritative;

subnet6 fde2:6494:1e09:2::/64 {
  range6 fde2:6494:1e09:2::20 fde2:6494:1e09:2::60;
  option dhcp6.name-servers fde2:6494:1e09:2::d;
  option dhcp6.domain-search "backend.lab.example.com";
  default-lease-time 600;
  max-lease-time 7200;
}

[root@servera ~]# dhcpd -t -6 -cf /etc/dhcp/dhcpd6.conf
[root@servera ~]# echo $?
0

5. Start dhcpd6 service and open firewall port.

[root@servera ~]# systemctl enable --now dhcpd6
Created symlink /etc/systemd/system/multi-user.target.wants/dhcpd6.service → /usr/lib/systemd/system/dhcpd6.service.
[root@servera ~]# systemctl status dhcpd6
● dhcpd6.service - DHCPv6 Server Daemon
   Loaded: loaded (/usr/lib/systemd/system/dhcpd6.service; enabled; vendor preset: disabled)
   Active: active (running) since Wed 2021-06-16 14:44:45 CST; 15s ago
     Docs: man:dhcpd(8)
           man:dhcpd.conf(5)
 Main PID: 2588 (dhcpd)
   Status: "Dispatching packets..."
    Tasks: 1 (limit: 11251)
   Memory: 2.8M
   CGroup: /system.slice/dhcpd6.service
           └─2588 /usr/sbin/dhcpd -f -6 -cf /etc/dhcp/dhcpd6.conf -user dhcpd -group dhcpd --no-pid
............

[root@servera ~]# firewall-cmd --permanent --add-service=dhcpv6
success
[root@servera ~]# firewall-cmd --reload
success

6. Create a NetworkManager connection as required.

Create a NetworkManager connection for the second network interface. The connection must use NDP and DHCPv6 to retrieve IPv6 network configuration parameters from the router running on the server and the DHCPv6 server running on the server.

[root@serverb ~]# nmcli con add con-name dhcp-conn type ethernet ifname eth1 ipv6.method auto
Connection 'dhcp-conn' (e48ce158-f6d0-44e5-b2f4-78589150630f) successfully added.
[root@serverb ~]# nmcli con up dhcp-conn
Connection successfully activated (D-Bus active path: /org/freedesktop/NetworkManager/ActiveConnection/7)

[root@serverb ~]# ip -6 addr show dev eth1
3: eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 state UP qlen 1000
    inet6 fde2:6494:1e09:2::60/128 scope global dynamic noprefixroute 
       valid_lft 570sec preferred_lft 345sec
    inet6 fe80::23ae:a48f:bf1b:c17c/64 scope link noprefixroute 
       valid_lft forever preferred_lft forever

[root@serverb ~]# cat /etc/resolv.conf
# Generated by NetworkManager
search lab.example.com example.com backend.lab.example.com
nameserver 172.25.250.254
nameserver fde2:6494:1e09:2::d

[root@serverb ~]# ip -6 route
::1 dev lo proto kernel metric 256 pref medium
fde2:6494:1e09:2::60 dev eth1 proto kernel metric 101 pref medium
fe80::/64 dev eth0 proto kernel metric 100 pref medium
fe80::/64 dev eth1 proto kernel metric 101 pref medium
default via fe80::23d7:22c9:c317:b038 dev eth1 proto ra metric 101 pref medium

[root@serverb ~]# ssh student@serverd ip -6 addr show
The authenticity of host 'serverd (172.25.250.13)' can't be established.
ECDSA key fingerprint is SHA256:RcLr4lV8JX3u7iIrNgTu3mxUMUuyoW9+4WGie6luifw.
Are you sure you want to continue connecting (yes/no/[fingerprint])? yes
Warning: Permanently added 'serverd,172.25.250.13' (ECDSA) to the list of known hosts.
student@serverd's password: student
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 state UNKNOWN qlen 1000
    inet6 ::1/128 scope host 
       valid_lft forever preferred_lft forever
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 state UP qlen 1000
    inet6 fe80::7456:b637:8a78:4120/64 scope link noprefixroute 
       valid_lft forever preferred_lft forever
3: eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 state UP qlen 1000
    inet6 fde2:6494:1e09:2::d/64 scope global noprefixroute 
       valid_lft forever preferred_lft forever
    inet6 fe80::23d7:22c9:c317:b038/64 scope link noprefixroute 
       valid_lft forever preferred_lft forever

In the second part of the exercise, you will modify the configuration of the DHCPv6 server to assign a fixed IPv6 address to serverc. When assigning a fixed IPv6 address to a client, DHCPv6 identifies the client through its DHCP unique identifier (DUID). One way to get the DUID of serverc is to temporarily configure serverc for DHCPv6 and check the logs of DHCPv6 server on servera.

7. Create a NetworkManager connection for the second network interface as required.

[root@serverc ~]# ip link
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN mode DEFAULT group default qlen 1000
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP mode DEFAULT group default qlen 1000
    link/ether 52:54:00:00:fa:0c brd ff:ff:ff:ff:ff:ff
3: eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP mode DEFAULT group default qlen 1000
    link/ether 52:54:00:01:fa:0c brd ff:ff:ff:ff:ff:ff
4: eth2: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP mode DEFAULT group default qlen 1000
    link/ether 52:54:00:02:fa:0c brd ff:ff:ff:ff:ff:ff

[root@serverc ~]# nmcli con add con-name dhcp-conn type ethernet ifname eth1 ipv6.method auto
Connection 'dhcp-conn' (9c09b795-c7c7-4ab0-a6ee-3d006c5bc340) successfully added.
[root@serverc ~]# nmcli con up dhcp-conn
Connection successfully activated (D-Bus active path: /org/freedesktop/NetworkManager/ActiveConnection/7)

[root@serverc ~]# ip -6 addr show dev eth1
3: eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 state UP qlen 1000
    inet6 fde2:6494:1e09:2::4f/128 scope global dynamic noprefixroute 
       valid_lft 589sec preferred_lft 364sec
    inet6 fe80::9ba:ae07:513e:3359/64 scope link noprefixroute 
       valid_lft forever preferred_lft forever

8. Modify the configuration of DHCPv6 server and assign a fixed IPv6 address to serverc.

[root@servera ~]# journalctl -u dhcpd6.service | grep duid
Jun 16 15:22:06 servera.lab.example.com dhcpd[2588]: Advertise NA: address fde2:6494:1e09:2::4f to client with duid 00:04:59:ad:fe:7c:d9:cb:58:37:bc:c3:9c:4f:10:44:a8:48 iaid = 713252315 valid for 600 seconds
Jun 16 15:22:07 servera.lab.example.com dhcpd[2588]: Reply NA: address fde2:6494:1e09:2::4f to client with duid 00:04:59:ad:fe:7c:d9:cb:58:37:bc:c3:9c:4f:10:44:a8:48 iaid = 713252315 valid for 600 seconds
 In echo message IPv6 The address is in the previous step DHCPv6 Server assigned to serverc Your address.

[root@servera ~]# vim /etc/dhcp/dhcpd6.conf 
#
# DHCPv6 Server Configuration file.
#   see /usr/share/doc/dhcp-server/dhcpd6.conf.example
#   see dhcpd.conf(5) man page
#
authoritative;

subnet6 fde2:6494:1e09:2::/64 {
  range6 fde2:6494:1e09:2::20 fde2:6494:1e09:2::60;
  option dhcp6.name-servers fde2:6494:1e09:2::d;
  option dhcp6.domain-search "backend.lab.example.com";
  default-lease-time 600;
  max-lease-time 7200;
}

host serverc {
  host-identifier option dhcp6.client-id 00:04:59:ad:fe:7c:d9:cb:58:37:bc:c3:9c:4f:10:44:a8:48;
  fixed-address6 fde2:6494:1e09:2::0451;
}

[root@servera ~]# dhcpd -t -6 -cf /etc/dhcp/dhcpd6.conf
[root@servera ~]# echo $?
0

[root@servera ~]# systemctl restart dhcpd6

9. On serverc, stop and start the DHCP conn NetworkManager connection.

Confirm that the network port is configured with a fixed IPv6 address.

[root@serverc ~]# nmcli con down dhcp-conn
Connection 'dhcp-conn' successfully deactivated (D-Bus active path: /org/freedesktop/NetworkManager/ActiveConnection/18)
[root@serverc ~]# nmcli con up dhcp-conn
Connection successfully activated (D-Bus active path: /org/freedesktop/NetworkManager/ActiveConnection/19)

[root@serverc ~]# ip -6 addr show dev eth1
3: eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 state UP qlen 1000
    inet6 fde2:6494:1e09:2::451/128 scope global dynamic noprefixroute 
       valid_lft 563sec preferred_lft 338sec
    inet6 fe80::9ba:ae07:513e:3359/64 scope link noprefixroute 
       valid_lft forever preferred_lft forever

Complete the experiment.

[student@workstation ~]$ lab dhcp-ipv6config finish

summary

  • Describes the overview of Pv6 address automatic configuration.
  • How to implement DHCPv6.
  • Configure the automatic address assignment method.
  • If you like brother goldfish's article, please praise it. You can also pay attention, because the follow-up will continue to dry goods.

Topics: Linux Operation & Maintenance server