A method and apparatus for launching bare metal servers in a cloud-free scenario
By coordinating the processing of DHCP messages by the controller and access switch, IP addresses are automatically assigned to bare metal servers, solving the problem of the inability to fully automate the online process of bare metal servers in cloud-free scenarios, and realizing automatic installation of the operating system and automatic configuration of the tenant network.
Patent Information
- Application Number
- CN202211673120.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-12-26
- Publication Date
- 2025-12-02
- Estimated Expiration
- 2042-12-26
AI Technical Summary
In cloudless scenarios, bare metal servers require manual intervention during the PXE and tenant network phases, making it impossible to achieve fully automated deployment. This is especially true when the PXE network and the tenant network are not in the same network, requiring users to manually configure VLAN-VXLAN mapping and VLAN tags, which increases the workload.
Through the coordinated operation of the controller and access switch, and utilizing DHCP message exchange, IP addresses for the PXE network and tenant network are automatically assigned to the bare metal server, enabling automatic installation and online deployment of the operating system. The specific steps include: receiving DHCP Discover messages from the bare metal server, assigning an IP address for the PXE network for system installation, and then assigning an IP address for the tenant network to complete the online deployment.
It enables automated deployment of bare metal servers in cloud-free scenarios, simplifies the user configuration process, improves deployment efficiency, and reduces manual intervention.
Smart Images

Figure CN116016444B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of server technology, and in particular to a method and apparatus for launching a bare metal server in a cloudless scenario. Background Technology
[0002] With the continuous development of cloud computing, users are increasingly using bare metal servers, leading to a growing demand for automated operating system installation. While bare metal solutions are mature with OpenStack cloud platforms, some users now require bare metal servers in cloud-free environments. Currently, without cloud platform notifications, manual intervention is required during the PXE and tenant phases, preventing full automation.
[0003] For example, in scenarios where the PXE network and the tenant network are not in the same network, users need to configure two VLAN-VXLAN mappings on the ports of the switches to which the bare metal servers to be deployed will be connected, according to the plan. One is configured as PVID (Port-base VLAN ID), and the VLAN corresponding to PVID is mapped to the VXLAN corresponding to the PXE network. The other is to select a specific VLAN to map to the VXLAN corresponding to the tenant network, based on the tenant network selected by the user. After the bare metal server is connected, during the PXE phase, the bare metal server's network card obtains an IP address via DHCP. Since there is no VLAN tag, it communicates with the PXE server based on the VXLAN corresponding to the PXE network, and installs the system. After the system is installed, the user needs to configure the corresponding VLAN tag in the operating system, mapping the corresponding VLAN tag to the PXE network VXLAN, in order to complete the service deployment.
[0004] However, if a bare metal server needs to be deployed to a tenant's system after the system is installed, the corresponding VLAN tag needs to be configured in the bare metal server's operating system. Bare metal servers cannot be deployed automatically, which is not a common bare metal usage method and increases the user's configuration workload. Summary of the Invention
[0005] This application provides a method and apparatus for launching a bare metal server in a cloudless scenario.
[0006] Firstly, this application provides a method for bringing bare-metal servers online in a cloud-free scenario, applied to a controller. The controller manages a tenant network and a PXE network, which are isolated from each other. The method includes:
[0007] Receive a first DHCP Discover message sent by a bare metal server, the first DHCP Discover message carrying an identifier to indicate that the bare metal server does not have an operating system installed;
[0008] Send a first DHCP Offer message to the bare metal server. The first DHCP Offer message carries a first IP address assigned to the bare metal server and belonging to the PXE network, and the IP address of the PXE server, so that the bare metal server can communicate with the PXE server based on the first IP address to install the operating system.
[0009] Receive a second DHCP Discover message sent by the bare metal server, wherein the second DHCP Discover message does not carry an identifier for identifying that the bare metal server does not have an operating system installed;
[0010] A second DHCP Offer message is sent to the bare metal server. The second DHCP Offer message carries a second IP address belonging to the tenant network and assigned to the bare metal server, so that the bare metal server can go online in the tenant network based on the second IP address.
[0011] Optionally, the first DHCP Offer message also carries boot file information required for the bare metal server to install the system. Based on the boot file information, the bare metal server communicates with the PXE server based on the first IP address and installs the operating system based on the boot file information.
[0012] Optionally, the bare metal server accesses the tenant network and the PXE network through the target port of the access switch. The PVID configured on the target port is the tenant network VLAN, and a mapping relationship between the tenant network VLAN and the tenant network VXLAN is configured. After receiving the packet sent by the bare metal server, the target port of the switch forwards the packet to the tenant network based on the PVID and the mapping relationship between the tenant network VLAN and the tenant network VXLAN.
[0013] Optionally, the system receives a first DHCP Discover message sent by the network card of the bare metal server. The Vendor class identifier option of the first DHCP Discover message contains a PXE Client field, which is used to identify that the bare metal server does not have an operating system installed.
[0014] Secondly, this application provides a method for bringing a bare metal server online in a cloudless scenario, applied to an access switch. The access switch has a pre-defined PVID as the tenant network VLAN and is configured with a mapping relationship between the tenant network VLAN and the tenant network VXLAN. The bare metal server accesses the tenant network and the PXE network through the target port of the access switch. The tenant network and the PXE network are isolated from each other. The method includes:
[0015] The system receives a first DHCP Discover message sent by the bare metal server and, based on a preset tenant network VLAN and the mapping relationship between the tenant network VLAN and the tenant network VXLAN, sends the first DHCP Discover message to the controller. The first DHCP Discover message carries an identifier to indicate that the bare metal server does not have an operating system installed.
[0016] The system receives a first DHCP Offer message from the controller and sends the first DHCP Offer message to the bare metal server. The first DHCP Offer message carries a first IP address assigned to the bare metal server and belonging to the PXE network, as well as the IP address of the PXE server, so that the bare metal server can communicate with the PXE server based on the first IP address to install the operating system.
[0017] The system receives a second DHCP Discover message sent by the bare metal server and sends the second DHCP Discover message to the controller. The second DHCP Discover message does not carry an identifier to indicate that the bare metal server does not have an operating system installed.
[0018] The system receives a second DHCP Offer message sent by the controller and sends the second DHCP Offer message to the bare metal server. The second DHCP Offer message carries a second IP address belonging to the tenant network assigned to the bare metal server, so that the bare metal server can go online in the tenant network based on the second IP address.
[0019] Thirdly, this application provides a bare-metal server deployment device for a cloud-free scenario, applied to a controller. The controller manages a tenant network and a PXE network, which are isolated from each other. The device includes:
[0020] The receiving unit is configured to receive a first DHCP Discover message sent by the bare metal server, wherein the first DHCP Discover message carries an identifier for identifying that the bare metal server does not have an operating system installed.
[0021] The sending unit is configured to send a first DHCP Offer message to the bare metal server. The first DHCP Offer message carries a first IP address assigned to the bare metal server and belonging to the PXE network, and the IP address of the PXE server, so that the bare metal server can communicate with the PXE server based on the first IP address to install the operating system.
[0022] The receiving unit is further configured to receive a second DHCP Discover message sent by the bare metal server, wherein the second DHCP Discover message does not carry an identifier for identifying that the bare metal server does not have an operating system installed;
[0023] The sending unit is further configured to send a second DHCP Offer message to the bare metal server, the second DHCP Offer message carrying a second IP address belonging to the tenant network assigned to the bare metal server, so that the bare metal server can go online in the tenant network based on the second IP address.
[0024] Optionally, the first DHCP Offer message also carries boot file information required for the bare metal server to install the system. Based on the boot file information, the bare metal server communicates with the PXE server based on the first IP address and installs the operating system based on the boot file information.
[0025] Optionally, the bare metal server accesses the tenant network and the PXE network through the target port of the access switch. The PVID configured on the target port is the tenant network VLAN, and a mapping relationship between the tenant network VLAN and the tenant network VXLAN is configured. After receiving the packet sent by the bare metal server, the target port of the switch forwards the packet to the tenant network based on the PVID and the mapping relationship between the tenant network VLAN and the tenant network VXLAN.
[0026] Optionally, the system receives a first DHCP Discover message sent by the network card of the bare metal server. The Vendor class identifier option of the first DHCP Discover message contains a PXE Client field, which is used to identify that the bare metal server does not have an operating system installed.
[0027] Fourthly, this application provides a bare metal server deployment device for a cloudless scenario, applied to an access switch. The access switch has a pre-defined PVID as a tenant network VLAN and is configured with a mapping relationship between the tenant network VLAN and the tenant network VXLAN. The bare metal server accesses the tenant network and the PXE network through the target port of the access switch. The tenant network and the PXE network are isolated from each other. The device includes:
[0028] The first receiving unit is configured to receive the first DHCP Discover message sent by the bare metal server;
[0029] The first sending unit is used to send the first DHCP Discover message to the controller based on a preset tenant network VLAN and the mapping relationship between the tenant network VLAN and the tenant network VXLAN. The first DHCP Discover message carries an identifier for identifying that the bare metal server does not have an operating system installed.
[0030] The second receiving unit is used to receive the first DHCP Offer message sent by the controller;
[0031] The second sending unit is used to send the first DHCP Offer message to the bare metal server. The first DHCP Offer message carries a first IP address assigned to the bare metal server and belonging to the PXE network, and the IP address of the PXE server, so that the bare metal server can communicate with the PXE server based on the first IP address to install the operating system.
[0032] The first receiving unit is further configured to receive a second DHCP Discover message sent by the bare metal server, and the first sending unit is further configured to send the second DHCP Discover message to the controller, wherein the second DHCP Discover message does not carry an identifier for identifying that the bare metal server does not have an operating system installed.
[0033] The second receiving unit is further configured to receive a second DHCP Offer message sent by the controller, and the second sending unit is further configured to send the second DHCP Offer message to the bare metal server. The second DHCP Offer message carries a second IP address belonging to the tenant network assigned to the bare metal server, so that the bare metal server can go online in the tenant network based on the second IP address.
[0034] Fifthly, embodiments of this application provide a device for bringing a bare metal server online in a cloudless scenario, the device comprising:
[0035] Memory, used to store program instructions;
[0036] A processor is configured to invoke program instructions stored in the memory and execute the steps of the method as described in any one of the first and second aspects above, according to the obtained program instructions.
[0037] In a sixth aspect, embodiments of this application also provide a computer-readable storage medium storing computer-executable instructions for causing the computer to perform the steps of the method as described in any one of the first / second aspects above.
[0038] In summary, the bare metal server online method in a cloudless scenario provided in this application embodiment is applied to a controller. The controller manages a tenant network and a PXE network, which are isolated from each other. The method includes: receiving a first DHCP Discover message sent by the bare metal server, the first DHCP Discover message carrying an identifier indicating that the bare metal server does not have an operating system installed; sending a first DHCP Offer message to the bare metal server, the first DHCP Offer message carrying a first IP address assigned to the bare metal server belonging to the PXE network and the IP address of the PXE server, so that the bare metal server can communicate with the PXE server based on the first IP address to install the operating system; receiving a second DHCP Discover message sent by the bare metal server, the second DHCP Discover message not carrying an identifier indicating that the bare metal server does not have an operating system installed; sending a second DHCP Offer message to the bare metal server, the second DHCP Offer message carrying a second IP address assigned to the bare metal server belonging to the tenant network, so that the bare metal server can go online in the tenant network based on the second IP address.
[0039] The bare metal server online method in a cloudless scenario provided in this application only requires configuring a PVID and a VLAN-VXLAN mapping relationship on a designated port of the access switch. DHCP messages sent by the bare metal server are forwarded to the controller. When the DHCP Discover message carries an identifier indicating that the bare metal server does not have an operating system installed, the controller assigns an IP address to the bare metal server for communication with the PXE server and informs the bare metal server of the PXE server's IP address. The bare metal server interacts with the PXE server based on this IP address to complete the operating system installation. After installation, it sends another DHCP message to obtain an IP address belonging to the tenant network, thus completing the online process on the tenant network based on this IP address. This eliminates the need for user reconfiguration, simplifying the online process and improving automated online efficiency. Attached Figure Description
[0040] To more clearly illustrate the technical solutions in the embodiments of this application or the prior art, the drawings used in the description of the embodiments of this application or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments recorded in this application. For those skilled in the art, other drawings can be obtained based on these drawings of the embodiments of this application.
[0041] Figure 1 A network topology diagram provided for an embodiment of this application;
[0042] Figure 2 A detailed flowchart illustrating a method for bringing a bare metal server online in a cloudless scenario, as provided in this application embodiment;
[0043] Figure 3 A detailed flowchart of another method for bringing a bare metal server online in a cloudless scenario provided in this application embodiment;
[0044] Figure 4 A schematic diagram of a bare metal server online device in a cloudless scenario provided in this application embodiment;
[0045] Figure 5 A schematic diagram of another bare metal server online device in a cloudless scenario provided in this application embodiment;
[0046] Figure 6 A schematic diagram of the hardware architecture of a bare metal server online device in a cloudless scenario provided in this application embodiment;
[0047] Figure 7 This is a schematic diagram of the hardware architecture of a bare metal server online device in a cloudless scenario, as provided in an embodiment of this application. Detailed Implementation
[0048] The terminology used in the embodiments of this application is for the purpose of describing particular embodiments only and is not intended to limit the application. The singular forms “a,” “the,” and “the” as used in this application and claims are also intended to include the plural forms unless the context clearly indicates otherwise. It should also be understood that the term “and / or” as used herein refers to any and all possible combinations comprising one or more of the associated listed items.
[0049] It should be understood that although the terms first, second, third, etc., may be used to describe various information in embodiments of this application, such information should not be limited to these terms. These terms are only used to distinguish information of the same type from one another. For example, without departing from the scope of this application, first information may also be referred to as second information, and similarly, second information may also be referred to as first information. Depending on the context, the word "if" may also be interpreted as "when," "when," or "in response to a determination."
[0050] Currently, in scenarios where the PXE network and the tenant network are not part of the same network—that is, scenarios where the PXE network and the tenant network (service network) need to be isolated—devices in the PXE network and the tenant network cannot communicate. For example, see [link to relevant documentation]. Figure 1 The diagram shown is a network topology diagram provided in an embodiment of this application. The network includes a PXE network and a tenant network. The PXE network includes at least a PXE Server, which maintains installation files for various operating systems. The SDN controller allocates IP network segments for the PXE network and also allocates IP network segments for the tenant network. The bare metal server is connected to the network through an access switch.
[0051] The following describes in detail the method for launching bare metal servers in a cloudless scenario provided in this application embodiment, with specific application scenarios in mind. For example, see [link to relevant documentation]. Figure 2 The diagram shown is a detailed flowchart of a method for bringing a bare metal server online in a cloudless scenario, provided by an embodiment of this application. This method is applied to a controller, which manages a tenant network and a PXE network. The tenant network and the PXE network are isolated from each other. The method includes the following steps:
[0052] Step 200: Receive a first DHCP Discover message sent by the bare metal server. The first DHCP Discover message carries an identifier to indicate that the bare metal server does not have an operating system installed.
[0053] In this embodiment, the bare metal server accesses the tenant network and the PXE network through the target port of the access switch. The PVID configured on the target port is the tenant network VLAN, and a mapping relationship between the tenant network VLAN and the tenant network VXLAN is configured. After receiving the packet sent by the bare metal server, the target port of the switch forwards the packet to the tenant network based on the PVID and the mapping relationship between the tenant network VLAN and the tenant network VXLAN.
[0054] In practical applications, according to the tenant plan, the switch is pre-bound to the VLAN-VXLAN mapping corresponding to the tenant on a designated port. The VLAN is the VLAN assigned to the tenant network (e.g., VLAN 1), and the VXLAN is also the VXLAN assigned to the tenant network. The PVID is configured to be the VLAN of the tenant network (e.g., VLAN 1). The purpose of the plan is to send the DHCP packets sent by the bare metal server received through the designated port to the controller.
[0055] In this embodiment of the application, a first DHCP Discover message sent by the network card of the bare metal server is received. The Vendor class identifier Option of the first DHCP Discover message contains a PXE Client field, which is used to identify that the bare metal server does not have an operating system installed.
[0056] In other words, when a bare metal server is connected to a designated port of a switch and powered on, the bare metal server's PXE network card sends a DHCP Discover message. In this embodiment, this DHCP Discover message is referred to as the first DHCPDiscover message. At this time, since the bare metal server has not installed any operating information, the Vendor class identifier Option of the first DHCPDiscover message it sends contains the PXE Client field. This indicates that the bare metal server has entered the PXE stage, which refers to the stage of operating system installation via PXE.
[0057] Step 210: Send a first DHCP Offer message to the bare metal server. The first DHCP Offer message carries a first IP address assigned to the bare metal server, belonging to the PXE network, and the IP address of the PXE server.
[0058] In this embodiment of the application, the bare metal server, upon receiving a first DHCP Offer message, communicates with the PXE server based on the first IP address to install the operating system.
[0059] Optionally, in this embodiment of the application, the first DHCP Offer message also carries boot file information required for the bare metal server to install the system. Based on the boot file information, the bare metal server communicates with the PXE server based on the first IP address and installs the operating system based on the boot file information.
[0060] Furthermore, after the bare metal server's network interface card obtains the first IP address, which belongs to the IP address pool planned for the PXE network, the first DHCP Offer message also carries the IP address of the PXE server. In this way, the bare metal server can communicate with the PXE server through the access switch and, based on the file name information of the operating system provided by the controller, start the operating system installation and perform subsequent operating system installation operations.
[0061] Step 220: Receive a second DHCP Discover message sent by the bare metal server. The second DHCP Discover message does not carry an identifier to indicate that the bare metal server does not have an operating system installed.
[0062] After the bare metal server confirms that the PXE phase is complete, i.e., the operating system installation is complete, it sends a second DHCP Discover message to the access switch. The access switch forwards the received second DHCP Discover message to the controller. The controller determines that the Vendor class identifier Option in the second DHCP Discover message does not contain the PXE Client field. At this point, it is determined that the bare metal server has an operating system installed and needs to go online in the tenant network. Therefore, the controller assigns a second IP address belonging to the tenant network to the bare metal server and returns it to the bare metal server in a second DHCP Offer message.
[0063] Step 230: Send a second DHCP Offer message to the bare metal server. The second DHCP Offer message carries a second IP address belonging to the tenant network assigned to the bare metal server, so that the bare metal server can go online in the tenant network based on the second IP address.
[0064] For example, see Figure 3The diagram shown is a detailed flowchart of a method for bringing a bare metal server online in a cloudless scenario according to an embodiment of this application. This method is applied to an access switch, where the PVID preset on the access switch is the tenant network VLAN, and a mapping relationship between the tenant network VLAN and the tenant network VXLAN is configured. The bare metal server accesses the tenant network and the PXE network through the target port of the access switch. The tenant network and the PXE network are isolated from each other. The method includes the following steps:
[0065] Step 300: Receive the first DHCP Discover message sent by the bare metal server, and based on the preset tenant network VLAN and the mapping relationship between the tenant network VLAN and the tenant network VXLAN, send the first DHCP Discover message to the controller. The first DHCP Discover message carries an identifier to indicate that the bare metal server does not have an operating system installed.
[0066] Step 310: Receive the first DHCP Offer message sent by the controller and send the first DHCP Offer message to the bare metal server. The first DHCP Offer message carries a first IP address assigned to the bare metal server and belonging to the PXE network, and the IP address of the PXE server, so that the bare metal server can communicate with the PXE server based on the first IP address to install the operating system.
[0067] Step 320: Receive the second DHCP Discover message sent by the bare metal server, and send the second DHCP Discover message to the controller. The second DHCP Discover message does not carry an identifier to indicate that the bare metal server does not have an operating system installed.
[0068] Step 330: Receive the second DHCP Offer message sent by the controller and send the second DHCP Offer message to the bare metal server. The second DHCP Offer message carries a second IP address belonging to the tenant network assigned to the bare metal server, so that the bare metal server can go online in the tenant network based on the second IP address.
[0069] Based on the same inventive concept as the above-described embodiments, see, for example, the following: Figure 4 The diagram shown is a structural schematic of a bare metal server deployment device in a cloudless scenario provided in this application embodiment. This device is applied to a controller, which manages a tenant network and a PXE network. The tenant network and the PXE network are isolated from each other. The device includes:
[0070] The receiving unit 40 is configured to receive a first DHCP Discover message sent by the bare metal server, the first DHCP Discover message carrying an identifier for identifying that the bare metal server does not have an operating system installed;
[0071] Sending unit 41 is used to send a first DHCP Offer message to the bare metal server. The first DHCP Offer message carries a first IP address assigned to the bare metal server and belonging to the PXE network, and the IP address of the PXE server, so that the bare metal server can communicate with the PXE server based on the first IP address to install the operating system.
[0072] The receiving unit 40 is further configured to receive a second DHCP Discover message sent by the bare metal server, wherein the second DHCP Discover message does not carry an identifier for identifying that the bare metal server does not have an operating system installed;
[0073] The sending unit 41 is further configured to send a second DHCP Offer message to the bare metal server, the second DHCP Offer message carrying a second IP address belonging to the tenant network assigned to the bare metal server, so that the bare metal server can go online in the tenant network based on the second IP address.
[0074] Optionally, the first DHCP Offer message also carries boot file information required for the bare metal server to install the system. Based on the boot file information, the bare metal server communicates with the PXE server based on the first IP address and installs the operating system based on the boot file information.
[0075] Optionally, the bare metal server accesses the tenant network and the PXE network through the target port of the access switch. The PVID configured on the target port is the tenant network VLAN, and a mapping relationship between the tenant network VLAN and the tenant network VXLAN is configured. After receiving the packet sent by the bare metal server, the target port of the switch forwards the packet to the tenant network based on the PVID and the mapping relationship between the tenant network VLAN and the tenant network VXLAN.
[0076] Optionally, the system receives a first DHCP Discover message sent by the network card of the bare metal server. The Vendor class identifier option of the first DHCP Discover message contains a PXE Client field, which is used to identify that the bare metal server does not have an operating system installed.
[0077] For example, see Figure 5 The diagram shown is a structural schematic of a bare metal server online device in a cloudless scenario provided in this application embodiment. This device is applied to an access switch. The access switch has a preset PVID as the tenant network VLAN and is configured with a mapping relationship between the tenant network VLAN and the tenant network VXLAN. The bare metal server accesses the tenant network and the PXE network through the target port of the access switch. The tenant network and the PXE network are isolated from each other. The device includes:
[0078] The first receiving unit 50 is used to receive the first DHCP Discover message sent by the bare metal server;
[0079] The first sending unit 51 is used to send the first DHCP Discover message to the controller based on a preset tenant network VLAN and the mapping relationship between the tenant network VLAN and the tenant network VXLAN. The first DHCP Discover message carries an identifier for identifying that the bare metal server does not have an operating system installed.
[0080] The second receiving unit 52 is used to receive the first DHCP Offer message sent by the controller;
[0081] The second sending unit 53 is used to send the first DHCP Offer message to the bare metal server. The first DHCP Offer message carries a first IP address assigned to the bare metal server and belonging to the PXE network, and the IP address of the PXE server, so that the bare metal server can communicate with the PXE server based on the first IP address to install the operating system.
[0082] The first receiving unit 50 is further configured to receive a second DHCP Discover message sent by the bare metal server, and the first sending unit 51 is further configured to send the second DHCP Discover message to the controller, wherein the second DHCP Discover message does not carry an identifier for identifying that the bare metal server does not have an operating system installed.
[0083] The second receiving unit 52 is further configured to receive a second DHCP Offer message sent by the controller, and the second sending unit 53 is further configured to send the second DHCP Offer message to the bare metal server. The second DHCP Offer message carries a second IP address assigned to the bare metal server and belonging to the tenant network, so that the bare metal server can go online in the tenant network based on the second IP address.
[0084] These units can be one or more integrated circuits configured to implement the above methods, such as one or more Application Specific Integrated Circuits (ASICs), one or more digital signal processors (DSPs), or one or more Field Programmable Gate Arrays (FPGAs). Alternatively, when one of these units is implemented using processing element scheduler code, the processing element can be a general-purpose processor, such as a Central Processing Unit (CPU) or other processor capable of calling program code. Furthermore, these units can be integrated together to form a system-on-a-chip (SOC).
[0085] Furthermore, regarding the bare metal server deployment device in a cloudless scenario provided in this application embodiment, from a hardware perspective, the hardware architecture diagram of the bare metal server deployment device in a cloudless scenario can be found in [reference needed]. Figure 6 As shown, the bare metal server deployment device in the cloudless scenario may include: a memory 60 and a processor 61.
[0086] The memory 60 is used to store program instructions; the processor 61 calls the program instructions stored in the memory 60 and executes the method embodiment applied to the controller according to the obtained program instructions. The specific implementation and technical effects are similar, and will not be described again here.
[0087] Optionally, this application also provides a controller, including at least one processing element (or chip) for performing the above-described method embodiments applied to the controller.
[0088] Optionally, this application also provides a program product, such as a computer-readable storage medium storing computer-executable instructions for causing the computer to perform the above-described method embodiments applied to the controller.
[0089] Furthermore, regarding the bare metal server deployment device in a cloudless scenario provided in this application embodiment, from a hardware perspective, the hardware architecture diagram of the bare metal server deployment device in a cloudless scenario can be found in [reference needed]. Figure 7 As shown, the bare metal server deployment device in the cloudless scenario may include: a memory 70 and a processor 71.
[0090] The memory 70 is used to store program instructions; the processor 71 calls the program instructions stored in the memory 70 and executes the method embodiment applied to the access switch as described above according to the obtained program instructions. The specific implementation method and technical effect are similar, and will not be described again here.
[0091] Optionally, this application also provides an access switch, including at least one processing element (or chip) for performing the above-described method embodiments applied to the access switch.
[0092] Optionally, this application also provides a program product, such as a computer-readable storage medium storing computer-executable instructions for causing the computer to execute the above-described method embodiments applied to an access switch.
[0093] Here, a machine-readable storage medium can be any electronic, magnetic, optical, or other physical storage device that can contain or store information, such as executable instructions, data, etc. For example, a machine-readable storage medium can be: RAM (Random Access Memory), volatile memory, non-volatile memory, flash memory, storage drives (such as hard disk drives), solid-state drives, any type of storage disk (such as optical discs, DVDs, etc.), or similar storage media, or combinations thereof.
[0094] The systems, devices, modules, or units described in the above embodiments can be implemented by computer chips or entities, or by products with certain functions. A typical implementation device is a computer, which can take the form of a personal computer, laptop computer, cellular phone, camera phone, smartphone, personal digital assistant, media player, navigation device, email sending and receiving device, game console, tablet computer, wearable device, or any combination of these devices.
[0095] For ease of description, the above devices are described separately by function as various units. Of course, in implementing this application, the functions of each unit can be implemented in one or more software and / or hardware.
[0096] Those skilled in the art will understand that embodiments of this application can be provided as methods, systems, or computer program products. Therefore, this application can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, embodiments of this application can take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0097] This application is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of this application. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart... Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.
[0098] Furthermore, these computer program instructions can also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to operate in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in the process. Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.
[0099] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.
[0100] The above description is merely a preferred embodiment of this application and is not intended to limit this application. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this application should be included within the scope of protection of this application.
Claims
1. A method for deploying a bare metal server in a cloud-free scenario, characterized in that, The method is applied to a controller that manages tenant networks and PXE networks, which are isolated from each other. The system receives a first DHCP Discover message sent by a bare metal server. The first DHCP Discover message carries an identifier to indicate that the bare metal server does not have an operating system installed. The bare metal server is connected to the tenant network and the PXE network through the target port of the access switch. The PVID configured on the target port is the tenant network VLAN, and a mapping relationship between the tenant network VLAN and the tenant network VXLAN is configured. After receiving the message sent by the bare metal server, the target port of the switch forwards the message to the tenant network based on the PVID and the mapping relationship between the tenant network VLAN and the tenant network VXLAN. Send a first DHCP Offer message to the bare metal server. The first DHCP Offer message carries a first IP address assigned to the bare metal server and belonging to the PXE network, and the IP address of the PXE server, so that the bare metal server can communicate with the PXE server based on the first IP address to install the operating system. Receive a second DHCP Discover message sent by the bare metal server, wherein the second DHCP Discover message does not carry an identifier for identifying that the bare metal server does not have an operating system installed; A second DHCP Offer message is sent to the bare metal server. The second DHCP Offer message carries a second IP address belonging to the tenant network and assigned to the bare metal server, so that the bare metal server can go online in the tenant network based on the second IP address.
2. The method as described in claim 1, characterized in that, The first DHCP Offer message also carries the boot file information required for the bare metal server to install the system. Based on the boot file information, the bare metal server communicates with the PXE server based on the first IP address and installs the operating system based on the boot file information.
3. The method as described in claim 1 or 2, characterized in that, The system receives a first DHCP Discover message sent by the network card of the bare metal server. The Vendor class identifier option of the first DHCP Discover message contains a PXE Client field, which is used to identify that the bare metal server does not have an operating system installed.
4. A method for deploying a bare-metal server in a cloud-free scenario, characterized in that, The method is applied to an access switch, where the preset PVID on the access switch is the tenant network VLAN, and a mapping relationship between the tenant network VLAN and the tenant network VXLAN is configured. A bare metal server accesses the tenant network and the PXE network through the target port of the access switch. The tenant network and the PXE network are mutually isolated. The system receives a first DHCP Discover message sent by the bare metal server and, based on a preset tenant network VLAN and the mapping relationship between the tenant network VLAN and the tenant network VXLAN, sends the first DHCP Discover message to the controller. The first DHCP Discover message carries an identifier to indicate that the bare metal server does not have an operating system installed. The system receives a first DHCP Offer message from the controller and sends the first DHCP Offer message to the bare metal server. The first DHCP Offer message carries a first IP address assigned to the bare metal server and belonging to the PXE network, as well as the IP address of the PXE server, so that the bare metal server can communicate with the PXE server based on the first IP address to install the operating system. The system receives a second DHCP Discover message sent by the bare metal server and sends the second DHCP Discover message to the controller. The second DHCP Discover message does not carry an identifier to indicate that the bare metal server does not have an operating system installed. The system receives a second DHCP Offer message sent by the controller and sends the second DHCP Offer message to the bare metal server. The second DHCP Offer message carries a second IP address belonging to the tenant network assigned to the bare metal server, so that the bare metal server can go online in the tenant network based on the second IP address.
5. A device for launching a bare metal server in a cloud-free scenario, characterized in that, An application for a controller that manages tenant networks and PXE networks, the tenant networks and PXE networks being isolated from each other, the device comprising: The receiving unit is configured to receive a first DHCP Discover message sent by a bare metal server. The first DHCP Discover message carries an identifier indicating that the bare metal server does not have an operating system installed. The bare metal server is connected to the tenant network and the PXE network through the target port of the access switch. The PVID configured on the target port is the tenant network VLAN, and a mapping relationship between the tenant network VLAN and the tenant network VXLAN is configured. After receiving the message sent by the bare metal server, the target port of the switch forwards the message to the tenant network based on the PVID and the mapping relationship between the tenant network VLAN and the tenant network VXLAN. The sending unit is configured to send a first DHCP Offer message to the bare metal server. The first DHCP Offer message carries a first IP address assigned to the bare metal server and belonging to the PXE network, and the IP address of the PXE server, so that the bare metal server can communicate with the PXE server based on the first IP address to install the operating system. The receiving unit is further configured to receive a second DHCP Discover message sent by the bare metal server, wherein the second DHCP Discover message does not carry an identifier for identifying that the bare metal server does not have an operating system installed; The sending unit is further configured to send a second DHCP Offer message to the bare metal server, the second DHCP Offer message carrying a second IP address belonging to the tenant network assigned to the bare metal server, so that the bare metal server can go online in the tenant network based on the second IP address.
6. The apparatus as claimed in claim 5, characterized in that, The first DHCP Offer message also carries the boot file information required for the bare metal server to install the system. Based on the boot file information, the bare metal server communicates with the PXE server based on the first IP address and installs the operating system based on the boot file information.
7. The apparatus as described in claim 5 or 6, characterized in that, The system receives a first DHCP Discover message sent by the network card of the bare metal server. The Vendor class identifier option of the first DHCP Discover message contains a PXE Client field, which is used to identify that the bare metal server does not have an operating system installed.
8. A device for launching a bare metal server in a cloud-free scenario, characterized in that, The device is applied to an access switch, where the preset PVID on the access switch is the tenant network VLAN, and a mapping relationship between the tenant network VLAN and the tenant network VXLAN is configured. A bare metal server accesses the tenant network and the PXE network through the target port of the access switch. The tenant network and the PXE network are isolated from each other. The device includes: The first receiving unit is configured to receive the first DHCP Discover message sent by the bare metal server; The first sending unit is used to send the first DHCP Discover message to the controller based on a preset tenant network VLAN and the mapping relationship between the tenant network VLAN and the tenant network VXLAN. The first DHCP Discover message carries an identifier for identifying that the bare metal server does not have an operating system installed. The second receiving unit is used to receive the first DHCP Offer message sent by the controller; The second sending unit is used to send the first DHCP Offer message to the bare metal server. The first DHCP Offer message carries a first IP address assigned to the bare metal server and belonging to the PXE network, and the IP address of the PXE server, so that the bare metal server can communicate with the PXE server based on the first IP address to install the operating system. The first receiving unit is further configured to receive a second DHCP Discover message sent by the bare metal server, and the first sending unit is further configured to send the second DHCP Discover message to the controller, wherein the second DHCP Discover message does not carry an identifier for identifying that the bare metal server does not have an operating system installed. The second receiving unit is further configured to receive a second DHCP Offer message sent by the controller, and the second sending unit is further configured to send the second DHCP Offer message to the bare metal server. The second DHCP Offer message carries a second IP address belonging to the tenant network assigned to the bare metal server, so that the bare metal server can go online in the tenant network based on the second IP address.
Citation Information
Patent Citations
Bare metal server network configuration method and system and related equipment
CN111901177A
Automatic bare computer deployment method and device and cloud environment platform
CN112491630A