Distributed consistency transmission method based on low-orbit satellite constellation network
Through the distributed consistent transmission method based on raft algorithm, the leader election and log replication process in low-orbit satellite networks is optimized, the problems of network isolation and frequent leader collapse are solved, and the system's response speed and high concurrency processing capabilities are improved.
Patent Information
- Application Number
- CN202411712889.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Priority Date
- 2024-05-17
- Filing Date
- 2024-11-27
- Publication Date
- 2025-07-04
AI Technical Summary
Existing distributed consistency methods have problems in low-orbit satellite networks such as network isolation, frequent leader node crashes and time-consuming log replication.
The distributed consistent transmission method based on the raft algorithm is adopted to optimize the leader election and log replication process through state transition between managers, followers, preparatory candidates and candidates, and use heartbeat information and term management to achieve efficient communication and fault tolerance between nodes.
It improves the efficiency of leader elections in satellite networks, shortens system response time, reduces the impact of network isolation and leader failure on the system, and optimizes the response performance in high concurrency situations.
Smart Images

Figure CN120263256A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to a distributed consistency transmission method based on a low-earth orbit satellite constellation network, belonging to the technical field of low-earth orbit satellite data transmission. Background Art
[0002] Due to the small coverage area of a single low-earth orbit satellite, a large number of satellites are required to form a network together. Compared with other orbit types, the communication of low-earth orbit satellites has shorter communication latency and lower bandwidth cost. However, it also has a larger communication system scale and higher maintenance cost.
[0003] When the existing distributed consistency methods are applied to satellite networks, the following problems exist:
[0004] Different from the ground network environment, the nodes in the satellite network are all moving at high speed, and there is a considerable distance between them. Therefore, it may cause the network connection to be unstable, and then lead to the problem of network isolation. Once a non-leader node has a network isolation problem, it will not be able to receive heartbeat information and mistakenly think that there is no suitable leader node in the cluster. After it resumes the connection and gets out of the network isolation state, it will initiate an election.
[0005] In addition, sometimes the leader node needs to be restarted for updates, and due to the relatively harsh outer space environment, the satellite nodes have a higher probability of failure and cannot work properly; the latency in the satellite network is higher than that in the ground network. In the case where the network condition of the leader node is poor and the network latency is high, it is no longer suitable to act as the leader.
[0006] During the process of log replication, after receiving a client's request, the leader node will package the log and replicate it to each follower node. Then, after receiving the confirmation information from the majority of nodes, it will submit this log and notify other follower nodes to also submit this log. That is to say, for each log submission, the leader node needs to spend a lot of time interacting with the other nodes multiple times and waiting for a reply.
[0007] Therefore, how to solve the problems of network isolation, frequent leader node crashes, and long log replication time generated by applying the existing distributed consistency methods to satellite networks has become an urgent problem to be solved. Summary of the Invention
[0008] The purpose of the present invention is to solve the technical problems of network isolation, frequent leader node crashes, and long log replication time generated by applying the existing distributed consistency methods to satellite networks, and to propose a distributed consistency transmission method based on a low-earth orbit satellite constellation network.
[0009] The purpose of the present invention is achieved through the following technical solutions:
[0010] A distributed consensus transmission method based on a low-earth orbit satellite constellation network, comprising the following steps:
[0011] Step 1: The states of the low-earth orbit satellite network cluster nodes include an initial state, a management state, and an operating state.
[0012] Step 1.1: The member nodes in the initial state of the low-earth orbit satellite network cluster include a manager, a follower, a pre-candidate, and a candidate based on the raft algorithm.
[0013] Step 1.2: The initial state of the above-mentioned member nodes obtained according to Step 1.1 is a follower.
[0014] Step 2: The follower member nodes obtained according to Step 1.2 enter the management state.
[0015] Step 2.1: In a term, a follower initiates a vote election and sets its own node to become a member node candidate.
[0016] Step 2.2: The candidate obtained according to Step 2.1 sends a message to request votes from followers other than itself in the immediately next monotonically increasing term.
[0017] Step 2.2.1: The candidate obtained according to Step 2.2 proceeds to Step 2.2.3 if it obtains more than half of the votes of all member nodes.
[0018] Step 2.2.2: The candidate obtained according to Step 2.2 proceeds to Step 2.2.5 if it obtains less than or equal to half of the votes of all member nodes.
[0019] Step 2.2.3: The candidate obtained according to Step 2.2.1 sets its own node to become a member node manager when there is no manager heartbeat information.
[0020] Step 2.2.4: The candidate obtained according to Step 2.2.1 sets its own node to become a member node follower when there is manager heartbeat information.
[0021] Step 2.2.5: The candidate obtained according to Step 2.2.2 returns to Step 2.1 when there is no manager heartbeat information.
[0022] Step 2.2.6: The member node manager obtained according to Step 2.2.3 sends a heartbeat message to followers other than itself to confirm that it is the manager.
[0023] Step 2.2.7: The number of member node managers obtained according to Step 2.2.6 is 1.
[0024] Step 2.3: In a term, a follower discovers the heartbeat information of the manager.
[0025] Step 2.3.1: According to the followers obtained in Step 2.3, when there is no manager heartbeat information, go to Step 4.
[0026] Step 2.3.2: According to the followers obtained in Step 2.3, when there is manager heartbeat information, receive the manager's log entries and submit the log to the manager.
[0027] Step 3: The member node manager obtained according to Step 2.2.7 enters the running state.
[0028] Step 3.1: The manager packs the requests from the client into a log.
[0029] Step 3.2: According to the log obtained in Step 3.1, establish a corresponding index marker to form a log entry. The log entry and the set of logs constitute a log list.
[0030] Step 3.3: The manager synchronizes the log to the followers. Thus, the distributed consistency transmission is completed.
[0031] Step 4: When the network connection of the low-earth orbit satellite network cluster nodes is abnormal, the member nodes are in an isolated state, and the low-earth orbit satellite network cluster nodes are reconnected;
[0032] Step 4.1: When the manager is in an isolated state, increment the term monotonically by 1 and initiate a vote for the next term to elect a manager for the next term with a term number higher than its own; convert its own node to a member node follower;
[0033] Step 4.2: When a follower or candidate is in an isolated state, the follower sets its own node to a member node pre-candidate and broadcasts to other member nodes to determine the state of the member nodes;
[0034] Step 4.2.1: When other member nodes and the pre-candidate belong to the same term, set the pre-candidate's own node to a member node candidate and go to Step 2.1;
[0035] Step 4.2.2: When other member nodes and the pre-candidate do not belong to the same term, increment the term monotonically by 1 and initiate a vote for the next term;
[0036] A distributed consistency transmission system based on a low-earth orbit satellite constellation network disclosed by the present invention is used to implement the above method. A distributed consistency transmission system based on a low-earth orbit satellite constellation network disclosed by the present invention includes a network forwarding module, a leader election module, and a log replication module.
[0037] The network forwarding module is used for the leader node to receive client requests and add the requests to the end of the leader node's queue for processing;
[0038] The leader election module is used to elect a leader node from among the nodes in a term through an election voting method, and to handle the nodes of low-earth orbit satellites through heartbeat information processing; thereby improving the fault tolerance and response speed of node request processing;
[0039] The log replication module is used to package client requests under the mapping relationship between the term and the log index;
[0040] Beneficial effects:
[0041] The present invention has the effects brought about by improvements in the following aspects.
[0042] 1. The present invention is deployed in a satellite network environment. When a certain follower node or candidate node is disconnected from other nodes or there is network isolation interference, this method can avoid the chaos of the election process caused by an increase in the term when the node rejoins, thereby improving the working efficiency of the algorithm.
[0043] 2. When the leader node in the cluster cannot continue to work properly due to a fault or other reasons, or because the network delay is too large and it is no longer suitable to act as the leader node, this method can help it actively designate the next leader, saving the time for the algorithm to conduct a random election and improving the election efficiency.
[0044] 3. In the face of high concurrency, this method uses a buffer to store incoming client requests, and packs multiple logs for batch synchronization at an appropriate time, saving the time-consuming of interaction communication between the leader and follower nodes, and improving the average response delay performance of the system when a large number of requests arrive simultaneously. Description of the drawings
[0045] Figure 1 It is a schematic diagram of the state transition diagram of the present invention;
[0046] Figure 2 It is a schematic diagram of the preliminary candidate process of the present invention;
[0047] Figure 3 It is a comparison result graph of the cumulative time used for cluster election when adding network isolation interference in the simulation experiment;
[0048] Figure 4 It is a comparison result graph of the leader crash recovery time in the simulation experiment;
[0049] Figure 5 It is a comparison result graph of the average response delay in the high-concurrency scenario of the simulation experiment. Detailed implementation manners
[0050] To better illustrate the objectives and advantages of the present invention, the following further describes the content of the invention in conjunction with the accompanying drawings and examples. It should be noted that the implementation of the present invention is not limited to the following examples, and any formal modification or change to the present invention will fall within the protection scope of the present invention.
[0051] Embodiment
[0052] As Figure 1 shown, a distributed consistency transmission method based on a low-earth orbit satellite constellation network is specifically implemented as follows:
[0053] Step 1: The states of the low-earth orbit satellite network cluster nodes include the initial state, the management state, and the running state.
[0054] Step 1.1: The member nodes in the initial state of the low-earth orbit satellite network cluster include the manager, the follower, the pre-candidate, and the candidate based on the raft algorithm.
[0055] Step 1.2: The initial state of the above-mentioned member nodes obtained according to Step 1.1 is the follower.
[0056] Step 2: The member node follower obtained according to Step 1.2 enters the management state.
[0057] Step 2.1: In a term, the follower initiates a vote election and sets its own node to turn into a member node candidate.
[0058] Step 2.2: The candidate obtained according to Step 2.1 sends a message to request a vote from the followers other than itself in the next immediately following term with a monotonically increasing number.
[0059] Step 2.2.1: The candidate obtained according to Step 2.2 proceeds to Step 2.2.3 according to the votes obtained being greater than half of all the member nodes.
[0060] Step 2.2.2: The candidate obtained according to Step 2.2 proceeds to Step 2.2.5 according to the votes obtained being less than or equal to half of all the member nodes.
[0061] Step 2.2.3: The candidate obtained according to Step 2.2.1 sets its own node to turn into a member node manager when there is no manager heartbeat information.
[0062] Step 2.2.4: The candidate obtained according to Step 2.2.1 sets its own node to turn into a member node follower when there is manager heartbeat information.
[0063] Step 2.2.5: The candidate obtained according to Step 2.2.2 goes back to Step 2.1 when there is no manager heartbeat information.
[0064] Step 2.2.6: The member node manager obtained in step 2.2.3 sends a heartbeat message to followers other than itself to confirm that it is the manager.
[0065] Step 2.2.7: The number of member node managers obtained in step 2.2.6 is 1.
[0066] Step 2.3: Followers discover the heartbeat message of the manager within one term.
[0067] Step 2.3.1: For the followers obtained in step 2.3, when there is no heartbeat message of the manager, go to step 4.
[0068] Step 2.3.2: For the followers obtained in step 2.3, when there is a heartbeat message of the manager, receive the log entries of the manager and submit the log to the manager.
[0069] Step 3: The member node manager obtained in step 2.2.7 enters the running state.
[0070] Step 3.1: The manager packs the requests from the client into a log.
[0071] Step 3.2: An index marker corresponding to the log obtained in step 3.1 is established to form a log entry. The log entry and the set of logs constitute a log list.
[0072] Step 3.3: The manager synchronizes the log to the followers. Thus, the distributed consistency transmission is completed.
[0073] In the embodiment, a polar-orbiting satellite constellation is constructed using STK and OPNET simulation software, which includes a total of 2N + 1 orbital planes. There are 12 LEO satellites evenly distributed on each orbital plane, with a total of 12×(2N + 1) satellites. The semi-major axis of the orbit is set to 6878.14 km, a circular orbit is adopted, and the eccentricity is 0. In addition, the inclination of the orbit is 97.4°, and the argument of perigee is set to 0°. On the same orbital plane, the phase difference between two adjacent satellites is 30° to ensure uniform satellite distribution and wide coverage within the constellation. One satellite is randomly selected from each orbital plane to participate in the election.
[0074] Step 4: When the network connection of the low-earth orbit satellite network cluster nodes is abnormal, the member nodes are in an isolated state, and the low-earth orbit satellite network cluster nodes are reconnected;
[0075] Step 4.1: When the manager is in an isolated state, increment the term monotonically by 1 and initiate a vote for the next term to obtain the manager of the next term with a term number higher than its own; convert its own node to a member node follower;
[0076] In the embodiment, the communication delay standard value τ is set according to specific requirements. At the same time, after the leader sends heartbeat information to the remaining nodes each time, it records the response delay of receiving the confirmation information returned by each node. When the delay of the leader node receiving the response information from most follower nodes exceeds the standard value, it is determined that the current leader has too long a delay and is no longer suitable to serve as the leader. It is necessary to select a node that meets the communication delay standard and has the fastest response from the followers and transfer the leadership to this node. After the leader node sends heartbeat information to the remaining nodes, it records the response delay of the information returned by each follower node and checks its own communication status accordingly. When the response delays of more than nodes exceed τ, the communication delay status of the remaining nodes is checked. Otherwise, it indicates that the communication status of the leader node is normal. Further, the node with the shortest response delay is selected from the followers. If its response delay t≥τ, it meets the communication delay standard and is used as the designated node for leadership transfer. Otherwise, it indicates that no node meets the communication delay standard and there is no need to perform the leadership transfer operation.
[0077] Step 4.2: When a follower or candidate is in an isolated state, the follower sets its own node to become a candidate for a member node and broadcasts to other member nodes to judge the status of the member nodes;
[0078] Step 4.2.1: When other member nodes and the candidate belong to the same term, set the candidate to become a candidate for a member node and go to Step 2.1;
[0079] Step 4.2.2: When other member nodes and the candidate do not belong to the same term, increase the term monotonically by 1 and initiate a vote for the next term;
[0080] In the embodiment, such as Figure 2As shown in the figure, first, since the follower does not receive the leader heartbeat message due to timeout, it transforms into a pre-candidate role. The pre-candidate broadcasts the PreCandidateRPC message designed above to other nodes in the cluster to apply for qualification review. Secondly, after receiving the PreCandidateRPC message, other nodes first compare their own term with that of the pre-candidate to determine whether it is an outdated node. If PreC_Term ≥ Current_Term, it means that this node is in the same term or newer than itself, meeting the election requirements, and proceeds to the next review. Otherwise, it means that it is an outdated node, and directly returns false along with the Current_Term value for this node to update. Thirdly, after passing the check of the node term number, other nodes will further compare the term number (lastLogTerm) and index number (lastLogIndex) of the last synchronized log to ensure that this node has the latest log update. If lastLogTerm is larger than its own, or lastLogTerm is the same and lastLogIndex is the same as or larger than the last one in its own log queue, it means that this node has the same or even newer log entries, meeting the requirements, and returns true to agree to its initiation of the election. Otherwise, it means that it has not received the latest log update, and directly returns false along with the Current_Term value. Then, when the pre-candidate receives more than half of the consent votes, that is then this node passes the qualification review, increments CurrentTerm by 1, and transforms its identity into a formal candidate, and then continues to initiate the formal voting session. When there is a Term ≥ Curren_Term in the responses received by the pre-candidate, it means that there are nodes with updated status in the cluster, and it immediately transforms its identity into a follower. When the pre-candidate does not receive enough consent vote responses within the specified time, it means that this node fails the qualification review and transforms its identity into a follower.
[0081] A distributed consistency transmission system based on a low-earth orbit satellite constellation network disclosed by the present invention is used to implement the above method. A distributed consistency transmission system based on a low-earth orbit satellite constellation network disclosed by the present invention includes a network forwarding module, a leader election module, and a log replication module.
[0082] The network forwarding module is used for the leader node to receive the client request and add the request to the end of the leader node's queue for processing;
[0083] The leader election module is used to elect a leader node for the nodes of the low-earth orbit satellite in a way of voting during the term, and to promote the fault tolerance and response speed of the node to process requests;
[0084] The log replication module is used to package the client requests under the mapping relationship between the term and the log index.
[0085] To further demonstrate the superiority of the present invention, the present invention uses simulation experiments to verify the effect of the present invention. The number of election nodes in the cluster satisfies the condition of 2N + 1. Five tracks, seven tracks, and nine tracks are respectively established in the experiment, and the rest of the settings are the same. Each group repeats 100 experiments, and the average value of the experimental data is taken.
[0086] Regarding the comparison of the cumulative time used for cluster election when adding network isolation interference, as Figure 3 shown. When there are 5 nodes in the cluster, 45.0% of the election time is saved; when there are 7 nodes in the cluster, 51.0% of the election time is saved; when there are 9 nodes in the cluster, 50.6% of the election time is saved.
[0087] Regarding the comparison of the time used for leader crash recovery, as Figure 4 shown. When there are 5 nodes in the cluster, the leader recovery is completed by saving 26.6% of the time; when there are 7 nodes in the cluster, the leader recovery is completed by saving 21.3% of the time; when there are 9 nodes in the cluster, the leader recovery is completed by saving 14.3% of the time.
[0088] Regarding the comparison of the average response delay in a high-concurrency scenario, as Figure 5 shown. When the number of requests is sent by 10, 15, and 20 clients, the response delay hardly changes, and there is a certain improvement compared with the original Raft algorithm.
[0089] In addition, it should be noted that for the specific embodiments described in this specification, the names taken may be different. The above content described in this specification is only an example of the structure of the present invention. Any equivalent changes or simple changes made according to the structure, features, and principles conceived by the present invention are included in the protection scope of the present invention. Those skilled in the art of the present invention can make various modifications or supplements to the described specific examples or use similar methods, as long as they do not deviate from the structure of the present invention or exceed the scope defined by this claim, they should belong to the protection scope of the present invention.
Claims
1. A distributed consensus transmission method based on a low-earth orbit satellite constellation network, characterized in that: including the following steps, Step 1: The states of the nodes in the low-earth orbit satellite network cluster include the initial state, the management state, and the running state; Step 1.1: The member nodes in the initial state of the low-earth orbit satellite network cluster include the manager, the follower, the pre-candidate, and the candidate based on the raft algorithm; Step 1.2: The initial state of the above member nodes obtained according to Step 1.1 is the follower; Step 2: The member node follower obtained according to Step 1.2 enters the management state; Step 2.1: In a term, the follower initiates a vote election and sets its own node to become a member node candidate; Step 2.2: The candidate obtained according to Step 2.1 sends a message to the followers other than itself to request a vote in the next immediately following term with a monotonically increasing term number; Step 2.2.1: The candidate obtained according to Step 2.2 transfers to Step 2.2.3 according to obtaining more than half of the votes of all member nodes; Step 2.2.2: The candidate obtained according to Step 2.2 transfers to Step 2.2.5 according to obtaining less than or equal to half of the votes of all member nodes; Step 2.2.3: The candidate obtained according to Step 2.2.1, when there is no manager heartbeat information, sets its own node to become a member node manager; Step 2.2.4: The candidate obtained according to Step 2.2.1, when there is manager heartbeat information, sets its own node to become a member node follower; Step 2.2.5: The candidate obtained according to Step 2.2.2, when there is no manager heartbeat information, goes to Step 2.1; Step 2.2.6: The member node manager obtained according to Step 2.2.3 sends a heartbeat message to the followers other than itself to confirm that it is the manager; Step 2.2.7: The number of member node managers obtained according to Step 2.2.6 is 1; Step 2.3: In a term, the follower discovers the heartbeat information of the manager; Step 2.3.1: The follower obtained according to Step 2.3, when there is no manager heartbeat information, goes to Step 4; Step 2.3.2: The follower obtained according to Step 2.3, when there is manager heartbeat information, receives the log entry of the manager and submits the log to the manager; Step 3: The member node manager obtained according to Step 2.2.7 enters the running state; Step 3.1: The manager packs the requests from the client into logs; Step 3.2: The log obtained according to Step 3.1 and the corresponding index mark are established to form a log entry; the log entry and the set of logs constitute a log list; Step 3.3: The manager synchronizes the logs to the followers; thus, the distributed consistency transmission is completed; Step 4: When the network connection of the low-earth orbit satellite network cluster node is abnormal, the member node is in an isolated state, and the low-earth orbit satellite network cluster node network is reconnected.
2. The distributed consensus transmission method based on the low-earth orbit satellite constellation network according to claim 1, wherein: The implementation method of Step 4 is, Step 4.1: When the manager is in an isolated state, increment the term number by 1 monotonically and initiate a vote election for the next term to obtain the manager of the next term with a term number higher than its own; set its own node to become a member node follower; Step 4.2: When the follower or candidate is in an isolated state, the follower sets its own node to a member node candidate and broadcasts to other member nodes to determine the member node status.
3. A distributed consistency transmission method based on a low-earth orbit satellite constellation network according to claim 1, characterized in that: The implementation method of Step 4.2 is as follows. Step 4.2.1: When other member nodes and the candidate belong to the same term, set the candidate's own node to a member node candidate and go to Step 2.
1. Step 4.2.2: When other member nodes and the candidate do not belong to the same term, increment the term monotonically by 1 and initiate a vote for the next term.
4. A distributed consistency transmission system based on a low-earth orbit satellite constellation network for implementing the method according to claim 1, characterized in that: It includes a network forwarding module, a leader election module, and a log replication module. The network forwarding module is used for the leader node to receive a client request and add the request to the end of the leader node's queue for processing. The leader election module is used to elect a leader node from among the nodes of the low-earth orbit satellites by means of a selection vote during a term, and to process the nodes with heartbeat information, thereby improving the fault tolerance and response speed of the nodes in processing requests. The log replication module is used to package the client's request under the mapping relationship between the term and the log index.