A method for checking migration of a tenant network element on a cloud

By sorting out the tenant list, generating inspection tasks, and executing the inspection concurrently at the network element host level, the problem of time-consuming confirmation of migration completion during tenant migration in cloud computing was solved. This enabled efficient and accurate confirmation of network resource status, improving the availability and scalability of the system.

CN117857352BActive Publication Date: 2026-01-16CHINA TELECOM CLOUD TECH CO LTD
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202311703093.X
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-12-12
Publication Date
2026-01-16
Estimated Expiration
2043-12-12

AI Technical Summary

Technical Problem

In cloud computing environments, tenants often struggle to quickly confirm the completion of network resource migrations, leading to lengthy confirmation times for network resource availability and status. This is especially true when dealing with a large number of configurations, as confirming each configuration individually is time-consuming and impacts the network's rapid adaptation and normal operation.

Method used

This paper provides a method for checking the migration of network elements in the cloud. By sorting out the list of tenants to be migrated, cloud network resource data is obtained, a check task is generated using a configuration checklist, and the check task is executed concurrently at the network element host granularity. The check results are summarized and abnormal information is output to ensure the accuracy and efficiency of migration configuration.

Benefits of technology

It improves the system availability and configuration check efficiency of cloud tenant network element migration, ensures the accuracy of migration configuration, reduces repeated checks and frequent calls to network element commands, and enhances the system's flexibility and scalability.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117857352B_ABST
    Figure CN117857352B_ABST
Patent Text Reader

Abstract

The cloud tenant network element migration checking method of the application, by sorting the list of tenants to be migrated, obtaining cloud network resource data according to the list of tenants to be migrated, using the defined configuration checking list to generate a configuration checkpoint list for each tenant to be migrated, traversing each check item in the configuration checking list of each tenant to be migrated, using the check item to generate a check task, summarizing and adding the check task to the task execution queue, obtaining the network element Host granularity, executing the check task concurrently in the network element Host granularity, obtaining the check task execution result, when all the check tasks in the check task set are executed, summarizing the check task execution result of the tenant to be migrated, outputting the tenant to be migrated with abnormal check items, and outputting abnormal information, returning -1 when there is an abnormal check item in the check task execution result, and returning 0 when there is no abnormal check item, improving the availability, scalability and configuration checking efficiency of the system.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of cloud computing, and in particular to a cloud tenant network element migration checking method. BACKGROUND

[0002] In a cloud computing environment, a tenant is an entity that uses cloud services, while VPC, EIP, BGP, and other terms are basic network concepts in cloud computing. A cloud network is usually composed of a control plane and a forwarding plane, with the control plane responsible for configuring and managing network services and the forwarding plane handling actual data transmission. In order to improve the availability and flexibility of the network, tenants may need to migrate their resources to different cloud Regions, which involves changes in network configuration and migration processes.

[0003] Elastic public IP (EIP) allows tenants to dynamically allocate and release public IP addresses and bind them to various cloud resources, providing more flexible network configuration. BGP, as a border gateway protocol, is used to exchange routing information between different autonomous systems, supporting dynamic routing selection to ensure the stability and reachability of the network. The control plane and forwarding plane of the cloud network are responsible for configuration delivery and actual data transmission, respectively, achieving logical separation of the network.

[0004] Because the network control plane uses an asynchronous method to deliver configurations to different network elements, it is difficult for tenants to accurately determine when the migration is complete during the migration process. This results in tenants being unable to promptly understand the availability and status of their network resources. Tenants have multiple network resource configurations on network elements, and performing configuration checks one by one is time-consuming. In particular, when the number of configurations is large, the time consumed is proportional to the number of configurations, and when the number of configurations is large, the time is more than a few minutes, and the time cost of confirming configurations one by one is relatively high, which is not conducive to quickly understanding tenant migration. As the network evolves, new network elements may be introduced, and it is necessary to quickly adapt and confirm whether new configurations are correctly delivered to ensure the normal operation of the network. SUMMARY

[0005] The present application aims to at least partially solve one of the technical problems in the related art. To this end, one object of the present application is to provide a cloud tenant network element migration checking method that improves the availability, scalability, and configuration checking efficiency of the system.

[0006] One aspect of the present application provides a cloud tenant network element migration checking method, comprising:

[0007] Step S100: Sort the list of tenants to be migrated;

[0008] The list of tenants to be migrated refers to a list for storing tenant IDs to be migrated and network resource information of the tenants to be migrated.

[0009] The specific method of the combing the list of tenants to be migrated is that an operation and maintenance personnel inputs the list of tenants to be migrated, the list of tenants to be migrated stores tenant ID to be migrated and network resource information of the corresponding tenant to be migrated, and the network resource information includes but is not limited to cloud network resource data;

[0010] Step S200: obtaining cloud network resource data according to the list of tenants to be migrated;

[0011] The cloud network resource data refers to network resources owned by a tenant in a cloud environment, including but not limited to the following elements: VPC, subnet, router, ACL, EIP;

[0012] The method of obtaining cloud network resource data according to the list of tenants to be migrated is that according to the input list of tenants to be migrated, a tenant to be migrated is identified, an API provided by a cloud service is used, network resource information of the tenant to be migrated stored in a cloud environment is queried through tenant ID to be migrated in the list of tenants to be migrated, response data is obtained, and cloud network resource data is extracted by parsing the response data of the API;

[0013] Step S300: generating a configuration check point list for each tenant to be migrated by using a check item in a defined configuration check list;

[0014] The configuration check list includes check items: EIP check item and VPC check item, the EIP refers to an independent public IP resource provided by an elastic public network IP, including public IP address and public bandwidth, and the VPC refers to a virtual private cloud;

[0015] The check item includes: EIP check item and VPC check item;

[0016] The configuration check point list refers to a list for storing execution results of each check item to be executed in the migration process, for ensuring that the network configuration of the tenant to be migrated is correct in the migration process, and the configuration check point list includes tenant ID to be migrated, check item, check task execution result, and exception information;

[0017] The specific method of generating a configuration check task list for each tenant to be migrated by using a check item in a defined configuration check list is that a configuration check list is defined in the system, the configuration check list includes check items to be checked, the list of tenants to be migrated is traversed, a configuration check point list is created for each tenant to be migrated, and the configuration check point list is used to store check task execution results of each check item;

[0018] Step S400: traversing each check item in the configuration check list of each tenant to be migrated, generating a check task using the check item, summarizing and adding the check task to a task execution queue, and obtaining a network element Host granularity;

[0019] The check task set is composed of check tasks, the check task includes a check item, a task execution method, a task subject method, and a task keyword, the task keyword is used to uniquely identify the task and is related to a network element Host that executes the task, the check task is executed by a corresponding task execution queue according to the task keyword, the task subject method refers to a core method for executing the check task, the task execution method refers to a method for executing the check task, and the system executes the check task according to the task execution method;

[0020] The check item in the configuration check list of each to-be-migrated tenant is traversed, the check item is used to generate a check task, the check tasks are summarized and added to a task execution queue, and the specific method for obtaining the network element Host granularity is as follows: a to-be-checked list object is constructed, the to-be-checked list object includes a to-be-migrated tenant list, a configuration check list, and a task execution method; for each to-be-migrated tenant in the to-be-migrated tenant list, the check item in the configuration check list is traversed, and each check item is registered in the to-be-checked list object; the to-be-checked list object generates a check task by executing the registered check item, the check task includes a task execution method, a task subject method, and a task keyword; the generated check tasks are summarized to obtain a check task set, an index of a task execution queue is obtained, the check task is added to the corresponding task execution queue, and the configuration task is executed, and a network element Host that executes the check task is obtained;

[0021] The index of the task execution queue is obtained, and the check task is added to the corresponding task execution queue by using an Index algorithm, so that the check tasks of the same network element Host are placed in the same task execution queue, and a calculation expression of the index Index is as follows: Index = crc32.ChecksumIEEE(key) % len(queue_len), wherein key is a keyword for determining the position of the check task in the task execution queue, crc32.ChecksumIEEE(key) represents that a checksum of key is calculated by using a CRC32 checksum algorithm and a ChecksumIEEE function, and len(queue_len) represents that a value of the obtained CRC32 checksum is taken modulo the length of the task execution queue, so as to ensure that the index value is within the length of the task execution queue and prevent out-of-bound;

[0022] Step S500: The check tasks are executed concurrently in the network element Host granularity, and a check task execution result is obtained.

[0023] The specific method for concurrently executing inspection tasks at the network element host granularity to obtain the inspection task execution results is as follows: create a number of threads corresponding to the length of the task execution queue, each thread executes an inspection task in the task execution queue one by one, each inspection task contains an inspection item, the inspection item contains a task execution method, and the result of each execution is added to the inspection task execution result, the inspection task execution result includes a method for setting the corresponding topic task result and a method for obtaining the overall execution record;

[0024] Step S600: After all the inspection tasks in the inspection task set have been completed, summarize the inspection task execution results of the tenants to be migrated, output the tenants to be migrated with abnormal inspection items, and output the abnormal information.

[0025] The execution result of the inspection task for the tenant to be migrated refers to the execution result of the inspection items for each tenant to be migrated during the migration configuration inspection process.

[0026] The tenant to be migrated that has abnormal check items refers to a tenant to be migrated that is found to have abnormal configuration migration during the migration configuration check process.

[0027] The specific method for summarizing the inspection task execution results of the tenants to be migrated after all inspection tasks in the inspection task set have been completed, outputting the tenants to be migrated with abnormal inspection items, and outputting the abnormal information is as follows:

[0028] Determine the inspector type, which includes: line inspector, area inspector, and newly added inspector;

[0029] Export the check items corresponding to the network element Host, and check whether the service configuration corresponding to the check items of the network element Host is cached locally. The service configuration includes VPC and EIP.

[0030] If there is no cached service configuration, the network element configuration export command is executed on the network element host using the SSH protocol. The network element configuration export command is a batch command used to export all such service configurations on the network element host. The exported service configuration is divided into a service configuration list, the service configuration list is cached in memory, and the service configuration list is returned.

[0031] If there are cached business configurations, the business configuration list is retrieved directly from the cache.

[0032] Check if the configuration keyword is in a configuration item in the business configuration list. If it exists, the configuration is normal. If it does not exist, it indicates an error in the migration. Output the error information and output the tenant to be migrated corresponding to the error check item.

[0033] The method for splitting the exported service configuration into a service configuration list is: when the checker type is a line checker that checks whether each line in the network element Host configuration contains key configuration information, using a line splitting method to split the service configuration; when the checker type is a region checker that checks whether each region in the network element Host configuration contains key configuration information, using a region splitting method to split the service configuration.

[0034] The method for creating the new checker is: writing a network element configuration export instruction for batch exporting the network element Host; using the NewSshInfoLister method to pass the network element configuration export instruction as a parameter to create a configuration Lister; using the NewLineChecker method to create a configuration checker using the configuration Lister as a creation parameter to obtain the new checker.

[0035] The configuration Lister is a component for obtaining configuration information, which processes the exported configuration information into a format available to the system by executing the network element configuration export instruction on the network element Host using the SSH protocol.

[0036] Step S700: returning -1 when there is an abnormal check item in the check task execution result, and returning 0 when there is no abnormal check item.

[0037] One aspect of the present application provides a cloud tenant network element migration check system, comprising:

[0038] A tenant list obtaining module is configured to sort a list of tenants to be migrated.

[0039] A cloud resource data obtaining module is configured to obtain cloud network resource data according to the list of tenants to be migrated.

[0040] A configuration list generating module is configured to generate a configuration checkpoint list for each tenant to be migrated using check items in a defined configuration check list.

[0041] A check task generating module is configured to traverse the check items in the configuration check list of each tenant to be migrated, generate check tasks using the check items, aggregate the check tasks and add them to a task execution queue, and obtain a network element Host granularity.

[0042] A check result obtaining module is configured to execute the check tasks concurrently in a network element Host granularity, and obtain check task execution results.

[0043] An abnormal information output module is configured to aggregate the check task execution results of the tenants to be migrated after all the check tasks in the check task set are executed, output the tenants to be migrated that have abnormal check items, and output abnormal information.

[0044] The execution result returning module is configured to return -1 when there is an abnormal check item in the check task execution result, and return 0 when there is no abnormal check item.

[0045] One aspect of the present application provides an electronic device, comprising a memory, a processor, and a computer program stored in the memory and capable of running on the processor, wherein the processor executes the program to implement the steps of the cloud tenant network element migration checking method.

[0046] One aspect of the present application provides a readable storage medium, which stores a computer program adapted to be loaded by a processor to execute the steps of the cloud tenant network element migration checking method.

[0047] The cloud tenant network element migration checking method provided by the present application has the following advantages over the prior art:

[0048] By checking the key configurations of the tenant to be migrated on the network element Host, it can be ensured that the migration of the tenant to be migrated is completed, or the migration abnormality is found as early as possible, and by means of the configuration checkpoint list and the check task set, a configuration check task is generated for each tenant to be migrated, so as to monitor and confirm the state of the tenant migration;

[0049] By configuring the check list, the check item, the check task, and the check task execution result structure, a cloud tenant network element migration checking system is organized, which has clear system structure, strong scalability, and is convenient for extension and addition of new check items, so that the system is more flexible and adaptive to network configuration changes.

[0050] In the configuration checking process, the configuration is obtained by using the network element configuration export command, and the configuration is cached in the memory, so as to avoid frequent calling of the network element command through ssh when checking the same type of configuration on the same network element Host each time, and greatly improve the efficiency of configuration checking. BRIEF DESCRIPTION OF DRAWINGS

[0051] Figure 1 A migration configuration checking overall flowchart of the cloud tenant network element migration checking method provided by the present application is provided.

[0052] Figure 2 A check task generation flowchart of the cloud tenant network element migration checking method provided by the present application is provided.

[0053] Figure 3 A structure schematic diagram of the electronic device provided by the present application is provided.

[0054] Figure 4 A structure schematic diagram of the readable storage medium provided by the present application is provided. DETAILED DESCRIPTION

[0055] To better understand this application, various aspects of this application will be described in more detail with reference to the accompanying drawings. It should be understood that these detailed descriptions are merely illustrative of exemplary embodiments of this application and are not intended to limit the scope of this application in any way. Throughout the specification, the same reference numerals refer to the same elements. The expression "and / or" includes any and all combinations of one or more of the associated listed items.

[0056] In the accompanying drawings, the size, dimensions, and shapes of the elements have been slightly adjusted for ease of illustration. The drawings are for illustrative purposes only and are not strictly to scale. As used herein, the terms “approximately,” “about,” and similar terms are used to indicate approximation, not degree, and are intended to illustrate inherent deviations in measured or calculated values ​​that will be recognized by one of ordinary skill in the art. Furthermore, the order in which the steps are described in this application does not necessarily indicate the order in which these steps occur in actual operation, unless otherwise expressly defined or deduced from the context.

[0057] It should also be understood that expressions such as "comprising," "including," "having," "containing," and / or "comprising" are open-ended rather than closed-ended expressions in this specification, indicating the presence of the stated features, elements, and / or components, but not excluding the presence of one or more other features, elements, components, and / or combinations thereof. Furthermore, when expressions such as "at least one of..." appear after a list of listed features, they modify the entire list of features, not just individual elements in the list. Additionally, when describing embodiments of this application, the word "may" is used to mean "one or more embodiments of this application." And the term "exemplary" is intended to refer to examples or illustrations.

[0058] Unless otherwise specified, all terms used herein (including engineering and technical terms) shall have the same meaning as commonly understood by one of ordinary skill in the art to which this application pertains. It should also be understood that, unless expressly stated herein, terms defined in common dictionaries shall be interpreted as having the meaning consistent with their meaning in the context of the relevant art, and not as having an idealized or overly formalized meaning.

[0059] It should be noted that, where there is no conflict, 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.

[0060] Example 1

[0061] like Figure 1 The diagram shown is an overall flowchart of the migration configuration check for a cloud tenant network element migration check method provided in this application, including:

[0062] Step S100: combing a list of tenants to be migrated;

[0063] The list of tenants to be migrated refers to a list for storing tenant IDs to be migrated and network resource information of the tenants to be migrated.

[0064] The specific method for combing the list of tenants to be migrated is that an operation and maintenance personnel inputs a list of tenants to be migrated, the list of tenants to be migrated stores tenant IDs to be migrated and network resource information of corresponding tenants to be migrated, and the network resource information includes but is not limited to cloud network resource data.

[0065] Step S200: obtaining cloud network resource data according to the list of tenants to be migrated;

[0066] The cloud network resource data refers to network resources possessed by a tenant in a cloud environment, including but not limited to the following elements: VPC, subnet, router, ACL, and EIP.

[0067] The method for obtaining cloud network resource data according to the list of tenants to be migrated is that a tenant to be migrated is identified according to the input list of tenants to be migrated, network resource information stored by the tenant to be migrated in a cloud environment is queried by using an API provided by a cloud service through a tenant ID to be migrated in the list of tenants to be migrated, response data is obtained, and cloud network resource data is extracted by parsing the response data of the API.

[0068] Step S300: generating a configuration check point list for each tenant to be migrated by using a check item in a defined configuration check list;

[0069] The configuration check list is defined in a system design stage, is formulated by a system architect or a network engineer according to business requirements and requirements of a migration task, and includes network configuration elements to be checked and corresponding checking methods.

[0070] The configuration check list includes an EIP check item and a VPC check item, the EIP refers to an independent public IP resource provided by an elastic public network IP, includes a public IP address and a public bandwidth, and the VPC refers to a virtual private cloud.

[0071] The check item includes an EIP check item and a VPC check item.

[0072] The configuration check point list refers to a list for storing execution results of each check item to be executed in a migration process, for ensuring that network configurations of tenants to be migrated are correct in the migration process, and includes a tenant ID to be migrated, a check item, a check task execution result, and abnormal information.

[0073] The specific method for generating a configuration check task list for each tenant to be migrated by using the check items in the defined configuration check list is: defining a configuration check list in the system, including check items that need to be checked, traversing the list of tenants to be migrated, for each tenant to be migrated, creating a configuration check point list for storing the check task execution results of each check item;

[0074] As shown in Figure 2 Fig. 1 is a flow chart of a check task generation process of a tenant network element migration check method provided by the present application;

[0075] Step S400: traverse the check items in the configuration check list of each tenant to be migrated, generate a check task using the check item, aggregate and add the check task to a task execution queue, and obtain a network element Host granularity;

[0076] The check task set is composed of check tasks, the check task includes a check item, a task execution method, a task subject method, and a task keyword, the task keyword is used to uniquely identify the task and is related to the network element Host executing the task, the check task is executed by the corresponding task execution queue according to the task keyword, the task subject method refers to the core method of executing the check task, the task execution method refers to the method of executing the check task, and the system executes the check task according to the task execution method;

[0077] The specific method for traversing the check items in the configuration check list of each tenant to be migrated, generating a check task using the check item, aggregating and adding the check task to a task execution queue, and obtaining a network element Host granularity is: constructing a to-be-checked list object, which contains a list of tenants to be migrated, a configuration check list, and a task execution method; for each tenant to be migrated in the list of tenants to be migrated, traverse the check items in the configuration check list, and for each check item, register it in the to-be-checked list object; the to-be-checked list object generates a check task by executing the registered check item, the check task includes a task execution method, a task subject method, and a task keyword; aggregate the generated check tasks to obtain a check task set, obtain the subscript of the task execution queue, add the check task to the corresponding task execution queue, wait for the configuration task to be executed, and obtain the network element Host executing the check task;

[0078] The index of the acquisition task execution queue, and the index algorithm is used to add the check task to the corresponding task execution queue, which ensures that the check tasks of the same network element Host are placed in the same task execution queue. The calculation expression of the index is: Index = crc32.ChecksumIEEE(key) % len(queue_len), wherein, the key is a keyword used to determine the position of the check task in the task execution queue, crc32.ChecksumIEEE(key) represents calculating the checksum of the key using the CRC32 checksum algorithm and the ChecksumIEEE function, and % len(queue_len) represents taking the modulus of the obtained CRC32 checksum value with respect to the length of the task execution queue, so as to ensure that the index value is within the length of the task execution queue and prevent out-of-bound;

[0079] The VPC check item generates check tasks for checking VPC, Subnet, route, NAT configuration and the like on each VPC network element Host;

[0080] The EIP check item generates tasks for checking BGP configuration and flow diversion configuration on each access network element, and generates tasks for checking rate limiting configuration and flow diversion configuration on each rate limiting network element Host;

[0081] Step S500: concurrently executing the check tasks in the network element Host granularity to obtain check task execution results;

[0082] The network element Host granularity refers to operating in the network architecture in the unit of the network element Host. Such operation improves the concurrent performance of the system, and the Hosts do not interfere with each other.

[0083] The purpose of concurrently executing the check tasks is to execute n check tasks in the same time period, and the system simultaneously processes the check tasks on each Host or device, thereby improving the system efficiency, and especially in a large-scale network, the check tasks can be quickly completed;

[0084] The check task execution result refers to the result obtained by executing each check task according to the task execution method. The check task execution result includes normal check items and abnormal check items.

[0085] The normal check item refers to that all check items of the to-be-migrated tenant configuration migration are normal.

[0086] The abnormal check item refers to that there is an abnormal check item in the check task executed by the to-be-migrated tenant configuration migration.

[0087] The specific method for concurrently performing the checking tasks in the granularity of the network element Host and obtaining checking task execution results comprises: creating threads corresponding to the number of threads of the length of the task execution queue, each thread performing a checking task in the task execution queue one by one, each checking task containing a checking item, the checking item containing a task execution method, and the result of each execution being added to the checking task execution results, the checking task execution results including a setting corresponding subject task result method and an obtaining overall execution method;

[0088] The same network element Host is in the same task execution queue, so the checking tasks on the same network element Host are not concurrently executed, thereby avoiding pressure on the network element Host and affecting normal service forwarding;

[0089] Different network element Hosts can be in different task execution queues, and the checking tasks of different network element Hosts can be executed on different threads, thereby improving system concurrency and configuration checking efficiency;

[0090] Step S600: When the checking tasks in the checking task set are all executed, the checking task execution results of the tenant to be migrated are summarized, the tenant to be migrated with an abnormal checking item is output, and abnormal information is output.

[0091] The checking task execution results of the tenant to be migrated refer to the execution results of the checking items of each tenant to be migrated in the migration configuration checking process;

[0092] The tenant to be migrated with an abnormal checking item refers to a tenant to be migrated that is checked to have configuration migration abnormalities in the migration configuration checking process of the tenant to be migrated;

[0093] The abnormal information refers to information that there is an abnormal checking item in the checking task;

[0094] The specific method for, when the checking tasks in the checking task set are all executed, summarizing the checking task execution results of the tenant to be migrated, outputting the tenant to be migrated with an abnormal checking item, and outputting abnormal information comprises:

[0095] Determining a checker type, the checker type including a line checker, a region checker, and a new addition checker;

[0096] Exporting a checking item corresponding to a network element Host, checking whether a service configuration corresponding to the checking item of the network element Host is cached locally, the service configuration including a VPC and an EIP;

[0097] If there is no cached service configuration, the SSH protocol is used to execute a network element configuration export instruction on the network element Host, the network element configuration export instruction is a batch instruction, and the network element configuration export instruction is used to export all corresponding service configurations on the network element Host; the exported service configurations are segmented into a service configuration list, the service configuration list is cached in the memory, and the service configuration list is returned;

[0098] If there is cached service configuration, the service configuration list is directly obtained from the cache;

[0099] It is checked whether the configuration keyword is in a configuration item of the service configuration list. If the configuration keyword exists, the configuration is normal. If the configuration keyword does not exist, it indicates that migration is abnormal. Abnormal information is output, and a tenant to be migrated corresponding to an abnormal check item is output.

[0100] The method for segmenting the exported service configurations into the service configuration list is that when the checker type is a line checker, a line segmentation method is used to segment the service configurations, the line checker checks whether each line in the network element Host configuration contains key configuration information, and when the checker type is a region checker, a region segmentation method is used to segment the service configurations, the region checker checks whether each region in the network element Host configuration contains key configuration information.

[0101] The checker is a component for performing a checking task, and is used to perform a specific checking task, including a line checker, a region checker, and a newly-added checker.

[0102] The purpose of directly obtaining the service configuration list from the cache if there is cached service configuration is to avoid repeatedly obtaining the same service configurations of the same network element Host, and to improve execution efficiency.

[0103] The creation method of the newly-added checker is that a network element configuration export instruction for batch exporting a network element Host is written, the network element configuration export instruction is used as a parameter by using a NewSshInfoLister method, a configuration Lister is newly created, the configuration Lister is used as a creation parameter by using a NewLineChecker method, and a newly-added checker is obtained.

[0104] The configuration Lister is a component for obtaining configuration information, and the configuration information is processed into a format available for a system by using the SSH protocol to execute a network element configuration export instruction on the network element Host.

[0105] The NewSshInfoLister method and the NewLineChecker method are common technical means in the field, and are not described herein.

[0106] Step S700: When an abnormal check item exists in a checking task execution result, -1 is returned, and 0 is returned when no abnormal check item exists.

[0107] The return of -1 when there is an abnormal check item in the check task execution result and the return of 0 when there is no abnormal check item means that when there is an abnormal check item in the check task execution result, -1 is returned, indicating that the abnormal check item does not pass, and when the check task execution result is normal, it indicates that the migration configuration is normal, and 0 is returned to continue the subsequent operation.

[0108] Embodiment 2

[0109] One embodiment provided by the present application includes the following steps:

[0110] Obtain a list of tenants to be migrated that need to perform network resource migration, and input the related information of the tenants to be migrated by an operation and maintenance personnel;

[0111] Migrate the network resources of the tenant from the Transit Gateway (TGW) network element to the Virtual Private Cloud Gateway (VPCGW) network element, to ensure that the network traffic of the tenant can pass through the new VPCGW network element;

[0112] Perform configuration verification using a specific configuration verification tool to ensure that the configuration of the migrated network resources is correct, including checking network configuration, security settings, routing tables, etc., to ensure the consistency and correctness of the configuration;

[0113] The operation and maintenance personnel observe the network equipment or check whether the traffic passes through the new VPCGW network element as expected through logs and monitoring tools, and ensure that there is no abnormality or error;

[0114] The above-described embodiments are only the preferred specific embodiments of the present application, and the usual changes and replacements made by those skilled in the art within the scope of the technical solutions of the present application should be included in the protection scope of the present application.

[0115] Embodiment 3

[0116] A tenant network element migration checking system provided by the present application includes:

[0117] A tenant list acquisition module for sorting a list of tenants to be migrated;

[0118] A cloud resource data acquisition module for acquiring cloud network resource data according to the list of tenants to be migrated;

[0119] A configuration list generation module for generating a configuration checkpoint list for each tenant to be migrated using the check items in the defined configuration check list;

[0120] The check task generation module is configured to traverse each check item in the configuration check list of each tenant to be migrated, generate a check task by using the check item, aggregate the check task and add the check task to a task execution queue, and obtain a network element Host granularity;

[0121] The check result acquisition module is configured to execute the check task in a network element Host granularity in parallel, and obtain a check task execution result;

[0122] The abnormal information output module is configured to aggregate the check task execution result of the tenant to be migrated after all the check tasks in the check task set are executed, output the tenant to be migrated with an abnormal check item, and output abnormal information.

[0123] The execution result return module is configured to return -1 when the check task execution result has an abnormal check item, and return 0 when the check task execution result has no abnormal check item.

[0124] Embodiment 4

[0125] Figure 3 is a schematic diagram of an electronic device structure according to an embodiment of the present application. As shown in Figure 3 According to another aspect of the present application, an electronic device is also provided. The electronic device can include one or more processors and one or more memories. The memory stores computer readable code which, when executed by the one or more processors, can perform a cloud tenant network element migration checking method as described above.

[0126] The method or system according to the embodiments of the present application can also be implemented by means of Figure 3 The electronic device shown in the architecture of the electronic device. As Figure 3As shown, the electronic device can include a bus, one or more CPUs, read only memory (ROM), random access memory (RAM), a communication port connected to a network, input / output components, a hard disk, etc. The storage device in the electronic device, such as the ROM or the hard disk, can store a cloud tenant network element migration checking method provided in the present application. The cloud tenant network element migration checking method may, for example, include: compiling a list of tenants to be migrated; obtaining cloud network resource data according to the list of tenants to be migrated; generating a configuration checkpoint list for each tenant to be migrated using the check items in the defined configuration check list; traversing the check items in the configuration check list of each tenant to be migrated, generating a check task using the check items, and summarizing and adding the check task to a task execution queue to obtain a network element Host granularity; concurrently executing the check task in the network element Host granularity to obtain a check task execution result; when all the check tasks in the check task set are executed, summarizing the check task execution result of the tenant to be migrated, outputting the tenant to be migrated with an abnormal check item, and outputting abnormal information; returning -1 when there is an abnormal check item in the check task execution result, and returning 0 when there is no abnormal check item. Further, the electronic device can also include a user interface. Of course, Figure 3 The architecture shown is only exemplary, and when implementing different devices, some components shown can be omitted Figure 3 One or more components in the electronic device shown.

[0127] Embodiment 5

[0128] Figure 4 is a readable storage medium structure provided by an embodiment of the present application. As shown in Figure 4 According to an embodiment of the present application, a readable storage medium is shown. The computer readable storage medium stores computer readable instructions. When the computer readable instructions are run by the processor, a cloud tenant network element migration checking method according to an embodiment of the present application described with reference to the above figures can be executed. The storage medium includes, but is not limited to, for example, volatile memory and / or non-volatile memory. The volatile memory may, for example, include random access memory (RAM) and cache memory, etc. The non-volatile memory may, for example, include read only memory (ROM), hard disk, flash memory, etc.

[0129] In addition, according to the embodiments of the present application, the processes described above with reference to the flowcharts can be implemented as a computer software program. For example, the present application provides a non-transitory machine-readable storage medium storing machine-readable instructions executable by a processor to perform instructions corresponding to the method steps provided by the present application, for example: combing a list of tenants to be migrated; obtaining cloud network resource data according to the list of tenants to be migrated; generating a configuration checkpoint list for each tenant to be migrated using the check items in the defined configuration check list; traversing the check items in the configuration check list of each tenant to be migrated, generating a check task using the check items, aggregating and adding the check task to a task execution queue, and obtaining a network element Host granularity; concurrently executing the check task in the network element Host granularity, and obtaining a check task execution result; when all the check tasks in the check task set are executed, aggregating the check task execution result of the tenant to be migrated, outputting the tenant to be migrated with an abnormal check item, and outputting abnormal information; returning -1 when there is an abnormal check item in the check task execution result, and returning 0 when there is no abnormal check item. When the computer program is executed by a central processing unit (CPU), the above functions defined in the method of the present application are performed.

[0130] The method and apparatus, device of the present application can be implemented in many ways. For example, the method and apparatus, device of the present application can be implemented by software, hardware, firmware, or any combination of software, hardware, and firmware. The above order of steps for the method is only for illustration, and the steps of the method of the present application are not limited to the above specifically described order, unless otherwise specifically stated. In addition, in some embodiments, the present application can also be implemented as programs recorded in a recording medium, which include machine-readable instructions for implementing the method according to the present application. Thus, the present application also covers a recording medium storing a program for executing the method according to the present application.

[0131] In addition, parts of the above technical solutions provided in the embodiments of the present application that are consistent with the implementation principles of corresponding technical solutions in the prior art are not described in detail to avoid excessive repetition.

[0132] The specific embodiments described above further illustrate the objects, technical solutions, and advantages of the present application. It should be understood that the above description is only a specific embodiment of the present application and is not intended to limit the present application. Any modification, equivalent replacement, improvement, etc. made within the spirit and principles of the present application should be included in the protection scope of the present application.

Claims

1. A method for checking migration of a tenant network element on a cloud, characterized in that, The method comprises the following steps: combing a list of tenants to be migrated; obtaining cloud network resource data according to the list of tenants to be migrated; generating a configuration checkpoint list for each tenant to be migrated by using the defined check items in the configuration check list; traversing the check items in the configuration check list of each tenant to be migrated, generating a check task by using the check items, and collecting and adding the check task to a task execution queue to obtain a network element Host granularity; concurrently executing the check task in the network element Host granularity to obtain a check task execution result; when all the check tasks in the check task set are executed, the check task execution results of the tenants to be migrated are summarized, the tenants to be migrated with abnormal check items are output, and abnormal information is output; returning -1 when there are abnormal check items in the check task execution result, and returning 0 when there are no abnormal check items; the specific method for summarizing the check task execution results of the tenants to be migrated when all the check tasks in the check task set are executed, outputting the tenants to be migrated with abnormal check items, and outputting abnormal information is as follows: determining the type of the checker, the type of the checker including a line checker, a region checker, and a new addition checker; exporting the check items corresponding to the network element Host, checking whether the business configuration corresponding to the check items of the network element Host is cached locally, the business configuration including VPC and EIP; if the business configuration is not cached, executing a network element configuration export instruction on the network element Host using the SSH protocol, the network element configuration export instruction being a batch instruction used to export all such business configurations corresponding to the network element Host; segmenting the exported business configuration into a business configuration list, caching the business configuration list in the memory, and returning the business configuration list; if the business configuration is cached, directly obtaining the business configuration list from the cache; checking whether the configuration keyword is in a configuration item of the business configuration list, if yes, the configuration is normal, and if no, the migration is abnormal, abnormal information is output, and the tenant to be migrated corresponding to the abnormal check item is output; the method for segmenting the exported business configuration into the business configuration list is as follows: when the type of the checker is the line checker, the business configuration is segmented by using a line segmentation method, the line checker checking whether each line in the network element Host configuration contains key configuration information, and when the type of the checker is the region checker, the business configuration is segmented by using a region segmentation method, the region checker checking whether each region in the network element Host configuration contains key configuration information.

2. A cloud tenant network element migration check method as claimed in claim 1, wherein, the specific method for generating a configuration check task list for each tenant to be migrated by using the defined check items in the configuration check list is as follows: defining a configuration check list in the system, the configuration check list including check items to be checked, traversing the list of tenants to be migrated, creating a configuration checkpoint list for each tenant to be migrated, and storing the check task execution results of each check item in the configuration checkpoint list.

3. A cloud tenant network element migration check method as claimed in claim 2, wherein, The specific method for traversing each check item in the configuration check list of each tenant to be migrated, generating a check task using the check item, aggregating and adding the check task to a task execution queue, and obtaining a specific method for a network element Host granularity is as follows: a to-be-checked list object is constructed, which contains a tenant list to be migrated, a configuration check list, and a task execution method; for each tenant to be migrated in the tenant list to be migrated, each check item in the configuration check list is traversed, and each check item is registered in the to-be-checked list object; the to-be-checked list object generates a check task by executing the registered check item, and the check task includes a task execution method, a task subject method, and a task keyword; The generated check tasks are aggregated to obtain a check task set, an index of a task execution queue is obtained, the check tasks are added to the corresponding task execution queue, and the configuration task is executed. The network element Host that executes the check task is obtained.

4. A cloud tenant network element migration check method as claimed in claim 3, wherein, The specific method for concurrently executing the check task in the network element Host granularity and obtaining the check task execution result is as follows: a number of threads corresponding to the length of the task execution queue are created, each thread executes a check task in a task execution queue one by one, each check task contains a check item, the check item contains a task execution method, and the result of each execution is added to the check task execution result; the check task execution result includes a corresponding subject task result method and an overall execution log method.

5. A cloud tenant network element migration check method as claimed in claim 4, wherein, The method for creating the new check person is as follows: a network element configuration export instruction for batch exporting a network element Host is written; the network element configuration export instruction is passed as a parameter by using the NewSshInfoLister method, and a configuration Lister is newly created; the configuration Lister is used as a creation parameter to create a configuration checker to obtain the new check person by using the NewLineChecker method.

6. A method system for cloud tenant network element migration check, the method system comprising: Comprise: A tenant list acquisition module for sorting a tenant list to be migrated; A cloud resource data acquisition module for acquiring cloud network resource data according to the tenant list to be migrated; A configuration list generation module for generating a configuration check point list for each tenant to be migrated by using a check item in a defined configuration check list; A check task generation module for traversing each check item in the configuration check list of each tenant to be migrated, generating a check task using the check item, aggregating and adding the check task to a task execution queue, and obtaining a network element Host granularity; a check result acquisition module for concurrently executing the check task in the network element Host granularity and obtaining a check task execution result; An abnormal information output module for aggregating the check task execution result of the tenant to be migrated when all the check tasks in the check task set are executed, outputting the tenant to be migrated that has an abnormal check item, and outputting abnormal information; An execution result return module for returning -1 when the check task execution result has an abnormal check item, and returning 0 when the check task execution result does not have an abnormal check item. The specific method for outputting the abnormal information and the tenant to be migrated with the abnormal check item after checking all the check tasks in the task set and summarizing the check task execution results of the tenant to be migrated is as follows: determining the checker type, wherein the checker type includes a line checker, a region checker and a new addition checker; exporting the check item corresponding to the network element Host, checking whether the service configuration corresponding to the check item of the network element Host is cached locally, wherein the service configuration includes VPC and EIP; if the service configuration is not cached, executing the network element configuration export instruction on the network element Host using the SSH protocol, wherein the network element configuration export instruction is a batch instruction used to export all the service configurations corresponding to the network element Host; dividing the exported service configuration into a service configuration list, caching the service configuration list in the memory and returning the service configuration list; if the service configuration is cached, directly obtaining the service configuration list from the cache; checking whether the configuration keyword is in a configuration item of the service configuration list, wherein if the configuration keyword exists, the configuration is normal, and if the configuration keyword does not exist, the migration is abnormal, the abnormal information is outputted, and the tenant to be migrated with the abnormal check item is outputted. The method for dividing the exported service configuration into the service configuration list is as follows: when the checker type is the line checker, the service configuration is divided using a line division method, wherein the line checker checks whether each line in the network element Host configuration contains the key configuration information; when the checker type is the region checker, the service configuration is divided using a region division method, wherein the region checker checks whether each region in the network element Host configuration contains the key configuration information.

7. An electronic device, comprising: The computer program product comprises a memory, a processor and a computer program stored in the memory and capable of running on the processor, and the processor executes the program to implement the steps of the cloud tenant network element migration checking method according to any one of claims 1-5.

8. A readable storage medium, characterized by, The readable storage medium stores a computer program, and the computer program is adapted to be loaded by the processor to execute the steps of the cloud tenant network element migration checking method according to any one of claims 1-5.

Citation Information

Patent Citations

  • System and method to conduct staggered maintenance activity based on customer prioritization in a cloud based saas platform contact center

    US20230023025A1