Data cache recovery method and system
Patent Information
- Application Number
- CN202511124903.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-08-12
- Publication Date
- 2025-10-24
- Estimated Expiration
- 2045-08-12
AI Technical Summary
In the network function virtualization system, during the construction and management of the service chain, VNF failures may cause packet drops or long-term caching, resulting in the loss of key functions of the network function platform or excessive storage overhead.
A combined caching mechanism of shared circular queues and linear queues is adopted to overwrite and save a small number of data packets when the service process is normal, cache incoming data packets in the event of a fault, and accurately restore all data packets after recovery, realizing the complete transmission of data packets through collaboration with the monitoring platform.
It ensures the complete transmission of data packets in any service process, reduces cache overhead, improves communication bandwidth and processing efficiency, and realizes data packet recovery without user perception.
Smart Images

Figure CN120835334A_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of computer networks, and particularly relates to a data cache recovery method and system. BACKGROUND
[0002] NFV (Network Functions Virtualization) is a technology architecture that separates the functions of traditional network devices (such as routers, firewalls, load balancers, etc.) from dedicated hardware through software technology, so that they can run on general servers, virtual machines or containers. NFV has been widely applied in key scenarios such as telecom core networks, data centers and edge computing, and is a network infrastructure supporting high flexibility and high programmability for operators. The deployment process of NFV relies on the construction of a resource pool by a virtualization infrastructure (such as OpenStack or Kubernetes), and the unified management of the life cycle of a virtual network function (VNF) by a management and orchestration (MANO) architecture. The deployment of NFV usually starts with defining a VNF, and multiple VNFs are combined into a service chain (SFC, also known as a service process) in a specific order. Through the service chain mechanism, NFV realizes a network service delivery mode of on-demand customization and flexible combination, so that network functions can be quickly deployed, replaced and managed like software services, greatly improving the ability of operators to control networks and innovate services.
[0003] Currently, the construction and management of service chains pose a series of technical challenges. In the actual working process of a virtual network, a VNF may fail due to resource bottlenecks, configuration errors or software abnormalities, thereby affecting the normal provision of the entire service chain network function. During the period when the VNF is abnormal, one method of processing the VNF abnormality is to discard or directly forward all data packets passing through the service chain to the target server. This will cause some key functions (such as billing functions and security detection functions) of the network function platform to be unable to be implemented, thereby causing the lack of key information statistics or security vulnerabilities. Another method of processing the VNF abnormality is to long-term cache data packets passing through the service chain, and then import the corresponding data packets into the service chain after the VNF recovers. Although this method can ensure that all data packets pass through the service chain, it still has the problems of excessive daily storage overhead and repeated traffic statistics. SUMMARY
[0004] The purpose of the present application is to ensure that data packets can pass through the service process completely and reasonably in any case, achieving the purpose of user unawareness.
[0005] To achieve the above object, the application provides a data cache recovery method and system.
[0006] In a first aspect, the application provides a data cache recovery method applied to a cache platform in a network function virtualization system, the cache platform being provided with a plurality of processes, each of the processes being in communication with a service flow, each of the processes including a cache space, the cache space including a common ring queue, a linear queue and a tail traffic cache, the method including:
[0007] receiving a maintenance signal sent by a monitoring platform, and sequentially caching each data packet in incoming traffic flowing into the service flow to the common ring queue; and caching the last data packet in outgoing traffic flowing out of the service flow to the tail traffic cache;
[0008] when the service flow fails, sequentially caching each data packet in incoming traffic to be flowed into the service flow to the linear queue, and determining the head of the common ring queue according to the data packet cached in the tail traffic cache;
[0009] when the service flow recovers from the failure, sequentially caching each data packet in incoming traffic to be flowed into the service flow to the linear queue, and sequentially sending the data packet cached in the common ring queue to the service flow from the head of the common ring queue; and sequentially leading the data packet cached in the linear queue into the common ring queue from the head of the linear queue, and sending the led-in data packet to the service flow through the common ring queue.
[0010] In an optional embodiment, the method further includes:
[0011] determining that the data packet cached in the linear queue has been led into the common ring queue, sending a cache traffic recovery signal to the monitoring platform, so that the monitoring platform feeds back the maintenance signal.
[0012] In an optional embodiment, the method further includes:
[0013] when the service flow recovers from the failure, caching the last data packet in outgoing traffic flowing out of the service flow to the tail traffic cache.
[0014] In an optional embodiment, the sequentially leading the data packet cached in the linear queue into the common ring queue from the head of the linear queue includes:
[0015] The data packets in the linear queue are input into a preset filter one by one from the head of the linear queue, and the data packets output by the filter are guided into the common ring queue;
[0016] The filter is used to filter out the data packets that have been guided into the common ring queue.
[0017] In an optional embodiment, the filter stores a hash table.
[0018] The hash table records the data packets in the common ring queue that are generated by the incoming traffic of the process after the service flow fails.
[0019] In an optional embodiment, the determination of the head of the common ring queue according to the data packets in the tail traffic cache comprises:
[0020] In the common ring queue, a target data packet identical to the data packet in the tail traffic cache is searched for;
[0021] In the common ring queue, the memory space occupied by the data packet after the target data packet is determined as the head of the common ring queue.
[0022] In an optional embodiment, the memory space occupied by the common ring queue is greater than a first storage space.
[0023] The first storage space corresponds to the storage space of the maximum total amount of data transmitted within the time of the traffic passing through the service flow.
[0024] In an optional embodiment, the memory space occupied by the tail traffic cache is greater than a second storage space.
[0025] The second storage space corresponds to the storage space occupied by the maximum value of the data packet under the current network protocol.
[0026] In an optional embodiment, each service flow comprises a plurality of virtual network functions.
[0027] The virtual network functions that provide modification services for the incoming traffic in the plurality of virtual network functions are linked together to generate a first type of service chain.
[0028] Correspondingly, the data packets in the common ring queue are sent to the service flow, comprising:
[0029] The data packets in the common ring queue are sent to the first type of service chain in the service flow.
[0030] In a second aspect, the present application provides a data cache recovery system applied to a cache platform in a network function virtualization system, wherein the cache platform is provided with a plurality of processes, each of which communicates with a service flow, and each of the processes comprises a cache space, which comprises a common ring queue, a linear queue and a tail traffic cache, and the system comprises:
[0031] a first execution module configured to receive a maintenance signal sent by a monitoring platform, and sequentially cache each data packet in the incoming traffic flowing into the service flow to the common ring queue, and cache the last data packet in the outgoing traffic flowing out of the service flow to the tail traffic cache;
[0032] a second execution module configured to, when the service flow fails, sequentially cache each data packet in the incoming traffic to be flowed into the service flow to the linear queue, and determine the head of the common ring queue according to the data packet cached in the tail traffic cache;
[0033] a third execution module configured to, when the service flow recovers, sequentially cache each data packet in the incoming traffic to be flowed into the service flow to the linear queue, and sequentially send the data packet cached in the common ring queue to the service flow from the head of the common ring queue; and sequentially lead the data packet cached in the linear queue into the common ring queue from the head of the linear queue, and send the led-in data packet to the service flow through the common ring queue.
[0034] The present application provides a data cache recovery method and system, which saves a small amount of data packets as preparation for service flow recovery in a covering and saving manner through a common ring queue when the service flow works normally. When the service flow fails, the data packets to be flowed into the service flow are cached through a linear queue, and the first data packet that fails to pass through the service flow is determined. After the service flow recovers, all cached data packets are recovered in time. Different cache mechanisms are adopted for normal service flow and abnormal service flow, which guarantees the communication bandwidth and processing efficiency of the service flow under normal conditions, has the advantage of small cache overhead, and can accurately recover all data packets after abnormal processing, so that the data packets can pass through the service flow completely and reasonably under any condition, thereby achieving the purpose of user non-perception. BRIEF DESCRIPTION OF DRAWINGS
[0035] Figure 1 The cache recovery mechanism architecture diagram of the data cache recovery method provided by the present application.
[0036] Figure 2 The recovery mode display schematic diagram in the data cache recovery method provided by the present application.
[0037] Figure 3 The schematic diagram of the architecture of the cache platform in the data cache recovery method provided by the present application.
[0038] Figure 4 The schematic diagram of the mode conversion of the execution module in the data cache recovery method provided by the present application.
[0039] Figure 5 The schematic diagram of the maintenance mode of the cache platform in the data cache recovery method provided by the present application.
[0040] Figure 6 The schematic diagram of the recovery preparation mode of the cache platform in the data cache recovery method provided by the present application.
[0041] Figure 7 The schematic diagram of the interrupt traffic recovery mode of the cache platform in the data cache recovery method provided by the present application.
[0042] Figure 8 The schematic diagram of the storage cleaning mode of the cache platform in the data cache recovery method provided by the present application.
[0043] Figure 9 The schematic diagram of the re-linking in the data cache recovery method provided by the present application. DETAILED DESCRIPTION
[0044] The best mode for carrying out the present application will be described below by way of examples. It should be understood that the specific embodiments herein are used to explain the present application in detail, and should not be construed as limiting the present application. It should be noted that various changes and modifications can be made under the premise of following the principles and core of the present application, and these changes should be considered as belonging to the protection scope of the present application. The specific implementation steps of the present application will be described in detail in combination with the drawings.
[0045] Currently, NFV has been widely applied in key scenarios such as telecom core network, data center and edge computing, and is the network infrastructure supporting operators to achieve high flexibility and high programmability. In the 5G network architecture, NFV carries the control and user plane functions of the core network (such as AMF, SMF, UPF, etc.). In enterprise and cloud computing platforms, NFV is used to build logical components such as virtual firewalls, load balancers, intrusion detection systems, and reduces overall operation and maintenance costs through flexible scheduling and automated management. The deployment of NFV usually starts with defining VNF (Virtual Network Function), and then according to business needs, multiple VNFs are combined into a service chain (Service Function Chain, SFC) in a specific order. Service chain is a key mechanism for implementing complex network service logic in NFV, which describes the processing order of data flow between multiple functional entities. For example, a typical business flow may need to pass through a virtual firewall, a load balancer, an intrusion detection system and a traffic billing system in turn, and each VNF node performs specific operations on the data flow.
[0046] In actual deployment, the definition of service chain is usually described by a service orchestrator (such as OSM or ONAP), modeled using formats such as TOSCA (Topology and Orchestration Specification for Cloud Applications) or YAML (a lightweight data serialization format), which specifies the logical location and connection relationship of each VNF. The deployment process includes mapping the service chain to physical or virtual resources, and configuring the forwarding path through the SDN (Software-Defined Networking) controller to ensure that the traffic traverses each VNF instance in the intended order. Each VNF in the link can be dynamically scaled or migrated according to the running state, and the system will automatically update the forwarding path to maintain the consistency and connectivity of the service chain. Through the service chain mechanism, NFV realizes the on-demand customization and flexible combination of network service delivery, enabling network functions to be quickly deployed, replaced and managed like software services, greatly improving the operator's ability to control and innovate the network.
[0047] However, the construction and management of service chain brings a series of technical challenges. How to ensure the continuous and stable operation of the service chain is a problem that cannot be ignored. In the actual working process of the virtual network, VNFs may fail due to resource bottlenecks, configuration errors or software abnormalities, etc., thereby affecting the normal provision of the entire service chain network function. However, the current method for handling VNF exceptions cannot bring good results:
[0048] 1) During the period of VNF exception, all data packets passing through the service chain are directly discarded or directly forwarded to the target server. But this often leads to the inability of some key functions of the network function platform (such as billing function, security detection function) to provide part of the traffic, thereby causing the lack of key information statistics or security vulnerabilities.
[0049] 2) Long-term cache of traffic passing through VNF, and then import the cached traffic into the service chain after the VNF is restored. Although this method can ensure that all traffic passes through the service chain, it still has the problems of large daily storage overhead and repeated traffic statistics.
[0050] To solve the above technical problems, the embodiment provides a data cache recovery method and system applied in a network function virtualization system. When the service flow in the network function virtualization system is working normally, a small amount of data packets are saved as a preparation for recovery in a cover saving manner through a common ring queue. When the service flow is abnormal, all data packets flowing into the service flow are cached in time through a linear queue, and the first data packet that fails to pass through the service flow is determined in time. After the service flow is restored, all cached data packets are recovered in time. The data cache recovery method provided by the embodiment solves the problem of partial traffic loss caused by service flow exception in the existing processing method. Different cache mechanisms are adopted for normal service flow and abnormal service flow, which guarantees the communication bandwidth and processing efficiency of the service flow under normal conditions. Under normal conditions, the cache overhead is small. After abnormal processing, all data packets can be accurately recovered, ensuring that the data packets can pass through the service flow completely and reasonably under any condition, thereby achieving the purpose of user non-perception.
[0051] As shown in Figure 1 , the data cache recovery method and system provided by the embodiment are applied in a network function virtualization system, which includes a cache platform, a monitoring platform, and a plurality of different service flows.
[0052] The cache platform is used to cache the incoming traffic flowing into the service flow and the outgoing traffic flowing out of the service flow, and to guide the direction of the cached traffic after the service flow fails and recovers. The cache platform isolates each service flow in the plurality of service flows and allocates computing resources and storage resources to ensure that the processing of different service flows does not interfere with each other.
[0053] The monitoring platform is used to check the working state of each virtual network service (VNF) in each service flow, and to notify the cache platform after the virtual network service is abnormal; and is also used to guide the restart and recovery of the virtual network service and to control the link state of the service flow. It should be noted that the virtual network service is restarted and recovered in Figure 1It is referred to as service in Chinese, and different virtual network services are distinguished by numbers.
[0054] The service process is the core function of the NFV platform and is the subject of service and protection. Different service processes are distinguished by numbers.
[0055] In general, the cache platform and the monitoring platform will work together to implement data cache recovery methods to ensure that traffic can pass through the service process completely and reasonably under any circumstances, achieving the goal of user non-perception.
[0056] The data cache recovery method in this embodiment is divided into normal mode and recovery mode. In normal mode, all service processes are working normally. Figure 1 For example, the traffic pkt sent by the source server m Before entering service process 0, it will enter the cache platform to make a backup in the cache. The cache platform will transfer the traffic pkt m Cache to the storage resource corresponding to service process 0, and transfer the traffic pkt m Send to service process 0. Traffic pkt m After a complete service process (service 1, service 2...service t), it is modified to traffic pkt n Service process 0 will flow pkt n Send it to the cache platform, and the cache platform will send the traffic pkt to the cache platform. n Cache to the storage resource corresponding to service process 0 to achieve traffic pkt n After recording, it is forwarded to the target address corresponding to the target server.
[0057] In normal mode, the monitoring platform frequently communicates with each service (Service 1, Service 2…Service t) contained in Service Process 0 and monitors the working status of each service. It also notifies the cache platform when an exception occurs in the virtual network service (Service 1, Service 2…Service t). The monitoring platform also guides the restart and recovery of the virtual network service and controls the link status of the service process to ensure the normal operation of the service process.
[0058] When a service fails in the service process, the traffic pkt m If you cannot pass the entire service process, enter the recovery mode, such as Figure 2 The recovery mode shown in the figure shows that the entire data cache recovery method will start working according to the following steps:
[0059] 1. The monitoring platform monitors the working status of each service. If the monitoring finds that service 2 in service process 0 has a fault, it will quickly locate the location of the fault.
[0060] 2. The monitoring platform sends relevant information about the fault to the cache platform. The cache platform determines the service process 0 that has failed based on the relevant information, enters the process corresponding to the service process 0 into the traffic cache mode and caches the traffic, and blocks the traffic pkt m Enter the failed service process 0. The relevant information includes: the failed service or the failed service process.
[0061] 3. The monitoring platform restarts the failed service 2 and restores the state before the failure.
[0062] 4. After the faulty service 2 returns to normal, the monitoring platform will relink all services with the same tag based on the different tags of the services in the service process.
[0063] 5. After all services are successfully reconnected, the monitoring platform will notify the cache platform to start the traffic recovery mode. The cache platform will first transmit the traffic that was discarded due to the failure to service process 0 to ensure the integrity of the traffic service.
[0064] 6. After the previous step is completed, the monitoring platform will receive a signal from the cache platform. Next, the monitoring platform will control the restoration of the initial link form of service process 0 (that is, the complete service chain, namely service 1, service 2...service t).
[0065] 7. After the initial link is successfully restored, the monitoring platform will notify the cache platform to continue to direct all remaining traffic to service process 0.
[0066] After completing all steps in recovery mode, if there is no problem with service process 0, it will enter normal mode and continue to run.
[0067] It should be noted that due to the isolation of computing resources and storage resources corresponding to each service process, the impact and resolution of failures in different service processes are independent, and the working modes of different service processes are also independent and do not affect each other.
[0068] The following will provide a detailed description of the cache platform and the monitoring platform, detailing how the cache platform and the monitoring platform serve the normal mode and the recovery mode of the entire cache recovery method.
[0069] like Figure 3 The cache platform architecture diagram shown in the figure shows that a process will be run on the cache platform for each service process, and the inbound and outbound traffic of the service process corresponding to the process will be processed by the process, thereby ensuring the independence of resources for different service processes. Figure 3 As shown, for service process X, there is a process for service process X on the cache platform.
[0070] Each process includes a communication module, an execution module and a cache space. The communication module receives information from the monitoring platform, obtains the state of the current service process, and delivers the received information to the execution module.
[0071] The cache space is a space used by the process to cache the incoming and outgoing traffic of the service process X and the state of the data packets, and is deployed in the memory of the cache platform. The cache space includes a shared ring queue, a linear queue, a hash table and a tail traffic cache.
[0072] It should be noted that the shared ring queue and the tail traffic cache are long-term. The shared ring queue functions to cache a necessary number of data packets to ensure that the process can find all the data packets that have failed to pass through when the service process fails. When the service process fails, the shared ring queue caches the data packets that have failed to pass through, so that the process can "backtrack" the cached data packets, avoid losing critical information due to failure, and ensure the reliability of the service and the integrity of the data.
[0073] The memory space of the shared ring queue is related to the current service process, and the time for testing traffic to pass through the service process is set as pass_time, and the maximum total amount of data transmitted within the time (pass_time) is maximum_bandwidth x pass_time, and the memory space occupied by the shared ring queue is greater than the storage space corresponding to the maximum total amount of data. The maximum_bandwidth is the maximum bandwidth, which refers to the maximum data transmission rate that the service process can handle. In the present embodiment, the size of the shared ring queue can be set as β x maximum_bandwidth x pass_time. β is to reserve sufficient redundancy to cope with traffic fluctuations, sudden data and the like (such as network instantaneous congestion, process processing delay), so that the shared ring queue is not easy to overflow due to sudden traffic, and the cache function is stable. In the present embodiment, β > 2 to provide sufficient redundancy. The memory space of the tail traffic cache should be the upper limit of the size of the data packet under the current network protocol (the maximum value of the data packet), that is, the memory space occupied by the tail traffic cache is greater than or equal to the storage space occupied by the maximum value of the data packet under the current network protocol. The tail traffic cache is used to cache the last data packet in the outgoing traffic of the service process X.
[0074] The linear queue and the hash table only appear in the recovery mode, and neither has a fixed size of memory space, and will become larger with the accumulation of cached data packets. The linear queue is used to accommodate all the data packets accumulated due to the failure of the service process. After the failure is recovered, the linear queue passes the cached data through the service process in the order of cache by means of dequeuing. The hash table is used to store the state of the data packets that have passed through the service process, and is used to check the state of the data packets that have passed through the service process. Figure 3The filter in the cache platform is used to record and query all data packets entering the service flow from the cache platform, and all retransmission data packets are removed by a hash table to prevent retransmission data packets from entering the service flow and causing repeated services.
[0075] It should be noted that the data packets recorded in the hash table are the traffic entering the process after the service flow fails, that is, the incoming traffic of the process corresponding to the currently failed service flow. Since the filter is between the linear queue and the shared ring queue, the traffic recorded by the hash table should be all the traffic entering the shared ring queue from the linear queue.
[0076] The execution module is the core of the process. The execution module obtains the incoming and outgoing traffic of the corresponding service flow, and takes control of the incoming and outgoing traffic of the service flow in necessary cases (referring to the recovery mode). At the same time, the execution module adjusts its working mode in time according to the signal sent by the monitoring platform, and controls and coordinates the cache space and the incoming and outgoing traffic of the service flow to ensure that all traffic can be reasonably cached or passed through the service flow.
[0077] The working mode of the execution module under different conditions and the coordination mode between the execution module and the communication module and the cache space will be introduced in more detail below.
[0078] As shown in the execution module mode conversion diagram in Figure 4 , in the normal mode, the execution module is in the maintenance mode. Since all service flows are normal, the process only needs to cache the incoming and outgoing traffic of the service flow, and the process handles the incoming and outgoing traffic of the service flow. If the service flow fails, it will be converted from the normal mode to the recovery mode. In the recovery mode, the execution module is first in the recovery preparation mode, the incoming traffic of the service flow cannot pass through the service flow smoothly, and the process needs to cache the incoming traffic of the service flow. When the service in the service flow recovers to normal, the monitoring platform sends a fault recovery signal to the cache platform, the execution module enters the interrupt traffic recovery mode, and the execution module recovers the interrupt traffic. When the service link in the service flow recovers to the initial form, the execution module sends a signal to the cache platform, the execution module enters the cache cleaning mode, and the execution module starts cache cleaning.
[0079] The execution module is in the maintenance mode, as shown in the cache platform maintenance mode diagram in Figure 5 , all incoming traffic entering the service flow X is copied into the process, and the execution module will enter each data packet in the incoming traffic into a shared ring queue one by one, that is, sequentially cached to the shared ring queue. Among them, the blue line represents the flow direction of the incoming traffic of the service flow X, and the red line represents the flow direction of the outgoing traffic of the service flow X.
[0080] It should be noted that the shared ring queue is a continuous space in memory, and each time the data packet is queued in the space after the last data packet. If the next space exceeds the space range limit of the shared ring queue, the data packet will be placed from the start of the shared ring queue. In maintenance mode, the shared ring queue will not have an active dequeue operation, that is, all data packets stored in the shared ring queue for too long will be overwritten by newly queued data packets, because these old data packets have been processed and sent out by the service process, and do not need to be processed. The way of covering can clean up old data packets in time, and greatly reduce the calculation and storage overhead of the cache recovery method in normal mode. In addition, all the outflow of the service process X also enters the process, and the execution module saves the outflow in the tail flow cache corresponding to the service process X. This operation exists in any mode. The tail flow cache only caches the last data packet in the outflow, and the early data packet will be overwritten by the later data packet. The significance of the tail flow cache is to replace the dequeue operation of the shared ring queue. Since the flow under the same service process has the order preserving property, recording the last outflow data packet can determine that all data packets before it in the shared ring queue have flowed out or been cleared (some NFVs, such as firewalls, will selectively clear some data packets).
[0081] If the service process X fails, the monitoring platform will send a fault signal to the notification cache platform in time, and the execution module will enter the recovery preparation mode. As shown in Figure 6 The schematic diagram of the cache platform recovery preparation mode is shown in FIG. 6, wherein the blue line represents the flow direction of the inflow of the service process X. At this time, the inflow of the service process X cannot pass through the service process X smoothly, and the cache platform will control the corresponding inflow to enter the process for the service process X for processing: a linear queue is generated in the cache space, and the execution module will queue all the inflow in turn, that is, each data packet in the inflow is cached to the linear queue in turn. At the same time, the execution module determines the head of the shared ring queue according to the data packet cached in the tail flow cache of the service process X. Specifically, in the shared ring queue, the same target data packet as the data packet cached in the tail flow cache is searched. According to the search of the same target data packet as the data packet cached in the tail flow cache from the end of the shared ring queue, the position of the found data packet is recorded, and in the shared ring queue, the memory space occupied by the data packet after the target data packet is determined as the head of the shared ring queue.
[0082] After the monitoring platform restarts the service flow of the fault, the service in the service flow resumes normal, and the corresponding service has been specially linked, the monitoring platform sends a fault recovery signal to the cache platform, and the execution module resumes the interrupted traffic. At this time, the cache platform needs to import the traffic interrupted and discarded due to service failure before into the service flow, that is, the data packets cached in the shared ring queue. Therefore, as shown in the schematic diagram of the cache platform interrupted traffic recovery mode, Figure 7 The blue line represents the flow direction of the incoming traffic of service flow X, the red line represents the flow direction of the outgoing traffic of service flow X, and the green line represents the flow direction of the data packets cached in the shared ring queue. On the one hand, the cache platform will continue to prevent incoming traffic from entering service flow X and cache all incoming traffic in this state; on the other hand, the execution module will control the shared ring queue to dequeue the data packets from the head of the queue in turn and import them into service flow X, that is, the shared ring queue caches the data packets from the head of the queue in turn and sends them to service flow X. After the shared ring queue is emptied, the communication module sends an interrupted traffic recovery completion signal to the monitoring platform. At this time, the outgoing traffic of service flow X has resumed normal and can be sent to the target server, and the last data packet in the outgoing traffic of service flow X is still cached at the end of the traffic cache.
[0083] After the monitoring platform receives the interrupted traffic recovery completion signal, the services in the service flow are linked to the initial form, and a signal is sent to the cache platform to start cache cleaning. As shown in the schematic diagram of the cache platform cleaning mode, Figure 8 At this time, the incoming traffic cannot directly enter the service flow and still needs to be cached in the linear queue. The linear queue cleans the cache from the head of the queue, and dequeues each data packet in turn, that is, the linear queue caches the data packets from the head of the queue in turn and imports them into the shared ring queue, and the imported data packets are sent to the service flow through the shared ring queue until the linear queue is completely emptied.
[0084] In addition, to prevent the same data packet from repeatedly passing through the service and causing errors, the linear queue caches the data packets from the head of the queue in turn and inputs them into the preset filter in turn. The filter is used to filter out data packets that have been imported into the shared ring queue. The data packets output by the filter are imported into the shared ring queue; the imported data packets are sent to the service flow through the shared ring queue until the linear queue is completely emptied.
[0085] At this time, the outflow of service process X has returned to normal, and the outflow can be sent to the target server. The last data packet in the outflow of service process X is still cached in the end flow cache. The data packets cached in the linear queue have all been imported into the common ring queue, and the cache platform lets the incoming flow directly enter the service process. After the linear queue and the filter are emptied and the cache flow recovery signal is sent to the monitoring platform, the monitoring platform feeds back the maintenance signal. After the execution module receives the maintenance signal, the execution module for the process of service process X returns to the maintenance mode, ensuring the operation of the cache recovery mechanism in a normal environment.
[0086] In this embodiment, the monitoring platform adjusts the connection mode of the services (service 1, service 2, …, service t) according to the location of the fault to ensure that the re-entered flow of the lost packet does not repeatedly affect some services when re-entering the service process.
[0087] Before describing the adjustment of the connection mode of the services, the characteristics of the VNFs are described. Through observation, the VNFs can be roughly divided into two categories: one category provides modification services for the flow, for example, security detection filters some flows that do not meet the security requirements, and the load balancing function modifies the data packet header in the flow to ensure that the flow reaches the destination through the optimal path; the other category modifies the corresponding statistical data through the passing flow, for example, the traffic billing function calculates the corresponding fee according to the size of the flow passing through the service, and the network state statistics predict the most suitable network path according to the transmission state of the flow in the network.
[0088] The above two categories of VNFs have different requirements for the passing flow: the first category of VNFs directly forwards the modified flow, and the fault in the forwarding process will cause the corresponding data packet to be discarded due to cache problems, so the discarded flow needs to pass through this type of VNF again after the fault is recovered to ensure the integrity of the service; the second category of VNFs modifies the statistical information in a timely manner according to the passing flow, so all the passing flow cannot pass through this type of VNF again, otherwise it will cause repeated statistics and other problems.
[0089] In this embodiment, according to the above two categories of VNFs, all VNFs on the NFV platform are manually marked with corresponding marks. The first category of VNFs is marked with a type one service mark, and the second category of VNFs is marked with a type two service mark.
[0090] Based on the above embodiment, after the service is successfully recovered, the monitoring platform sends a service recovery signal to the cache platform, and the cache platform sends a service recovery signal to the execution module. After receiving the service recovery signal, the execution module for the process of service process X returns to the maintenance mode, ensuring the operation of the cache recovery mechanism in a normal environment. Figure 9As shown in the re-linking schematic diagram, the monitoring platform links together the virtual network functions that provide modification services for the incoming traffic in the plurality of virtual network functions according to the classification of each service (the mark of the type one service and the mark of the type two service) to generate a first type of service chain; that is, all type one services before the faulty service are connected together and the type two service is skipped to obtain the first type of service chain. The data packets cached in the common ring queue are sent to the first type of service chain in the service flow. In this way, the service state of the type two service is not affected by the repeated data packets, and the passing traffic is also provided with modification services.
[0091] Next, the monitoring platform sends a fault recovery signal to the caching platform to inform it to resume the interrupted traffic, and listens to the signal from the caching platform. When receiving the signal that the interrupted traffic recovery is completed, the monitoring platform restores the corresponding service flow to the initial connection mode (that is, the connection mode of all services before modification), and sends a link recovery signal to the caching platform to inform it to clean up the cache. Then, the monitoring platform resumes the normal mode of the caching recovery mechanism, that is, it maintains communication to monitor the state of each service.
[0092] The embodiment also provides a data cache recovery system applied to a caching platform in a network function virtualization system, wherein the caching platform is provided with a plurality of processes, each of the processes communicates with a service flow, and each of the processes includes a cache space, the cache space includes a common ring queue, a linear queue and a tail traffic cache, and the system includes:
[0093] A first execution module is configured to receive a maintenance signal sent by the monitoring platform, and sequentially cache each data packet in the incoming traffic flowing into the service flow into the common ring queue; and cache the last data packet in the outgoing traffic flowing out of the service flow into the tail traffic cache.
[0094] A second execution module is configured to, when the service flow fails, sequentially cache each data packet in the incoming traffic to be flowed into the service flow into the linear queue, and determine the head of the common ring queue according to the data packet cached in the tail traffic cache.
[0095] A third execution module is configured to, when the service flow recovers, sequentially cache each data packet in the incoming traffic to be flowed into the service flow into the linear queue, and sequentially send the data packets cached in the common ring queue to the service flow from the head of the common ring queue; and sequentially import the data packets cached in the linear queue into the common ring queue from the head of the linear queue, and send the imported data packets to the service flow through the common ring queue.
[0096] In an optional embodiment, the system for recovering data buffering further comprises:
[0097] a feedback module configured to determine that all the buffered data packets in the linear queue have been imported into the common ring queue, send a buffering traffic recovery signal to the monitoring platform, and make the monitoring platform feedback the maintenance signal.
[0098] In an optional embodiment, the system for recovering data buffering further comprises:
[0099] a fourth execution module configured to buffer the last data packet in the outflow of the service flow to the end traffic buffer when the service flow recovers from failure.
[0100] In an optional embodiment, the third execution module comprises:
[0101] a filter unit configured to sequentially input the data packets buffered in the linear queue into a preset filter from the head of the linear queue, and import the data packets output by the filter into the common ring queue; wherein the filter is configured to filter out the data packets that have been imported into the common ring queue.
[0102] wherein the filter stores a hash table; and the hash table records the data packets of the in-flow of the process in the common ring queue after the service flow fails.
[0103] In an optional embodiment, the second execution module comprises:
[0104] a searching unit configured to search for a target data packet identical to the data packet buffered in the end traffic buffer in the common ring queue, and determine the memory space occupied by the data packet after the target data packet in the common ring queue as the head of the common ring queue.
[0105] In an optional embodiment, the memory space occupied by the common ring queue is greater than a first storage space; wherein the first storage space is a storage space corresponding to the maximum total amount of data transmitted within the time when the traffic passes through the service flow.
[0106] the memory space occupied by the end traffic buffer is greater than a second storage space; wherein the second storage space is a storage space occupied by the maximum value of the data packet under the current network protocol.
[0107] In an optional embodiment, each of the service flows comprises a plurality of virtual network functions.
[0108] linking together the virtual network functions in the plurality of virtual network functions that provide modification services for the in-flow to generate a first type of service chain.
[0109] Correspondingly, the third execution module is further configured to send the data packets in the common ring queue cache to a first type of service chain in the service flow.
[0110] The data cache recovery system provided by the embodiments of the present application can be used to execute the processing flow of the data cache recovery method in the above-mentioned embodiments, and the functions thereof will not be described herein again, and can be referred to the detailed description of the above-mentioned method embodiments.
[0111] The above-mentioned specific embodiments further explain the purposes, technical solutions and beneficial effects of the present application. It should be understood that the above-mentioned specific embodiments are only used to limit the protection scope of the present application, and any modification, equivalent replacement, improvement, etc. within the spirit and principle of the present application should be included in the protection scope of the present application.
Claims
1. A method of data cache recovery, the method comprising: The application discloses a cache platform applied to a network function virtualization system, wherein the cache platform is provided with a plurality of processes, each of the processes communicates with a service flow, and each of the processes comprises a cache space, the cache space comprises a common ring queue, a linear queue and a tail flow cache, and the method comprises the following steps: When the service flow fails, each data packet in the incoming flow to be flowed into the service flow is sequentially cached to the linear queue, and the head of the common ring queue is determined according to the data packet cached in the tail flow cache; When the service flow recovers from the failure, each data packet in the incoming flow to be flowed into the service flow is sequentially cached to the linear queue, and the data packets cached in the common ring queue are sequentially sent to the service flow from the head of the common ring queue; and the data packets cached in the linear queue are sequentially introduced into the common ring queue from the head of the linear queue, and the introduced data packets are sent to the service flow through the common ring queue. Further comprising:
2. The method of data cache recovery according to claim 1, wherein, When the service flow recovers from the failure, the last data packet in the outgoing flow from the service flow is cached to the tail flow cache. The step of sequentially introducing the data packets cached in the linear queue into the common ring queue from the head of the linear queue comprises the following steps:
3. The method of data cache recovery according to claim 1, wherein, The data packets cached in the linear queue are sequentially input into a preset filter from the head of the linear queue, and the data packets output by the filter are introduced into the common ring queue; The filter is used for filtering out the data packets that have been introduced into the common ring queue.
4. The method of data cache recovery of claim 1, wherein, The filter stores a hash table; The hash table records the data packet of the incoming flow of the process in the common ring queue after the service flow fails. The step of determining the head of the common ring queue according to the data packet cached in the tail flow cache comprises the following steps:
5. The method of data cache recovery according to claim 4, wherein, In the common ring queue, a target data packet same as the data packet cached in the tail flow cache is searched; In the common ring queue, the memory space occupied by the data packet after the target data packet is determined as the head of the common ring queue.
6. The method of data cache recovery of claim 1, wherein, The memory space occupied by the common ring queue is greater than a first storage space; The first storage space is a storage space corresponding to the maximum total amount of data transmitted in the time when the flow passes through the service flow. The memory space occupied by the tail flow cache is greater than a second storage space; 7. The method of data cache recovery of claim 1, wherein, The second storage space is a storage space occupied by the maximum value of the data packet under the current network protocol. Each service flow comprises a plurality of virtual network functions.
8. The method of data cache recovery according to claim 1, wherein, 9. The method of data cache recovery of claim 1, wherein, Linking together virtual network functions in the plurality of virtual network functions that provide modification services for incoming traffic generates a first type of service chain; Correspondingly, sending the data packets buffered in the common ring queue to the service flow includes: Sending the data packets buffered in the common ring queue to the first type of service chain in the service flow.
10. A system for data cache recovery, the system comprising: The application relates to a cache platform applied to a network function virtualization system, wherein the cache platform is provided with a plurality of processes, each process communicates with a service flow, and each process comprises a cache space, the cache space comprises a common ring queue, a linear queue and a tail traffic cache, and the system comprises: A first execution module is used for receiving a maintenance signal sent by a monitoring platform, sequentially buffering each data packet in incoming traffic flowing into the service flow into the common ring queue, and buffering the last data packet in outgoing traffic flowing out of the service flow into the tail traffic cache; A second execution module is used for sequentially buffering each data packet in incoming traffic to be flowed into the service flow into the linear queue when the service flow fails, and determining the head of the common ring queue according to the data packet buffered in the tail traffic cache; A third execution module is used for sequentially buffering each data packet in incoming traffic to be flowed into the service flow into the linear queue when the service flow recovers from the failure, sequentially sending the data packets buffered in the common ring queue to the service flow from the head of the common ring queue, and sequentially leading the data packets buffered in the linear queue into the common ring queue from the head of the linear queue, and sending the led-in data packets to the service flow through the common ring queue.
Citation Information
Patent Citations
Method for distributing and transmitting streaming media
CN101753439A
Queue processing method and device
CN103186585A
Data storage system and method
CN104125252A
Data reading and writing method and device, and circle queue
CN108733344A
Data processing method and system, data reading method and system, storage medium and electronic equipment
CN115964210A