A multicast message replication method and device
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- 格创通信(浙江)有限公司
- Filing Date
- 2026-01-08
- Publication Date
- 2026-06-02
Smart Images

Figure CN121462486B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of communication technology, and in particular to a method and apparatus for multicast message copying. Background Technology
[0002] With the development of network technology, multicast replication technology is being used more and more widely. In special industry application scenarios such as securities, in addition to the increased requirement for the number of replication nodes in the multicast group, there are also specific requirements for the execution order of each replication node. For example, each replication node corresponds to an entry in a table, and when performing multicast packet replication, it is desirable that the multicast replication operation corresponding to each entry in each replication node has a priority execution opportunity, and that the priority execution opportunities are equal.
[0003] The existing multicast replication mechanism generally stores the entries corresponding to each replication node in a multicast group as a linear linked list. This allows the replication and forwarding operations of multicast packets to be performed using this linked list. However, if multicast replication is performed starting from the head entry (the first entry in the linked list) according to this linear structure, each time a replicated packet arrives, the replication node corresponding to the entry closer to the head will inevitably perform the replication operation before the replication node corresponding to the entry closer to the tail (the last entry in the linked list). From the chip or device's output perspective, the multicast replicated packets from the replication nodes corresponding to the head entries will always be output first at the output position. For downstream interfaces / devices that require high precision in the refresh order and timeliness of multicast replicated packets, this results in an unfair message acquisition order.
[0004] Therefore, how to solve the problem that the fixed execution order leads to a fixed priority order for downstream devices to obtain multicast packets when using a straight linked list for multicast packet replication is one of the technical issues worth considering. Summary of the Invention
[0005] This application provides a multicast message copying method and apparatus to solve the problem that the priority order of downstream devices in obtaining multicast messages is fixed due to the fixed execution order when multicast message copying is performed in the form of a straight linked list.
[0006] On one hand, embodiments of this application provide a multicast message replication method, the method comprising:
[0007] For the multicast message to be copied, obtain the current ring head address from the multicast access table entry;
[0008] The current ring start address is used to query the ring multicast linked list to obtain the target entry corresponding to the current ring start address. The entries in the ring multicast linked list are linked in a ring structure.
[0009] Perform a copy operation on the multicast message based on the target entry;
[0010] Get the next hop address;
[0011] Update the value of the current ring head address in the multicast access entry to the next hop address.
[0012] On the other hand, embodiments of this application provide a multicast message replication apparatus, the apparatus comprising:
[0013] The first acquisition module is used to obtain the current ring head address from the multicast access table entry for the multicast packet to be copied this time;
[0014] The query module is used to query the ring multicast linked list using the current ring start address to obtain the target entry corresponding to the current ring start address. The entries in the ring multicast linked list are linked in a ring structure.
[0015] The replication module is used to perform a replication operation on the multicast message based on the target entry;
[0016] The second acquisition module is used to acquire the next-hop address;
[0017] The update module is used to update the value of the current ring head address in the multicast access table entry to the next hop address.
[0018] The technical solutions provided in the embodiments of this specification may include the following beneficial effects:
[0019] A circular multicast list is introduced when performing multicast message replication. The entries in this circular multicast list are linked in a circular structure. Thus, when replicating a multicast message to be replicated, the current ring head address is obtained from the multicast access entry. Then, the circular multicast list is queried using the current ring head address to obtain the target entry corresponding to the current ring head address. The replication operation is then performed on the multicast message based on the target entry. After the multicast message replication operation is completed, the next-hop address is obtained. The value of the current ring head address in the multicast access entry is updated to the next-hop address. In this way, the ring head address in the multicast access table can be dynamically updated, so that when the next multicast packet arrives, the corresponding table entry can be found based on the updated ring head address. In other words, the table entry found based on the dynamic ring head address is not fixed each time, which makes the order in which the copied multicast packets are forwarded also not fixed. This solves the problem that when multicast packets are copied in the form of a straight linked list, the order of downstream devices obtaining multicast packets is fixed because the order of each entry in the straight linked list is fixed.
[0020] It should be understood that the above general description and the following detailed description are exemplary and explanatory only, and are not intended to limit this specification. Attached Figure Description
[0021] Figure 1 This is a flowchart illustrating a multicast message copying method according to an embodiment of this application;
[0022] Figure 2a This is a schematic diagram of the structure of a ring multicast linked list obtained by linking a single entry ring structure, as shown in an embodiment of this application;
[0023] Figure 2b This is a schematic diagram of the structure of a ring multicast linked list obtained by linking multiple entries in a ring structure according to an embodiment of this application;
[0024] Figure 2c This is a schematic diagram illustrating the structure of a specific circular multicast linked list according to an embodiment of this application;
[0025] Figure 2d This is a schematic diagram of another specific circular multicast linked list structure shown in one embodiment of this application;
[0026] Figure 3 This is a schematic diagram of the structure of a multicast message copying device shown in one embodiment of this application;
[0027] Figure 4 This is a hardware structure diagram of a computer device shown in one embodiment of this application. Detailed Implementation
[0028] The exemplary embodiments will now be described in detail. When the description refers to the accompanying drawings, unless otherwise indicated, the same numbers in different drawings represent the same or similar elements. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with this specification; they are merely exemplary embodiments of apparatuses and methods consistent with some aspects of this specification.
[0029] The terminology used in this specification is for the purpose of describing particular embodiments only and is not intended to be limiting of this specification. The singular forms “a,” “described,” and “the” as used herein are also intended to include the plural forms unless the context clearly indicates otherwise.
[0030] It should be understood that the terms "first," "second," "third," etc., may be used in this specification to describe various information or structural modules for the purpose of more clearly describing the solution. These terms should not be construed as indicating or implying relative importance or implicitly specifying the number, order, or position of the indicated technical features. Therefore, a feature defined with "first," "second," "third," etc., may explicitly or implicitly include one or more of that feature. In the description of this specification, unless otherwise stated, "a plurality of" means two or more; "if" can be interpreted as "when," "when," or "in response to determination."
[0031] In this specification, "and / or" describes the relationship between associated objects, indicating that three relationships can exist. For example, A and / or B can represent: A alone, A and B simultaneously, or B alone, where A and B can be singular or plural. The character " / " generally indicates that the preceding and following associated objects are in an "or" relationship.
[0032] The embodiments described in this specification will now be described in detail.
[0033] like Figure 1 As shown, Figure 1 This is a flowchart illustrating a multicast packet replication method according to an exemplary embodiment. This multicast packet replication method can be applied to network devices. When implementing the method, the network device may include the following steps:
[0034] In step 102, for the multicast message to be copied this time, obtain the current ring head address from the multicast access table entry.
[0035] In this step, when the network device receives a multicast message, if it identifies that a message replication operation needs to be performed based on the multicast message, then the multicast message can be recorded as the multicast message to be replicated this time. To achieve multicast message replication, this application pre-maintains a multicast access table entry. This multicast access table entry only maintains the ring head address, which points to an entry in the ring-shaped multicast linked list used for multicast replication. It should be noted that the first ring head address can be any address in the ring-shaped multicast linked list.
[0036] Based on this, before performing multicast packet replication on the multicast packet, the network device first obtains the current ring head address from the multicast access table entry. This current ring head address can be understood as the ring head address currently recorded in the multicast access table entry.
[0037] In step 104, the current ring head address is used to query the ring multicast linked list to obtain the target entry corresponding to the current ring head address.
[0038] The entries in the aforementioned ring-shaped multicast list are linked in a ring structure.
[0039] Optionally, the aforementioned circular multicast list may include at least one entry. When the circular multicast list includes one entry, the individual entries are also linked in a circular structure, with the tail of the entry pointing to the other entry. Figure 2a A ring-shaped multicast linked list obtained by linking a single entry is provided. When the ring-shaped multicast linked list includes multiple entries, these multiple entries are linked in a ring structure, and the links between adjacent entries are directed. Furthermore, the configuration of adjacent entries among the multiple entries can be determined according to actual conditions. Specifically, network devices are pre-configured with multiple entries for multicast replication. To ensure that the distribution of packets obtained after each multicast replication based on entries is random and the order is not fixed, this application links multiple entries in a ring structure. The ring-shaped multicast linked list obtained by linking multiple entries can be referenced. Figure 2b As shown, Figure 2b Each link point represents a table entry.
[0040] To better understand, let's take a configuration of 5 entries as an example. These 5 entries are denoted as Entry 1, Entry 2, Entry 3, Entry 4, and Entry 5. It should be noted that when these 5 entries are linked in a ring, the settings of adjacent entries can be configured according to the actual situation and can be dynamically adjusted accordingly. In one embodiment, the ring multicast linked list obtained by linking these 5 entries in a ring can be as follows: Entry 1 links to Entry 2, Entry 2 links to Entry 3, Entry 3 links to Entry 4, Entry 4 links to Entry 5, and Entry 5 links to Entry 1. Furthermore, Entry 1 points to Entry 2, Entry 2 points to Entry 3, Entry 3 points to Entry 4, Entry 4 points to Entry 5, and Entry 5 points to Entry 1. (See reference...) Figure 2c As shown. In another embodiment, the circular multicast list obtained by the circular linking of these 5 entries can also be as follows: Entry 1 links to Entry 3, Entry 3 links to Entry 2, Entry 2 links to Entry 4, Entry 4 links to Entry 5, and Entry 5 links to Entry 1. Moreover, Entry 1 points to Entry 3, Entry 3 points to Entry 2, Entry 2 points to Entry 4, Entry 4 points to Entry 5, and Entry 5 points to Entry 1. For details, please refer to [reference needed]. Figure 2d As shown. Of course, there may be other embodiments, which will not be listed in detail here.
[0041] Specifically, each entry includes an address, replication requirement information, etc. Based on this, the obtained current ring head address can be used to query the ring multicast linked list to confirm the entry containing that current ring head address, which is the aforementioned target entry.
[0042] In step 106, a copy operation is performed on the multicast message based on the target entry.
[0043] In this step, after finding the target entry, the replication requirement information included in the target entry can be used to perform a replication operation on the multicast message, thereby obtaining the multicast replicated message.
[0044] In addition, the target entry also includes an outgoing interface, which can be used to forward the multicast replication message to the outside world after the multicast replication message is obtained.
[0045] In step 108, obtain the next-hop address.
[0046] In this step, to ensure that the order of multicast packet replication is no longer fixed and that multicast replicated packets based on each entry have an equal chance of priority execution, the next-hop address can be obtained after the packet replication operation for the current packet is completed. Specifically, the next-hop address can be obtained from the target entry. To better understand this step, the above... Figure 2c Taking the ring-shaped multicast linked list shown as an example, if the current ring head address is the address of entry 2, then if the address obtained from entry 2 is the address of entry 4, then the next hop address is the address of entry 4.
[0047] In step 110, the value of the current ring head address in the multicast access entry is updated to the next hop address.
[0048] In this step, after obtaining the next-hop address, the value of the current ring head address in the multicast access table is updated to the obtained next-hop address. This way, when the next multicast packet is obtained, the corresponding table entry for the next-hop address can be found based on the current ring head address, and multicast packet replication can be performed based on the found entry. This allows for multicast packet replication to be performed based on different table entries, ensuring that multicast packets replicated based on each entry have priority for execution. This solves the problem of fixed priority for downstream devices acquiring multicast packets when using a linearly linked list for multicast packet replication due to the fixed order of entries in the linearly linked list.
[0049] In the above multicast message replication method, for the multicast message to be replicated, the current ring head address is obtained from the multicast access table; the current ring head address is used to query the ring-shaped multicast linked list to obtain the target entry corresponding to the current ring head address, wherein the entries in the ring-shaped multicast linked list are linked in a ring structure; the replication operation is performed on the multicast message based on the target entry; if it is found that the ring-shaped multicast linked list has not completed the multicast replication task, the next-hop address is obtained; and the value of the current ring head address in the multicast access table is updated to the next-hop address. In this way, the ring head address in the multicast access table can be dynamically updated, so that when the next multicast packet arrives, the corresponding table entry can be found based on the updated ring head address. In other words, the table entry found based on the dynamic ring head address is not fixed each time, which makes the order in which the copied multicast packets are forwarded also not fixed. This solves the problem that when multicast packets are copied in the form of a straight linked list, the order of downstream devices obtaining multicast packets is fixed because the order of each entry in the straight linked list is fixed.
[0050] Optionally, based on the above embodiments, before obtaining the next-hop address, the multicast message replication method provided in this embodiment further includes the following step of identifying whether the circular multicast list has completed the multicast replication task: obtaining the current number of entries in the circular list from the multicast access table, wherein the current number of entries in the circular list is used to characterize the lifecycle of the circular multicast list for multicast replication; if the current number of entries in the circular list is not a first preset value, then the circular multicast list is identified as not having completed the multicast replication task; if the current number of entries in the circular list is a first preset value, then the circular multicast list is identified as having completed the multicast replication task.
[0051] After identifying that the circular multicast linked list has not completed the multicast replication task, the step of obtaining the next hop address is executed.
[0052] Specifically, to improve multicast replication, since the circular multicast list is a circular linked list structure, this embodiment proposes to monitor and process the multicast replication tasks of the circular multicast list to avoid continuous multicast replication loops. When it is identified that the circular multicast list has not completed the multicast replication task, the next-hop address is obtained so that the multicast replication operation can be performed based on the next multicast packet arrival. Since the ring head address in the multicast access table is dynamically changing, the order of each multicast replication is effectively refreshed, thereby better solving the problem that the priority order of downstream devices obtaining multicast packets is fixed when using a straight linked list for multicast packet replication due to the fixed order of each entry in the straight linked list.
[0053] Furthermore, to better identify the completion status of the multicast replication task of the circular multicast list, this embodiment proposes maintaining the number of entries in the circular multicast list within the aforementioned multicast access table. This number of entries is used to characterize the lifecycle of the circular multicast list used for multicast replication. A larger number of entries indicates a longer multicast replication lifecycle, while a smaller number indicates a shorter lifecycle. When the number of entries is 0, it indicates that the lifecycle of the circular multicast list used for multicast replication has terminated.
[0054] Based on this, the first setting value can be set to 0. Thus, after the message replication operation for this multicast message is completed based on the target entry, the current number of entries in the circular linked list can be obtained from the multicast access entry. If the current number of entries in the circular linked list is 0, it indicates that the lifecycle of the circular multicast linked list used for multicast replication has ended, meaning that the circular multicast linked list has completed its multicast replication task. If the current number of entries in the circular linked list is not 0, it indicates that the circular multicast linked list has not yet completed its multicast replication task.
[0055] Furthermore, if the identified circular multicast list has not completed the multicast replication task, this embodiment proposes to decrement the number of entries in the current circular list according to a second preset value.
[0056] Specifically, the second setting value mentioned above can be 1. Based on this, since the currently identified circular multicast list has not yet completed the multicast replication task, but has already performed a multicast message replication operation based on the found target entry, the number of entries in the current circular list in the multicast access entry can be decremented by 1 to obtain the number of entries in the circular list after the decrement operation, so as to facilitate the next multicast replication task.
[0057] In another embodiment, the following method can be used to identify whether the ring multicast list has completed the multicast replication task: when the multicast access entry only maintains the ring head address, it is identified whether the counter corresponding to the ring multicast list has reached a set count value, which is the number of entries in the ring multicast list; when the set count value is reached, it indicates that the ring multicast list has completed the multicast replication task; if the set count value is not reached, it indicates that the ring multicast list has not yet completed the multicast replication task.
[0058] Optionally, based on any of the above embodiments, the method for obtaining multicast access entries in this embodiment is as follows: obtaining the multicast access entry address from the message accompanying information or message header of the multicast message; and obtaining the multicast access entry using the multicast access entry address.
[0059] Specifically, after acquiring a multicast message, the multicast message is identified. If the identification indicates that the multicast message needs to be copied, a multicast access table entry address is added to the message comma information or the message header. Accordingly, the aforementioned multicast message is the multicast message to be copied this time. In this way, after acquiring the multicast message to be copied, the network device can obtain the aforementioned multicast access table entry address from the message comma information or the message header, and then use the multicast access table entry address to retrieve the multicast access table entry.
[0060] It should be noted that when the network device includes a processing core and a forwarding chip, the processing core, upon receiving a multicast message, can identify the multicast message. If the multicast message requires message copying, it writes the multicast access table entry address into the message accompaniment information or message header to obtain the multicast message to be copied. Then, the processing core can send it to the forwarding chip, which performs message forwarding. Upon receiving the multicast message, the forwarding chip can obtain the multicast access table entry address from the message accompaniment information or message header, thus obtaining the multicast access table entry. After obtaining the multicast access table entry, the forwarding chip executes the multicast message copying process proposed in any embodiment of this application.
[0061] It is worth noting that the processing core can identify whether the multicast message header includes a multicast message replication identifier. If it does, it determines that the multicast message needs to be replicated.
[0062] By providing the above-mentioned multicast message replication method, which adopts a ring multicast link structure for multicast message replication, the table entry address for the next multicast message replication can be updated each time the multicast message replication process is executed. This effectively solves the problem that the downstream devices have a fixed priority order for obtaining multicast replicated messages due to the fixed execution order when performing multicast message replication in a straight linked list structure.
[0063] Corresponding to the embodiments of the foregoing methods, this specification also provides an embodiment of a multicast message copying apparatus and the computer equipment on which it is applied. The above-described multicast message copying apparatus can be found in [reference needed]. Figure 3 As shown, it may include:
[0064] The first acquisition module 301 is used to obtain the current ring head address from the multicast access table entry for the multicast packet to be copied this time;
[0065] The query module 302 is used to query the ring multicast linked list using the current ring start address to obtain the target entry corresponding to the current ring start address. The entries in the ring multicast linked list are linked in a ring structure.
[0066] The replication module 303 is used to perform a replication operation on the multicast message based on the target entry;
[0067] The second acquisition module 304 is used to acquire the next-hop address;
[0068] The update module 305 is used to update the value of the current ring head address in the multicast access entry to the next hop address.
[0069] In the multicast message replication device described above, for the multicast message to be replicated, the current ring head address is obtained from the multicast access table; the current ring head address is used to query the ring-shaped multicast linked list to obtain the target entry corresponding to the current ring head address, wherein the entries in the ring-shaped multicast linked list are linked in a ring structure; the replication operation is performed on the multicast message based on the target entry; if it is identified that the ring-shaped multicast linked list has not completed the multicast replication task, the next-hop address is obtained; and the value of the current ring head address in the multicast access table is updated to the next-hop address. In this way, the ring head address in the multicast access table can be dynamically updated, so that when the next multicast packet arrives, the corresponding table entry can be found based on the updated ring head address. In other words, the table entry found based on the dynamic ring head address is not fixed each time, which makes the order in which the copied multicast packets are forwarded also not fixed. This solves the problem that when multicast packets are copied in the form of a straight linked list, the order of downstream devices obtaining multicast packets is fixed because the order of each entry in the straight linked list is fixed.
[0070] Optionally, based on the above embodiments, the multicast message replication apparatus provided in this embodiment may further include:
[0071] An identification module (not shown in the figure) is used to identify whether the circular multicast list has completed the multicast replication task according to the following method: obtaining the current number of entries in the circular list from the multicast access entries, wherein the current number of entries in the circular list is used to characterize the lifecycle of the circular multicast list for multicast replication; if the current number of entries in the circular list is not a first preset value, then the circular multicast list is identified as having not completed the multicast replication task; if the current number of entries in the circular list is a first preset value, then the circular multicast list is identified as having completed the multicast replication task.
[0072] The second acquisition module is specifically used to execute the step of acquiring the next hop address after the identification module identifies that the circular multicast linked list has not completed the multicast replication task.
[0073] Optionally, the update module 305 is further configured to, if the identification module identifies that the circular multicast list has not completed the multicast replication task, decrement the number of entries in the current circular multicast list according to a second preset value.
[0074] Based on any of the above embodiments, the multicast message replication apparatus provided in this embodiment may further include:
[0075] The third acquisition module (not shown in the figure) is used to obtain the multicast access entry address from the message accompanying information or message header of the multicast message; and to obtain the multicast access entry using the multicast access entry address.
[0076] The embodiments of the multicast message replication device described in this specification can be applied to computer devices, such as network devices. The device embodiments can be implemented through software, hardware, or a combination of both. Taking software implementation as an example, as a logical device, it is formed by the forwarding chip of the multicast message replication system reading the corresponding computer program instructions from non-volatile memory into memory for execution. From a hardware perspective, such as... Figure 4 The diagram shown is a hardware structure diagram of a computer device containing the multicast message copying device according to an embodiment of this specification. Except for... Figure 4 In addition to the processor 410, memory 430, network interface 420, non-volatile memory 440, and forwarding chip shown, the network device or electronic device where the multicast message copying device 431 is located in the embodiment may also include other hardware depending on the actual function of the computer device, which will not be described in detail here.
[0077] Accordingly, this specification also provides a multicast message copying apparatus, the apparatus including a processor; a memory for storing processor-executable instructions; wherein the processor is configured to:
[0078] For the multicast message to be replicated, the current ring head address is obtained from the multicast access table; the current ring head address is used to query the ring multicast linked list to obtain the target entry corresponding to the current ring head address, wherein the entries in the ring multicast linked list are linked in a ring structure; a replication operation is performed on the multicast message based on the target entry; if it is found that the ring multicast linked list has not completed the multicast replication task, the next hop address is obtained; the value of the current ring head address in the multicast access table is updated to the next hop address.
[0079] By adopting a ring-shaped multicast link structure for multicast packet replication, the table entry address for the next multicast packet replication can be updated each time the multicast packet replication process is executed. This effectively solves the problem of fixed priority order for downstream devices to obtain multicast replicated packets when performing multicast packet replication in a straight-linked list structure due to the fixed execution order.
[0080] The specific implementation process of the functions and roles of each module in the above device can be found in the implementation process of the corresponding steps in the above method, and will not be repeated here.
[0081] For the device embodiments, since they basically correspond to the method embodiments, the relevant parts can be referred to in the description of the method embodiments. The device embodiments described above are merely illustrative. The modules described as separate components may or may not be physically separate, and the components shown as modules may or may not be physical modules, that is, they may be located in one place or distributed across multiple network modules. Some or all of the modules can be selected to achieve the purpose of the solution in this specification according to actual needs. Those skilled in the art can understand and implement this without creative effort.
[0082] The foregoing has described exemplary embodiments of this specification. It should be understood that in some cases, the modules described in this specification may be divided in a manner different from that in the embodiments, and the described actions or steps may be performed in a different order than that in the embodiments, while still achieving the desired result. Furthermore, the processes depicted in the accompanying drawings do not necessarily require a specific or sequential order to achieve the desired result. In some embodiments, multitasking and parallel processing are also possible or may be advantageous.
[0083] Other embodiments of this specification will readily occur to those skilled in the art upon consideration of the specification and practice of the invention claimed herein. This specification is intended to cover any variations, uses, or adaptations that follow the general principles of this specification and include common knowledge or customary techniques in the art not illustrated herein.
[0084] The above description is merely a preferred embodiment of this specification and is not intended to limit this specification. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this specification should be included within the scope of protection of this specification.
Claims
1. A method for multicast message replication, characterized in that, The method includes: For the multicast message to be copied, obtain the current ring head address from the multicast access table entry; The current ring start address is used to query the ring multicast linked list to obtain the target entry corresponding to the current ring start address. The entries in the ring multicast linked list are linked in a ring structure. Perform a copy operation on the multicast message based on the target entry; Get the next hop address; Update the value of the current ring head address in the multicast access entry to the next hop address; Before obtaining the next-hop address, the method further includes the following steps to identify whether the circular multicast list has completed the multicast replication task: obtaining the current number of entries in the circular list from the multicast access entries, wherein the current number of entries in the circular list is used to characterize the lifecycle of the circular multicast list for multicast replication; if the current number of entries in the circular list is not a first preset value, then the circular multicast list is identified as not having completed the multicast replication task; if the current number of entries in the circular list is a first preset value, then the circular multicast list is identified as having completed the multicast replication task. After identifying that the circular multicast linked list has not completed the multicast replication task, the step of obtaining the next hop address is executed.
2. The method according to claim 1, characterized in that, If the circular multicast list is found to have failed to complete the multicast replication task, the method further includes: The number of entries in the current circular linked list is decremented according to the second set value.
3. The method according to claim 1, characterized in that, The method for obtaining the multicast access table entry is as follows: Obtain the multicast access table entry address from the message accompanying information or message header of the multicast message; The multicast access entry is obtained using the multicast access entry address.
4. A multicast message copying device, characterized in that, The device includes: The first acquisition module is used to obtain the current ring head address from the multicast access table entry for the multicast packet to be copied this time; The query module is used to query the ring multicast linked list using the current ring start address to obtain the target entry corresponding to the current ring start address. The entries in the ring multicast linked list are linked in a ring structure. The replication module is used to perform a replication operation on the multicast message based on the target entry; The second acquisition module is used to acquire the next-hop address; The update module is used to update the value of the current ring head address in the multicast access table entry to the next hop address; The device further includes: The identification module is used to identify whether the circular multicast list has completed the multicast replication task according to the following method: obtaining the current number of entries in the circular list from the multicast access entries, wherein the current number of entries in the circular list is used to characterize the lifecycle of the circular multicast list for multicast replication; if the current number of entries in the circular list is not a first preset value, then the circular multicast list is identified as having not completed the multicast replication task; if the current number of entries in the circular list is a first preset value, then the circular multicast list is identified as having completed the multicast replication task. The second acquisition module is specifically used to execute the step of acquiring the next hop address after the identification module identifies that the circular multicast linked list has not completed the multicast replication task.
5. The apparatus according to claim 4, characterized in that, The update module is further configured to, if the identification module identifies that the circular multicast linked list has not completed the multicast replication task, decrement the number of entries in the current circular linked list according to a second preset value.
6. The apparatus according to claim 4, characterized in that, The device further includes: The third acquisition module is used to obtain the multicast access entry address from the message accompanying information or message header of the multicast message; and to obtain the multicast access entry using the multicast access entry address.
7. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a computer program that, when executed by a processor, performs the method as described in any one of claims 1 to 3.
8. A computer device, characterized in that, The device includes a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor, when executing the program, performs the following method: For the multicast message to be copied, obtain the current ring head address from the multicast access table entry; The current ring start address is used to query the ring multicast linked list to obtain the target entry corresponding to the current ring start address. The entries in the ring multicast linked list are linked in a ring structure. Perform a copy operation on the multicast message based on the target entry; Get the next hop address; Update the value of the current ring head address in the multicast access entry to the next hop address; Before obtaining the next-hop address, the method further includes the following steps to identify whether the circular multicast list has completed the multicast replication task: obtaining the current number of entries in the circular list from the multicast access entries, wherein the current number of entries in the circular list is used to characterize the lifecycle of the circular multicast list for multicast replication; if the current number of entries in the circular list is not a first preset value, then the circular multicast list is identified as not having completed the multicast replication task; if the current number of entries in the circular list is a first preset value, then the circular multicast list is identified as having completed the multicast replication task; after identifying that the circular multicast list has not completed the multicast replication task, the step of obtaining the next-hop address is executed.