File deployment method and computing device
By dividing the second computing device into a multi-level structure and using DHCP, TFTP and NFS components for automated deployment, the problem of long deployment time in large-scale deployments is solved, achieving efficient file deployment and resource saving.
Patent Information
- Application Number
- CN202511417060.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-09-29
- Publication Date
- 2026-01-16
AI Technical Summary
In large-scale deployment scenarios, existing technologies require multiple rounds of deployment for the first computing device to complete the deployment of target files to multiple second computing devices, resulting in long deployment times and low efficiency.
Multiple secondary computing devices are divided into a multi-level structure according to their order, so that computing devices other than the first level can obtain target files through their own attached parent nodes. The number of concurrent deployment rounds for the first computing device is reduced, and the number of concurrent deployments is increased by increasing the hierarchy of the multi-level structure. Automated deployment is achieved by combining DHCP, TFTP and NFS components.
It shortens the deployment time of target files, improves file deployment efficiency, reduces the resource consumption of the primary computing device, and simplifies the configuration process.
Smart Images

Figure CN121349476A_ABST
Abstract
Description
TECHNICAL FIELD
[0001] Embodiments of the present application relate to the technical field of computing devices, and particularly relate to a file deployment method and a computing device. BACKGROUND
[0002] In some scenarios, a user needs to deploy a target file in multiple second computing devices (such as servers) in batches.
[0003] In the related art, the user can use a first computing device to deploy the target file in the multiple second computing devices in a remote deployment manner. For example, the user can use a first computing device supporting a Preboot eXecution Environment (PXE) technology to remotely deploy an image file in a second computing device, so as to remotely deploy and start an Operating System (OS) of the second computing device through the image file.
[0004] However, in a large-scale deployment scenario (such as the number of second computing devices is several thousand), the first computing device needs to perform multiple rounds of deployment to complete the deployment of the target file in the second computing devices, which results in a long file deployment time of the target file and a low file deployment efficiency. SUMMARY
[0005] Embodiments of the present application provide a file deployment method and a computing device, which can reduce the deployment rounds of the first computing device in the process of deploying a target file in multiple second computing devices in a large-scale deployment scenario, thereby facilitating to shorten the deployment time of the target file and improve the file deployment efficiency.
[0006] In a first aspect, embodiments of the present application provide a file deployment method applied in a first computing device, and the method comprises:
[0007] obtaining deployment information of multiple second computing devices; the deployment information is used to indicate deployment of a target file on the multiple second computing devices; wherein the multiple second computing devices are divided into multiple levels according to an order, each level includes one or more second computing devices, and a second computing device in an Nth level is a parent node of at least one second computing device in an (N+1)th level, N is a positive integer;
[0008] deploying the target file to a second computing device in a first level;
[0009] sending a first file acquisition address to a second computing device in a level other than the first level; the first file acquisition address is used to indicate the second computing device to acquire the target file from a parent node to which the second computing device is connected.
[0010] In the above technical solution, by deploying multiple second computing devices in a multi-level structure, the second computing devices in other levels do not need to obtain target files from the first computing device. Instead, they obtain the target files through their own attached parent nodes. The number of concurrent deployments of target files by the first computing device can increase with the increase of the multi-level structure. This reduces the number of deployment rounds for the first computing device to concurrently deploy the target system of multiple second computing devices, thus solving the problem of increased deployment rounds and extended deployment time caused by the limited number of devices that the first computing device can support downloading target files simultaneously. Furthermore, the target files are no longer fixed to one or more devices, but rather exhibit fission-like deployment with the hierarchical deployment of the multi-level structure. The larger the scale of the multi-level structure, the more file sources the target files have, resulting in faster deployment speed and higher deployment efficiency for the first computing device. This fission-like deployment method can reduce the number of first computing devices configured in large-scale deployment scenarios, thereby reducing the amount of resources occupied by the first computing device. In summary, this technical solution is beneficial for improving the file deployment efficiency of the first computing device to multiple second computing devices.
[0011] In one possible implementation, deploying the target file to the second computing device in the first stage includes:
[0012] Send a second file retrieval address to the second computing device in the first level. The second file retrieval address is used to instruct the second computing device in the first level to retrieve the target file from the first computing device to which it is connected.
[0013] In response to a file retrieval request sent by the second computing device in the first level, the target file is sent to the second computing device in the first level.
[0014] In the above technical solution, the first computing device can send a second file retrieval address to the second computing device in the first stage, enabling the second computing device in the first stage to accurately retrieve the target file based on the second file retrieval address. Upon receiving a file retrieval request, the first computing device can send the target file to the second computing device in the first stage to avoid the second computing device in the first stage receiving the target file before it is ready, thus preventing abnormalities in the target file transmission process.
[0015] In one possible implementation, the first computing device deploys multiple deployment components; sending a second file acquisition address to the second computing device in the first stage includes:
[0016] The deployment boot parameters corresponding to the second computing device in the first level are configured through multiple deployment components. The deployment boot parameters are used to indicate the address where the second file is obtained.
[0017] Send deployment boot parameters to the second computing device in the first stage;
[0018] Several deployment components include DHCP, TFTP, and NFS components.
[0019] In the above technical solution, the first computing device (such as a "PXE server") can be a fully functional server. This server internally runs a management module that integrates multiple deployment components, including DHCP, TFTP, and NFS components. This allows the first computing device to automatically configure corresponding deployment boot parameters for the second computing devices through these components, and to automatically deploy the target files of the second computing devices based on these parameters. During the deployment of target files from multiple second computing devices, the first computing device can do so without requiring the user to manually install these deployment components, thus saving deployment time, improving deployment efficiency, and enhancing user convenience.
[0020] In one possible implementation, the method is directed to a second computing device in the Nth stage; the method further includes:
[0021] After confirming that the second computing device has completed the deployment of the target file, control the second computing device to start the NFS service; the NFS service is used to share the file retrieval address of the target file in the second computing device with the child nodes of the second computing device.
[0022] It should be noted that if the target file is an image file, the image file is used to deploy the target system in the second computing device. After the first computing device determines that the second computing device has completed the deployment of the target file and that the second computing device has child nodes attached, it can control the second computing device to deploy the target system (such as an OS) based on the target file. After determining that the second computing device has completed the deployment of the target system and that the second computing device has child nodes attached, the image file is stored in the target directory of the second computing device, and the second computing device is controlled to start the NFS service to expose the target directory to the child nodes attached to the second computing device.
[0023] In the above technical solution, after the target file is deployed on the second computing device, it can be determined whether the computing device has child nodes attached. If the second computing device has child nodes attached, the second computing device can be controlled to start an NFS service to expose the file retrieval address of the target file on the second computing device to the child nodes attached to the second computing device. This can turn the second computing device into a secondary target file source to realize the chained deployment of the target file, which is beneficial to improving the file deployment efficiency of the target file.
[0024] In one possible implementation, the method is directed to a second computing device in the Nth stage; the method further includes:
[0025] After the child nodes attached to the second computing device complete the deployment of the target files, control the second computing device to shut down the NFS service;
[0026] If the target file is an image file, the image file is used to deploy the target system in the second computing device, and the method further includes:
[0027] After the target system deployment is completed on the child node attached to the second computing device, the target file is deleted from the second computing device.
[0028] In the above technical solution, after the child nodes attached to the second computing device complete the deployment of the target file, the NFS service of the second computing device can be shut down to avoid the NFS service consuming the resources of the second computing device. Furthermore, in scenarios where the target file is used to deploy the target system, the target file can be deleted from the second computing device after the child nodes attached to the second computing device complete the deployment of the target system, thereby releasing the storage resources of the second computing device and ensuring that the deployment process of the target file has no impact on the storage resources of the second computing device. In the deployment scenario of the target system, the target file is no longer permanently stored on one or more devices, but is temporarily generated and deleted during the hierarchical deployment process of the multi-level structure. This allows the target file to be deployed in a fission-like manner with the hierarchical deployment of the multi-level structure, and the target file has no impact on the storage resources of the second computing device during the deployment process, thus achieving fission-like deployment of the target system and improving the deployment efficiency of the target system.
[0029] In one possible implementation, the method further includes:
[0030] Based on the grouping indication information of multiple second computing devices in the deployment information, the multiple second computing devices are divided into multiple device groups, and the grouping indication information of the second computing devices within the same device group is the same;
[0031] Based on the number of first devices that the first computing device can support simultaneously downloading target files and the number of second devices that the second computing device can support simultaneously downloading target files, determine the first deployment order among multiple device groups and the second deployment order of the second computing devices within each device group;
[0032] The topology configuration strategy is determined based on the first deployment order and the second deployment order of the second computing devices within each device group;
[0033] Based on the topology configuration strategy, multiple secondary computing devices are deployed as multi-level secondary computing devices;
[0034] The grouping indication information includes at least one of the following information of the second computing device: rack information, network segment information, computer room information, or functional information.
[0035] Topology configuration policies can be used to indicate the deployment process of deploying multiple second computing devices as multi-level second computing devices. Topology configuration policies can be used to indicate the following information: the total number of levels in the multi-level structure; the deployment order of the multi-level second computing devices; the allocation of a first computing device in the root node; and the device information of at least one second computing device allocated in each level of the multi-level structure. The device information may include the device identifier of the second computing device, the node identifier corresponding to the second computing device in that level, and the device identifier and / or node identifier of the parent node to which the computing device is attached.
[0036] The first computing device can determine the number of first devices based on its network card speed and the data volume of the target file; the second computing device can determine the number of second devices based on its network card speed and the data volume of the target file. Alternatively, the deployment information can include the number of first and second devices.
[0037] In the above technical solution, users do not need to manually specify the deployment order of multiple second computing devices. The first computing device can automatically generate a topology configuration strategy by combining the grouping indication information in the deployment information. The first computing device can determine the topology configuration strategy according to the deployment principle of fastest deployment speed and shortest deployment time for a single second computing device, based on the first deployment order and the second deployment order among the second computing devices within each device group. This ensures that the multi-level structure generated based on the topology configuration strategy allows the first computing device to deploy target files (or target systems) of multiple second computing devices more quickly, and also helps to shorten the file deployment time of the second computing devices.
[0038] In one possible implementation, the target file is an image file, which is used to deploy the target system in a second computing device.
[0039] In the above technical solution, the first computing device can deploy an image file on the second computing device, enabling the second computing device to automatically deploy the target system based on the image file, which helps to improve the deployment efficiency of the target system.
[0040] Secondly, embodiments of this application provide a file deployment method applied in a second computing device, the method comprising:
[0041] Obtain the file retrieval address; the file retrieval address is sent by the parent node of the second computing device or by the first computing device; wherein, multiple second computing devices are divided into multiple levels in order, each level includes one or more second computing devices, and the second computing device in the Nth level is the parent node of at least one second computing device in the N+1th level, where N is a positive integer;
[0042] Based on the file address, the target file is obtained from the parent node of the second computing device;
[0043] In response to a file retrieval request from a child node of the second computing device, the target file is sent to the attached child node.
[0044] In the above technical solution, by deploying multiple second computing devices in a multi-level structure in sequence, the second computing devices can obtain the target file from the parent node of the second computing device based on the file acquisition address, and can send the target file to the attached child node in response to the file acquisition request of the child node of the second computing device, so as to realize the chained deployment of the file source of the target file, which is beneficial to improving the file deployment efficiency of the target file.
[0045] In one possible implementation, the method further includes:
[0046] After the target file is deployed on the second computing device and child nodes are attached to the second computing device, the NFS service is started under the control of the first computing device. The NFS service is used to share the file retrieval address of the target file in the second computing device with the child nodes of the second computing device.
[0047] In the above technical solution, after the target file is deployed on the second computing device, it can be determined whether the computing device has child nodes attached. If the second computing device has child nodes attached, the second computing device can start an NFS service under the control of the first computing device to expose the file retrieval address of the target file on the second computing device to the child nodes attached to the second computing device. This can turn the second computing device into a secondary target file source to realize the chained deployment of the target file, which is beneficial to improving the file deployment efficiency of the target file.
[0048] In one possible implementation, the method further includes:
[0049] After the child nodes attached to the second computing device complete the deployment of the target files, the NFS service is shut down under the control of the first computing device.
[0050] If the target file is an image file, the image file is used to deploy the target system in the second computing device, and the method further includes:
[0051] After the target system deployment is completed on the child node attached to the second computing device, the target file is deleted from the second computing device.
[0052] In the above technical solution, after the child nodes attached to the second computing device complete the deployment of the target file, the NFS service of the second computing device can be shut down to avoid the NFS service consuming the resources of the second computing device. Furthermore, in scenarios where the target file is used to deploy the target system, the target file can be deleted from the second computing device after the child nodes attached to the second computing device complete the deployment of the target system, thereby releasing the storage resources of the second computing device and ensuring that the deployment process of the target file has no impact on the storage resources of the second computing device. In the deployment scenario of the target system, the target file is no longer permanently stored on one or more devices, but is temporarily generated and deleted during the hierarchical deployment process of the multi-level structure. This allows the target file to be deployed in a fission-like manner with the hierarchical deployment of the multi-level structure, and the target file has no impact on the storage resources of the second computing device during the deployment process, thus achieving fission-like deployment of the target system and improving the deployment efficiency of the target system.
[0053] In one possible implementation, the multiple second computing devices are deployed as multi-level second computing devices according to a topology configuration strategy. The topology configuration strategy is determined based on the grouping indication information of the multiple second computing devices in the deployment information, the number of first devices that the first computing device supports for simultaneous downloading of target files, and the number of second devices that the second computing device supports for simultaneous downloading of target files. The grouping indication information includes at least one of the following information of the multiple second computing devices: rack information, network segment information, data center information, or supported functions.
[0054] In one possible implementation, the target file is an image file; the method further includes:
[0055] Based on the image file, deploy the target system on the second computing device.
[0056] Thirdly, embodiments of this application provide a file deployment method, which may include:
[0057] Obtain deployment information for multiple secondary computing devices input by the user; the deployment information is used to instruct the deployment of target files on multiple secondary computing devices;
[0058] In response to deployment information, a first topology diagram is displayed in the deployment interface; in the first topology diagram, multiple second computing devices are divided into multiple levels in order, each level includes one or more second computing devices, and the second computing device in level N is the parent node of at least one second computing device in level N+1, where N is a positive integer;
[0059] In response to a user-triggered deployment command, the target file is deployed in multiple second computing devices according to the hierarchical relationship shown in the first topology diagram, based on the deployment information.
[0060] In the above technical solution, the method can be applied to a terminal with a display. Users can quickly deploy target files of multiple second computing devices through interface interaction on the terminal, making the deployment of target files of multiple second computing devices simpler and more convenient, and improving the deployment efficiency of target files.
[0061] In one possible implementation, the method further includes:
[0062] In response to the user-triggered update command, the first topology diagram is updated in the deployment interface to obtain the second topology diagram.
[0063] In the above technical solution, users can update the first topology diagram in the deployment interface according to their own business needs to obtain the second topology diagram, making the deployment of the multiple second computing devices into a multi-level structure more flexible.
[0064] In one possible implementation, the method further includes:
[0065] In response to a user-triggered query, a third topology diagram is displayed in the deployment interface;
[0066] The query command is used to query the deployment status of multiple secondary computing devices. The deployment status can be one of the following: not deployed, deploying, deployment failed, or deployment completed.
[0067] The third topology diagram can be obtained by adding the status indication information of the second computing device to the second topology diagram. The status indication information can be used to indicate the deployment status of the second computing device.
[0068] In the above technical solution, during the deployment of multiple second computing devices, a third topology diagram can be displayed on the deployment interface in response to a query command triggered by the user. The third topology diagram includes status indication information of each second computing device, allowing the user to quickly determine the deployment progress of multiple second computing devices.
[0069] In one possible implementation, the method further includes:
[0070] Based on the grouping indication information of multiple second computing devices in the deployment information, the multiple second computing devices are divided into multiple device groups, and the grouping indication information of the second computing devices within the same device group is the same;
[0071] Based on the number of first devices that the first computing device can support simultaneously downloading target files and the number of second devices that the second computing device can support simultaneously downloading target files, determine the first deployment order among multiple device groups and the second deployment order of the second computing devices within each device group;
[0072] The topology configuration strategy is determined based on the first deployment order and the second deployment order of the second computing devices within each device group;
[0073] Based on the topology configuration strategy, multiple secondary computing devices are deployed as multi-level secondary computing devices;
[0074] The grouping indication information includes at least one of the following information of the second computing device: rack information, network segment information, computer room information, or functional information.
[0075] Fourthly, embodiments of this application provide a file deployment apparatus, applied in a first computing device, comprising:
[0076] The acquisition module is used to acquire deployment information for multiple second computing devices; the deployment information is used to instruct the deployment of target files on multiple second computing devices; wherein, the multiple second computing devices are divided into multiple levels in order, each level includes one or more second computing devices, and the second computing device in the Nth level node is the parent node of at least one second computing device in the N+1th level, where N is a positive integer;
[0077] The deployment module is used to deploy target files to the second computing device in the first level.
[0078] The transceiver module is used to send the first file retrieval address to other level second computing devices besides the first-level second computing devices; the first file retrieval address is used to instruct the second computing device to retrieve the target file from the parent node to which it is attached.
[0079] The file deployment apparatus provided in this application embodiment can execute the technical solutions shown in any of the first aspects, and its beneficial effects are similar, so they will not be described again here.
[0080] Fifthly, embodiments of this application provide a file deployment apparatus, applied in a second computing device, comprising:
[0081] The acquisition module is used to acquire the file acquisition address; the file acquisition address is sent by the parent node of the second computing device or by the first computing device; wherein, multiple second computing devices are divided into multiple levels in order, each level includes one or more second computing devices, and the second computing device in the Nth level is the parent node of at least one second computing device in the N+1th level, where N is a positive integer;
[0082] The acquisition module is also used to obtain the target file from the parent node of the second computing device based on the file address;
[0083] The transceiver module is used to send the target file to the attached child node in response to the file retrieval request from the child node of the second computing device.
[0084] The file deployment apparatus provided in this application embodiment can execute the technical solutions shown in any of the second aspects, and its beneficial effects are similar, so they will not be described again here.
[0085] Sixthly, embodiments of this application provide a file deployment apparatus, including:
[0086] The acquisition module is used to acquire deployment information for multiple second computing devices input by the user; the deployment information is used to instruct the deployment of target files on multiple second computing devices.
[0087] The display module is used to display a first topology diagram in the deployment interface in response to deployment information. In the first topology diagram, multiple second computing devices are divided into multiple levels in order, each level includes one or more second computing devices, and the second computing device in the Nth level is the parent node of at least one second computing device in the N+1th level, where N is a positive integer.
[0088] The deployment module is used to respond to user-triggered deployment commands and deploy target files in multiple second computing devices according to the hierarchical relationship shown in the first topology diagram, based on deployment information.
[0089] The file deployment apparatus provided in this application embodiment can execute the technical solutions shown in any of the third aspects, and its beneficial effects are similar, so they will not be described again here.
[0090] In a seventh aspect, embodiments of this application provide a computing device, including: a processor and a memory; the processor and the memory are coupled.
[0091] Memory is used to store program instructions;
[0092] The processor is configured to execute program instructions to perform the methods as described in any of the first, second, or third aspects.
[0093] The computing device provided in the embodiments of this application can execute the technical solutions shown in any of the first, second, or third aspects, and the beneficial effects are similar, so they will not be described again here.
[0094] Eighthly, embodiments of this application provide a computer-readable storage medium storing computer-executable instructions that, when executed by a computer, implement the method as described in any of the first, second, or third aspects.
[0095] The computer-readable storage medium provided in the embodiments of this application can execute the technical solutions shown in any of the first, second, or third aspects, and the beneficial effects are similar, so they will not be described again here.
[0096] Ninthly, embodiments of this application provide a computer program product, including a computer program that, when executed by a processor, implements the method as described in any of the first, second, or third aspects.
[0097] The computer program product provided in the embodiments of this application can execute the technical solutions shown in any of the first, second, or third aspects, and the beneficial effects are similar, so they will not be described again here.
[0098] The file deployment method and computing device provided in this application embodiment can reduce the number of deployment rounds in the process of deploying target files of multiple second computing devices by the first computing device, thereby helping to shorten the deployment time of the target files and improve the file deployment efficiency. Attached Figure Description
[0099] To more clearly illustrate the technical solutions in the embodiments of this application or related technologies, the drawings used in the description of the embodiments or related technologies will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0100] Figure 1A This is a schematic diagram of an application scenario provided by an embodiment of this application;
[0101] Figure 1B This is a schematic diagram of a first topology provided in an embodiment of this application;
[0102] Figure 1C A schematic diagram of a system deployment structure provided in an embodiment of this application;
[0103] Figure 2 One of the flowcharts illustrating the file deployment method provided in this application embodiment;
[0104] Figure 3 A second schematic flowchart illustrating the file deployment method provided in this application embodiment;
[0105] Figure 4 The third flowchart illustrating the file deployment method provided in this application embodiment;
[0106] Figure 5This is a schematic diagram illustrating the generation process of a multi-level structure provided in an embodiment of this application;
[0107] Figure 6 The fourth flowchart illustrating the file deployment method provided in this application embodiment;
[0108] Figure 7 This is one of the structural schematic diagrams of the file deployment device provided in the embodiments of this application;
[0109] Figure 8 A second schematic diagram of the structure of the file deployment device provided in the embodiments of this application;
[0110] Figure 9 A third schematic diagram of the structure of the file deployment device provided in the embodiments of this application;
[0111] Figure 10 A schematic diagram of the structure of a computing device provided in an embodiment of this application. Detailed Implementation
[0112] Exemplary embodiments will now be described in detail, examples of which are illustrated in the accompanying drawings. When the following description relates to the drawings, unless otherwise indicated, the same numbers in different drawings represent the same or similar elements. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with those of this application. Rather, they are merely examples of apparatuses and methods consistent with some aspects of the embodiments of this application as detailed in the appended claims.
[0113] It should be noted that in the embodiments of this application, certain software, components, models and other existing solutions in the industry may be mentioned. These should be regarded as exemplary and are only intended to illustrate the feasibility of the technical solutions in the embodiments of this application. However, it does not mean that the applicant has used or necessarily used such solutions.
[0114] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved in the embodiments of this application are all information and data authorized by the user or fully authorized by all parties. Furthermore, the collection, use and processing of related data must comply with relevant laws, regulations and standards, and corresponding operation entry points are provided for users to choose to authorize or refuse.
[0115] It should be noted that in the embodiments of this application, the term "at least one" refers to one or more, and "more than one" refers to two or more.
[0116] First, the terminology used in the embodiments of this application will be explained.
[0117] PXE technology is a technology that enables remote booting and installation of operating systems on devices via a network.
[0118] Server: A type of computing device that provides computing or application services to other devices (such as client devices) on a network.
[0119] The file deployment method provided in this application embodiment can be applied to centralized network management scenarios. To facilitate understanding of the file deployment method provided in this application embodiment, the following will be combined with… Figure 1A and Figure 1B The application scenarios involved in the embodiments of this application will be introduced.
[0120] Figure 1A This is a schematic diagram illustrating an application scenario provided by an embodiment of this application. Please refer to [link / reference]. Figure 1A The management system may include a first computing device and multiple second computing devices. The first computing device can be used to manage each second computing device, and the first device can communicate with each second computing device.
[0121] In some embodiments, the terms "first computing device" can be used interchangeably with "management device", "management node", "management server" or "PXE server", and the terms "second computing device" can be used interchangeably with "device to be deployed", "node to be deployed" or "server to be deployed".
[0122] For example, the first computing device can be a server, or a virtual machine deployed on a server; the second computing device can be a server, and the target system can be the server's operating system.
[0123] like Figure 1A As shown, the file deployment method provided in this application embodiment can also be applied to a terminal with a display, and the file deployment method can be executed interactively by the terminal and the first computing device.
[0124] The terminal can display a configuration interface through which users can input deployment information for multiple second computing devices. The terminal can send this deployment information to the first computing device, which can be used to instruct the deployment of target files on the multiple second computing devices. The terminal can be a server equipped with a display device or a computer.
[0125] The first computing device can obtain deployment information for multiple second computing devices input by the user, and in response to the deployment information, generate a first topology diagram and send the first topology diagram to the terminal.
[0126] The first computing device can manage multiple second computing devices, and the first computing device and each of the second computing devices can communicate through a switch.
[0127] The terminal can display a deployment interface. After receiving the first topology diagram, the terminal can display the first topology diagram in the deployment interface. In the first topology diagram, multiple second computing devices are divided into multiple levels in order. Each level includes one or more second computing devices, and the second computing device in the Nth level is the parent node of at least one second computing device in the N+1th level. N is a positive integer.
[0128] For example, a user needs to deploy an image file across nodes in 60 racks using a first computing device. Each rack from rack 1 to rack 30 contains 31 nodes, and each rack from rack 31 to rack 60 contains 30 nodes, totaling 1830 nodes. It should be noted that these nodes within the racks are the "second computing device" in the above embodiment.
[0129] Users can send deployment information for these 1830 nodes to the first computing device via a terminal. The first computing device can respond to the deployment information and generate a first topology diagram as shown in 1B.
[0130] Figure 1B For a schematic diagram of a first topology provided in an embodiment of this application, please refer to [link / reference]. Figure 1B The first topology diagram shows a multi-level tree structure including a root node and three levels of child nodes. Specifically:
[0131] The root node is the node where the first computing device resides, and it is the parent node to which all nodes in the first level are attached. For example... Figure 1B As shown, the first computing device is the parent node to which the 30 nodes from rack 1-node 1 to rack 30-node 1 are connected.
[0132] Each node in the first level can serve as the parent node of a node in the second level, and each node in the first level can connect to multiple nodes in the second level. For example... Figure 1B As shown, Rack 1-Node 1 can be the parent node of Rack 1-Node 2 to Rack 1-Node 31, and correspondingly, Rack 1-Node 2 to Rack 1-Node 31 can be the child nodes of Rack 1-Node 1.
[0133] Some nodes in the second level can continue to attach to multiple nodes in the third level, until all nodes are attached. The remaining nodes in the second level no longer need to attach child nodes. For example... Figure 1B As shown, each node from Rack 1-Node 2 to Rack 1-Node 31 can continue to connect to 30 nodes in the third level. At this point, 1830 nodes have been connected, and there is no need to connect any more child nodes from Rack 2-Node 2 to Rack 30-Node 31.
[0134] Based on the first topology diagram displayed in the deployment interface, the following scenarios are possible:
[0135] Scenario 1: The user does not need to modify the first topology diagram.
[0136] A user can trigger a deployment command from the terminal to the first computing device. For example, the deployment interface includes a deployment control; the user can click the deployment control on the deployment interface via the terminal, and the terminal, in response to the click operation, can send a deployment command to the first computing device. The first computing device can respond to the deployment command triggered by the user and, based on the deployment information, deploy the target file among multiple second computing devices according to the hierarchical relationship shown in the first topology diagram.
[0137] It should be noted that the specific process of deploying the target files across multiple second computing devices according to the hierarchical relationship shown in the first topology diagram, based on the deployment information, will be explained later. Figure 3 Detailed explanation is provided in the embodiments.
[0138] Scenario 2: The user needs to modify the first topology diagram.
[0139] Users can modify the first topology diagram in the deployment interface via a terminal to obtain a second topology diagram. For example, the deployment interface may include a canvas displaying the first topology diagram. Users can modify the position of at least one second computing device in the first topology diagram on the canvas via a terminal to obtain the second topology diagram. For example, in... Figure 1B In the first topology diagram shown, cabinet 31-node 1 to cabinet 31-node 30 are located in the third level and are attached to cabinet 1-node 2 in the second level; in the second topology diagram modified by the user, cabinet 31-node 1 to cabinet 31-node 30 can still be located in the third level, but are attached to cabinet 1-node 31 in the second level.
[0140] After obtaining the second topology diagram, the user can trigger the terminal to send a deployment command to the first computing device. The first computing device can respond to the user-triggered deployment command and, based on the deployment information, deploy the target file across multiple second computing devices according to the hierarchical relationship shown in the second topology diagram.
[0141] Scenario 3: Users need to query the deployment status of each second computing device in the first topology diagram.
[0142] Users can trigger a terminal to send a query request to the first computing device. The query request can be used to query the deployment status of multiple second computing devices. The deployment status can be one of the following: not deployed, deploying, deployment failed, or deployment completed.
[0143] In response to a query command, the first computing device can generate a third topology diagram based on the deployment status of multiple second computing devices and a first topology diagram, and send the third topology diagram to the terminal. The terminal can then display the third topology diagram on the deployment interface.
[0144] If the first computing device deploys the target file in multiple second computing devices based on the hierarchical relationship shown in the first topology diagram, the third topology diagram can be obtained by adding the status indication information of the second computing devices to the first topology diagram.
[0145] If the first computing device deploys the target file in multiple second computing devices based on the hierarchical relationship shown in the second topology diagram, the third topology diagram can be obtained by adding the status indication information of the second computing devices to the second topology diagram.
[0146] Status indication information can be used to indicate the deployment status of the second computing device. For example, the status indication information can be presented in the form of indicator lights in the third topology diagram, with different colors of the indicator lights used to indicate different deployment statuses. For example, a stationary yellow indicator light can indicate that the device is not deployed (or is waiting to be deployed), a flashing yellow indicator light indicates that the device is being deployed, a red indicator light indicates that the deployment has failed, and a green indicator light indicates that the deployment has been completed.
[0147] In the file deployment method provided in this application embodiment, by deploying multiple second computing devices in a multi-level structure (such as a multi-level tree structure) in sequence, the first computing device can deploy the target file on multiple second computing devices according to the deployment information. The first computing device can first deploy the target file to the second computing devices in the first level, and then send a first file retrieval address to the second computing devices in other levels, so that the second computing devices in other levels can retrieve the target file from their own attached parent nodes based on the first file retrieval address. In this process, the second computing devices in other levels do not need to retrieve the target file from the first computing device, but rather from their own attached parent nodes. This allows the number of concurrent deployments of the target file by the first computing device to increase with the increase in the multi-level structure, solving the problem that the number of second devices that the first computing device can support for simultaneous downloading of the target file is limited due to the network card speed of the first computing device. This helps to shorten the deployment time of the target file and improve the deployment efficiency of the target file.
[0148] In large-scale deployment scenarios, as the multi-level structure extends, the first computing device can concurrently deploy the target file for more second computing devices at a time. This reduces the number of deployment rounds for the first computing device, shortens the file deployment time, and improves deployment efficiency. For example, in some scenarios, as the tree structure extends, the number of second computing devices that the first computing device can concurrently deploy can increase exponentially. Furthermore, by increasing the number of second computing devices that the first computing device can concurrently deploy, the number of deployment rounds for the first computing device can be reduced. In large-scale deployment scenarios, it is not necessary to set up multiple first computing devices for system deployment. This reduces the management resources occupied by the first computing device and eliminates the need to configure multiple first computing devices during the deployment of the target system on multiple second computing devices, simplifying the Internet Protocol (IP) network partitioning and configuration process.
[0149] The file deployment method provided in this application can be applied to scenarios where files are transferred via network cards. By adopting this file deployment method, a single file source can be dynamically generated into multiple file sources through a multi-level structure, which is beneficial to improving file transfer efficiency.
[0150] In some embodiments, the target file may be an image file, which can be used to deploy the target system in a second computing device. The first computing device may deploy the image file in multiple second computing devices based on deployment information, and deploy the target system in the multiple second computing devices based on the image file, and then start the target system.
[0151] To facilitate understanding of the deployment method of the target system provided in the embodiments of this application, the following will be combined with... Figure 1C The system deployment architecture involved in the embodiments of this application will be described.
[0152] Figure 1C This is a schematic diagram of a system deployment structure provided in an embodiment of this application. Please refer to [link / reference]. Figure 1C In this system deployment architecture, the first computing device may include a management module, which may include multiple deployment components, including Dynamic Host Configuration Protocol (DHCP) component, Trivial File Transfer Protocol (TFTP) component, and Network File System (NFS) component.
[0153] Optionally, such as Figure 1CAs shown, each of the multiple second computing devices may include a PXE client, which can be used to deploy image files in each second computing device and deploy the target system in the second computing device based on the image files.
[0154] In some embodiments, the PXE client may be pre-installed on the second computing device before it leaves the factory.
[0155] Optionally, the deployment components may include more components. For example, the deployment components may include a PXE server that can be used to communicate with PXE clients.
[0156] In some embodiments, the first computing device may configure corresponding deployment boot parameters for each second computing device through multiple deployment components. The deployment boot parameters may include a file acquisition address, which may be used to instruct the second computing device to acquire the image file from the parent node to which it is attached.
[0157] The deployment boot parameters can be used to start a PXE client on a second computing device, and after the PXE client starts, to deploy target files on the second computing device according to the deployment boot parameters, and to deploy the target system on the second computing device based on the target files.
[0158] For example, deployment boot parameters may include an initialization disk (initrd) file, a Linux kernel (vmlinuz) file, and a boot file. The boot file can indicate the path to the installation configuration file, which in turn can indicate the file location where the image file is retrieved; that is, the installation configuration file can indicate the image source corresponding to the image file. For example, the installation configuration file can be a Kickstart (KS) file.
[0159] The image file can be stored in a target directory of the first computing device. This storage location may include the IP address of the first computing device and the address of the target directory. The first computing device can configure this target directory according to deployment information.
[0160] In this embodiment, the first computing device (e.g., a "PXE server") can be a fully functional server. The server's internal management module integrates multiple deployment components, such as a PXE server, DHCP component, TFTP component, and NFS component. This eliminates the need for users to manually install these deployment components during the deployment of image files and target systems from multiple second computing devices, saving deployment time and improving deployment efficiency and user convenience. Furthermore, this method can reduce the number of first computing devices required in large-scale deployment scenarios, thereby reducing the resource consumption of the first computing devices.
[0161] In this embodiment, by deploying multiple second computing devices in a multi-level structure, the second computing devices in other levels do not need to obtain the target file from the first computing device, but instead obtain the target file through their own attached parent node. The number of concurrent deployments of the target file by the first computing device can increase with the increase of the multi-level structure, thereby reducing the number of deployment rounds for the first computing device to concurrently deploy the target system of multiple second computing devices. This solves the problem of increased deployment rounds and extended deployment time of the target file due to the limited number of devices that the first computing device can support to download the target file at the same time, which is conducive to improving the system deployment efficiency of the first computing device to multiple second computing devices.
[0162] The technical solutions of the embodiments of this application will be described in detail below with specific examples. These specific embodiments can be combined with each other, and the same or similar concepts or processes may not be repeated in some embodiments. The embodiments of this application will be described below with reference to the accompanying drawings.
[0163] Figure 2 This is one of the flowcharts illustrating a file deployment method provided in an embodiment of this application. The method can be interactively executed by a first computing device and multiple second computing devices. See also... Figure 2 The method may include the following steps:
[0164] S201, The first computing device obtains deployment information for multiple second computing devices.
[0165] Deployment information can be used to instruct the deployment of target files on multiple secondary computing devices. These secondary computing devices are arranged in multiple levels, with each level comprising one or more secondary computing devices. A secondary computing device in a level N node is the parent node of at least one secondary computing device in level N+1, where N is a positive integer. It should be noted that not every secondary computing device in a level N node must have child nodes; in one implementation, one or more secondary computing devices in a level N node may not have any child nodes attached.
[0166] like Figure 1A As shown, users can enter deployment information for multiple second computing devices on the configuration interface displayed on the terminal, and send the deployment information to the first computing device through the terminal.
[0167] In some embodiments, the target file may be an image file, which is used to deploy the target system in a second computing device. For example, the target system may be an operating system.
[0168] In some embodiments, deployment information may include identifiers of multiple second computing devices and indication information for target files.
[0169] For example, the identifier of the second computing device may be the Internet Protocol (IP) address or device serial number of the second computing device.
[0170] For example, the indication information may include the target file's identifier, version information, file source, file format, file size, and deployment path. The file source can be used by the first computing device to obtain the target file.
[0171] Optionally, the deployment information may also include at least one of the following:
[0172] (1) Grouping indication information for multiple second computing devices.
[0173] The grouping instruction information may include at least one of the following information of the second computing device: rack information, network segment information, computer room information, or functional information.
[0174] Rack information can be used to indicate the rack in which the second computing device is located. For example, rack information may include rack identification, etc.
[0175] Network segment information can be used to indicate the network segment in which the second computing device is located. For example, network segment information may include the IP address and network port of the second computing device.
[0176] The data center information can be used to indicate the data center where the second computing device is located. For example, the data center information may include a data center identifier, etc.
[0177] Functional information can be used to indicate the functions supported by the second computing device. For example, functional information may include a function identifier and a function type, where the function identifier can be function 1, and the function type may include computing functions and / or storage functions.
[0178] In this method, the grouping indication information of the second computing device may include one or more of the following: rack information, network segment information, computer room information, and functional information, so that the first computing device can flexibly group multiple second computing devices based on the grouping indication information of the second computing device.
[0179] (2) Number of first equipment and number of second equipment
[0180] The first number of devices can be the number of devices that the user-configured first computing device can support for simultaneously downloading the target file (such as the maximum number of devices).
[0181] The second computing device can be configured by the user to support the number of devices simultaneously downloading the target file (e.g., the maximum number of devices).
[0182] The first computing device can determine the topology configuration strategy for multiple second computing devices based on the grouping instruction information, the number of first devices, and the number of second devices, and deploy the multiple second computing devices as multi-level second computing devices according to the topology configuration strategy.
[0183] like Figure 1B As shown, the first-level computing devices in the multi-level tree structure corresponding to multiple second computing devices are connected to the root node. The number of first computing devices that the first computing devices allocated in the root node can support for simultaneous downloading of target files determines how many second computing devices can be connected to the first-level computing device; the number of first devices and the number of second computing devices that the second computing devices can support for simultaneous downloading of target files determine the allocation of multiple second computing devices in other levels of the multi-level tree structure.
[0184] Optionally, the number of the first device can be the same as the number of the second device; or the number of the first device can be different from the number of the second device, such as the number of the first device being greater than or less than the number of the second device.
[0185] (3) Topology configuration strategy
[0186] Topology configuration policies can be used to indicate the deployment process of deploying multiple secondary computing devices as multi-level secondary computing devices.
[0187] Topology configuration policies can be used to indicate the following information: the total number of levels in the multi-level structure; the deployment order of the second computing devices in the multi-level structure; the allocation of a first computing device in the root node; and the device information of at least one second computing device allocated in each level of the multi-level structure. The device information may include the device identifier of the second computing device, the node identifier corresponding to the second computing device in that level, and the device identifier and / or node identifier of the parent node to which the computing device is attached.
[0188] S202, The first computing device deploys the target file to the second computing device in the first level.
[0189] The first level may include one or more second computing devices.
[0190] In some embodiments, the first computing device may send a second file retrieval address to the second computing device in the first stage. The second file retrieval address may be used to instruct the second computing device in the first stage to retrieve the target file from the first computing device to which it is connected.
[0191] Optionally, such as Figure 1C As shown, the first computing device can deploy multiple deployment components, which may include a DHCP component, a TFTP component, and an NFS component. The first computing device can configure the deployment boot parameters corresponding to the second computing device in the first level through the multiple deployment components, and send the deployment boot parameters to the second computing device in the first level. The deployment boot parameters can be used to indicate the address for obtaining the second file.
[0192] In some embodiments, the first computing device may individually configure corresponding deployment boot parameters for each second computing device in the first stage. Alternatively, the first computing device may also batch configure corresponding deployment boot parameters for multiple second computing devices in the first stage.
[0193] It should be noted that the deployment boot parameters can be found by referring to... Figure 1C The details of the deployment of boot parameters will not be elaborated here.
[0194] The target file can be stored in a specified directory on the first computing device.
[0195] The address for obtaining the second file may include the IP address of the first computing device and the address of the specified directory.
[0196] For example, the second file retrieval address can be represented as "nfs-IP address of the first computing device-address of the specified directory".
[0197] The second computing device in the first level can obtain the target file from the first computing device based on the address obtained from the second file. For example, the second computing device in the first level can generate a file retrieval request based on the address obtained from the second file and send the file retrieval request to the first computing device. The first computing device can respond to the file retrieval request sent by the second computing device in the first level and send the target file to the second computing device in the first level.
[0198] If the first level includes multiple second computing devices, the first computing device can deploy target files to multiple second computing devices in parallel to improve the deployment efficiency of target files.
[0199] For example, if the first level includes multiple second computing devices, the first computing device can send the second file retrieval address to these multiple second computing devices in parallel; after receiving the file retrieval request sent by each of the second computing devices, the first computing device can send the target file to each of the second computing devices.
[0200] In some embodiments, the second computing device in the first level may also send a target file to the child node in response to a file retrieval request from the child node to which it is attached.
[0201] If the first level includes multiple second computing devices, each of these second computing devices can have child nodes connected to it; and the number of child nodes connected to any two second computing devices can be the same or different. For example, the first level includes 30 second computing devices, and all 30 second computing devices have child nodes connected to them. Among these 30 second computing devices, the first 29 second computing devices each have 30 child nodes connected to them, and the 30th second computing device has 10 child nodes connected to it.
[0202] Alternatively, some of the multiple second computing devices in the first level may have child nodes attached, while others may not need to have child nodes attached.
[0203] S203, The first computing device sends the first file acquisition address to other level second computing devices besides the first level second computing device.
[0204] The first file retrieval address can be used to instruct the second computing device to retrieve the target file from its attached parent node.
[0205] For a second computing device in another level of second computing device, the computing device may perform the following steps: obtain a first file retrieval address sent by the first computing device; obtain a target file from the parent node of the computing device based on the first file retrieval address; and send the target file to the attached child node in response to a file retrieval request from the child node of the second computing device.
[0206] The file deployment method provided in this application deploys multiple second computing devices in a multi-level structure. This allows a first computing device to concurrently deploy multiple levels of second computing devices sequentially, by sending target files to first-level second computing devices and first file acquisition addresses to other levels of second computing devices. During this process, other levels of second computing devices do not need to obtain target files from the first computing device; instead, they obtain them through their attached parent nodes. This allows the number of concurrent deployments of target files to increase with the number of levels in the multi-level structure. Thus, the first computing device can complete the concurrent deployment of target files to multiple second computing devices in fewer rounds, avoiding the problem of increased deployment rounds and longer deployment times caused by the limited number of devices the first computing device can support for simultaneous target file downloads. This improves the efficiency of file deployment from the first computing device to multiple second computing devices.
[0207] If multiple second computing devices are divided into M levels according to their order, the M-level second computing devices can include first-level second computing devices and M-1 other levels of second computing devices, where M is an integer greater than 1. The first computing devices can be arranged according to... Figure 3 The target file is deployed to the M-level second computing device in the manner shown.
[0208] Figure 3 This is a second flowchart illustrating the file deployment method provided in this application embodiment. This method can be executed by a first computing device or by a management module within the first computing device. Please refer to... Figure 3 The method may include the following steps:
[0209] S301. Obtain deployment information for multiple second computing devices.
[0210] It should be noted that the specific execution process of this step can be referred to the specific execution process of S201, and will not be repeated here.
[0211] S302. Based on the deployment information, the multiple second computing devices are divided into M levels in order.
[0212] Based on different deployment information, the first computing device can classify multiple second computing devices into M levels in the following manner.
[0213] Method 1: The deployment information includes grouping instructions.
[0214] The first computing device can divide multiple second computing devices into multiple device groups based on grouping instruction information, with the grouping instruction information being the same for the second computing devices within the same device group; determine the number of first devices that the first computing device can support for simultaneous downloading of target files and the number of second devices that the second computing device can support for simultaneous downloading of target files; determine the first deployment order among the multiple device groups and the second deployment order of the second computing devices within each device group based on the number of first devices and the number of second devices; determine the topology configuration strategy based on the first deployment order and the second deployment order of the second computing devices within each device group; and divide the multiple second computing devices into M levels according to the topology configuration strategy.
[0215] In some embodiments, the first computing device may determine the number of first devices based on the network card speed of the first computing device and the data volume of the target file; and determine the number of second devices based on the network card speed of the second computing device and the data volume of the target file.
[0216] For example, if the target file is an image file for deploying an OS, the number of first devices that can simultaneously download the image file can be 30.
[0217] In some embodiments, users can specify grouping policies in the deployment information by means of grouping indication information according to their own business needs (such as the networking situation of the laboratory), so as to keep the second computing devices in a Layer 2 network in one device group as much as possible, thereby improving the download speed of image files and deployment speed of the second computing devices in the device group.
[0218] For example, if each rack has a switch, devices can be grouped based on rack information; or, if each network segment corresponds to a switch, devices can be grouped based on network segment information.
[0219] In some embodiments, users can distribute one or more second computing devices in a data center into a device group according to their own business needs; or, second computing devices with the same functional information can be distributed into a first computing device group. During this device grouping process, multiple second computing devices within a Layer 2 network can be grouped together as much as possible to improve the speed of downloading image files and deploying target systems for the second computing devices within that group.
[0220] In some embodiments, the first computing device (or management module) may determine multiple indications based on the first deployment order and the second deployment order among the second computing devices within each device group, and generate the topology configuration policy based on these multiple indications.
[0221] The multiple indication information may include: the total number of levels in the multi-level structure; the deployment order of the multi-level second computing devices; and the device information of at least one second computing device allocated in each level of the multi-level structure. The device information may include the device identifier of the second computing device, the node identifier corresponding to the second computing device in that level, and the device identifier and / or node identifier of the parent node to which the computing device is attached.
[0222] In some embodiments, if the number of first devices is P, the number of second devices is Q, and the total number of multiple device groups is T, where P, Q, and T are all integers greater than 1.
[0223] Case 1: P is greater than or equal to T.
[0224] In some embodiments, if P is greater than or equal to T, P second computing devices can be selected from the T device groups as the preferred second computing devices for deployment, and these P second computing devices can be allocated to the nodes of the first level of the multi-level structure; the maximum number of devices that can simultaneously download image files supported by the P second computing devices, S1 = P × Q, and the total number of unallocated second computing devices F in the T device groups are determined.
[0225] If S1 is greater than F, the F unassigned second computing devices in the T device groups can be sequentially allocated to the child nodes attached to some of the P second computing devices. That is, these F second computing devices are located in the second level of the multi-level structure. At this time, all second computing devices in the T device groups have been deployed.
[0226] If S1 equals F, the F unassigned second computing devices in the T device groups can be sequentially assigned to the child nodes attached to each of the P second computing devices. That is, these F second computing devices are located in the second level of the multi-level structure. At this point, all second computing devices in the T device groups have been deployed.
[0227] If S1 is less than F, the S1 unallocated second computing devices out of the F unallocated second computing devices are sequentially allocated to the child nodes attached to the P second computing devices. That is, these S1 second computing devices are located in the second level of the multi-level structure. Determine the maximum number of devices that the S1 second computing devices can simultaneously download image files, S2 = S1 × Q, and the total number of unallocated second computing devices in the T device groups, F - S1. Based on the maximum number of devices S2 and the unallocated F - S1 second computing devices, continue the deployment according to the above process until all the second computing devices in the T device groups are allocated to the nodes of the multi-level structure.
[0228] In this scenario, the initial deployment order of multiple device groups can be the same. During the multi-level deployment process, the first computing device can select a portion of the second computing devices from each device group to be deployed preferentially to the first level, and then attach the remaining second computing devices from each device group to the child nodes of these preferentially deployed second computing devices.
[0229] The number of second computing devices that are prioritized in any two device groups can be the same or different.
[0230] Optionally, for any group of devices, the first computing device may randomly select N second computing devices in the group for priority deployment; or, it may select N second computing devices in a preset order, where the preset order may be from smallest to largest or from largest to smallest, and N is an integer greater than or equal to 1.
[0231] For example, for any device group containing 31 second computing devices, where N is 1, the first computing device can choose any one of the 31 second computing devices for priority deployment; or, if the preset order is from smallest to largest, the first computing device can choose the second computing device with the smallest device identifier among the 31 second computing devices for priority deployment; or, if the preset order is from largest to smallest, the first computing device can choose the second computing device with the largest device identifier among the 31 second computing devices for priority deployment.
[0232] Case 2: P is less than T.
[0233] If P is less than T, the second computing devices in the P device groups can be deployed first in the multi-level structure until all the second computing devices in the P device groups are allocated to the child nodes of the multi-level structure. Then, the second computing devices in the TP device groups can be deployed in the multi-level structure.
[0234] It should be noted that, in this case, the allocation process of the second computing device in the P device groups in the multi-level structure can refer to the allocation process of the second computing device in Case 1, and will not be repeated here.
[0235] Optionally, the first computing device may randomly select P device groups from T device groups; or, it may select P device groups in a preset order, which may be from smallest to largest or from largest to smallest.
[0236] In this scenario, the first deployment order of P device groups can precede the first deployment order of QP device groups.
[0237] In this embodiment, the user does not need to manually specify the deployment order of multiple second computing devices. The first computing device (or the management module in the first computing device) can automatically generate a topology configuration strategy by combining the grouping indication information in the deployment information. The first computing device can determine the topology configuration strategy according to the deployment principle of fastest deployment speed and shortest deployment time for a single second computing device, based on the first deployment order and the second deployment order among the second computing devices in each device group. This ensures that the multi-level structure generated based on the topology configuration strategy allows the first computing device to deploy target files (or target systems) of multiple second computing devices more quickly, and also helps to shorten the file deployment time of the second computing devices.
[0238] Method 2: The deployment information includes grouping instructions, the number of first computing devices that can simultaneously download target files, and the number of second computing devices that can simultaneously download target files.
[0239] The hierarchical deployment process for multiple second computing devices in Method 2 is largely the same as in Method 1. The difference between Method 2 and Method 1 is that the first computing device does not need to determine the number of first and second devices itself, but can directly adopt the number of first and second devices indicated in the deployment information.
[0240] Method 3: The deployment information includes topology configuration strategies.
[0241] The first computing device can classify multiple second computing devices into M levels according to the topology configuration strategy.
[0242] S303. Configure the first deployment boot parameters corresponding to the second computing device in the first level through multiple deployment components. The first deployment boot parameters are used to indicate the address for obtaining the second file.
[0243] It should be noted that the specific execution process of step S303 can be found in [reference needed]. Figure 1C The details regarding the configuration of corresponding deployment boot parameters for each second computing device by the first computing device through multiple deployment components will not be elaborated here.
[0244] S303, Send the first deployment boot parameters to the second computing device in the first stage.
[0245] Correspondingly, the second computing device in the first stage can receive the first deployment boot parameters.
[0246] If there are multiple second computing devices in the first level, the first computing devices can send the first deployment boot parameters to the second computing devices in the first level in parallel.
[0247] S304. In response to the file retrieval request sent by the second computing device in the first level, send the target file to the second computing device in the first level.
[0248] If the target file is an image file, the second computing device can deploy the target system based on the target file.
[0249] For example, the target system can be an OS.
[0250] S305. After confirming that the second computing device in the first level has completed the deployment of the target file and that the second computing device in the first level has a child node attached, control the second computing device in the first level to start the NFS service.
[0251] For the second computing device in the first level, the NFS service is used to share the file retrieval address of the target file in the second computing device with the child nodes of the second computing device.
[0252] Optionally, the first level includes multiple second computing devices, some of which have child nodes mounted on them, while others do not. The first computing device can control the second computing devices in the first level that have child nodes mounted to start NFS services.
[0253] The first computing device can receive a deployment completion message from the second computing device in the first level, which instructs the second computing device to complete the deployment of the target file. After receiving the deployment completion message from the second computing device in the first level, the first computing device can send a control command to the second computing device in the first level, which can instruct the second computing device to start the NFS service.
[0254] In some embodiments, if the target file is an image file, after determining that the second computing device in the first level has completed the deployment of the target system based on the target file and that the second computing device in the first level has child nodes attached, the first computing device may also perform the following steps: the first computing device (or management module) may copy the image file stored in the operating system of the first computing device to the first target directory of the second computing device in the first level through the Secure Copy Protocol (SCP), and control the second computing device in the first level to start the NFS service through the Secure Shell Protocol (SSH) to expose the first target directory to the child nodes attached to the second computing device in the first level.
[0255] The first computing device can set the first target directory in the second computing device in the first level through the first deployment boot parameters.
[0256] For example, the target system can be an OS, and the first target directory can be a temporary directory configured in the OS for temporarily storing image files.
[0257] S306. Initialize i to 2.
[0258] S307. Configure the i-th deployment boot parameters corresponding to the second computing device in the i-th level through multiple deployment components. The i-th deployment boot parameters are used to indicate the address for obtaining the first file.
[0259] The first file retrieval address is used to instruct the second computing device to retrieve the target file from its attached parent node.
[0260] Where i is 2, 3, ..., M in sequence.
[0261] S308. Send the i-th deployment boot parameters to the second computing device in the i-th stage.
[0262] Correspondingly, the second computing device in the i-th stage can receive the first deployment boot parameters and determine the first file acquisition address based on the first deployment boot parameters; generate a file acquisition request based on the first file acquisition address, and send the file acquisition request to the parent node to which the second computing device in the i-th stage is attached.
[0263] The parent node to which the second computing device in level i is attached can respond to the file retrieval request by sending the target file to the second computing device in level i.
[0264] S309. After determining that the second computing device in level i has completed the deployment of the target file, determine whether i is less than M.
[0265] If i is less than M, proceed to step S310;
[0266] If i is greater than or equal to M, proceed to step S312.
[0267] S310. Control the second computing device in the (i-1)th stage to shut down the NFS service, and control the second computing device in the i-th stage to start the NFS service.
[0268] If the target file is an image file, this image file is used to deploy the target system in the second computing device. After determining that the second computing device in level i has completed the deployment of the target system based on the image file, the first computing device can perform the following steps:
[0269] Step 1: Store the image file stored in the second computing device in level i-1 to the i-th target directory of the child node to which the second computing device in level i-1 is attached. Control the second computing device in level i-1 to shut down the NFS service and delete the image file stored in the second computing device in level i-1.
[0270] The first computing device can copy the image file stored in the second computing device at level i-1 to the i-th target directory of the child node (which is at level i and has child nodes at level i+1) that the second computing device at level i-1 is attached to via the SCP protocol, delete the image file stored in the second computing device at level i-1, and control the second computing device at level i-1 to shut down the NFS service via the SSH protocol.
[0271] The first computing device can set the i-th target directory in the second computing device at level i by deploying the i-th boot parameters.
[0272] In some embodiments, the target file may be stored in the (i-1)th target directory of the second computing device in the (i-1)th level. The first computing device (or the management module in the first computing device) may delete the image file stored in the second computing device in the (i-1)th level by deleting the (i-1)th target directory in the second computing device in the (i-1)th level, thereby deleting the target file stored in the (i-1)th target directory.
[0273] Optionally, the first computing device (or management module) may send a deletion command to the second computing device in the (i-1)th level, which may be used to instruct the deletion of the (i-1)th target directory.
[0274] In this embodiment, after the target file deployment of the second computing device in level i is completed and the image file stored in the second computing device in level i-1 is copied to the i-th target directory of the child node attached to the second computing device in level i-1 via the SCP protocol, the first computing device can release the storage resources of the second computing device in level i-1 after the target file deployment of the second computing device in level i-1 is completed by deleting the target file stored in the second computing device in level i-1 and shutting down the NFS service of the second computing device in level i-1. This avoids the target file still occupying the storage space of the second computing device in level i-1 after the target file deployment of the second computing device in level i is completed, so that the target file deployment process has no impact on the storage resources of the second computing device in level i-1.
[0275] Step 2: Control the second computing device in level i to start the NFS service to expose the target directory i to the child nodes attached to the second computing device in level i.
[0276] The first computing device can control the second computing device in level i to start an NFS service via the SSH protocol, so as to expose the target directory i to the child nodes attached to the second computing device in level i in a secure environment.
[0277] The storage location of the target file in the second computing device at level i may include: the IP address of the parent node to which the second computing device at level i is attached and the address of the target directory at level i. For example, the storage location may be represented as "nfs - IP address of the parent node to which the second computing device at level i is attached - address of the target directory at level i".
[0278] S311, Update i to i+1.
[0279] After completing step S311, return to step S307.
[0280] S312. Control the second computing device in level i-1 to shut down the NFS service and confirm that the target file deployment in the second computing device of level M is complete.
[0281] The file deployment method provided in this application deploys multiple second computing devices in a multi-level structure. This allows a first computing device to concurrently deploy multiple levels of second computing devices sequentially, by sending target files to first-level second computing devices and first file acquisition addresses to other levels of second computing devices. During this process, other levels of second computing devices do not need to obtain target files from the first computing device; instead, they obtain them through their attached parent nodes. This allows the number of concurrent deployments of target files to increase with the number of levels in the multi-level structure. Thus, the first computing device can complete the concurrent deployment of target files to multiple second computing devices in fewer rounds, avoiding the problem of increased deployment rounds and longer deployment times caused by the limited number of devices the first computing device can support for simultaneous target file downloads. This improves the efficiency of file deployment from the first computing device to multiple second computing devices.
[0282] In this embodiment, after the target file (or target system) of the second computing device in the i-th level is deployed, the first computing device can determine whether it needs to become a secondary target file source to achieve chained deployment of the target file based on the total number of levels M and i in the multi-level structure. During this process, the target file exhibits fission-like deployment as the multi-level structure is deployed hierarchically. The larger the scale of the multi-level structure, the more file sources the target file has, resulting in faster deployment speed and higher deployment efficiency for the first computing device. Furthermore, in the deployment scenario of the target system, the target file is no longer fixedly stored in one or more devices, but is temporarily generated and deleted during the hierarchical deployment process of the multi-level structure. This allows the target file to exhibit fission-like deployment as the multi-level structure is deployed hierarchically, thereby achieving fission-like deployment of the target system, which is beneficial for improving the deployment efficiency of the target system.
[0283] Below, for ease of understanding, we will combine... Figure 4 The deployment process of the target file in any of the other level second computing devices is described during the deployment of the target file.
[0284] Figure 4 This is the third flowchart illustrating the file deployment method provided in this application embodiment. This method can be executed by a second computing device. Please refer to... Figure 4 The method may include the following steps:
[0285] S401, Get the file address.
[0286] The file retrieval address is sent by the parent node of the second computing device or by the first computing device; wherein, the multiple second computing devices are divided into multiple levels in order, each level includes one or more second computing devices, and the second computing device in the Nth level is the parent node of at least one second computing device in the N+1th level, where N is a positive integer.
[0287] Multiple secondary computing devices are deployed as multi-level secondary computing devices according to a topology configuration strategy;
[0288] The topology configuration strategy can be determined based on grouping indication information of multiple second computing devices. The grouping indication information may include at least one of the following information of the multiple second computing devices: rack information, network segment information, data center information, or supported functions.
[0289] In some embodiments, the first computing device may send deployment boot parameters to the second computing device, the deployment boot parameters including a file acquisition address.
[0290] S402. Obtain the target file from the parent node of the second computing device based on the file address.
[0291] If the target file is an image file, the image file is used to deploy the target system on the second computing device. After obtaining the target file, the second computing device can deploy the target system (such as an OS) on the second computing device based on the target file.
[0292] If the second computing device has no child nodes attached, and the target file is an image file, the second computing device can also perform the following steps: Based on the target file, on the second computing device...
[0293] The target system (such as an OS) is deployed in the secondary computing device. The image file is used to deploy the target system in the secondary computing device.
[0294] If the second computing device has child nodes connected, the method may further include the following steps S403 to S405.
[0295] S403. After confirming that the second computing device has completed the deployment of the target file and that the second computing device has attached child nodes, start the NFS service under the control of the first computing device.
[0296] In some embodiments, if the target file is used to deploy the target system in the second computing device, the second computing device may store the target file in the target directory of the second computing device before starting the NFS service.
[0297] S404. In response to a file retrieval request from a child node of the second computing device, send the target file to the attached child node.
[0298] S405. After the target file deployment is completed on the child node attached to the second computing device, the NFS service is shut down on the second computing device under the control of the first computing device.
[0299] In some embodiments, if the target file is an image file, the image file is used to deploy the target system in the second computing device. After the child node attached to the second computing device completes the deployment of the target system, the first computing device can delete the target file in the second computing device.
[0300] The file deployment method provided in this application embodiment eliminates the fixed storage of target files on one or more devices. The second computing device can flexibly retrieve the target file from its attached parent node based on the file retrieval address. The target file undergoes exponential replication during the hierarchical deployment of the multi-level structure. The larger the multi-level structure, the more file sources the target file has, resulting in faster deployment speed and higher efficiency for the first computing device. Furthermore, file sources can be temporarily generated and deleted in the parent node during the hierarchical deployment process, ensuring that temporarily generated file sources have no impact on the storage resources of the second computing device in the parent node.
[0301] Below, in conjunction with Figure 5 The generation process of the multi-level structure corresponding to multiple second computing devices is explained.
[0302] Figure 5 Please refer to the schematic diagram of the generation process of a multi-level structure provided in the embodiments of this application. Figure 5 The first computing device needs to deploy the OS across nodes in 60 racks. These racks are the "second computing device" in the above embodiment. Each rack from rack 1 to rack 30 contains 31 nodes, and each rack from rack 31 to rack 60 contains 30 nodes.
[0303] In some embodiments, the first computing device can, based on the rack information of multiple second computing devices in the deployment information, divide multiple second computing devices located in the same rack into a device group, thus obtaining multiple device groups. Figure 5 In this system, the first computing device can divide the nodes of 60 racks into 60 device groups, with each rack corresponding to one device group.
[0304] The first computing device can support a maximum of 30 devices simultaneously downloading image files. If 60 is greater than 30, then the first computing device can prioritize deploying nodes from device group 1 (rack 1) to device group 30 (rack 30). For example... Figure 5 As shown, the first computing device can prioritize allocating the first node (Rack 1-Node 1 to Rack 30-Node 1) in the first 30 racks (Rack 1 to Rack 30) to the first level. The second computing device can also support a maximum of 30 devices simultaneously downloading image files. The first computing device can allocate nodes 2 to 31 in rack 1 to the child nodes corresponding to Rack 1-Node 1, ..., and allocate nodes 2 to 31 in rack 30 to the child nodes corresponding to Rack 30-Node 1 to obtain the second level structure. Subsequently, nodes 1 to 30 in rack 31 are allocated to the child nodes corresponding to Rack 1-Node 2, nodes 1 to 30 in rack 32 are allocated to the child nodes corresponding to Rack 1-Node 3, ..., and nodes 1 to 30 in rack 60 are allocated to the child nodes corresponding to Rack 1-Node 31 to obtain the third level structure. At this point, all nodes in the 60 racks have been allocated, and the multi-level structure deployment is complete.
[0305] The deployment method provided in this application embodiment allows the first computing device to group multiple second computing devices according to the grouping indication information of each second computing device in the deployment information (such as combining one or more of rack information, data center information, network segment information, and functional information) after obtaining deployment information. Based on the first deployment order of multiple device groups, the second deployment order of the second computing devices in each device group, and the maximum number of devices, the topology configuration strategy is determined to automatically generate a multi-layer tree structure. This eliminates the need for users to manually specify the deployment order of the multi-layer tree structure, making the deployment process of the multi-layer tree structure simpler and more convenient.
[0306] Figure 6 This is the fourth flowchart illustrating the file deployment method provided in this application embodiment. This method can be interactively executed by a terminal, a first computing device, and multiple second computing devices. Please refer to... Figure 6 The method may include the following steps:
[0307] S601, The terminal obtains deployment information for multiple second computing devices input by the user.
[0308] It should be noted that the execution process of step S601 can be referred to Figure 1A The interaction process between the terminal and the user in the embodiment will not be described in detail here.
[0309] The terminal can respond to deployment information and display a first topology diagram in the deployment interface. In the first topology diagram, multiple second computing devices are divided into multiple levels in order. Each level includes one or more second computing devices, and the second computing device in level N is the parent node of at least one second computing device in level N+1, where N is a positive integer.
[0310] The terminal can display a first topology diagram in the deployment interface in response to deployment information by executing the following steps S602 to S605.
[0311] S602, The terminal sends deployment information for multiple second computing devices to the first computing device.
[0312] S603, The first computing device responds to the deployment information and generates a first topology diagram.
[0313] The first computing device (or the management module of the first computing device) can determine multiple second computing devices that need to be deployed for target files based on the deployment information, and manage these multiple second computing devices; determine the topology configuration strategy of the multiple second computing devices based on the deployment information, and deploy the multiple second computing devices in sequence into a multi-level structure according to the topology configuration strategy and the topology structure generation algorithm, and generate the first topology structure diagram corresponding to the multi-level structure.
[0314] For example, the topology generation algorithm can be a multi-branch tree generation algorithm.
[0315] It should be noted that the process by which the first computing device determines the topology configuration strategy of multiple second computing devices based on the deployment information can refer to the process of determining the topology configuration strategy of multiple second computing devices in step S302, and will not be repeated here.
[0316] S604. The first computing device sends the first topology diagram to the terminal.
[0317] S605. The terminal displays the first topology diagram in the deployment interface.
[0318] The terminal can respond to deployment commands triggered by the user and deploy target files in multiple second computing devices according to the hierarchical relationship shown in the first or second topology diagram, based on deployment information. The second topology diagram can be obtained by the user updating the first topology diagram through the deployment interface on the terminal.
[0319] The terminal can execute the following steps S606 to S607 to respond to a user-triggered deployment command and deploy the target file in multiple second computing devices according to the hierarchical relationship shown in the first or second topology diagram, based on the deployment information.
[0320] S606. In response to the update command triggered by the user, the terminal updates the first topology diagram in the deployment interface to obtain the second topology diagram.
[0321] It should be noted that step S606 is an optional step and can be omitted in some embodiments.
[0322] Optionally, after obtaining the second topology diagram, the terminal can send the second topology diagram to the first computing device. The first computing device can update the multi-level structure corresponding to the first topology diagram based on the second topology diagram to obtain the multi-level structure corresponding to the second topology diagram.
[0323] S607. In response to the deployment command triggered by the user, the terminal sends a deployment request to the first computing device.
[0324] A deployment request can be used to instruct a first computing device to deploy a target file across multiple second computing devices according to the hierarchical relationship shown in a first or second topology diagram.
[0325] S608. In response to the deployment request, the first computing device deploys the target file in multiple second computing devices according to the hierarchical relationship shown in the first topology diagram or the second topology diagram.
[0326] It should be noted that the process of the first computing device deploying the target file on multiple second computing devices can refer to the deployment process of the first computing device on multiple second computing devices in the above embodiment, and will not be repeated here.
[0327] The terminal can display the third topology diagram in the deployment interface in response to a user-triggered query command by executing the following steps S609 to S612.
[0328] S609. The terminal responds to the query command input by the user and sends a query request to the first computing device.
[0329] A query request can be used to query the deployment status of multiple secondary computing devices. The deployment status can be one of the following: not deployed, deploying, deployment failed, or deployment completed.
[0330] S610, the first computing device responds to the query request, obtains the deployment status of multiple second computing devices, and generates a third topology diagram based on the deployment status of the multiple second computing devices and the target topology diagram.
[0331] The target topology diagram can be the topology diagram used by the first computing device in the process of deploying target files of multiple second computing devices, and it can be either the first topology diagram or the second topology diagram.
[0332] The third topology diagram can be obtained by adding the status indication information of the second computing device to the second topology diagram. The status indication information can be used to indicate the deployment status of the second computing device.
[0333] S611, The first computing device sends the third topology diagram to the terminal.
[0334] S612, The terminal displays the third topology diagram in the deployment interface.
[0335] The file deployment method provided in this application embodiment allows users to interact with a first computing device (or a management module in the first computing device) via a terminal to quickly deploy target files to multiple second computing devices. This makes the deployment of target files to multiple second computing devices simpler and more convenient for users, and also helps to improve the deployment efficiency of target files.
[0336] Figure 7 This is one of the structural schematic diagrams of the file deployment apparatus provided in the embodiments of this application. Please refer to... Figure 7 The file deployment device 700 is applied in the aforementioned first computing device, and the file deployment device 700 may include:
[0337] The acquisition module 701 is used to acquire deployment information for multiple second computing devices; the deployment information is used to instruct the deployment of target files on multiple second computing devices; wherein, the multiple second computing devices are divided into multiple levels in order, each level includes one or more second computing devices, and the second computing device in the Nth level node is the parent node of at least one second computing device in the N+1th level, where N is a positive integer;
[0338] Deployment module 702 is used to deploy target files to the second computing device in the first stage;
[0339] The transceiver module 703 is also used to send a first file retrieval address to other level second computing devices besides the first-level second computing devices; the first file retrieval address is used to instruct the second computing device to retrieve the target file from the parent node to which it is attached.
[0340] The file deployment apparatus provided in this application embodiment can execute the technical solution executed by the first computing device in the above embodiment, and its beneficial effects are similar, so it will not be described again here.
[0341] In one possible implementation, deployment module 702 is specifically used for:
[0342] Send a second file retrieval address to the second computing device in the first level. The second file retrieval address is used to instruct the second computing device in the first level to retrieve the target file from the first computing device to which it is connected.
[0343] In response to a file retrieval request sent by the second computing device in the first level, the target file is sent to the second computing device in the first level.
[0344] In one possible implementation, a plurality of deployment components are deployed in the first computing device; the deployment module 702 is specifically used for:
[0345] The deployment boot parameters corresponding to the second computing device in the first level are configured through multiple deployment components. The deployment boot parameters are used to indicate the address where the second file is obtained.
[0346] Send deployment boot parameters to the second computing device in the first stage;
[0347] Several deployment components include DHCP, TFTP, and NFS components.
[0348] In one possible implementation, for the second computing device in the Nth level; deployment module 702 is further configured to:
[0349] After confirming that the second computing device has completed the deployment of the target file, control the second computing device to start the NFS service; the NFS service is used to share the file retrieval address of the target file in the second computing device with the child nodes of the second computing device.
[0350] In one possible implementation, for the second computing device in the Nth level; deployment module 702 is further configured to:
[0351] After the child nodes attached to the second computing device complete the deployment of the target files, control the second computing device to shut down the NFS service;
[0352] If the target file is an image file, the image file is used to deploy the target system in the second computing device, and the method further includes:
[0353] After the target system deployment is completed on the child node attached to the second computing device, the target file is deleted from the second computing device.
[0354] In one possible implementation, for the second computing device in the Nth level; deployment module 702 is further configured to:
[0355] Based on the grouping indication information of multiple second computing devices in the deployment information, the multiple second computing devices are divided into multiple device groups, and the grouping indication information of the second computing devices within the same device group is the same;
[0356] Based on the number of first devices that the first computing device can support simultaneously downloading target files and the number of second devices that the second computing device can support simultaneously downloading target files, determine the first deployment order among multiple device groups and the second deployment order of the second computing devices within each device group;
[0357] The topology configuration strategy is determined based on the first deployment order and the second deployment order of the second computing devices within each device group;
[0358] Based on the topology configuration strategy, multiple secondary computing devices are deployed as multi-level secondary computing devices;
[0359] The grouping indication information includes at least one of the following information of the second computing device: rack information, network segment information, computer room information, or functional information.
[0360] In one possible implementation, the target file is an image file, which is used to deploy the target system in a second computing device.
[0361] Figure 8 This is a second schematic diagram of the file deployment device provided in an embodiment of this application. Please refer to [link / reference]. Figure 8The file deployment device 800 is applied in the aforementioned second computing device. The file deployment device 800 may include an acquisition module 801, a transceiver module 802, and a deployment module 803.
[0362] The acquisition module 801 is used to acquire the file acquisition address; the file acquisition address is sent by the parent node of the second computing device or by the first computing device; wherein, the multiple second computing devices are divided into multiple levels in order, each level includes one or more second computing devices, and the second computing device in the Nth level is the parent node of at least one second computing device in the N+1th level, where N is a positive integer;
[0363] The acquisition module 801 is also used to acquire the target file from the parent node of the second computing device based on the file address;
[0364] The transceiver module 802 is used to send the target file to the attached child node in response to the file retrieval request of the child node of the second computing device.
[0365] The file deployment apparatus provided in this application embodiment can execute the technical solution executed by the second computing device in the above embodiment, and its beneficial effects are similar, so they will not be described again here.
[0366] In one possible implementation, deployment module 803 is used for:
[0367] After the target file is deployed on the second computing device and child nodes are attached to the second computing device, the NFS service is started under the control of the first computing device. The NFS service is used to share the file retrieval address of the target file in the second computing device with the child nodes of the second computing device.
[0368] In one possible implementation, deployment module 803 is used for:
[0369] After the child nodes attached to the second computing device complete the deployment of the target files, the NFS service is shut down under the control of the first computing device.
[0370] If the target file is an image file, the image file is used to deploy the target system in the second computing device, and the method further includes:
[0371] After the target system deployment is completed on the child node attached to the second computing device, the target file is deleted from the second computing device.
[0372] In one possible implementation, the multiple second computing devices are deployed as multi-level second computing devices according to a topology configuration strategy. The topology configuration strategy is determined based on the grouping indication information of the multiple second computing devices in the deployment information, the number of first devices that the first computing device supports for simultaneous downloading of target files, and the number of second devices that the second computing device supports for simultaneous downloading of target files. The grouping indication information includes at least one of the following information of the multiple second computing devices: rack information, network segment information, data center information, or supported functions.
[0373] In one possible implementation, the target file is an image file; the deployment module 803 is used for:
[0374] Based on the image file, deploy the target system on the second computing device.
[0375] Figure 9 This is the third schematic diagram of the file deployment device provided in the embodiments of this application. Please refer to... Figure 9 The file deployment device 900 is applied in the aforementioned terminal with a display. The file deployment device 900 may include an acquisition module 901, a display module 902, a deployment module 903, and an update module 904, wherein:
[0376] The acquisition module 901 is used to acquire deployment information for multiple second computing devices input by the user; the deployment information is used to instruct the deployment of target files on multiple second computing devices;
[0377] Display module 902 is used to display a first topology diagram in the deployment interface in response to deployment information; in the first topology diagram, multiple second computing devices are divided into multiple levels in order, each level includes one or more second computing devices, and the second computing device in level N is the parent node of at least one second computing device in level N+1, where N is a positive integer;
[0378] Deployment module 903 is used to respond to deployment instructions triggered by the user and deploy target files in multiple second computing devices according to the hierarchical relationship shown in the first topology diagram, based on deployment information.
[0379] The file deployment device provided in this application embodiment can execute the technical solution executed by the terminal in the above embodiment, and its beneficial effects are similar, so they will not be described again here.
[0380] In one possible implementation, update module 904 is used for:
[0381] In response to the user-triggered update command, the first topology diagram is updated in the deployment interface to obtain the second topology diagram.
[0382] In one possible implementation, deployment module 903 is also used for:
[0383] In response to a user-triggered query, a third topology diagram is displayed in the deployment interface;
[0384] The query command is used to query the deployment status of multiple secondary computing devices. The deployment status can be one of the following: not deployed, deploying, deployment failed, or deployment completed.
[0385] The third topology diagram can be obtained by adding the status indication information of the second computing device to the second topology diagram. The status indication information can be used to indicate the deployment status of the second computing device.
[0386] In one possible implementation, deployment module 903 is further configured to:
[0387] Based on the grouping indication information of multiple second computing devices in the deployment information, the multiple second computing devices are divided into multiple device groups, and the grouping indication information of the second computing devices within the same device group is the same;
[0388] Based on the number of first devices that the first computing device can support simultaneously downloading target files and the number of second devices that the second computing device can support simultaneously downloading target files, determine the first deployment order among multiple device groups and the second deployment order of the second computing devices within each device group;
[0389] The topology configuration strategy is determined based on the first deployment order and the second deployment order of the second computing devices within each device group;
[0390] Based on the topology configuration strategy, multiple secondary computing devices are deployed as multi-level secondary computing devices;
[0391] The grouping indication information includes at least one of the following information of the second computing device: rack information, network segment information, computer room information, or functional information.
[0392] Figure 10 This is a schematic diagram of the structure of a computing device provided in an embodiment of this application. Please refer to... Figure 10 The computing device 1000 can be the first computing device, the second computing device, or the terminal in the above method embodiments. The computing device 1000 may include a processor 1001 and a memory 1002, which are coupled together. The processor 1001 and the memory 1002 can communicate; for example, the processor 1001 and the memory 1002 communicate via a communication bus 1003.
[0393] Memory 1002 is used to store program instructions;
[0394] The processor 1001 is used to execute program instructions to perform the technical solution as shown in the above method embodiments.
[0395] Optionally, the aforementioned processor can be a CPU, or other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), etc. A general-purpose processor can be a microprocessor or any conventional processor. The steps of the method disclosed in the embodiments of this application can be directly implemented by a hardware processor, or implemented by a combination of hardware and software modules within the processor.
[0396] This application provides a computer-readable storage medium storing computer-executable instructions; when executed by a processor, the computer-executable instructions are used to implement the file deployment method shown in the above embodiments.
[0397] This application provides a computer program product, which includes a computer program. When the computer program is executed by a processor, it causes the computer to perform the file deployment method shown in the above embodiments.
[0398] All or part of the steps in the above-described method embodiments can be implemented by hardware related to program instructions. The aforementioned program can be stored in a readable memory. When the program is executed, it performs the steps of the above-described method embodiments; and the aforementioned memory (storage medium) includes: read-only memory (ROM), RAM, flash memory, hard disk, solid-state drive, magnetic tape, floppy disk, optical disk, and any combination thereof.
[0399] This application describes embodiments with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of this application. It should 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 processing unit of a general-purpose computer, special-purpose computer, embedded processor, or other programmable device to produce a machine, such that the instructions, which execute via the processing unit of the computer or other programmable device, create means for implementing the functions specified in one or more flowchart illustrations and / or one or more block diagrams.
[0400] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means that implement the functions specified in one or more flowcharts and / or one or more block diagrams.
[0401] These computer program instructions may also be loaded onto a computer or other programmable device to cause a series of operational steps to be performed on the computer or other programmable device to produce a computer-implemented process, such that the instructions, which execute on the computer or other programmable device, provide steps for implementing the functions specified in one or more flowcharts and / or one or more block diagrams.
[0402] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the embodiments of this application, and are not intended to limit them. Although the embodiments of this application have been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some or all of the technical features therein. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of this application.
Claims
1. A file deployment method characterized by, Applied in the first computing device, the method comprises: Obtaining deployment information of a plurality of second computing devices; the deployment information is used to indicate deployment of a target file on the plurality of second computing devices; wherein the plurality of second computing devices are divided into multiple levels in order, each level comprises one or more second computing devices, and the second computing device in the Nth level is the parent node of at least one second computing device in the N+1th level, and N is a positive integer; Deploying the target file to the second computing device in the first level; Sending a first file acquisition address to the second computing device in other levels except the first level; the first file acquisition address is used to indicate that the second computing device acquires the target file from the parent node to which the second computing device is connected.
2. The method of claim 1, wherein, Deploying the target file to the second computing device in the first level comprises: Sending a second file acquisition address to the second computing device in the first level, the second file acquisition address is used to indicate that the second computing device in the first level acquires the target file from the first computing device to which the second computing device is connected; In response to the file acquisition request sent by the second computing device in the first level, sending the target file to the second computing device in the first level.
3. The method of claim 2, wherein, A plurality of deployment components are deployed in the first computing device; sending a second file acquisition address to the second computing device in the first level comprises: Configuring deployment guide parameters corresponding to the second computing device in the first level through the plurality of deployment components, the deployment guide parameters being used to indicate the second file acquisition address; Sending the deployment guide parameters to the second computing device in the first level; Wherein the plurality of deployment components comprise a dynamic host configuration protocol (DHCP) component, a simple file transfer protocol (TFTP) component and a network file system (NFS) component.
4. The method according to any one of claims 1 to 3, characterized in that, For the second computing device in the Nth level; the method further comprises: After determining that the second computing device completes the deployment of the target file and the second computing device is connected with a child node, controlling the second computing device to start an NFS service; The NFS service is used to share the file acquisition address of the target file in the second computing device to the child node of the second computing device.
5. The method of claim 4, wherein, For the second computing device in the Nth level; the method further comprises: After the child node connected with the second computing device completes the deployment of the target file, controlling the second computing device to close the NFS service; If the target file is an image file used to deploy a target system in the second computing device, the method further comprises: After the child node connected with the second computing device completes the deployment of the target system, deleting the target file in the second computing device.
6. The method according to any one of claims 1-5, characterized in that, The method further comprises: According to the grouping indication information of the plurality of second computing devices in the deployment information, dividing the plurality of second computing devices into a plurality of device groups, and the grouping indication information of the second computing devices in the same device group is the same. determining a first deployment order between a plurality of device groups and a second deployment order of the second computing devices within each device group according to a first number of devices supported by the first computing device to download the target file simultaneously and a second number of devices supported by the second computing device to download the target file simultaneously; determining a topology configuration strategy according to the first deployment order and the second deployment order of the second computing devices within each device group; deploying a plurality of the second computing devices as multi-level second computing devices according to the topology configuration strategy; wherein the grouping indication information comprises at least one of the following information of the second computing devices: cabinet information, network segment information, computer room information or function information.
7. The method according to any one of claims 1 to 6, characterized in that, The target file is an image file, and the image file is used to deploy a target system in the second computing device.
8. A file deployment method characterized by, The method applied to the second computing device comprises: obtaining a file obtaining address; the file obtaining address is sent by a parent node of the second computing device or sent by a first computing device; wherein a plurality of the second computing devices are divided into multiple levels in order, each level comprises one or more of the second computing devices, and a second computing device in an Nth level is a parent node of at least one second computing device in an (N+1)th level, and N is a positive integer; obtaining a target file from the parent node of the second computing device based on the file obtaining address; in response to a file obtaining request of a child node of the second computing device, sending the target file to the child node.
9. A file deployment method characterized by, The method comprises: obtaining deployment information of a plurality of second computing devices input by a user; the deployment information is used to indicate deployment of a target file on a plurality of the second computing devices; in response to the deployment information, displaying a first topology structure diagram in a deployment interface; in the first topology structure diagram, a plurality of the second computing devices are divided into multiple levels in order, each level comprises one or more of the second computing devices, and a second computing device in an Nth level is a parent node of at least one second computing device in an (N+1)th level, and N is a positive integer; in response to a deployment instruction triggered by the user, deploying the target file in a plurality of the second computing devices according to a hierarchical relationship shown in the first topology structure diagram according to the deployment information.
10. A computing device, comprising: comprise: a processor and a memory; the processor and the memory are coupled; the memory is used to store program instructions; the processor is used to execute the program instructions to implement the method of any one of claims 1 to 9.