A self-adaptive deployment method and system for a signal creation heterogeneous environment
By building a hardware resource pool and a standardized software repository, combined with DAG dependency resolution and Kahn topology sorting, adaptive deployment of heterogeneous CPUs in a domestic environment is achieved. This solves the problems of compatibility of diverse CPU architectures and complex software dependencies, improves deployment efficiency and security, and meets the requirements of domestic production.
Patent Information
- Application Number
- CN202510551724.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-29
- Publication Date
- 2026-01-13
- Estimated Expiration
- 2045-04-29
AI Technical Summary
In a domestic production environment, the poor compatibility of diverse CPU architectures, complex software dependencies, and high security configuration risks mean that traditional deployment models cannot meet the needs for rapid response and independent control.
By building a hardware resource pool, a multi-architecture operating system image library, and a standardized software repository, and combining the DAG dependency resolution algorithm and Kahn topology sorting, one-click automated deployment of domestic software such as databases and middleware is achieved in heterogeneous CPU environments. Probe + rule engine is used to dynamically adapt firewall policies, and SHA-256 hash verification is used to ensure image security.
It enables efficient and automated deployment of domestically developed software in heterogeneous CPU environments, resolves dependency conflicts, improves deployment efficiency, ensures network security, complies with the Cybersecurity Classified Protection 2.0 requirements, simplifies environment configuration, and reduces manual intervention.
Smart Images

Figure CN120104142B_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of automated deployment technology for cloud computing platforms, and specifically relates to an adaptive deployment method and system for heterogeneous environments for domestic IT innovation. Background Technology
[0002] In the current development of the information technology industry, the trend of domestic substitution is becoming increasingly significant. Domestic operating systems, middleware, and databases have made substantial progress, exhibiting rapid growth with a compound annual growth rate of 38.7%. Many companies are actively investing in the application of domestic technologies; however, in this process, their products face extremely complex challenges in adapting to domestic technologies. Traditional build and deployment models, when faced with the rapid iteration of domestic technology systems, have revealed many drawbacks and can no longer meet the urgent needs of companies for rapid response to domestic environments. There is an urgent need to explore more efficient adaptation and delivery paths.
[0003] Chinese patent application CN201110404908.5 discloses a semi-automatic batch deployment method for heterogeneous cluster operating systems. It employs a distributed image server architecture, generates system images using prototype machines, and accelerates distribution via P2P image sharing. Heterogeneous nodes install via network (ISO image), while homogeneous nodes install using file system copying. However, this solution lacks consideration for the unique characteristics of domestic CPU architectures and fails to address instruction set compatibility issues. The software installation process relies on manual operation, making it difficult to resolve version dependency conflicts with domestic software. Furthermore, it lacks security protection, failing to automate firewall policy configuration and struggling to cope with complex security challenges. Chinese patent application CN202011366095.0 discloses an intelligent deployment method for heterogeneous hybrid environments. It utilizes version control (Git / SVN) to manage configurations, unifying the management of hardware information, software dependencies, and configuration items, and performs intelligent environment adaptation deployment based on the CART classification tree algorithm. However, this solution relies on foreign middleware such as Rancher / Nexus, which does not meet the requirements of independent and controllable development; the classification tree model needs to be pre-trained, making it difficult to keep up with the rapid updates of domestic software; and its security protection capabilities are limited, only achieving basic configuration management, which is insufficient to deal with various security risks.
[0004] Therefore, there is an urgent need for a new method for adaptive deployment of heterogeneous domestic CPUs in the context of information technology innovation. Summary of the Invention
[0005] To address the aforementioned problems in the existing technology, namely poor compatibility of diverse CPU architectures, complex software dependencies, and high security configuration risks in a domestically developed environment, the first aspect of this invention proposes an adaptive deployment method for heterogeneous environments in the context of domestic IT innovation. The method includes the following steps:
[0006] S1. Obtain task instructions, create a new target task in the pre-built automated deployment engine, and define the environmental basic metadata for deploying the target task; the automated deployment engine includes a hardware resource pool, a domestic software standardization repository, and a system image repository;
[0007] S2. Analyze the target task to obtain hardware information templates and key hardware parameters;
[0008] S3. Based on the key hardware parameters, configure the virtual machine to be built, dynamically match the CPU architecture and OS in the system image repository, and generate a list of CPU architecture and OS candidates that are compatible with the architecture.
[0009] S4. Determine the target CPU architecture and target OS, pull the image adapted to the target CPU architecture from the system image repository to the local host machine, and perform security verification.
[0010] S5. Based on the hardware information template, generate a virtual machine startup command, send it to the host machine for execution, and perform a secondary security verification.
[0011] S6. Inject the IP address information from the environment's basic metadata into the network interface card configuration file, and then restart the network interface card;
[0012] S7. Identify the firewall type of the target system based on the firewall probe, generate an adaptive network security policy based on the identification results, obtain the network security configuration file and load it.
[0013] S8. After the network security configuration file is loaded, the target software and its dependency configuration files are pulled from the domestic software standardization repository to the virtual machine, and its dependencies and version constraints are extracted. The topological sorting result is generated based on the DAG dependency relationship parsing algorithm.
[0014] S9. Install applications in sequence according to the topology sorting results to achieve automated deployment of application software.
[0015] In some preferred embodiments, the environmental metadata includes project number, deployment type, CPU information, CPU cores, memory specifications, storage capacity, operating system name, system version, IP address information, firewall whitelist, and pre-installed software list.
[0016] In some preferred embodiments, the method for obtaining hardware information templates and key hardware parameters is as follows:
[0017] The environmental metadata of the target task is assembled into a hardware information template, and the hardware information template is parsed to obtain key hardware parameters, including processor architecture, memory capacity, number of CPU cores and storage space.
[0018] In some preferred embodiments, during the process of dynamically matching the CPU architecture and the OS, a dynamic capacity assessment of the CPU is performed based on the load status of the resource pool:
[0019] If the average CPU usage rate continuously ≥ M% and < N%, a mild alarm is triggered to prompt an expansion suggestion; if the CPU usage rate ≥ N% or the peak value of a single core ≥ S%, the construction is terminated and an alarm is triggered;
[0020] where M < N < S.
[0021] In some preferred embodiments, a security check is performed, and the method is as follows:
[0022] When pulling the image, the pre-stored hash value is read from the metadata file and compared with the real-time hash value of the image after transmission; if the verification fails, an automatic retransmission or an alarm is triggered;
[0023] Among them, the execution times of the automatic retransmission do not exceed 3 times.
[0024] In some preferred embodiments, a secondary security check is performed, and the method is as follows:
[0025] Before starting the virtual machine, the original hash value of the image file is verified and compared with the pre-stored hash value in the metadata. If the hash values are the same, the virtual machine is started; otherwise, the deployment is terminated and the image file is marked as untrusted, and the execution ends and the system pops up a window to remind the user to confirm.
[0026] In some preferred embodiments, an adaptive network security policy is generated, and the method is as follows:
[0027] The firewall service currently used by the host is identified through probe technology. According to the identification result, a predefined security policy template is called, and the placeholders in the template are automatically replaced to generate specific configuration instructions. Then, the security policy is executed through SSH and its effectiveness is verified, and security parameter appendices are dynamically generated according to requirements for command execution.
[0028] In some preferred embodiments, if the identification result is that multiple firewall services are active at the same time, the highest priority is selected as the main firewall, other firewall services are automatically disabled, and a firewall service conflict report is generated and pushed to the management interface to prompt the user to confirm; if the user confirmation passes, the historical rules of other firewalls are migrated to the main firewall.
[0029] In some preferred embodiments, a topological sorting result is generated based on the DAG-based dependency parsing algorithm, and the method is as follows:
[0030] A. Create DAG nodes and verify whether the software package supports the target CPU architecture;
[0031] B. Based on the extracted dependencies and version constraints, resolve the dependency relationships and construct a DAG dependency graph;
[0032] C. Use depth-first search to traverse the DAG dependency graph and detect whether there are circular dependencies:
[0033] If it does not exist, proceed to step D;
[0034] Otherwise, search for and replace lower version dependencies from the domestic software standardization repository, and then proceed to step A; if no solution is found, generate a circular dependency report containing conflicting paths and suggested versions and push it to manual decision-making.
[0035] D. Check for version conflicts. If no conflict exists, proceed to step E. Otherwise, first search for a compatible version or recommended equivalent version from the domestic software standardization repository, replace it, and then execute step A. If a replacement cannot be made, generate a conflict report for manual processing.
[0036] E. Generate a topological sorting sequence based on the Kahn algorithm, and mark node groups with no direct dependencies as those that can be installed in parallel.
[0037] A second aspect of the present invention proposes an adaptive deployment system for heterogeneous environments in the field of information technology innovation, comprising:
[0038] The automated deployment engine is configured to generate virtual machine startup commands based on the hardware information template and send them to the host machine for execution; it is also configured to inject IP address information from the environment's basic metadata into the network card configuration file and restart the network card; it is further configured to execute installations sequentially based on the topology sorting results, thereby achieving automated deployment of the application system; the automated deployment engine includes a hardware resource pool, a standardized repository of domestic software, and a system image repository;
[0039] The hardware parameter configuration / parsing module is configured to obtain task instructions, create a new target task in the pre-built automated deployment engine, define the environmental basic metadata for deploying the target task, and then obtain hardware information templates and key hardware parameters.
[0040] The cross-platform image generation module is configured to dynamically match the CPU architecture and OS in the system image repository based on the key hardware parameters, and generate a candidate list of CPU architecture and OS that are compatible with the architecture; it is also configured to parse the host machine's device IP information according to the target CPU architecture and target OS, and pull the image adapted to the target CPU architecture from the system image repository to the host machine; it is also configured to pull the target software and its dependency configuration files from the domestic software standardization repository.
[0041] The security verification module is configured to perform security verification when pulling the image; it is also configured to perform a secondary security verification before executing the virtual machine startup command.
[0042] The network security module is configured to execute firewall probes, identify the firewall type of the target system, generate adaptive network security policies based on the identification results, obtain security configuration files, and load them.
[0043] The topology sorting generation module is configured to extract the dependencies and version constraints of the target software and its dependency configuration files, abstract the software packages into DAG nodes, and generate topology sorting results based on the DAG dependency resolution algorithm.
[0044] The beneficial effects of this invention are:
[0045] (1) The present invention constructs a multi-architecture automatic deployment engine for hardware abstraction layer by using hardware resource pool, multi-architecture operating system image library and standardized software repository. Combined with DAG dependency parsing algorithm and Kahn topology sorting to optimize installation order, it realizes one-click automated and efficient deployment of domestic software such as database and middleware in heterogeneous CPU environment, solves the problem of dependency conflict, significantly improves deployment efficiency, eliminates human operation error, and supports cross-architecture compatibility.
[0046] (2) The probe + rule engine is used to dynamically adapt the firewall policy to ensure compliance with the security requirements of the Information Security Protection 2.0. It supports dynamic adaptation of mainstream firewall tools such as firewalld, ufw, and iptables, enabling rapid deployment of firewall policies. It can automatically adjust the policy according to changes in the network environment to ensure the network security of the system.
[0047] (3) At the same time, through the automatic configuration of hash verification and security policies, the SHA-256 hash verification algorithm is used to ensure the security and consistency of the image during the generation, transmission and use of the image, to prevent the image from being tampered with or damaged, to ensure the stable operation of the system, and to provide solid support for the information technology innovation ecosystem.
[0048] (4) The environment configuration of domestic systems is simplified by dynamically generating configuration files through preset templates. The standardized software repository covers basic software. Package dependencies and compatibility constraints are defined through depends.json. Combined with the DAG dependency resolution algorithm, a directed acyclic graph is automatically generated. The installation order is optimized by combining the Kahn algorithm to solve the multi-level nested dependency problem. A conflict-free installation sequence is automatically generated. Dynamic dependency resolution is optimized to reduce repeated debugging caused by manual intervention. Attached Figure Description
[0049] Other features, objects, and advantages of this application will become more apparent from the following detailed description of non-limiting embodiments with reference to the accompanying drawings:
[0050] Figure 1This is a flowchart of an adaptive deployment method for heterogeneous environments in the context of information technology innovation, as described in this invention.
[0051] Figure 2 This is a flowchart of the adaptive network security policy generation strategy in an embodiment of the present invention;
[0052] Figure 3 This is a schematic diagram of the security policy template library in an embodiment of the present invention;
[0053] Figure 4 This is a flowchart of the process of pulling the system from the image library and performing hash verification in an embodiment of the present invention;
[0054] Figure 5 This is a flowchart of the automated software deployment in an embodiment of the present invention. Detailed Implementation
[0055] The present application will now be described in further detail with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are for illustrative purposes only and are not intended to limit the invention. Furthermore, it should be noted that, for ease of description, only the parts relevant to the invention are shown in the accompanying drawings.
[0056] It should be noted that, unless otherwise specified, the embodiments and features described in this application can be combined with each other. This application will now be described in detail with reference to the accompanying drawings and embodiments.
[0057] This invention addresses the challenges of poor compatibility with diverse CPU architectures, complex software dependencies, and high security configuration risks in domestically developed environments. Based on dynamic dependency resolution and adaptive strategies, it proposes an adaptive deployment method for heterogeneous environments in the domestic IT innovation sector. By constructing a hardware resource pool, a multi-architecture operating system image library, and a standardized software repository, and combining a DAG dependency resolution algorithm with Kahn topology sorting to optimize the installation order, it achieves one-click automated and efficient deployment of domestically developed software such as databases and middleware in heterogeneous CPU environments. This achieves compatibility with diverse domestic CPU architectures, enables one-click automated deployment of domestically developed operating systems, databases, middleware, and other software, improves deployment efficiency, reduces deployment difficulty, and constructs a secure, reliable, and universal automated deployment solution, facilitating the smooth advancement of domestic technology applications.
[0058] To more clearly illustrate the adaptive deployment method for heterogeneous environments in the field of information technology innovation according to the present invention, the following will be combined with... Figure 1-5 The steps in the embodiments of the present invention will be described in detail below.
[0059] An adaptive deployment method for heterogeneous environments in the field of information technology innovation according to a first embodiment of the present invention includes steps S100-S600, each step of which is described in detail below:
[0060] S100: Obtain task instructions, create a new target task in the pre-built automated deployment engine, define the environmental basic metadata for deploying the target task, and finally assemble this information into a hardware information configuration template; the automated deployment engine includes a hardware resource pool, a domestic software standardization repository, and a system image repository.
[0061] Preferably, the environmental basic metadata includes project number, deployment type, CPU information, CPU cores, memory specifications, storage capacity, operating system name, system version, IP address information, firewall whitelist, and pre-installed software list.
[0062] Preferably, an automated deployment engine is built, including the separate construction of a basic domestic hardware pool, a storage pool, a standardized domestic software repository, and a system image repository.
[0063] In this embodiment, a basic domestic hardware pool and storage pool are constructed. The domestic hardware CPU, memory, storage, and network are virtualized using bare metal virtualization technology QEMU-KVM. For different CPU architectures (such as LoongArch, which requires enabling the KVM extension module), the corresponding virtualization driver is dynamically loaded. Then, the architecture, memory, number of cores, and storage capacity information are recorded. The recorded information can be dynamically adjusted according to the actual information of the host machine hardware resource pool.
[0064] In this embodiment, a standardized repository for domestically developed software is constructed, covering the full-stack software ecosystem of mainstream domestic CPU architectures. A layered architecture design is adopted to achieve unified management and scheduling of domestically developed components.
[0065] The operating system layer integrates mainstream domestic operating system distributions, forming a multi-architecture compatible system including a domestic OS, supporting mainstream instruction sets such as C86 / ARM / SW64, ensuring cross-platform deployment capabilities. The database layer provides a full-scenario solution for domestic databases, including transactional and analytical databases. The middleware layer covers enterprise-level application support platforms. Furthermore, it provides out-of-the-box configuration templates, including pre-installed software installation addresses, configuration files, pre-installed parameters, and default port information. The dependency environment layer builds a standardized development toolchain including gcc / g++, supporting C / C++ compilation, a glibc compatibility layer, Java JDK, etc. By covering the complete basic software "operating system-database-middleware" technology stack, it achieves the integration of a domestic ecosystem.
[0066] In this embodiment, the mainstream domestic CPU architecture is any one of C86 / ARM / MIPS / LoongArch / SW64.
[0067] The standardized software repository covers foundational software (databases, middleware, dependent environments, etc.). Package dependencies and compatibility constraints are defined using depends.json. A Directed Acyclic Graph (DAG) dependency resolution algorithm is used to automatically generate a DAG. The Kahn algorithm optimizes installation order and resolves multi-level nested dependency issues. A layered architecture design enables unified management and automated deployment of domestically developed components.
[0068] In this embodiment, a system image repository is constructed, which stores system templates in RAW format (supporting fast cloning and bare metal-level performance). These templates mainly include basic operating system templates and application platform combination templates, which users can select and use as needed to achieve rapid deployment. After the image is built, its SHA-256 hash value is immediately calculated and written to the metadata file (metadata.json), which is then synchronously stored in the repository along with the image.
[0069] In a further preferred embodiment, a storage capacity threshold is preset based on actual business needs.
[0070] S200. Based on the task information submitted by the user, parse the obtained hardware information configuration template and parse the obtained key hardware parameters; the key hardware parameters include:
[0071] Processor architecture, memory capacity, number of CPU cores, and storage space.
[0072] The hardware abstraction layer decouples the environment configuration from the physical devices. This is achieved by defining hardware parameters as template data, which are dynamically adapted to the hardware during deployment, rather than being hard-coded to a specific server. The same template can be reused across different domestic CPUs, thus decoupling the environment configuration from the physical devices and ensuring the consistency of the environment configuration.
[0073] During the parsing process, the processor architecture information is first filtered and compared with the host information in the hardware pool to obtain the IP address and configuration information of the target host. The virtual machine hardware parameters are compared with the available resources of the host to determine whether they have exceeded and reached the critical value. Otherwise, the host cannot meet the virtual machine's requirements.
[0074] S300. Based on the key hardware parameters, configure the virtual machine to be built, dynamically match domestic CPUs and domestic operating systems in the system image repository according to the hardware parameters, and generate a list of compatible CPU architectures and OS candidates for users to choose from.
[0075] Preferably, in this embodiment, during the process of dynamically matching the CPU architecture and OS, the CPU's capacity is dynamically assessed based on the resource pool load status, and a tiered alarm is triggered if resources are insufficient.
[0076] If the average CPU utilization remains ≥70% and <80%, a minor alarm will be triggered, suggesting capacity expansion; if the CPU utilization is ≥80% or the single-core peak is ≥95%, the build will be terminated and an alarm will be triggered.
[0077] S400 determines the target CPU architecture and target OS, parses the host machine's device IP information, pulls an image adapted to the target CPU architecture from the system image repository to the host machine, and performs security verification.
[0078] Preferably, in this embodiment, based on the CPU architecture selected by the user, the host device IP address is resolved through the resource scheduling module to ensure that the target host has virtualization support for the corresponding CPU instruction set (e.g., an ARM host needs to enable KVM-RAM extension). Bare-metal level deployment efficiency is achieved through the KVM virtualization driver layer (QEMU-KVM technology), enabling rapid installation and deployment of the operating system.
[0079] Preferably, in this embodiment, based on the operating system selected by the user, a RAW format image adapted to the target CPU architecture is pulled from a preset operating system image repository and stored on the host machine.
[0080] By pre-installing domestically developed operating systems and drivers through an operating system image repository, software installation efficiency is improved. When a virtual machine needs to be created, the host machine is matched according to the configuration and requirements of the target virtual machine. Then, the RAW image of the target virtual machine is pulled to the host machine, and the virtual machine is started. The virtualization software on the host machine allocates the corresponding resources to the virtual machine according to the storage location of the image on the host machine and related configuration information, and loads the operating system and related software in the image into the virtual machine, thereby completing the startup and initialization of the virtual machine.
[0081] In some preferred embodiments, a security check is performed during image fetching, and the method is as follows:
[0082] When pulling the image, the pre-stored hash value is read from the metadata file and compared with the real-time hash value of the image after transmission. If the verification is successful, the automatic deployment process continues; if the verification fails, automatic retransmission or alarm is triggered.
[0083] The automatic retransmission is executed no more than 3 times.
[0084] S500. Based on the hardware information template, generate a virtual machine startup command and send it to the host machine for execution. Before starting the virtual machine, perform a second verification of the original hash value of the image file and compare it with the pre-stored hash value in the metadata. If the hash values match, start the virtual machine; otherwise, terminate the deployment and mark the image file as "untrusted". After execution, the system will pop up a dialog box to remind the user to confirm.
[0085] S600: Inject the IP address information from the environmental basic metadata into the network card configuration file, and restart the network card. The method is as follows:
[0086] The preset IP information is injected into the network card configuration file via virt-customize, then the network card is restarted. The host machine is then checked for PING based on the IP address information (IP / network card / DNS). If PING fails, the operation is rolled back.
[0087] The S700 identifies the firewall type of the target system based on firewall probes, calls predefined security policy templates according to the identification results, and dynamically generates adaptive network security policies that meet the requirements of Cybersecurity Classified Protection 2.0 and Information Technology Innovation.
[0088] Preferably, the method for generating the adaptive network security policy is as follows:
[0089] The system uses probe technology to identify the firewall services currently used by the host machine. Based on the identification results, it calls a predefined security policy template, automatically replaces placeholders in the template to generate specific configuration instructions, and then drives the execution of the security policy via SSH and verifies its effectiveness. The configuration rule base complies with the "Information Security Technology - Basic Requirements for Network Security Level Protection" (GB / T 22239—2019), which is the requirement of Level Protection 2.0 and the adaptation requirements of the information technology innovation environment, thus avoiding the risks of manual configuration.
[0090] More preferably, in this embodiment, if the identification result shows that multiple firewall services are active at the same time, the highest priority is selected as the main firewall, other firewall services are automatically disabled, and a firewall service conflict report is generated and pushed to the management interface to prompt the user for confirmation; if the user confirms, the historical rules of other firewalls are migrated to the main firewall.
[0091] More preferably, in this embodiment, the method for identifying the firewall service currently used by the host machine is as follows:
[0092] Using firewall state probe commands (e.g., `systemctl is-active firewalld> / dev / null 2>&1&&echo "firewalld"`), the status of firewall services is probed by executing system commands. The probing logic prioritizes the first active firewall service, following the order firewalld->ufw->iptables. Figure 3 As shown.
[0093] The firewall policy generation mechanism employs a probe + rule engine, supporting dynamic adaptation to mainstream firewall tools such as firewalld, ufw, and iptables, enabling rapid deployment of firewall policies. This policy can automatically adjust according to changes in the network environment, ensuring system network security.
[0094] S800 retrieves the target software and its dependency configuration file depends.json from the domestic software standardization repository, extracts its dependencies and version constraints, and generates a topological sorting result based on the DAG dependency resolution algorithm.
[0095] Preferably, the topological sorting result is generated using a dependency resolution algorithm based on DAG, and the method is as follows:
[0096] A. Create DAG nodes and verify whether the software package supports the target CPU architecture. If the dependency only supports the x86 architecture, trigger an alarm and exclude incompatible nodes.
[0097] B. Based on the extracted dependencies and version constraints, resolve the dependency relationships, construct a DAG dependency graph to map each software package (such as A and B) as a node, label the name, version and architecture information, and create directed edges according to the dependency relationships (if A depends on B, then generate the edge A→B).
[0098] C. Use depth-first search to traverse the DAG dependency graph and detect whether there are circular dependencies (such as A→B→A):
[0099] If it does not exist, proceed to step D;
[0100] Otherwise, search for and replace lower version dependencies from the domestic software standardization repository, and then proceed to step A; if no solution is found, generate a circular dependency report containing conflicting paths and suggested versions and push it to manual decision-making.
[0101] D. Check for version conflicts (e.g., A requires glibc ≥ 2.17, B requires glibc < 2.0):
[0102] If it does not exist, proceed to step E;
[0103] Otherwise, prioritize searching for compatible or recommended equivalent versions from the domestic software standardization repository, replace them, and then proceed to step A; if replacement is not possible, generate a conflict report for manual processing.
[0104] E. Generate a topological sorting sequence based on the Kahn algorithm, and mark node groups with no direct dependencies as those that can be installed in parallel.
[0105] The DAG-based dependency resolution algorithm (Kahn topological sorting) automatically generates conflict-free installation sequences, optimizes dynamic dependency resolution, and reduces repeated debugging caused by manual intervention.
[0106] S900: Install components sequentially according to the topology sorting results, using RPM / DPKG commands to install dependencies; assign components marked as parallel to independent threads for concurrent execution, limiting the maximum number of parallel executions through a thread pool (logical CPU count). Monitor the installation status in real time during deployment; if a node fails (e.g., due to missing dependencies), immediately interrupt the process and roll back installed components; verify the validity and integrity of the software after installation.
[0107] Preferably, after all nodes are successfully installed, the authorization file is configured, the authorization certificate file is deployed to the installation root directory, and finally the service is started and verified, and the feedback is uniformly sent to the user; after all is completed, the system interface prompts "deployment completed" and generates a deployment report containing detailed logs, recording the installation time, parallel efficiency and abnormal events.
[0108] Preferably, before installation, the environment is verified by using a preset verification module to perform multi-dimensional environmental detection on the target host, including hardware indicators such as memory capacity and disk space.
[0109] Although the steps in the above embodiments are described in the above order, those skilled in the art will understand that in order to achieve the effect of this embodiment, different steps do not need to be executed in such an order. They can be executed simultaneously (in parallel) or in a reverse order. These simple variations are all within the protection scope of this invention.
[0110] A second embodiment of the present invention provides an adaptive deployment system for heterogeneous environments in the field of information technology innovation, comprising:
[0111] The automated deployment engine is configured to generate virtual machine startup commands based on the hardware information template and send them to the host machine for execution; it is also configured to inject IP address information from the environment's basic metadata into the network card configuration file and restart the network card; it is further configured to execute installations sequentially based on the topology sorting results, thereby achieving automated deployment of the application system; the automated deployment engine includes a hardware resource pool, a standardized repository of domestic software, and a system image repository;
[0112] The hardware parameter configuration / parsing module is configured to obtain task instructions, create a new target task in the pre-built automated deployment engine, define the environmental basic metadata for deploying the target task, and then obtain hardware information templates and key hardware parameters.
[0113] The cross-platform image generation module is configured to dynamically match the CPU architecture and OS in the system image repository based on the key hardware parameters, and generate a candidate list of CPU architecture and OS that are compatible with the architecture; it is also configured to parse the host machine's device IP information according to the target CPU architecture and target OS, and pull the image adapted to the target CPU architecture from the system image repository to the host machine; it is also configured to pull the target software and its dependency configuration files from the domestic software standardization repository.
[0114] The security verification module is configured to perform security verification when pulling the image; it is also configured to perform a secondary security verification before executing the virtual machine startup command.
[0115] The network security module is configured to execute firewall probes, identify the firewall type of the target system, and generate adaptive network security policies by calling predefined security policy templates based on the identification results.
[0116] The topology sorting generation module is configured to extract the dependencies and version constraints of the target software and its dependency configuration files, abstract the software packages into DAG nodes, and generate topology sorting results based on the DAG dependency resolution algorithm.
[0117] Those skilled in the art will understand that, for the sake of convenience and brevity, the specific working process and related descriptions of the system described above can be found in the corresponding processes in the foregoing method embodiments, and will not be repeated here.
[0118] It should be noted that the adaptive deployment system for heterogeneous environments in the context of domestic IT innovation provided in the above embodiments is only an example of the division of the above functional modules. In practical applications, the above functions can be assigned to different functional modules as needed, that is, the modules or steps in the embodiments of the present invention can be further decomposed or combined. For example, the modules in the above embodiments can be merged into one module, or further divided into multiple sub-modules to complete all or part of the functions described above. The names of the modules and steps involved in the embodiments of the present invention are only for distinguishing the various modules or steps and are not considered as an improper limitation of the present invention.
[0119] An electronic device according to a third embodiment of the present invention includes:
[0120] At least one processor; and
[0121] A memory communicatively connected to at least one of the processors; wherein,
[0122] The memory stores instructions that can be executed by the processor to implement the aforementioned adaptive deployment method for a heterogeneous information technology innovation environment.
[0123] A computer-readable storage medium according to a fourth embodiment of the present invention stores computer instructions, which are executed by the computer to implement the above-described adaptive deployment method for a heterogeneous environment of information technology innovation.
[0124] Those skilled in the art will understand that, for the sake of convenience and brevity, the specific working process and related descriptions of the electronic device and computer-readable storage medium described above can be referred to the corresponding processes in the foregoing method embodiments, and will not be repeated here.
[0125] Those skilled in the art will recognize that the modules and method steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of both. The programs corresponding to the software modules and method steps can be placed in random access memory (RAM), main memory, read-only memory (ROM), electrically programmable ROM, electrically erasable programmable ROM, registers, hard disks, removable disks, CD-ROMs, or any other form of storage medium known in the art. To clearly illustrate the interchangeability of electronic hardware and software, the components and steps of the various examples have been generally described in terms of functionality in the foregoing description. Whether these functions are implemented in electronic hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of the invention.
[0126] Computer program code for performing the operations of this application can be written in one or more programming languages or a combination thereof, including object-oriented programming languages such as Java, Smalltalk, and C++, and conventional procedural programming languages such as the "C" language or similar programming languages. The program code can be executed entirely on the user's computer, partially on the user's computer, as a standalone software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving remote computers, the remote computer can be connected to the user's computer via any type of network—including a local area network (LAN) or a wide area network (WAN)—or can be connected to an external computer (e.g., via the Internet using an Internet service provider).
[0127] The flowcharts and block diagrams in the accompanying drawings illustrate the architecture, functionality, and operation of possible implementations of systems, methods, and computer program products according to various embodiments of this application. In this regard, each block in a flowchart or block diagram may represent a module, segment, or portion of code containing one or more executable instructions for implementing a specified logical function. It should also be noted that in some alternative implementations, the functions indicated in the blocks may occur in a different order than those indicated in the drawings. For example, two consecutively indicated blocks may actually be executed substantially in parallel, and they may sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each block in the block diagrams and / or flowcharts, and combinations of blocks in the block diagrams and / or flowcharts, can be implemented using a dedicated hardware-based system that performs the specified function or operation, or using a combination of dedicated hardware and computer instructions.
[0128] The terms “first”, “second”, etc., are used to distinguish similar objects, not to describe or indicate a specific order or sequence.
[0129] The term "comprising" or any other similar term is intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus / device that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent in such process, method, article, or apparatus / device.
[0130] The technical solution of the present invention has been described above with reference to the preferred embodiments shown in the accompanying drawings. However, it will be readily understood by those skilled in the art that the scope of protection of the present invention is obviously not limited to these specific embodiments. Without departing from the principles of the present invention, those skilled in the art can make equivalent changes or substitutions to the relevant technical features, and the technical solutions after these changes or substitutions will all fall within the scope of protection of the present invention.
Claims
1. An adaptive deployment method for heterogeneous environments in the field of information technology innovation, characterized in that, It includes the following steps: S1. Obtain a task instruction, create a target task in a pre-built automated deployment engine, and define the environmental basic metadata for deploying the target task; the automated deployment engine includes a hardware resource pool, a domestic software standardization repository, and a system image repository; S2. Parse the target task to obtain a hardware information template and key hardware parameters; S3. Based on the key hardware parameters, configure the virtual machine to be built, dynamically match the CPU architecture and OS in the system image repository, and generate a list of candidate CPU architectures and OSs that are architecture-compatible; S4. Determine the target CPU architecture and target OS, pull the image adapted to the target CPU architecture from the system image repository to the local host of the host, and perform a security check; S5. Generate a virtual machine startup command according to the hardware information template, send it to the host for execution, and perform a secondary security check; S6. Inject the IP address information in the environmental basic metadata into the network card configuration file and restart the network card; S7. Identify the firewall type of the target system based on a firewall probe, generate an adaptive network security policy according to the identification result, obtain a security configuration file and load it; S8. After the security configuration file is loaded, pull the target software and its dependency configuration file from the domestic software standardization repository to the virtual machine, extract its dependencies and version constraints, and generate a topological sorting result based on the DAG-based dependency parsing algorithm; Among them, when generating the topological sorting result, first check the architecture, then build a DAG dependency graph and build directed edges according to the dependencies; then detect circular dependencies and version conflicts; when a circular dependency is detected, automatically search for a lower version dependency in the domestic software standardization repository for replacement; finally, generate a topological sorting sequence, and mark the node group without direct dependencies as installable in parallel; S9. Execute the installation in sequence according to the topological sorting result to achieve the automated deployment of the application software.
2. The adaptive deployment method for heterogeneous environments in the field of information technology innovation according to claim 1, characterized in that, The environmental basic metadata includes a project number, a deployment type, CPU information, CPU cores, memory specifications, storage capacity, operating system name, system version, IP address information, firewall whitelist, and a list of pre-installed software.
3. The adaptive deployment method for heterogeneous environments in the field of information technology innovation according to claim 2, characterized in that, The method for obtaining the hardware information template and key hardware parameters is as follows: Assemble the environmental basic metadata of the target task into a hardware information template, and parse the hardware information template to obtain key hardware parameters including the processor architecture, memory capacity, number of CPU cores, and storage space.
4. The adaptive deployment method for heterogeneous environments in the field of information technology innovation according to claim 1, characterized in that, During the process of dynamically matching the CPU architecture and OS, perform a dynamic capacity assessment of the CPU based on the load status of the resource pool: If the average CPU usage rate continuously ≥ M% and < N%, trigger a mild alarm and prompt an expansion suggestion; if the CPU usage rate ≥ N% or the single-core peak ≥ S%, trigger the termination of construction and alarm; Among them, M < N < S.
5. The adaptive deployment method for heterogeneous environments in the field of information technology innovation according to claim 2, characterized in that, The method for performing the security check is as follows: When pulling the image, read the pre-stored hash value from the metadata file and compare it with the real-time hash value of the transferred image; if the check fails, trigger an automatic retransmission or an alarm; Among them, the number of executions of the automatic retransmission does not exceed 3 times.
6. The adaptive deployment method for heterogeneous environments in the field of information technology innovation according to claim 5, characterized in that, The method for performing the secondary security check is as follows: Before starting the virtual machine, the original hash value of the image file is verified and compared with the pre-stored hash value in the metadata. If the hash values match, the virtual machine is started; otherwise, the deployment is terminated and the image file is marked as untrusted. After the execution is complete, the system prompts the user to confirm.
7. The adaptive deployment method for heterogeneous environments in the field of information technology innovation according to claim 1, characterized in that, The method for generating adaptive network security policies is as follows: The system uses probe technology to identify the firewall service currently used by the host machine. Based on the identification results, it calls a predefined security policy template, automatically replaces the placeholders in the template to generate specific configuration instructions, and then drives the execution of the security policy via SSH, verifies its validity, and dynamically generates commands to append security parameters as needed.
8. The adaptive deployment method for heterogeneous environments in the field of information technology innovation according to claim 7, characterized in that, If the identification result shows that multiple firewall services are active at the same time, the highest priority firewall is selected as the primary firewall, other firewall services are automatically disabled, a firewall service conflict report is generated, and a notification is sent to the management interface for user confirmation. If the user confirms the approval, the historical rules from other firewalls will be migrated to the main firewall.
9. The adaptive deployment method for heterogeneous environments in the field of information technology innovation according to claim 1, characterized in that, The topological sorting result is generated using a dependency resolution algorithm based on DAG. The method is as follows: A. Create DAG nodes and verify whether the software package supports the target CPU architecture; B. Based on the extracted dependencies and version constraints, resolve the dependency relationships and construct a DAG dependency graph; C. Use depth-first search to traverse the DAG dependency graph and detect whether there are circular dependencies: If it does not exist, proceed to step D; Otherwise, search for and replace lower version dependencies from the domestic software standardization repository, and then proceed to step A; if no solution is found, generate a circular dependency report containing conflicting paths and suggested versions and push it to manual decision-making. D. Check for version conflicts. If no conflict exists, proceed to step E; otherwise, search for a compatible version or recommended equivalent version in the domestic software standardization repository, replace it, and then proceed to step A. If a replacement is not possible, a conflict report will be generated and submitted for manual processing. E. Generate a topological sorting sequence based on the Kahn algorithm, and mark node groups with no direct dependencies as those that can be installed in parallel.
10. An adaptive deployment system for heterogeneous environments in the context of domestic IT innovation, comprising an adaptive deployment method for heterogeneous environments in the context of domestic IT innovation according to any one of claims 1-9, characterized in that, The system includes: The hardware parameter configuration / parsing module is configured to obtain task instructions, create a new target task in the pre-built automated deployment engine, define the environmental basic metadata for deploying the target task, and then obtain hardware information templates and key hardware parameters. The automated deployment engine is configured to generate virtual machine startup commands based on the hardware information template and send them to the host machine for execution; inject IP address information from the environment's basic metadata into the network card configuration file and restart the network card; and is also configured to execute installations sequentially based on the topology sorting results to achieve automated deployment of the application system; the automated deployment engine includes a hardware resource pool, a standardized repository of domestic software, and a system image repository; The cross-platform image generation module is configured to dynamically match the CPU architecture and OS in the system image repository based on the key hardware parameters, and generate a candidate list of CPU architecture and OS that are compatible with the architecture; according to the target CPU architecture and target OS, it parses the device IP information of the host machine, pulls the image adapted to the target CPU architecture from the system image repository to the local host machine; it is also configured to pull the target software and dependency configuration files from the domestic software standardization repository. The security verification module is configured to perform security verification when pulling the image; it is also configured to perform a secondary security verification before executing the virtual machine startup command. The network security module is configured to execute firewall probes, identify the firewall type of the target system, generate adaptive network security policies based on the identification results, obtain security configuration files, and load them. The topology sorting generation module is configured to extract the dependencies and version constraints of the target software and its dependency configuration files, abstract the software packages into DAG nodes, and generate topology sorting results based on the DAG dependency resolution algorithm.
Citation Information
Patent Citations
A method for semi-automatic batch deployment of heterogeneous cluster operating systems
CN102497408B
Intelligent deployment method for heterogeneous hybrid environment
CN112416369A
Design and implementation method and system of software construction publishing device and terminal
CN116774989A