SRV6-based computing power-aware routing allocation method and SRV6-based computing power-aware routing allocation system
By adopting the SRV6-based computing power-aware routing allocation method in cross-cloud and cloud-edge wide-area network environments, the problem of lack of flexibility in computing power resource scheduling in traditional technologies is solved, and efficient and flexible resource allocation and network performance optimization are achieved.
Patent Information
- Application Number
- CN202411537411.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-31
- Publication Date
- 2025-02-14
AI Technical Summary
Traditional computing resource orchestration technology faces the challenges of computing power perception and routing optimization in cross-cloud and cloud-edge wide-area network environments, and lacks the ability to make real-time adjustments based on business status, resulting in lack of flexibility in computing power resource scheduling.
The computing power-aware routing allocation method based on SRV6 is adopted, and the resource state data of the nodes is obtained in real time by constructing a network topology undirected graph, the improved Dijkstra algorithm is used to calculate the optimal path, and routing rules are configured through SRV6 network programming technology.
It improves resource allocation efficiency, optimizes network performance, enhances network programmability and flexibility, supports large-scale network deployment, and ensures efficient and reasonable allocation of resources and improves network performance.
Smart Images

Figure CN119449690A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of communication technology, and in particular to a computing power-aware routing allocation method and system based on SRV6. Background Art
[0002] With the rapid development of cloud computing and distributed computing, the effective scheduling and utilization of computing resources have become an important means to improve computing efficiency and system performance. In the existing technology, container orchestration technology is widely used in the management of distributed clusters to achieve efficient utilization of computing resources.
[0003] However, with the continuous growth of computing demand, traditional computing resource orchestration technology faces challenges in computing power perception and routing optimization in cross-cloud and cloud-edge wide area network environments. Existing computing power perception and routing algorithms are mainly based on preset policies and static rules, and lack the ability to make real-time adjustments based on business status. In complex and ever-changing cloud environments and wide area networks, business needs and computing power resource status often change rapidly, and static scheduling strategies are difficult to adapt to such changes, resulting in a lack of flexibility in the scheduling of computing power resources. Summary of the invention
[0004] The present invention aims to provide a computing power-aware routing allocation method and system based on SRV6 to solve the technical problem of insufficient flexibility in routing allocation of computing power resources.
[0005] In order to solve the above technical problems, an embodiment of the present invention provides a computing power-aware routing allocation method based on SRV6, including:
[0006] Based on the target distributed cluster, construct a network topology undirected graph, wherein the nodes of the undirected graph represent computing devices, and the weights of the edges are determined according to latency and bandwidth;
[0007] In response to a service request, obtaining real-time resource status data of each of the nodes in the target distributed cluster, and parsing the service request to obtain resource request data;
[0008] Matching each node in the network topology undirected graph with the resource request data to obtain a target node, wherein the matching is designed to eliminate the influence of node overload through a load balancing algorithm;
[0009] Using the improved Dijkstra algorithm to calculate the optimal path from the source node to the target node in the network topology undirected graph;
[0010] According to the optimal path, corresponding routing rules are configured in the target distributed cluster through SRV6 network programming technology.
[0011] As one preferred solution, the acquiring of real-time resource status data of each of the nodes in the target distributed cluster includes:
[0012] Collect the real-time resource status data of each node in the target distributed cluster through Prometheus and node Exporter, and configure the collection cycle, wherein the real-time resource status data at least includes the CPU usage, GPU usage, memory occupancy and disk I / O of the computing device;
[0013] A multi-dimensional vector is constructed based on the real-time resource status data to obtain the computing resource vector of each node, which is expressed as:
[0014] S(node i )
[0015] =[node i (CPU),node i (GPU),node i (Mem), node i (IO)]
[0016] Among them, node i Represents the i-th node in the cluster, S(node i ) represents the computing resource vector of the i-th node, node i (CPU) represents the CPU resource usage of the i-th node, node i (GPU) represents the GPU resource usage of the i-th node, node i (Mem) represents the memory resource usage of the i-th node, node i (IO) represents the IO rate of the i-th node.
[0017] As one of the preferred solutions, the resource request data includes multi-dimensional resource requirements and corresponding weights of the business request;
[0018] The step of matching each node in the network topology undirected graph with the resource request data to obtain a target node includes:
[0019] The matching degree between each node in the network topology undirected graph and the resource request data is calculated according to the node allocation calculation formula, and the node allocation calculation formula is expressed as:
[0020] Score(node i )
[0021] =α cpu CPU+α gpu GPU+α memMem
[0022] +α io IO
[0023] Among them, Score(node i ) represents the matching degree between the i-th node and the resource request data, and its value range is [0,4], α x is the weight of different computing resource types in the score. CPU, GPU, Mem, and IO respectively represent the matching degree between the business request and the node on the computing resource of that type.
[0024] According to the matching degree, sorting each of the nodes;
[0025] According to the sorting result, a target node is obtained.
[0026] As one preferred solution, before obtaining the target node according to the sorting result, the method further includes:
[0027] Calculating the load balancing degree of the target node;
[0028] Determining a load balancing threshold according to the target distributed cluster environment and the service request;
[0029] If the load balance degree of the target node exceeds the threshold, the next node with a lower load balance degree is selected as the new target node according to the sorting result; this process is repeated until a node with a load balance degree within the threshold range is found.
[0030] As one of the preferred solutions, the use of the improved Dijkstra algorithm to calculate the optimal path from the source node to the target node in the network topology undirected graph includes:
[0031] constructing a heuristic function for estimating a minimum distance from the source node to the target node;
[0032] Initialize a priority queue and add the source node to the priority queue;
[0033] During the extraction process, extracting a node with the minimum cost from the priority queue as the current expansion node, wherein the cost includes a source node cost and a heuristic value, wherein the heuristic value is calculated by the heuristic function;
[0034] During the judgment process, if the current extended node is the target node, the algorithm ends; otherwise, the cumulative cost of each neighbor node from the source node to the current extended node is calculated, and the position of the neighbor node in the priority queue is updated;
[0035] The extraction process and the judgment process are repeated until the target node is found, and the path from the source node to the target node is used as the optimal path.
[0036] Another embodiment of the present invention provides a computing power-aware routing allocation system based on SRV6, including:
[0037] A construction module is used to construct a network topology undirected graph based on a target distributed cluster, wherein nodes of the undirected graph represent computing devices and edge weights are determined according to latency and bandwidth;
[0038] An acquisition module, configured to acquire real-time resource status data of each of the nodes in the target distributed cluster in response to a service request, and parse the service request to obtain resource request data;
[0039] A matching module, used to match each node in the network topology undirected graph with the resource request data to obtain a target node, wherein the matching is designed to eliminate the influence of node overload through a load balancing algorithm;
[0040] A calculation module, used for calculating the optimal path from the source node to the target node in the network topology undirected graph using the improved Dijkstra algorithm;
[0041] As one preferred solution, the acquisition module is specifically used for:
[0042] Collect the real-time resource status data of each node in the target distributed cluster through Prometheus and node Exporter, and configure the collection cycle, wherein the real-time resource status data at least includes the CPU usage, GPU usage, memory occupancy and disk I / O of the computing device;
[0043] A multi-dimensional vector is constructed based on the real-time resource status data to obtain the computing resource vector of each node, which is expressed as:
[0044] S(node i )
[0045] =[node i (CPU),node i (GPU),node i (Mem), node i (IO)]
[0046] Among them, node i Represents the i-th node in the cluster, S(node i ) represents the computing resource vector of the i-th node, node i(CPU) represents the CPU resource usage of the i-th node, node i (GPU) represents the GPU resource usage of the i-th node, node i (Mem) represents the memory resource usage of the i-th node, node i (IO) represents the IO rate of the i-th node.
[0047] As one of the preferred solutions, the resource request data includes multi-dimensional resource requirements and corresponding weights of the business request;
[0048] The matching module is specifically used for:
[0049] The matching degree between each node in the network topology undirected graph and the resource request data is calculated according to the node allocation calculation formula, and the node allocation calculation formula is expressed as:
[0050] Score(node i )
[0051] =α cpu CPU+α gpu GPU+α mem Mem
[0052] +α io IO
[0053] Among them, Score(node i ) represents the matching degree between the i-th node and the resource request data, and its value range is [0,4], α x is the weight of different computing resource types in the score. CPU, GPU, Mem, and IO respectively represent the matching degree between the business request and the node on the computing resource of that type.
[0054] According to the matching degree, sorting each of the nodes;
[0055] According to the sorting result, a target node is obtained.
[0056] As one preferred solution, the matching module is further used for:
[0057] Calculating the load balancing degree of the target node;
[0058] Determining a load balancing threshold according to the target distributed cluster environment and the service request;
[0059] If the load balance degree of the target node exceeds the threshold, the next node with a lower load balance degree is selected as the new target node according to the sorting result; this process is repeated until a node with a load balance degree within the threshold range is found.
[0060] As one preferred solution, the computing module is used to:
[0061] constructing a heuristic function for estimating a minimum distance from the source node to the target node;
[0062] Initialize a priority queue and add the source node to the priority queue;
[0063] During the extraction process, extracting a node with the minimum cost from the priority queue as the current expansion node, wherein the cost includes a source node cost and a heuristic value, wherein the heuristic value is calculated by the heuristic function;
[0064] During the judgment process, if the current extended node is the target node, the algorithm ends; otherwise, the cumulative cost of each neighbor node from the source node to the current extended node is calculated, and the position of the neighbor node in the priority queue is updated;
[0065] The extraction process and the judgment process are repeated until the target node is found, and the path from the source node to the target node is used as the optimal path.
[0066] Compared with the prior art, the embodiments of the present invention have the following advantages:
[0067] 1) Improve resource allocation efficiency: By obtaining the resource status data of the node in real time and matching it according to business needs, resources can be allocated efficiently and reasonably. The application of load balancing algorithms further eliminates the risk of node overload and improves the stability and reliability of the entire distributed cluster.
[0068] 2) Optimize network performance: Using the improved Dijkstra algorithm to calculate the optimal path can ensure that data packets have the lowest latency and highest bandwidth utilization when transmitted in the network. This is crucial to improving the overall performance of the network and user experience.
[0069] 3) Enhanced network programmability and flexibility: The application of SRv6 network programming technology allows network administrators to flexibly configure and manage the network according to business needs. Through programming, it is easy to dynamically adjust and optimize network resources to adapt to changing business needs.
[0070] 4) Support large-scale network deployment: SRv6 leverages the scalability of IPv6 to provide the network with a larger address space and richer functions, thereby supporting larger-scale and more complex network scenarios. BRIEF DESCRIPTION OF THE DRAWINGS
[0071] Figure 1It is a flowchart of a computing power-aware routing allocation method based on SRV6 in one embodiment of the present invention;
[0072] Figure 2 It is a schematic diagram of a cross-cloud environment SDN control plane design in one embodiment of the present invention;
[0073] Figure 3 is a schematic diagram of a network topology in one embodiment of the present invention;
[0074] Figure 4 is a schematic diagram of an example of a data dictionary of an SRv6 controller in one embodiment of the present invention;
[0075] Figure 5 It is a schematic diagram of a computing power-aware routing allocation system based on SRV6 in one embodiment of the present invention. DETAILED DESCRIPTION
[0076] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. The purpose of providing these embodiments is to make the disclosure of the present invention more thorough and comprehensive. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0077] In the description of this application, the terms "first", "second", "third", etc. are used for descriptive purposes only and are not to be understood as indicating or implying relative importance or implicitly indicating the number of the indicated technical features. Thus, a feature defined as "first", "second", "third", etc. may explicitly or implicitly include one or more of the feature. In the description of this application, unless otherwise specified, "plurality" means two or more.
[0078] In the description of the present application, it should be noted that, unless otherwise clearly specified and limited, the terms "installed", "connected", and "connected" should be understood in a broad sense. For example, it can be a fixed connection, a detachable connection, or an integral connection; it can be a mechanical connection or an electrical connection; it can be a direct connection, or it can be indirectly connected through an intermediate medium, or it can be a connection between the two elements. The terms "vertical", "horizontal", "left", "right", "upper", "lower" and similar expressions used in this article are only for illustrative purposes, and do not indicate or imply that the device or element referred to must have a specific orientation, be constructed and operated in a specific orientation, and therefore cannot be understood as a limitation on the present invention. The term "and / or" used in this article includes any and all combinations of one or more related listed items. For those of ordinary skill in the art, the specific meanings of the above terms in this application can be understood according to specific circumstances.
[0079] In the description of this application, it should be noted that, unless otherwise defined, all technical and scientific terms used in the present invention have the same meaning as those commonly understood by those skilled in the art. The terms used in the specification of the present invention are only for the purpose of describing specific embodiments and are not intended to limit the present invention. For those of ordinary skill in the art, the specific meanings of the above terms in this application can be understood by specific circumstances.
[0080] An embodiment of the present invention provides a computing power-aware routing allocation method based on SRV6. For details, see Figure 1 , Figure 1 The flowchart of the SRV6-based computing power-aware routing allocation method in one embodiment of the present invention is shown, wherein it includes steps S1-S5:
[0081] S1: Based on the target distributed cluster, construct a network topology undirected graph, where the nodes of the undirected graph represent computing devices and the weights of the edges are determined according to latency and bandwidth;
[0082] S2: in response to the service request, obtaining the real-time resource status data of each node in the target distributed cluster, and parsing the service request to obtain resource request data;
[0083] S3: Matching each node in the network topology undirected graph with the resource request data to obtain a target node, wherein the matching is designed to eliminate the influence of node overload through a load balancing algorithm;
[0084] S4: using the improved Dijkstra algorithm to calculate the optimal path from the source node to the target node in the network topology undirected graph;
[0085] S5: According to the optimal path, corresponding routing rules are configured in the target distributed cluster through SRV6 network programming technology.
[0086] It should be noted that although SRv6 network programming technology has shown great potential in computing power perception and routing allocation, there are still some shortcomings and challenges in practical applications. These shortcomings are mainly reflected in the following aspects:
[0087] Insufficient real-time computing power perception and routing: The current SIDasaService research ideas and related technologies have insufficient real-time performance when facing dynamically changing business needs. Although the programming operation of extending SID can achieve a certain degree of flexibility, the existing methods are still unable to respond in a timely manner to high-frequency and instantaneous computing power requirements. This lack of real-time performance leads to a low comprehensive utilization rate of computing power resources and cannot give full play to the potential performance of the system.
[0088] Limited flexibility in computing resource scheduling: Existing computing power perception and routing algorithms are mainly based on preset strategies and static rules, and lack the ability to make real-time adjustments based on business status. In complex and ever-changing cloud environments and wide area networks, business needs and computing resource status often change rapidly, and static scheduling strategies are difficult to adapt to such changes, resulting in a lack of flexibility and adaptability in the scheduling of computing resources.
[0089] Insufficient coordination in cross-cloud and cloud-edge environments: In cross-cloud and cloud-edge wide area network environments, the coordinated scheduling and optimization of computing resources face great challenges. Existing computing routing technologies lack effective resource coordination mechanisms in cross-cloud and cloud-edge environments, resulting in low resource utilization and failure to fully utilize the performance advantages of each computing node.
[0090] Challenges of multi-dimensional resource perception and unified measurement: The state perception and unified measurement technology of multi-dimensional resources such as network, computing, and storage of State Grid Cloud has not yet fully matured. Existing technologies have certain technical difficulties in integrating and uniformly measuring different types of resources, resulting in deviations in the formulation and implementation of computing power scheduling strategies, affecting the performance and efficiency of the overall system.
[0091] The problem of resolution efficiency and accuracy of computing power gateway: When resolving SID, computing power gateway has the problem of resolution efficiency and accuracy. Due to the complexity of network environment and the diversity of business needs, computing power gateway is prone to delay and misjudgment during the resolution process, which affects the accurate routing and timely processing of computing power requests.
[0092] In summary, the current SRv6 network programming technology still has many deficiencies in achieving computing power perception and optimal routing, including insufficient real-time and flexibility, limited cross-cloud collaborative scheduling capabilities, challenges in multi-dimensional resource perception and measurement, and efficiency and accuracy issues in computing power gateway analysis. These defects need to be addressed through further research and technical improvements to achieve more efficient and flexible computing power resource scheduling and routing optimization.
[0093] The present invention proposes a computing power-aware routing allocation algorithm based on SRV6, using Figure 2 The SDN architecture shown, specifically, Figure 2 Shown is a schematic diagram of a cross-cloud environment SDN control plane design in one embodiment of the present invention.
[0094] Preferably, in one embodiment of the present invention, as one of the preferred solutions, the acquiring of the real-time resource status data of each of the nodes in the target distributed cluster includes:
[0095] Collect the real-time resource status data of each node in the target distributed cluster through Prometheus and node Exporter, and configure the collection cycle, wherein the real-time resource status data at least includes the CPU usage, GPU usage, memory occupancy and disk I / O of the computing device;
[0096] A multi-dimensional vector is constructed based on the real-time resource status data to obtain the computing resource vector of each node, which is expressed as:
[0097] S(node i )
[0098] =[node i (CPU),node i (GPU),node i (Mem),node i (IO)]
[0099] Among them, node i Represents the i-th node in the cluster, S(node i ) represents the computing resource vector of the i-th node, node i (CPU) represents the CPU resource usage of the i-th node, node i (GPU) represents the GPU resource usage of the i-th node, node i (Mem) represents the memory resource usage of the i-th node, node i (IO) represents the IO rate of the i-th node.
[0100] Specifically, the core of data collection is to obtain the resource usage of all nodes in the cluster, including but not limited to CPU usage, GPU usage, memory occupancy, disk I / O, network throughput and other resource indicators. The data is collected and displayed by prometheus and node exporter. In order to meet different monitoring needs, the collection cycle is configurable. By default, the system collects data every 10 seconds. This setting can ensure the real-time nature of the data and balance the performance overhead of the system.
[0101] The collected data is stored uniformly by the management system to record the status of all nodes in the cluster. The status can be used to describe the types of resources that the node can provide and its ability to provide resources. The status is expressed in a multidimensional vector, and each value of the vector represents a resource processing capability of the node.
[0102] This application classifies the resources that may be requested by the business. The basic resource requirement types of the business include the following: CPU resources, GPU resources, memory resources, and IO resources. In actual use, the business may require multiple resources at the same time. Therefore, this application proposes a multi-dimensional resource type calculation method. For each type of resource requirement business, including multiple types of resource requirements, the node allocation module can allocate the corresponding required resources. The decision of the business resource type is determined by the resource type requested by the business. The usage scenario of this application is in the Kubernetes cluster. In the cluster, users generally need to use yaml files to create resources. When creating a pod, the user will specify the required resource request. The system reads the corresponding fields from the yaml file to obtain the resource type required by the current business.
[0103] In actual applications, users may apply for multiple resources. Therefore, it is necessary to allocate multi-dimensional resource demand services to the nodes that best meet the requirements in each dimension. We cannot only consider one type of resource. When considering multiple dimensions, we must also consider the weight. For example, if a business is CPU intensive and requires a small amount of GPU resources, then we cannot simply set the weights of CPU and GPU to the same. Instead, we should appropriately increase the proportion of CPU resources and reduce the proportion of GPU resources. Based on the above ideas, this application proposes a routing node allocation calculation formula.
[0104] Preferably, in one embodiment of the present invention, the resource request data includes multi-dimensional resource requirements and corresponding weights of the service request;
[0105] The step of matching each node in the network topology undirected graph with the resource request data to obtain a target node includes:
[0106] The matching degree between each node in the network topology undirected graph and the resource request data is calculated according to the node allocation calculation formula, and the node allocation calculation formula is expressed as:
[0107] Score(node i )
[0108] =α cpu CPU+α gpu GPU+α mem Mem
[0109] +α io IO
[0110] Among them, Score(node i ) represents the matching degree between the i-th node and the resource request data, and its value range is [0,4], α x is the weight of different computing resource types in the score. CPU, GPU, Mem, and IO respectively represent the matching degree between the business request and the node on the computing resource of that type.
[0111] According to the matching degree, sorting each of the nodes;
[0112] According to the sorting result, a target node is obtained.
[0113] Specifically, the network topology needs to be modeled as an undirected graph, as shown in the following diagram: Figure 3 Specifically, Figure 3 It is shown as a schematic diagram of the network topology in one embodiment of the present invention. The nodes in the figure represent devices (such as servers, switches, etc.) in the network, and the edges represent the network connections between the nodes. In order to use the topology diagram in the algorithm, it is necessary to use information such as network latency and bandwidth as the weight of the edge. The iperf3 tool is used to measure the network performance between nodes, including latency and bandwidth. These measurement results are used to calculate the weight of the edge in the network topology: the round-trip time (RTT) between nodes is measured by iperf3. The lower the latency, the better the performance of the network path; the throughput between nodes is measured by iperf3. The higher the bandwidth, the stronger the transmission capacity of the network path. The weight calculation of the edge is to calculate the weight of the edge in the diagram based on the latency and bandwidth data measured by iperf3. The latency and bandwidth can be converted into weight values to synthesize a comprehensive edge weight.
[0114] According to the calculation results of the formula, each node in the network topology undirected graph is sorted from high to low, and the business is scheduled to the node with the highest score. If the business requires multiple nodes, the top n nodes are taken as the final node allocation.
[0115] Integrating the process of calculating the load balancing degree of the target node, determining the load balancing threshold, and selecting the target node based on these conditions into the original solution can further enhance the stability of the system and the rationality of resource allocation.
[0116] Preferably, in one embodiment of the present invention, before obtaining the target node according to the sorting result, the method further includes:
[0117] Calculating the load balancing degree of the target node;
[0118] Determining a load balancing threshold according to the target distributed cluster environment and the service request;
[0119] If the load balance degree of the target node exceeds the threshold, the next node with a lower load balance degree is selected as the new target node according to the sorting result; this process is repeated until a node with a load balance degree within the threshold range is found.
[0120] By introducing the calculation of load balancing and the setting of thresholds, the rationality of resource allocation and the stability of the system are further improved, providing strong support for building efficient and reliable distributed systems.
[0121] Preferably, in one embodiment of the present invention, the use of the improved Dijkstra algorithm to calculate the optimal path from the source node to the target node in the network topology undirected graph includes:
[0122] constructing a heuristic function for estimating a minimum distance from the source node to the target node;
[0123] Initialize a priority queue and add the source node to the priority queue;
[0124] During the extraction process, extracting a node with the minimum cost from the priority queue as the current expansion node, wherein the cost includes a source node cost and a heuristic value, wherein the heuristic value is calculated by the heuristic function;
[0125] During the judgment process, if the current extended node is the target node, the algorithm ends; otherwise, the cumulative cost of each neighbor node from the source node to the current extended node is calculated, and the position of the neighbor node in the priority queue is updated;
[0126] The extraction process and the judgment process are repeated until the target node is found, and the path from the source node to the target node is used as the optimal path.
[0127] The present invention uses the improved Dijkstra algorithm to obtain the shortest path in the network, that is, the path to the destination node the fastest. The input of the Dijkstra algorithm before the improvement includes:
[0128] A weighted directed graph G = (V, E), where V is the set of vertices, i.e., the routing nodes in the cluster, and E is the set of edges, i.e., the connections between the nodes in the cluster.
[0129] Each edge (u, v) in the graph has a non-negative weight w(u, v), which represents the path cost from node u to node v, that is, bandwidth, delay and other data.
[0130] A source node s∈V.
[0131] The output of Dijkstra includes:
[0132] The shortest path distance d(s,v) from the source node s to all other nodes v∈V in the graph.
[0133] The predecessor node array p(v) is used to reconstruct the shortest path from s to v.
[0134] The steps of Dijkstra algorithm are as follows:
[0135] 1) Initialization
[0136] For each node v∈V, set the shortest path estimate d(s,v) to infinity (i.e., d(s,v)=∞), and set the shortest path estimate of the source node s to 0, i.e., d(s,s)=0.
[0137] Initialize an empty predecessor node array p(v), where p(v) = null.
[0138] Create a priority queue Q and sort all nodes v∈V according to the value of d(s,v).
[0139] 2) Main loop
[0140] When the priority queue Q is not empty, the following steps are performed:
[0141] Extract the node u with the minimum d(s,u) value from Q.
[0142] For each adjacent node v belonging to the adjacent set Adj(u) of u, perform the following steps:
[0143] Calculate the path distance from s to v via u: d(s,u)+w(u,v).
[0144] If d(s, u) + w(u, v) < d(s, v), then update the shortest path estimate d(s, u) to d(s, u) + w(u, v), and set the predecessor node p(v) to u.
[0145] Update the position of v in the priority queue Q to reflect the new shortest path estimate.
[0146] 3) Termination
[0147] When all nodes have been processed, i.e., Q is empty, the algorithm terminates.
[0148] Finally, d(s, v) will represent the shortest path length from the source node s to all other nodes v, and p(v) can be used to backtrack to obtain the shortest path.
[0149] In the case of using a binary heap to implement the priority queue, the time complexity of Dijkstra's algorithm is O((|V| + |E|) log |V|), where |V| is the number of vertices and |E| is the number of edges.
[0150] This application uses an improved Dijkstra's algorithm to calculate the optimal path, incorporating the idea of heuristic search, especially the use of the priority queue and heuristic function, to find the optimal path from the source node to the target node in an undirected graph of network topology, which can ensure the lowest latency and the highest bandwidth utilization when data packets are transmitted in the network.
[0151] The final routing path obtained by the above improved Dijkstra's algorithm is the final routing path obtained by the present invention. This path is the fastest routing path from the current node to the most suitable node. This patent is based on the SRV6 network programming technology to control node routing. The routing control based on SRV6 is designed as follows:
[0152] SRv6 achieves flexible control based on source routing by utilizing the Segment Identifier (SID) in the IPv6 address. SRv6 is an IPv6-based source routing mechanism that allows encoding the routing path as a series of IPv6 addresses, which are the SIDs. By carrying these SIDs in the SRv6 routing extension header of the packet header, data packets can pass through the network along a predetermined path.
[0153] The SID is a 128-bit IPv6 address that represents a segment in the network path. The SID can represent different types of network operations, such as forwarding, translation, or network services, etc. By combining multiple SIDs, SRv6 can achieve complex network path programming without relying on traditional protocols.
[0154] In a cross-cloud environment, Kubernetes clusters are deployed on each cloud platform, and communication between clusters is achieved through Linux kernel soft routers configured in each cluster. These soft routers support the SRv6 protocol and can process and forward IPv6 packets with SIDs, thereby achieving fine control over network paths.
[0155] The core component of routing management: pyroute2, pyroute2 is a powerful Python library for network interface management in Linux systems, including operations on routes, links, flow rules, addresses, etc. In the design of the SRv6 controller, pyroute2 acts as a low-level interface to help the controller interact with the kernel's routing subsystem. By using this library, the controller can easily create, update, delete, and query the status of SRv6 paths.
[0156] Route management operations:
[0157] Creating Paths: pyroute2 allows the controller to define SRv6 paths, specifying the destination address, source address, and a list of Segment IDs (SIDs) that need to be passed along the path. Through a flexible path creation mechanism, the controller can support service programming requirements in the network.
[0158] Delete path: When a path fails or resources are reallocated, the controller can call pyroute2 to clean up existing paths to ensure efficient use of network resources and avoid routing confusion.
[0159] Query path status: Through pyroute2, the controller can obtain the status information of the current path in real time, including whether the path is unobstructed, the current traffic status, etc. This provides data support for network operation and maintenance and fault diagnosis.
[0160] Path management based on data dictionary. In order to effectively manage a large number of SRv6 paths, the controller uses a data dictionary to organize and store the paths. Each path is represented by a specific key-value pair, including specific operations on the path (addition, deletion, modification, and query), as well as detailed information on the path (such as destination address, SID list, encapsulation mode, forwarding network card, etc.). This design makes path search, modification, and deletion fast and efficient. The design of the path dictionary is as follows: Figure 4 Specifically, Figure 4 A schematic diagram showing an example of a data dictionary of an SRv6 controller in one embodiment of the present invention is shown.
[0161] REST API interaction with routers,The SRv6 controller interacts with the routers in the network through the REST API, ensuring that the controller can dynamically manage network paths and implement service programming.,REST API allows the controller to communicate with the rest_server on the router and send management instructions to the router.
[0162] Scalability and programming capabilities. The SRv6 controller can achieve more flexible and customized network programming capabilities by expanding the application of SID (Segment ID). Each SID can not only represent a certain hop in the network, but also represent a specific service or functional module (such as load balancing, NAT, etc.). Through the joint programming of SID, the controller can orchestrate complex service links to meet different business needs:
[0163] Service path programming: By inserting different SIDs in the path, the controller can call service functions. For example, a certain SID can represent a firewall service, and another SID can represent a traffic monitoring service. By combining these SIDs, business requests can be transmitted along the service chain in sequence to obtain the corresponding services.
[0164] Scalability: The scalability of SIDs enables the SRv6 controller to easily adapt to future network requirements and service changes. As services are added or updated, the controller can easily adjust the path by updating the SID list without making large-scale changes to the underlying network.
[0165] In terms of network topology discovery, this algorithm obtains topology information from Linux soft routers through REST and dynamically updates the routing table of cross-cloud networks by combining the flexibility of SRv6 Segment. The algorithm uses customized topology structure analysis and optimization strategies to ensure the accuracy and efficiency of multi-path routing in cross-cloud environments.
[0166] In terms of computing resource management, the algorithm uses the computing status data of distributed nodes to build a real-time dynamic computing perception model. By introducing weight factors and priority strategies, the system can automatically select the optimal path to ensure that business requests are always assigned to the node with the strongest computing power, thereby improving the overall service quality and response speed.
[0167] In terms of computing power scheduling strategy, this algorithm combines Kubernetes' container orchestration technology to design a cross-cloud, cloud-edge integrated computing power scheduling mechanism. By expanding the programming capabilities of SID, the system implements refined routing and dynamic load balancing of service requests, effectively reduces network latency, optimizes resource utilization, and achieves efficient scheduling of computing power resources in a cross-cloud environment.
[0168] Compared with the prior art, the embodiments of the present invention have the following advantages:
[0169] 1) Improve resource allocation efficiency: By obtaining the resource status data of the node in real time and matching it according to business needs, resources can be allocated efficiently and reasonably. The application of load balancing algorithms further eliminates the risk of node overload and improves the stability and reliability of the entire distributed cluster.
[0170] 2) Optimize network performance: Using the improved Dijkstra algorithm to calculate the optimal path can ensure that data packets have the lowest latency and highest bandwidth utilization when transmitted in the network. This is crucial to improving the overall performance of the network and user experience.
[0171] 3) Enhanced network programmability and flexibility: The application of SRv6 network programming technology allows network administrators to flexibly configure and manage the network according to business needs. Through programming, it is easy to dynamically adjust and optimize network resources to adapt to changing business needs.
[0172] 4) Support large-scale network deployment: SRv6 leverages the scalability of IPv6 to provide the network with a larger address space and richer functions, thereby supporting larger-scale and more complex network scenarios.
[0173] Another embodiment of the present invention provides a device for predicting mooring tension in a time-varying marine environment. For details, see Figure 5 , Figure 5 The figure shows a schematic diagram of a computing power-aware routing allocation system based on SRV6 provided in one embodiment of the present invention, which includes: a construction module 11, an acquisition module 12, a matching module 13, a calculation module 14, and a planning module 15, wherein:
[0174] A construction module is used to construct a network topology undirected graph based on a target distributed cluster, wherein nodes of the undirected graph represent computing devices and edge weights are determined according to latency and bandwidth;
[0175] An acquisition module, configured to acquire real-time resource status data of each of the nodes in the target distributed cluster in response to a service request, and parse the service request to obtain resource request data;
[0176] A matching module, used to match each node in the network topology undirected graph with the resource request data to obtain a target node, wherein the matching is designed to eliminate the influence of node overload through a load balancing algorithm;
[0177] A calculation module, used for calculating the optimal path from the source node to the target node in the network topology undirected graph using the improved Dijkstra algorithm;
[0178] The planning module is used to configure corresponding routing rules in the target distributed cluster according to the optimal path through SRV6 network programming technology.
[0179] Preferably, in one embodiment of the present invention, the acquisition module is specifically used to:
[0180] Collect the real-time resource status data of each node in the target distributed cluster through Prometheus and node Exporter, and configure the collection cycle, wherein the real-time resource status data at least includes the CPU usage, GPU usage, memory occupancy and disk I / O of the computing device;
[0181] A multi-dimensional vector is constructed based on the real-time resource status data to obtain the computing resource vector of each node, which is expressed as:
[0182] S(node i )
[0183] =[node i (CPU),node i (GPU),node i (Mem),node i (IO)]
[0184] Among them, node i Represents the i-th node in the cluster, S(node i ) represents the computing resource vector of the i-th node, node i (CPU) represents the CPU resource usage of the i-th node, node i (GPU) represents the GPU resource usage of the i-th node, node i (Mem) represents the memory resource usage of the i-th node, node i (IO) represents the IO rate of the i-th node.
[0185] Preferably, in one embodiment of the present invention, the resource request data includes multi-dimensional resource requirements and corresponding weights of the service request;
[0186] The matching module is specifically used for:
[0187] The matching degree between each node in the network topology undirected graph and the resource request data is calculated according to the node allocation calculation formula, and the node allocation calculation formula is expressed as:
[0188] Score(node i )
[0189] =α cpu CPU+α gpu GPU+α mem Mem
[0190] +α io IO
[0191] Among them, Score(node i ) represents the matching degree between the i-th node and the resource request data, and its value range is [0,4], α x is the weight of different computing resource types in the score. CPU, GPU, Mem, and IO respectively represent the matching degree between the business request and the node on the computing resource of that type.
[0192] According to the matching degree, sorting each of the nodes;
[0193] According to the sorting result, a target node is obtained.
[0194] Preferably, in one embodiment of the present invention, the matching module is further used for:
[0195] Calculating the load balancing degree of the target node;
[0196] Determining a load balancing threshold according to the target distributed cluster environment and the service request;
[0197] If the load balance degree of the target node exceeds the threshold, the next node with a lower load balance degree is selected as the new target node according to the sorting result; this process is repeated until a node with a load balance degree within the threshold range is found.
[0198] Preferably, in one embodiment of the present invention, the calculation module is used to:
[0199] constructing a heuristic function for estimating a minimum distance from the source node to the target node;
[0200] Initialize a priority queue and add the source node to the priority queue;
[0201] During the extraction process, a node with the minimum cost is extracted from the priority queue as the current expansion node, wherein the cost includes a source node cost and a heuristic value, wherein the heuristic value is calculated by the heuristic function;
[0202] During the judgment process, if the current extended node is the target node, the algorithm ends; otherwise, the cumulative cost of each neighbor node from the source node to the current extended node is calculated, and the position of the neighbor node in the priority queue is updated;
[0203] The extraction process and the judgment process are repeated until the target node is found, and the path from the source node to the target node is used as the optimal path.
[0204] The above-mentioned embodiments only express several implementation methods of the present invention, and the description thereof is relatively specific and detailed, but it cannot be understood as limiting the scope of the patent of the present invention. It should be pointed out that, for ordinary technicians in this field, several variations and improvements can be made without departing from the concept of the present invention, which all belong to the protection scope of the present invention. Therefore, the protection scope of the patent of the present invention shall be subject to the attached claims.
Claims
1. A computing power-aware routing allocation method based on SRV6, characterized in that: include: Based on the target distributed cluster, construct a network topology undirected graph, wherein the nodes of the undirected graph represent computing devices, and the weights of the edges are determined according to latency and bandwidth; In response to a service request, obtaining real-time resource status data of each of the nodes in the target distributed cluster, and parsing the service request to obtain resource request data; Matching each node in the network topology undirected graph with the resource request data to obtain a target node, wherein the matching is designed to eliminate the influence of node overload through a load balancing algorithm; Using the improved Dijkstra algorithm to calculate the optimal path from the source node to the target node in the network topology undirected graph; According to the optimal path, corresponding routing rules are configured in the target distributed cluster through SRV6 network programming technology to allocate computing resources for the business request.
2. The computing power-aware routing allocation method based on SRV6 according to claim 1 is characterized in that: The acquiring of real-time resource status data of each of the nodes in the target distributed cluster includes: Collect the real-time resource status data of each node in the target distributed cluster through Prometheus and node Exporter, and configure the collection cycle, wherein the real-time resource status data at least includes the CPU usage, GPU usage, memory occupancy and disk I / O of the computing device; A multi-dimensional vector is constructed based on the real-time resource status data to obtain the computing resource vector of each node, which is expressed as: S(node i ) =[no$e i (CPU),node i (CPU),node i (More),node i (10)] Among them, node i Represents the i-th node in the cluster, S(node i ) represents the computing resource vector of the i-th node, node i (CPU) represents the CPU resource usage of the i-th node, node i (GPU) represents the GPU resource usage of the i-th node, node i (Mem) represents the memory resource usage of the i-th node, node i (IO) represents the IO rate of the i-th node.
3. The computing power-aware routing allocation method based on SRV6 according to claim 1 is characterized in that: The resource request data includes the multi-dimensional resource requirements and corresponding weights of the business request; The step of matching each node in the network topology undirected graph with the resource request data to obtain a target node includes: The matching degree between each node in the network topology undirected graph and the resource request data is calculated according to the node allocation calculation formula, and the node allocation calculation formula is expressed as: Score(node i ) =a cpu CPU+a gpu GPU+a mem Mem+a io IO Among them, Score(node i ) represents the matching degree between the i-th node and the resource request data, and its value range is [0,4], α x is the weight of different computing resource types in the score. CPU, GPU, Mem, and IO respectively represent the matching degree between the business request and the node on the computing resource of that type. According to the matching degree, sorting each of the nodes; According to the sorting result, a target node is obtained.
4. The computing power-aware routing allocation method based on SRV6 according to claim 3 is characterized in that: Before obtaining the target node according to the sorting result, the method further includes: Calculating the load balancing degree of the target node; Determining a load balancing threshold according to the target distributed cluster environment and the service request; If the load balance degree of the target node exceeds the threshold, the next node with a lower load balance degree is selected as the new target node according to the sorting result; this process is repeated until a node with a load balance degree within the threshold range is found.
5. The computing power-aware routing allocation method based on SRV6 according to claim 1 is characterized in that: The method of using the improved Dijkstra algorithm to calculate the optimal path from the source node to the target node in the network topology undirected graph includes: Constructing a heuristic function, the heuristic function being used to estimate the minimum distance from the source node to the target node; Initialize a priority queue and add the source node to the priority queue; During the extraction process, a node with the minimum cost is extracted from the priority queue as the current expansion node, wherein the cost includes a source node cost and a heuristic value, wherein the heuristic value is calculated by the heuristic function; During the judgment process, if the current extended node is the target node, the algorithm ends; otherwise, the cumulative cost of each neighbor node from the source node to the current extended node is calculated, and the position of the neighbor node in the priority queue is updated; The extraction process and the judgment process are repeated until the target node is found, and the path from the source node to the target node is used as the optimal path.
6. A computing power-aware routing allocation system based on SRV6, characterized in that: include: A construction module is used to construct a network topology undirected graph based on the target distributed cluster, wherein the nodes of the undirected graph represent computing devices and the weights of the edges are determined according to latency and bandwidth; An acquisition module, configured to acquire real-time resource status data of each of the nodes in the target distributed cluster in response to a service request, and parse the service request to obtain resource request data; A matching module, used to match each node in the network topology undirected graph with the resource request data to obtain a target node, wherein the matching is designed to eliminate the influence of node overload through a load balancing algorithm; A calculation module, used for calculating the optimal path from the source node to the target node in the network topology undirected graph using the improved Dijkstra algorithm; The planning module is used to configure corresponding routing rules in the target distributed cluster according to the optimal path through SRV6 network programming technology to allocate computing power resources for the business request.
7. The computing power-aware routing allocation system based on SRV6 according to claim 6, characterized in that: The acquisition module is specifically used for: Collect the real-time resource status data of each node in the target distributed cluster through Prometheus and node Exporter, and configure the collection cycle, wherein the real-time resource status data at least includes the CPU usage, GPU usage, memory occupancy and disk I / O of the computing device; A multi-dimensional vector is constructed based on the real-time resource status data to obtain the computing resource vector of each node, which is expressed as: S(node i ) =[node i (CPU),node i (GPU),node i (Mem),node i (IO)] Among them, node i Represents the i-th node in the cluster, S(node i ) represents the computing resource vector of the i-th node, node i (CPU) represents the CPU resource usage of the i-th node, node i (GPU) represents the GPU resource usage of the i-th node, node i (Mem) represents the memory resource usage of the i-th node, node i (IO) represents the IO rate of the i-th node.
8. The computing power-aware routing allocation system based on SRV6 according to claim 6, characterized in that: The resource request data includes the multi-dimensional resource requirements and corresponding weights of the business request; The matching module is specifically used for: The matching degree between each node in the network topology undirected graph and the resource request data is calculated according to the node allocation calculation formula, and the node allocation calculation formula is expressed as: Score(node i ) =a cpu CPU+a gpu GPU+a mem Mem+a io IO Among them, Score(node i ) represents the matching degree between the i-th node and the resource request data, and its value range is [0,4], α x is the weight of different computing resource types in the score. CPU, GPU, Mem, and IO respectively represent the matching degree between the business request and the node on the computing resource of that type. According to the matching degree, sorting each of the nodes; According to the sorting result, a target node is obtained.
9. The computing power-aware routing allocation system based on SRV6 according to claim 8, characterized in that: The matching module is further used for: Calculating the load balancing degree of the target node; Determining a load balancing threshold according to the target distributed cluster environment and the service request; If the load balancing degree of the target node exceeds the threshold, the next node with a lower load balancing degree is selected as the new target node according to the sorting result; This process is repeated until a node with a load balance degree within the threshold range is found.
10. The SRV6-based computing power-aware routing allocation system according to claim 6, characterized in that: The computing module is used for: Constructing a heuristic function, the heuristic function being used to estimate the minimum distance from the source node to the target node; Initialize a priority queue and add the source node to the priority queue; During the extraction process, a node with the minimum cost is extracted from the priority queue as the current expansion node, wherein the cost includes a source node cost and a heuristic value, wherein the heuristic value is calculated by the heuristic function; During the judgment process, if the current extended node is the target node, the algorithm ends; otherwise, the cumulative cost of each neighbor node from the source node to the current extended node is calculated, and the position of the neighbor node in the priority queue is updated; The extraction process and the judgment process are repeated until the target node is found, and the path from the source node to the target node is used as the optimal path.
Citation Information
Cited By
High-performance computing power network construction method based on SRv6 and DPU
CN120301814A
A high-performance computing power network construction method based on SRv6 and DPU
CN120301814B
Data storage method and system in distributed heterogeneous environment
CN120750931A
Distributed service management method and system
CN120785883A