Management method, system and device of kubernetes platform, medium and product

By detecting changes in the configuration file of the single root I/O virtualization device plugin on the Kubernetes platform, and dynamically adjusting resource group configuration and isolation, the performance bottleneck in high-throughput, low-latency network scenarios is resolved, resource pooling and elastic management are achieved, and network security and resource scheduling flexibility are improved.

CN120909676APending Publication Date: 2025-11-07INSPUR SUZHOU INTELLIGENT TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202511067374.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-07-31
Publication Date
2025-11-07

AI Technical Summary

Technical Problem

The Kubernetes platform has performance bottlenecks when dealing with high-throughput, low-latency network scenarios, making it difficult to meet the needs of scenarios with extremely high network requirements.

Method used

By detecting changes in the configuration files of a single root I/O virtualization device plugin, management requests are identified, and resource group configuration, resource group isolation, and resource group node adjustment are performed according to the target management policy. This enables resource pooling and elastic management, improving network security and resource scheduling flexibility.

Benefits of technology

It significantly enhances the reliability, scalability, and quality of service assurance capabilities of the Kubernetes platform, and improves network security and resource scheduling flexibility in multi-tenant environments.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120909676A_ABST
    Figure CN120909676A_ABST
Patent Text Reader

Abstract

The invention discloses a management method, system and device of a kubernetes platform, a medium and a product, and relates to the technical field of computers, and the management method comprises the steps that whether a configuration file of a single-root I / O virtualization device plug-in is changed or not is detected; determining a current management request under the condition that the configuration file is changed, and determining a target management strategy according to the current management request; and performing at least one operation of resource group configuration, resource group isolation and resource group node adjustment according to the target management strategy. Therefore, the problems that a Kubernetes platform has a performance bottleneck when processing a high-throughput and low-delay network scene and is difficult to meet a scene with extremely high network requirements are solved, resource pooling, elastic management and single-root I / O virtualized network isolation are realized, the network security, resource scheduling flexibility and system operation and maintenance intelligence level in a multi-tenant environment are effectively improved, and the system performance is improved. And the reliability, the expandability and the service quality guarantee capability of the platform are obviously enhanced.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of computer technology, and in particular to a Kubernetes platform management method, system, device, medium and product. BACKGROUND

[0002] Kubernetes (K8s for short) is currently the most mainstream container orchestration system. It realizes the automatic deployment, scaling, fault self-recovery and resource management of containerized applications through a declarative API (Application Programming Interface), and has been widely applied in cloud computing, edge computing and data centers. Kubernetes provides flexible scheduling mechanisms, network models and plugin architectures, making it adaptable to computing environments of various scales and types. However, the default network architecture of Kubernetes is mainly based on software virtualization technologies (such as Linuxbridge, Open vSwitch or CNI (Container Network Interface) plugins), which has certain performance bottlenecks in handling high-throughput, low-latency network scenarios, and is difficult to meet the requirements of scenarios such as high-performance computing (HPC), network function virtualization (NFV) or large-scale AI inference, which have extremely high network requirements.

[0003] In order to solve the above performance bottleneck, SR-IOV (Single Root I / O Virtualization) technology is introduced into the Kubernetes network system. SR-IOV allows a physical network card to be virtually divided into multiple virtual functions (VF), and directly assigned to containers or virtual machines, thereby bypassing traditional virtual switches and kernel network stacks, and achieving network performance close to bare metal. By connecting SR-IOV VF to Kubernetes CNI plugins (such as Multus+SR-IOV CNI), containers can obtain higher bandwidth and lower latency while ensuring isolation. However, the integration of SR-IOV with Kubernetes still faces many challenges, such as VF lifecycle management, network resource scheduling visibility, cross-node scheduling constraints, and security isolation mechanisms in multi-tenant scenarios. Therefore, further research and optimization of the application and management mechanisms of SR-IOV in Kubernetes are still needed to improve overall network performance and availability. SUMMARY

[0004] The application provides a kubernetes platform management method, system, device, medium and product to at least solve the performance bottleneck of the Kubernetes platform when processing high-throughput and low-delay network scenarios, and the difficulty in meeting the requirements of extremely high network scenarios.

[0005] The application provides a kubernetes platform management method, comprising the following steps: detecting whether a configuration file of a single-root I / O virtualization device plugin is changed; in the case that the configuration file is changed, determining a current management request according to a change result, and determining a target management strategy according to the current management request; and performing at least one operation of resource group configuration, resource group isolation and resource group node adjustment according to the target management strategy.

[0006] The application further provides a kubernetes platform management system, comprising: a detection module configured to detect whether a configuration file of a single-root I / O virtualization device plugin is changed; a determination module configured to, in the case that the configuration file is changed, determine a current management request according to a change result, and determine a target management strategy according to the current management request; and a management module configured to perform at least one operation of resource group configuration, resource group isolation and resource group node adjustment according to the target management strategy.

[0007] The application further provides an electronic device, comprising: a memory configured to store a computer program; and a processor configured to implement the steps of the above kubernetes platform management method when executing the computer program.

[0008] The application further provides a non-volatile computer readable storage medium, wherein the non-volatile computer readable storage medium stores a computer program, and the computer program is executed by a processor to implement the steps of the above kubernetes platform management method.

[0009] The application further provides a computer program product, comprising a computer program, and the computer program is executed by a processor to implement the above kubernetes platform management method.

[0010] By the present application, whether the configuration file of the single-root I / O virtualization device plug-in is changed is detected; in the case that the configuration file is changed, the current management request is determined according to the change result, and the target management strategy is determined according to the current management request; at least one of resource group configuration, resource group isolation and resource group node adjustment is performed according to the target management strategy. Thus, the performance bottleneck of the Kubernetes platform in processing high-throughput and low-delay network scenarios is solved, and the problem that it is difficult to meet the scenarios with extremely high network requirements is solved, resource pooling and elastic management, single-root I / O virtualization network isolation are realized, the network security, resource scheduling flexibility and system operation intelligent level in the multi-tenant environment are effectively improved, and the reliability, scalability and service quality guarantee capability of the platform are significantly enhanced. BRIEF DESCRIPTION OF DRAWINGS

[0011] In order to more clearly illustrate the embodiments of the present application, the drawings needed in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application, and other drawings can be obtained by those skilled in the art without creative labor.

[0012] Figure 1 A flowchart of a kubernetes platform management method according to an embodiment of the present application is provided. Figure 2 A structure diagram of a resource group according to an embodiment of the present application is provided. Figure 3 A diagram of automatically parsing and assigning corresponding network attachment configuration network attachment when Multus assigns virtual network card VF according to an embodiment of the present application is provided. Figure 4 A diagram of adjusting resource group nodes of a resource group management service according to an embodiment of the present application is provided. Figure 5 A diagram of a kubernetes platform management system according to an embodiment of the present application is provided. Figure 6 A diagram of an electronic device structure according to an embodiment of the present application is provided. DETAILED DESCRIPTION

[0013] The technical solutions in the embodiments of the present application will be described clearly and completely below with reference to the drawings in the embodiments of the present application. Obviously, the described embodiments are only some embodiments of the present application, not all embodiments. Based on the embodiments in the present application, all other embodiments obtained by those skilled in the art without creative labor are within the protection scope of the present application.

[0014] It should be noted that, in the description of this invention, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. The terms "first," "second," etc., used in this invention are used to distinguish similar objects and are not used to describe a specific order or sequence.

[0015] This invention provides a management method for a Kubernetes platform.

[0016] like Figure 1 As shown, the management method of this Kubernetes platform includes the following steps: Step S101: Check if there are any changes to the configuration file of the single root I / O virtualization device plugin.

[0017] Optionally, in some embodiments, before detecting whether the configuration file of the single root I / O virtualization device plugin has been changed, the method further includes: determining the configuration information of each resource group; configuring the single root I / O virtualization device plugin based on the configuration information to obtain the configuration file of the single root I / O virtualization device plugin.

[0018] In some embodiments, the configuration information includes at least one of resource group identifier, node list, network additional configuration name, and QoS (Quality of Service) parameters.

[0019] By configuring multiple physical nodes, they can be flexibly divided into one or more resource groups. Each resource group can dynamically adjust its node members, achieving resource pooling and elastic management.

[0020] Design and implement the configuration file structure for the SR-IOV device plugin (a plugin used to manage and allocate network device resources that support SR-IOV technology), and add the nodeResourceGroup attribute to support resource group definition and node member list.

[0021] In the configuration file, the configuration information for each resource group includes the resource group identifier (groupID), a list of nodes, a network attachment name, QoS parameters, etc., for example: nodeResourceGroup: # List of node resource groups - groupID: group-a# Unique identifier for the resource group, group-a nodes: [node1, node2]# The resource group contains a list of node names networkAttachment: net-attach-groupA# Network attachment name assigned to the group of nodes (usually corresponds to NetworkAttachmentDefinition) qos:# Network bandwidth QoS policy configuration minBandwidth: 1Gbps# Minimum guaranteed bandwidth maxBandwidth: 10Gbps# Maximum bandwidth limit - groupID: group-b# Resource group unique identifier, group-b nodes: [node3]# The resource group only contains node3 networkAttachment: net-attach-groupB# Network attachment name assigned qos: minBandwidth: 500Mbps# Minimum guaranteed bandwidth maxBandwidth: 5Gbps# Maximum bandwidth limit Further based on the configuration information, the SR-IOV device plugin is configured to obtain the configuration file of the SR-IOV device plugin.

[0022] Through the above technical solution, since the configuration information can be defined flexibly, the system can dynamically create new resource groups according to actual needs, or modify the configuration information of existing resource groups, so that the resource group can quickly adapt to different business scenarios and user needs, realizing the elastic allocation and management of resources. In a multi-tenant environment, different tenants may have different needs and security requirements for network resources. By defining independent configuration information for each resource group, resource isolation between tenants can be achieved.

[0023] Step S102, in the case of changes in the configuration file, determining the current management request according to the change result, and determining the target management strategy according to the current management request.

[0024] In some embodiments, the current management request includes a resource allocation request, a resource group isolation request, and a resource group node adjustment request.

[0025] When the SR-IOV device plugin is started, the configuration file is automatically loaded and parsed, and in the case of changes in the configuration file, the current management request is determined according to the change result, and the target management strategy is determined according to the current management request.

[0026] Through the technical solution, when detecting that the configuration file is changed, the system can quickly determine the type of the current management request (resource allocation request, resource group isolation request, resource group node adjustment request) according to the change result, and by determining the corresponding management strategy for different request types, the system can realize fine management of resources.

[0027] In step S103, at least one of resource group configuration, resource group isolation, and resource group node adjustment is performed according to the target management strategy.

[0028] Optionally, in some embodiments, before determining the target management strategy according to the current management request and performing resource group configuration and resource group isolation according to the target management strategy, the method further includes: creating a network attachment corresponding to each resource group, and updating the configuration file of the single-root I / O virtualization device plugin according to the creation result.

[0029] Each resource group is bound to an independent network attachment, realizing network isolation and policy distribution at the resource group level, and ensuring that pods (container groups) in the same group can communicate at high speed through the single-root I / O virtualization physical network card SR-IOV VF, and cross-group communication is limited. An independent network attachment (such as Multus CRD (Custom Resource Definition, network plugin)) is created for each resource group, and is bound in the configuration file to update the configuration file of the SR-IOV device plugin.

[0030] An administrator creates an independent Network Attachment Definition (NAD) for each resource group, such as net-attach-group A and net-attach-group B.

[0031] In each resource group entry of the SR-IOV device plugin configuration file, a networkAttachment field is added to explicitly bind the relationship.

[0032] The platform supports dynamic binding of resource groups and NADs, and automatically synchronizes to each node after configuration update.

[0033] When configuring the network attachment, SR-IOV related parameters (such as virtual local area network VLAN, IPAM (IPAddress Management, IP address management), bandwidth, etc.) are specified to ensure that pods in the same group communicate at high speed through SR-IOV VF.

[0034] Through the technical solution, when the target management strategy is determined according to the current management request and the resource group configuration or isolation is prepared, the network attachment is created in advance and the configuration file is updated, so that the network configuration can respond to the dynamic change of resource management in time.

[0035] Optionally, in some embodiments, before at least one of the resource group configuration, the resource group isolation, and the resource group node adjustment is performed according to the target management strategy, the method further includes: determining a service level of each resource group, determining a quality of service parameter of each resource group according to the priority and the service level, and modifying a quality of service configuration of each resource group according to the quality of service parameter of each resource group.

[0036] The resource group management service can dynamically adjust the bandwidth and network resource allocation of the resource group according to the demand or business change of the tenant.

[0037] According to the user priority and the service level of different resource groups, generally, the fewer users using the same resource group, the higher the priority of the user, and the number of users is limited according to the service level of the resource group. The network and bandwidth resources are dynamically allocated and adjusted to meet the requirements of elasticity, efficiency and security management in a multi-tenant environment.

[0038] The QoS parameters (such as minBandwidth, maxBandwidth, etc.) are defined for each resource group in the configuration file, and the platform dynamically adjusts the bandwidth, network policy and other QoS parameters of each resource group according to the user priority and the service level.

[0039] Through the technical solution, the service level of each resource group is determined, the network and bandwidth resources can be dynamically allocated and adjusted to each resource group in a scientific and reasonable manner, different QoS parameters are set for different resource groups, and the service quality of each resource group can be better guaranteed in the resource group isolation process.

[0040] Optionally, in some embodiments, the current management request is a resource allocation request, the target management strategy is determined according to the current management request, and at least one of the resource group configuration, the resource group isolation, and the resource group node adjustment is performed according to the target management strategy, including: determining whether the resource allocation request is determined based on the business demand of the user; if the resource allocation request is determined based on the business demand of the user, determining the current priority of the user, and determining the bandwidth and network resource allocation result of each resource group according to the current priority and the current business demand; and performing resource allocation on each resource group based on the bandwidth and network resource allocation result of each resource group.

[0041] When the resource allocation request is based on the business demand of the user, the subsequent resource allocation process is entered.

[0042] According to the priority of the user and the service requirement, a certain algorithm or rule is used to calculate the bandwidth and network resource allocation result of each resource group, and the system actually allocates the bandwidth and network resources to each resource group according to the calculated bandwidth and network resource allocation result of each resource group.

[0043] By the above technical solution, the resource allocation is combined with the user priority and the service requirement, so that the system resources can be more reasonably used under the premise of meeting the basic service requirement. The low-priority service is prevented from excessively occupying the resources and affecting the normal operation of the high-priority service. Through dynamic adjustment of the resource allocation, the system resources are always in the optimal allocation state, and the overall resource utilization efficiency is improved.

[0044] Optionally, in some embodiments, after judging whether the resource allocation request is determined based on the service requirement of the user, the method further includes: if the resource allocation request is not determined based on the service requirement of the user, determining the to-be-modified resource group and the target QoS parameter of the to-be-modified resource group based on the QoS configuration modification request; and modifying the current QoS parameter of the to-be-modified resource group according to the target QoS parameter.

[0045] When it is judged that the resource allocation request is not determined based on the service requirement of the user, it means that the request does not originate from the resource requirement of the user for meeting the service development, at this time, the system will change the processing idea and carry out the subsequent operation according to the QoS configuration modification request.

[0046] The system will analyze the received QoS configuration modification request in detail.

[0047] By analyzing the identification information in the request, such as the name, ID or specific service label of the resource group, the system can accurately identify the to-be-modified resource group which needs to be adjusted in QoS parameter.

[0048] The request will also clearly indicate the target QoS parameter that the to-be-modified resource group needs to reach.

[0049] According to the extracted target QoS parameter, the system will modify the current QoS parameter of the to-be-modified resource group.

[0050] The embodiment of the application supports the administrator to modify the QoS configuration of the resource group in real time, and the modification is issued to each node and network component through the hot update mechanism.

[0051] Through the above technical solution, when the running environment of the system, the network condition or other non-user service factors change, the QoS parameter of the resource group can be quickly adjusted through the QoS configuration modification request, so that the system can timely adapt to these changes.

[0052] Optionally, in some embodiments, the current management request is a resource group isolation request, the target management policy is determined according to the current management request, and at least one of resource group configuration, resource group isolation, and resource group node adjustment is performed according to the target management policy, including: based on the resource group isolation request, assigning independent port information and subnet information to each resource group; and based on the port information and the subnet information corresponding to each resource group, performing isolation configuration on each resource group.

[0053] In the spec field of the NAD (Network Attachment Definition, a custom resource used to define the network attachment configuration of a node), the CNI type is configured as sriov, and the corresponding resourceName, VLAN ID, and IPAM configuration (such as static / dynamic IP allocation) are specified.

[0054] The bandwidth QoS parameter (such as the bandwidth plugin) is configured to set the min / max bandwidth, thereby guaranteeing the bandwidth requirement of the Pods in the resource group.

[0055] If isolation is required, independent port information VLAN ID and subnet information are assigned, and based on the port information and the subnet information corresponding to each resource group, the network traffic of different resource groups is ensured to be physically isolated.

[0056] Through the above technical solution, by assigning independent port information and subnet information to each resource group and performing isolation configuration, even if a certain resource group is subjected to a network attack, it is difficult to spread to other resource groups. Independent subnet and port allocation make the data access paths of different resource groups isolated from each other, thereby guaranteeing the security of data access.

[0057] Optionally, in some embodiments, after performing isolation configuration on each resource group based on the port information and the subnet information corresponding to each resource group, the method further includes: obtaining the identification information of each virtualization instance and the resource group to which each virtualization instance belongs; and binding the identification information of each virtualization instance and the resource group to which the corresponding virtualization instance belongs, to form a resource group granular virtual network card resource pool.

[0058] When the SR-IOV device plugin is started, the identification information of each virtualization instance VF and the resource group to which each virtualization instance belongs is obtained.

[0059] When reporting each virtualization instance VF (such as a PCI address (Peripheral Component Interconnect, a unique address for identifying and accessing devices on a PCI bus and its derivative buses), network card information), the resource group ID to which the corresponding virtualization instance belongs is attached, and the identification information of each virtualization instance and the resource group to which the corresponding virtualization instance belongs are bound, as shown in Figure 2 , forming a unique mapping of VF@groupID.

[0060] When the resource group is changed, the binding relationship between the VF and the resource group is automatically adjusted, and is synchronized to the node agent kubelet or the scheduling system.

[0061] When the Pod applies for an SR-IOV resource, the required network attachment is specified through annotations or CRD, and Multus automatically parses the resource group information and allocates the corresponding VF and network attachment.

[0062] When the SR-IOV device plugin reports the VF resource, the unique identification information of each virtualization instance VF is bound to the resource group ID to which it belongs (such as xxxx@net-attach-groupA, zzzz@net-attach-groupB), forming a VF resource pool at the granularity of a resource group.

[0063] Through the above technical solutions, the VF resource pool at the granularity of a resource group provides a more efficient basis for resource scheduling. The system can quickly allocate the most suitable VF resource to the resource group according to the business characteristics and performance requirements of the resource group, and the VF resource pool at the granularity of a resource group further strengthens the security isolation between different resource groups. The virtualization instances in each resource group share the VF resources of the resource group, and are mutually isolated from the VF resources of other resource groups.

[0064] Optionally, in some embodiments, after forming the virtual network card resource pool at the granularity of a resource group, the method further includes: determining whether there is a network allocation requirement; if there is a network allocation requirement, parsing the network allocation requirement to obtain a target resource group; and selecting a virtual network card resource pool under the target resource group for network allocation.

[0065] The user defines the required network attachment name (bound to the resource group) in the Pod spec (Pod specification) through annotations or network-attachment.

[0066] Multus parses the network attachment request of the Pod when assigning network for the container group Pod, that is, when there is a network allocation requirement, determines the corresponding target resource group.

[0067] When Multus calls the SR-IOV CNI plug-in, the VF resource pool under the target resource group is automatically selected, the available VF is allocated, and the corresponding network attachment is configured, as shown in Figure 3 It should be noted that when the resource is registered to the node agent kubelet, the registered ID contains both the device ID and the virtual local area network information.

[0068] The same group of Pods is allocated to the same NAD and VLAN to achieve high-speed communication, and the Pods across groups cannot directly communicate due to VLAN and subnet isolation.

[0069] The SR-IOV CNI allocates independent network segments for each resource group according to the network attachment configuration, achieving L2 / L3 network isolation.

[0070] Through the above technical solution, by judging the network allocation requirement and parsing the target resource group, the specific range of network resource allocation is accurately positioned, and resource waste caused by blind allocation is avoided.

[0071] Optionally, in some embodiments, the current management request is a resource group node adjustment request, the target management strategy is determined according to the current management request, and at least one of resource group configuration, resource group isolation, and resource group node adjustment is performed according to the target management strategy, including: determining resource group node change content based on the resource group node adjustment request, wherein the resource group node change content includes a node to be adjusted and a resource group to be joined; adjusting the node to be adjusted to the resource group to be joined according to the resource group node change content; updating the configuration file of the SR-IOV device plug-in based on the adjusted information, and performing network configuration based on the updated configuration file.

[0072] When the current management request is a resource group node adjustment request, the resource group management service remotely operates the network switch connected to the cluster node based on the resource group node adjustment request, updates the vlan port range on the switch side, as shown in Figure 4 It supports dynamic hot update of the configuration file, can adjust the node ownership, network attachment, and QoS parameters in real time, and realizes flexible adjustment and bandwidth guarantee of the resource group service level.

[0073] When the resource group node change is detected in the configuration file (such as the nodeResourceGroup field), the resource group node change content (such as adjusting the to-be-adjusted node to the resource group to be joined or removed from the resource group) is parsed, the to-be-adjusted node is adjusted to the resource group to be joined, the resource group management service detects the configuration file update, and the resource group management service continuously monitors the SR-IOV device plugin configuration file (such as through the inotify, fswatch, or the like mechanism), and updates the SR-IOV device plugin configuration file based on the adjusted information, and performs network configuration based on the updated configuration file.

[0074] Through the above technical solution, by explicitly determining the resource group node change content, including the to-be-adjusted node and the resource group to be joined, the node can be accurately allocated to the most needed place. When the business development needs to expand resources, the resource group node adjustment operation can conveniently join the new node to the corresponding resource group and complete the related configuration update, so that the resource expansion can be quickly realized to meet the demand of business growth.

[0075] Optionally, in some embodiments, after determining the resource group node change content based on the resource group node adjustment request, the method further includes: recording the identification information of the resource group to be joined, the current node list of the to-be-adjusted node, and the to-be-joined list of the to-be-adjusted node.

[0076] Specifically, the changed resource group ID, the affected node list, the network attachment, and the QoS parameter change are recorded. For example, the identification information of the resource group to be joined, the current node list of the to-be-adjusted node, and the to-be-joined list of the to-be-adjusted node are recorded.

[0077] Through the above technical solution, the identification information of the resource group to be joined, the current node list of the to-be-adjusted node, and the to-be-joined list of the to-be-adjusted node are recorded, so that it can be clearly known that each node will be included in which resource group, and the system can conveniently track and monitor the resources globally. The administrator can view the node composition of each resource group at any time, and understand the distribution and use state of the resources.

[0078] Optionally, in some embodiments, adjusting the to-be-adjusted node to the resource group to be joined according to the resource group node change content includes: determining a target node port of the to-be-adjusted node in the resource group to be joined based on the resource group node change content; and adjusting the to-be-adjusted node to the resource group to be joined based on the target node port.

[0079] According to the resource group node change content, determine the to-be-adjusted node and its physical port (i.e. target node port) that need to adjust the VLAN configuration, and based on the target node port, adjust the to-be-adjusted node to the resource group to be joined. Through remote calling of a switch management API (such as RESTful, SNMP (Simple Network Management Protocol), Netconf, etc.), update the VLAN ID of the corresponding target node port, so as to be consistent with the networkattachment policy of the resource group to be joined.

[0080] The pseudo code is as follows: Function ConfigureSwitchPortVLAN (brand, switch IP, username, password, interface name, VLAN number): Establish an SSH (Secure Shell, a network protocol for secure remote login and file transfer) connection to the switch IP, using the username and password After login success: If brand == "Cisco": Send command: enable# Enter privileged mode If a privileged password is required: Send command: privileged password Send command: configure terminal# Enter global configuration mode Send command: interface interface name# Enter the specified interface configuration mode (such as GigabitEthernet0 / 1) Send command: switchport mode access# Set the interface to access mode Send command: switchport access vlan VLAN number# Add the interface to the specified VLAN Send command: exit# Exit the interface configuration mode Send command: exit# Exit the global configuration mode Send command: write memory# Save the configuration to memory (i.e. save to the startup configuration) Else if brand == "Huawei" or "H3C":# Otherwise, if it is a Huawei or H3C brand device Send command: system-view# Enter system view (configuration mode) Send command: interface interface name# Enter the specified interface configuration mode Send command: port link-type access# Set interface to access type Send command: port access vlan VLAN number# Add interface to specified VLAN Send command: quit# Exit interface configuration Send command: quit# Exit system configuration mode Send command: save# Save configuration If prompted whether to save configuration:# If the system prompts for confirmation of saving Send command: y# Enter y to confirm saving Close SSH connection# Finally, disconnect the SSH connection to end the function.

[0081] Through the above technical solution, the target node port of the to-be-adjusted node in the target resource group to be joined is determined based on the content of the resource group node change, which can accurately match the specific needs of the resource group to be joined and the characteristics of the to-be-adjusted node, and helps to optimize the network topology structure between the to-be-adjusted node and the resource group to be joined.

[0082] Optionally, in some embodiments, before adjusting the to-be-adjusted node to the resource group to be joined based on the target node port, it further includes: obtaining the to-be-moved-out resource group of the to-be-adjusted node; judging whether the to-be-moved-out resource group is consistent with the resource group to be joined; if the to-be-moved-out resource group is not consistent with the resource group to be joined, the binding relationship between the to-be-adjusted node and the to-be-moved-out resource group is removed.

[0083] The resource group management service remotely calls the network switch API to dynamically adjust the VLAN configuration of the related node port, ensuring that the network isolation policy is consistent with the latest mapping of the resource group.

[0084] Determine the to-be-moved-out resource group of the to-be-adjusted node and the resource group to be joined, remove the port of the to-be-adjusted node from the original VLAN, and then join the VLAN corresponding to the resource group to be joined.

[0085] After the operation is completed, record the VLAN change log to facilitate subsequent auditing and troubleshooting.

[0086] After the configuration file changes, the SR-IOV device plugin automatically hot loads the new configuration, realizing real-time adjustment of node affiliation, network attachment, and QoS parameters.

[0087] SR-IOV device plugin has a built-in configuration hot loading mechanism to listen to configuration file change events.

[0088] After detecting the configuration change, automatically re-resolve the nodeResourceGroup, network attachment, QoS, etc. According to the new configuration, dynamically adjust the resource group belonging, available VF resource pool, bandwidth policy, etc. of the node.

[0089] If the node is assigned to a new resource group, automatically unbind the original resource group related configuration, and apply the network attachment and QoS policy of the new resource group. After the configuration change, automatically synchronize to Multus, CNI, etc. related components to ensure that all network and bandwidth policies take effect immediately.

[0090] The SR-IOV device plugin reports the latest resource group, VF, QoS, etc. information to Kubernetes (such as through Node resources, CRD, or API Server).

[0091] After Multus detects NAD or related CRD changes, automatically refresh the cache to ensure that the latest network attachment and resource pool information is used when assigning networks to Pods.

[0092] Through the above technical solutions, when the to-be-moved-out resource group and the to-be-joined resource group are inconsistent, the binding relationship between the to-be-adjusted node and the to-be-moved-out resource group is released, which can prevent resource conflict problems during node migration.

[0093] Optionally, in some embodiments, when the network configuration is performed based on the updated configuration file, it further includes: generating network reconfiguration information or rolling restart information; sending the network reconfiguration information or the rolling restart information to the target deployment unit, so that the target deployment unit performs network reconfiguration based on the network reconfiguration information or performs rolling restart based on the rolling restart information.

[0094] When the SR-IOV CNI plugin allocates VF and configures the network, it reads the latest network attachment and bandwidth policy in real time to ensure that the Pod network configuration is consistent with the resource group policy.

[0095] At the same time, network reconfiguration information or rolling restart information is generated, and the network reconfiguration information or the rolling restart information is sent to the target deployment unit (i.e. related Pods), notifying the related Pods to perform network reconfiguration based on the network reconfiguration information or perform rolling restart based on the rolling restart information, to ensure that the policy change takes effect immediately.

[0096] By the technical solution, the network configuration of the target deployment unit can be modified and updated in real time by sending network reconfiguration information or rolling restart information, without manually configuring each node one by one, so that the flexibility and response speed of network configuration are greatly improved.

[0097] To sum up, the technical effects brought by the embodiment of the application are as follows: The dynamic and automatic management of network and bandwidth resources at the resource group level in the artificial intelligence platform is realized, the resource group elastic division, VLAN automatic configuration, SR-IOV network isolation and bandwidth guarantee are realized by platform linkage switches and nodes, the network security, resource scheduling flexibility and system operation intelligent level in the multi-tenant environment are effectively improved, and the reliability, scalability and service quality guarantee capability of the platform are significantly enhanced.

[0098] According to the kubernetes platform management method provided in the embodiment of the application, it is detected whether a configuration file of a single I / O virtualization device plug-in is changed, in the case that the configuration file is changed, a current management request is determined according to a change result, and a target management strategy is determined according to the current management request, and at least one of resource group configuration, resource group isolation and resource group node adjustment is performed according to the target management strategy. Therefore, the performance bottleneck of the Kubernetes platform in processing high-throughput and low-delay network scenarios is solved, and the problem that the Kubernetes platform is difficult to meet the extremely high network requirement scenarios is solved.

[0099] Secondly, the kubernetes platform management system provided in the embodiment of the application is described with reference to the accompanying drawings.

[0100] Figure 5 is a schematic diagram of the kubernetes platform management system in the embodiment of the application.

[0101] As shown in Figure 5 , the kubernetes platform management system 10 includes a detection module 100, a determination module 200 and a management module 300.

[0102] The detection module 100 is configured to detect whether a configuration file of a single I / O virtualization device plug-in is changed, the determination module 200 is configured to determine a current management request according to a change result in the case that the configuration file is changed, and determine a target management strategy according to the current management request, and the management module 300 is configured to perform at least one of resource group configuration, resource group isolation and resource group node adjustment according to the target management strategy.

[0103] Optionally, in some embodiments, before detecting whether the configuration file of the single-root I / O virtualization device plugin exists a change, the detection module 100 is further configured to: determine configuration information of each resource group; and configure the single-root I / O virtualization device plugin based on the configuration information to obtain the configuration file of the single-root I / O virtualization device plugin.

[0104] Optionally, in some embodiments, the configuration information comprises at least one of a resource group identifier, a node list, a network additional configuration name, and a quality of service parameter.

[0105] Optionally, in some embodiments, the current management request comprises a resource allocation request, a resource group isolation request, and a resource group node adjustment request.

[0106] Optionally, in some embodiments, before determining the target management strategy according to the current management request and performing resource group configuration and resource group isolation according to the target management strategy, the management module 300 is further configured to: create a network additional configuration corresponding to each resource group, and update the configuration file of the single-root I / O virtualization device plugin according to a result of the creation.

[0107] Optionally, in some embodiments, the current management request is a resource allocation request, and the management module 300 is further configured to: determine whether the resource allocation request is determined based on a service requirement of a user; if the resource allocation request is determined based on the service requirement of the user, determine a current priority of the user and determine a bandwidth and a network resource allocation result of each resource group according to the current priority and the service requirement; and perform resource allocation on each resource group based on the bandwidth and the network resource allocation result of each resource group.

[0108] Optionally, in some embodiments, after determining whether the resource allocation request is determined based on the service requirement of the user, the management module 300 is further configured to: if the resource allocation request is not determined based on the service requirement of the user, determine a target quality of service parameter of a resource group to be modified and the resource group to be modified based on a quality of service configuration modification request; and modify a current quality of service parameter of the resource group to be modified according to the target quality of service parameter.

[0109] Optionally, in some embodiments, before performing at least one of resource group configuration, resource group isolation, and resource group node adjustment according to the target management strategy, the management module 300 is further configured to: determine a service level of each resource group, determine a quality of service parameter of each resource group according to the priority and the service level; and modify a quality of service configuration of each resource group according to the quality of service parameter of each resource group.

[0110] Optionally, in some embodiments, the current management request is a resource group isolation request, the target management policy is determined according to the current management request, and at least one of resource group configuration, resource group isolation, and resource group node adjustment is performed according to the target management policy. The management module 300 is further configured to: based on the resource group isolation request, allocate independent port information and subnet information for each resource group; and based on the port information and the subnet information corresponding to each resource group, perform isolation configuration on each resource group.

[0111] Optionally, in some embodiments, after performing isolation configuration on each resource group based on the port information and the subnet information corresponding to each resource group, the management module 300 is further configured to: obtain identification information of each virtualization instance and a resource group to which each virtualization instance belongs; and bind the identification information of each virtualization instance and the resource group to which the corresponding virtualization instance belongs, to form a resource group granularity virtual network card resource pool.

[0112] Optionally, in some embodiments, after forming the resource group granularity virtual network card resource pool, the management module 300 is further configured to: determine whether there is a network allocation requirement; if there is a network allocation requirement, parse the network allocation requirement to obtain a target resource group; and select a virtual network card resource pool under the target resource group for network allocation.

[0113] Optionally, in some embodiments, the current management request is a resource group node adjustment request, the target management policy is determined according to the current management request, and at least one of resource group configuration, resource group isolation, and resource group node adjustment is performed according to the target management policy. The management module 300 is further configured to: based on the resource group node adjustment request, determine resource group node change content, wherein the resource group node change content includes a node to be adjusted and a resource group to be added; based on the resource group node change content, adjust the node to be adjusted to the resource group to be added; update a configuration file of a single-root I / O virtualization device plug-in based on the adjusted information, and perform network configuration based on the updated configuration file.

[0114] Optionally, in some embodiments, after determining the resource group node change content based on the resource group node adjustment request, the management module 300 is further configured to: record identification information of the resource group to be added, a current node list of the node to be adjusted, and a to-be-added list of the node to be adjusted.

[0115] Optionally, in some embodiments, based on the resource group node change content, the node to be adjusted is adjusted to the resource group to be added, and the management module 300 is further configured to: based on the resource group node change content, determine a target node port of the node to be adjusted in the resource group to be added; and based on the target node port, adjust the node to be adjusted to the resource group to be added.

[0116] Optionally, in some embodiments, before adjusting the to-be-adjusted node to the to-be-joined resource group based on the target node port, the management module 300 is further configured to: acquire a to-be-moved-out resource group of the to-be-adjusted node; determine whether the to-be-moved-out resource group is consistent with the to-be-joined resource group; and if the to-be-moved-out resource group is inconsistent with the to-be-joined resource group, release the binding relationship between the to-be-adjusted node and the to-be-moved-out resource group.

[0117] Optionally, in some embodiments, when performing network configuration based on the updated configuration file, the management module 300 is further configured to: generate network reconfiguration information or rolling restart information; and send the network reconfiguration information or the rolling restart information to the target deployment unit, so that the target deployment unit performs network reconfiguration based on the network reconfiguration information or performs rolling restart based on the rolling restart information.

[0118] It should be noted that the description of the features in the embodiments of the management system of the kubernetes platform can refer to the related description of the embodiments of the management method of the kubernetes platform described above, which will not be repeated here.

[0119] Figure 6 The electronic device provided by the embodiments of the present application is shown in the structural schematic diagram. The electronic device can include: The memory 601, the processor 602, and the computer program stored in the memory 601 and executable on the processor 602.

[0120] The processor 602 executes the program to implement the management method of the kubernetes platform provided in the above embodiments.

[0121] Further, the electronic device further includes: The communication interface 603 is used for communication between the memory 601 and the processor 602.

[0122] The memory 601 is used to store the computer program executable on the processor 602.

[0123] The memory 601 can include a high-speed RAM memory, and can also include a non-volatile memory, such as at least one disk memory.

[0124] If the memory 601, the processor 602 and the communication interface 603 are implemented independently, the communication interface 603, the memory 601 and the processor 602 can be connected with each other through a bus and complete communication between each other. The bus can be an Industry Standard Architecture (ISA) bus, a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus, etc. The bus can be divided into an address bus, a data bus, a control bus, etc. For convenience of representation, Figure 6 Only one thick line is used to represent the bus in the figure, but it does not mean that there is only one bus or only one type of bus.

[0125] Optionally, in a specific implementation, if the memory 601, the processor 602 and the communication interface 603 are integrated on a chip, the memory 601, the processor 602 and the communication interface 603 can complete communication between each other through an internal interface.

[0126] The processor 602 can be a Central Processing Unit (CPU), or an Application Specific Integrated Circuit (ASIC), or one or more integrated circuits configured to implement embodiments of the present application.

[0127] Embodiments of the present application also provide a non-volatile computer readable storage medium, which stores a computer program, and the computer program is configured to execute steps in any of the above-mentioned embodiments of the management method of the kubernetes platform when running.

[0128] In an exemplary embodiment, the above-mentioned non-volatile computer readable storage medium can include, but is not limited to, a U disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a mobile hard disk, a magnetic disk or an optical disk and various computer program storage media.

[0129] Embodiments of the present application also provide a computer program product, which includes a computer program, and the computer program is executed by a processor to implement the above-mentioned management method of the kubernetes platform.

[0130] Those skilled in the art will further realize that the mere conception of the examples described herein is sufficient to enable practitioners to practice the examples as changed or modified for variations of the embodiments. Based on the teachings and guidance presented in the foregoing descriptions of the embodiments, those skilled in the art will envision and have no difficulty developing alternative methods that incorporate one or more of the novel aspects described herein. Those skilled in the art will also realize that such modifications are intended to be within the scope of the embodiments. Accordingly, the drawings and descriptions are to be regarded as illustrative in nature and that it is to be understood that not only the combinations and / or arrangements described are possible but that other combinations and / or arrangements will occur to those skilled in the art and are intended to be within the scope of the embodiments.

[0131] The above describes in detail the method, system, device, medium and product provided by the application. The principles and implementation modes of the application are described by applying specific examples. The above description of the examples is only for helping to understand the method of the application and its core idea. It should be pointed out that, for those skilled in the art, some improvements and modifications can be made to the application without departing from the principles of the application. These improvements and modifications also fall within the protection scope of the claims of the application.

Claims

1. A method for managing a kubernetes platform, characterized by, The method comprises the following steps: detecting whether a configuration file of a single I / O virtualization device plug-in has a change; in the case that the configuration file has a change, determining a current management request according to a change result, and determining a target management strategy according to the current management request; performing at least one of resource group configuration, resource group isolation, and resource group node adjustment according to the target management strategy.

2. The management method of the kubernetes platform according to claim 1, wherein, The current management request comprises a resource allocation request, a resource group isolation request, and a resource group node adjustment request.

3. The management method of the kubernetes platform according to claim 2, wherein, The current management request is the resource allocation request, and the determination of the target management strategy according to the current management request and the performance of at least one of resource group configuration, resource group isolation, and resource group node adjustment according to the target management strategy comprise: determining whether the resource allocation request is determined based on a service demand of a user; if the resource allocation request is determined based on the service demand of the user, determining a current priority of the user, and determining a bandwidth and a network resource allocation result of each resource group according to the current priority and the current service demand; allocating resources to each resource group based on the bandwidth and the network resource allocation result of each resource group.

4. The management method of the kubernetes platform according to claim 3, wherein, After determining whether the resource allocation request is determined based on the service demand of the user, the method further comprises: if the resource allocation request is not determined based on the service demand of the user, determining a target service quality parameter of a to-be-modified resource group and the to-be-modified resource group based on a quality of service configuration modification request; modifying a current service quality parameter of the to-be-modified resource group according to the target service quality parameter. 5.The method of Claim 2, wherein, Before performing at least one of resource group configuration, resource group isolation, and resource group node adjustment according to the target management strategy, the method further comprises: determining a service level of each resource group, and determining a service quality parameter of each resource group according to a priority and the service level; modifying a service quality configuration of each resource group according to the service quality parameter of each resource group.

6. The management method of the kubernetes platform according to claim 2, wherein, The current management request is the resource group isolation request, and the determination of the target management strategy according to the current management request and the performance of at least one of resource group configuration, resource group isolation, and resource group node adjustment according to the target management strategy comprise: allocating independent port information and subnet information to each resource group based on the resource group isolation request; performing isolation configuration on each resource group based on the port information and the subnet information corresponding to each resource group.

7. The management method of the kubernetes platform according to claim 6, wherein, After performing isolation configuration on each resource group based on the port information and the subnet information corresponding to each resource group, the method further comprises: obtaining identification information of each virtualization instance and a resource group to which each virtualization instance belongs; binding the identification information of each virtualization instance and the resource group to which the corresponding virtualization instance belongs, to form a virtual network card resource pool at a resource group granularity.

8. The management method of the kubernetes platform according to claim 7, wherein, After forming the virtual network card resource pool at the resource group granularity, the method further comprises: determining whether there is a network allocation demand; if there is the network allocation demand, analyzing the network allocation demand to obtain a target resource group; Select a virtual network card resource pool under the target resource group for network allocation. 9.The method of Claim 6, wherein, Before determining the target management policy according to the current management request and performing resource group configuration, resource group isolation according to the target management policy, the method further comprises: Creating a network attachment configuration corresponding to each resource group, and updating the configuration file of the single-root I / O virtualization device plug-in according to the creation result. 10.The management method of the kubernetes platform of claim 2, wherein, The current management request is a resource group node adjustment request, and the method of determining the target management policy according to the current management request and performing at least one operation of resource group configuration, resource group isolation, and resource group node adjustment according to the target management policy comprises: Based on the resource group node adjustment request, determine the resource group node change content, wherein the resource group node change content includes a node to be adjusted and a resource group to be joined; According to the resource group node change content, the node to be adjusted is adjusted to the resource group to be joined; Based on the adjusted information, update the configuration file of the single-root I / O virtualization device plug-in, and perform network configuration based on the updated configuration file.

11. The management method of the kubernetes platform according to claim 10, wherein, After determining the resource group node change content based on the resource group node adjustment request, the method further comprises: Record the identification information of the resource group to be joined, the current node list of the node to be adjusted, and the list of the node to be joined.

12. The management method of the kubernetes platform according to claim 10, wherein, The method of adjusting the node to be adjusted to the resource group to be joined according to the resource group node change content comprises: Based on the resource group node change content, determine the target node port of the node to be adjusted in the resource group to be joined; Based on the target node port, adjust the node to be adjusted to the resource group to be joined.

13. The management method of the kubernetes platform according to claim 12, wherein, Before adjusting the node to be adjusted to the resource group to be joined based on the target node port, the method further comprises: Obtain the resource group to be removed from the node to be adjusted; Determine whether the resource group to be removed is consistent with the resource group to be joined; If the resource group to be removed is not consistent with the resource group to be joined, the binding relationship between the node to be adjusted and the resource group to be removed is released.

14. The management method of the kubernetes platform according to claim 12, wherein, When performing network configuration based on the updated configuration file, the method further comprises: Generating network reconfiguration information or rolling restart information; Send the network reconfiguration information or the rolling restart information to a target deployment unit, so that the target deployment unit performs network reconfiguration based on the network reconfiguration information or performs rolling restart based on the rolling restart information.

15. The management method of the kubernetes platform according to claim 1, wherein, Before detecting whether the configuration file of the single-root I / O virtualization device plug-in has changed, the method further comprises: Determine the configuration information of each resource group; Based on the configuration information, configure the single-root I / O virtualization device plug-in to obtain the configuration file of the single-root I / O virtualization device plug-in.

16. The management method of the kubernetes platform according to claim 15, wherein, The configuration information includes at least one of a resource group identifier, a node list, a network attachment configuration name, and a quality of service parameter. 17.A management system of a kubernetes platform, characterized in that, The method comprises: A detection module for detecting whether the configuration file of the single-root I / O virtualization device plug-in has changed; The determining module is configured to determine a current management request according to a result of the change when the configuration file is changed, and determine a target management strategy according to the current management request. The management module is configured to perform at least one of resource group configuration, resource group isolation, and resource group node adjustment according to the target management strategy.

18. An electronic device, comprising: The computer program is stored in the memory and executable on the processor, and the processor executes the program to implement the management method of the kubernetes platform according to any one of claims 1-16. The program is executed by the processor to implement the management method of the kubernetes platform according to any one of claims 1-16.

19. A non-transitory computer readable storage medium having stored thereon a computer program, characterized in that, The computer program is executed by the processor to implement the management method of the kubernetes platform according to any one of claims 1-16.

20. A computer program product comprising a computer program, characterized in that, ​