Obtaining the Device Management Mode and Cloud Management Platform's Address Information Through a DHCP Server
Process
In the Huawei Cloud Managed Network Solution, DHCP can implement plug-and-play deployment of switches, removing the need to manually change the switch management mode and configure the cloud management platform's address information.
- The administrator needs to deploy the DHCP server function on the network egress gateway or deploy an independent DHCP server on the network, and then configure DHCP Option 148, which includes the cloud-based management mode and cloud management platform's IP address/URL and port number.
- An unconfigured switch starts and sends a request packet containing
VLAN 1 to the DHCP server.
- If the VLAN for the IP address pool of the DHCP server is VLAN 1, the switch can use VLAN 1 to communicate with the DHCP server and register with the cloud management platform. If the switch negotiates a PNP VLAN with an upstream device, the switch uses this PNP VLAN to register with the cloud management platform again. For details about the PNP VLAN negotiation process, see PNP VLAN Auto-Negotiation.
- If the VLAN for the IP address pool of the DHCP server is not VLAN 1, the switch cannot use VLAN 1 to communicate with the DHCP server. The switch then uses the upstream device's PNP VLAN negotiated through the Link Layer Discovery Protocol (LLDP) to initiate a request to the DHCP server again.
- The DHCP server receives the request and sends a DHCP packet containing Option 148 to the switch.
- The switch changes from the traditional management mode to the cloud-based management mode based on Option 148 and restarts.
- After the switch restarts, all its configurations are cleared. Therefore, the switch needs to send a DHCP request again to obtain its management IP address.
- The DHCP server receives the request and sends a DHCP packet containing Option 148 to the switch again.
- The switch obtains its management IP address and obtains the cloud management platform's IP address/URL and port number based on Option 148.
If a management VLAN has been configured on a switch using cloud management platform, the switch directly uses this management VLAN to send requests to the DHCP server. Even if the requests fail, the switch will not use the PNP VLAN to send requests to the DHCP server. Therefore, ensure that the switch can communicate with the DHCP server in this management VLAN, so that the switch can go online properly.
PNP VLAN Auto-Negotiation
Background
In Figure 5-2, SwitchA and SwitchB register with the cloud management platform, and then the cloud management platform changes the management VLAN to another VLAN, which is not the default one, VLAN 1. The VLAN for the IP address pool of the DHCP server is also changed to the management VLAN. An unconfigured switch, SwitchC, is connected to SwitchA. After SwitchC is powered on and starts, it sends a request packet containing VLAN 1 to the DHCP server to obtain the device management mode and cloud management platform's address information. However, the VLAN for the IP address pool of the DHCP server has been changed to a VLAN, which is not VLAN 1, so SwitchC cannot obtain the device management mode and cloud management platform's address information and cannot register with the cloud management platform.
To solve this problem, PNP VLAN auto-negotiation is used:- SwitchA registers with the cloud management platform successfully, and then the cloud management platform delivers a PNP VLAN to SwitchA based on the preconfiguration. SwitchA can use this PNP VLAN to communicate with the DHCP server normally.
- SwitchC connects to the network and auto-negotiates a PNP VLAN with the upstream device, SwitchA.
- SwitchC uses the negotiated PNP VLAN to obtain the device management mode and cloud management platform's address information from the DHCP server. This process implements plug and play of newly added devices.
PNP VLAN auto-negotiation provides the following advantages:- A new device can connect to the cloud network through any interface of an upstream device, and the upstream device can identify the access interface and adds it to the PNP VLAN.
- If an upstream device and a downstream device are connected through multiple links, they can auto-negotiate the multiple links as an Eth-Trunk interface and auto-negotiate the working mode of the Eth-Trunk interface as Link Aggregation Control Protocol (LACP) mode.
Addition of a new unconfigured switch to a cloud network
In Figure 5-3:- An unconfigured switch starts and sends LLDP packets to negotiate with the upstream device in an effort to obtain the PNP VLAN configured on the upstream device.
- The switch uses the negotiated PNP VLAN to obtain the device management mode and cloud management platform's address information from the DHCP server. The switch uses the negotiated PNP VLAN to send DHCP request packets regardless of whether it can use VLAN 1 to receive DHCP response packets. That is, a PNP VLAN takes precedence over VLAN 1.
- The switch determines whether to change to the cloud-based management mode and restart based on the device management mode obtained from the DHCP server. If the switch is working in cloud-based management mode, it does not need to change its management mode and restart.
- The switch registers with the cloud management platform based on the cloud management platform's address information obtained from the DHCP server.
- The cloud management platform delivers the PNP VLAN configuration to the switch based on the preconfiguration so that a new switch connected to this switch can perform PNP VLAN auto-negotiation with this switch. The PNP VLAN configuration includes: PNP VLAN ID, enabling the function of transmitting a PNP VLAN to a downstream device, enabling the function of sending LLDP packets containing PNP VLAN information to a downstream device (this function is enabled by default), and enabling the function of transmitting the flag indicating whether to establish an Eth-Trunk to a downstream device.
Processing PNP VLAN switchover
In Figure 5-4, the cloud management platform changes the PNP VLAN of an upstream device to enable a downstream device to use a new PNP VLAN to register with the cloud management platform again.
The upstream device's PNP VLAN and management VLAN are two concepts. The two VLANs can be the same or different. The downstream device can register with the cloud management platform normally when the cloud management platform can communicate with the upstream device normally.
Changing the PNP VLAN enables only the downstream device but not the upstream device to register with the cloud management platform again. Whether the upstream device registers with the cloud management platform again depends on whether its management VLAN is changed.