Zero-configuration opening method, device and system, electronic equipment and program product
By introducing the IPv6 multicast group communication mechanism in the zero-configuration commissioning of network devices, the message impact problem caused by DHCP server dependence is solved, and efficient and impact-free multi-device commissioning process tracking is achieved.
Patent Information
- Application Number
- CN202511210178.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-08-27
- Publication Date
- 2025-11-18
AI Technical Summary
In existing technologies, the zero-configuration setup process of network devices relies on a DHCP server, which can lead to packet intrusion from other devices in the local area network. Furthermore, it is inefficient and cannot effectively track the setup process.
The introduction of IPv6 multicast group mechanism enables the devices to be commissioned and the commissioning server to join the same IPv6 multicast group, communicate via multicast, and use preset message formats to identify different commissioning stages, thus avoiding reliance on DHCP servers.
It reduces the impact of packets on other devices on the local area network, improves the commissioning efficiency, supports simultaneous commissioning of multiple devices, and can effectively track the commissioning process.
Smart Images

Figure CN120979934A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of data communication technology, and more specifically, to a zero-configuration start-up method, apparatus, system, electronic device, and program product. Background Technology
[0002] Zero-configuration commissioning refers to the process by which newly manufactured or unconfigured network devices automatically acquire configuration information and perform configuration deployment upon power-on. The current process for zero-configuration commissioning of network devices typically includes the following steps: Step 1: User generates configuration file.
[0003] Step 2: Edit the intermediate files of the device. The intermediate files store the information for the initial setup of multiple devices. Associate each device's unique identifier with the corresponding configuration file, version file, and other target file information. The unique identifier may be the device serial number, the device MAC (Media Access Control address), the device hostname, or other information that can uniquely identify the device.
[0004] Step 3: Set up a DHCP (Dynamic Host Configuration Protocol) server, configure the DHCP server to send the DHCP address, options, file server and other information required for device startup, and import the configuration file generated in Step 1 and the intermediate files, version files and other target information files edited in Step 2 into the file server, and start the file server and DHCP server.
[0005] Step 4: The device to be started is physically connected to the DHCP server and file server to enter the zero-configuration startup process.
[0006] Step 5: The device to be deployed sends a DHCP request to obtain the IP address, file server address, intermediate file name, and corresponding username and password from the DHCP server. Then, the device downloads the intermediate file from the file server, parses the intermediate file, obtains the corresponding configuration file from the intermediate file based on the device's unique identifier, and then downloads the configuration file, version file, and other information from the file server.
[0007] Step 6: The device to be started parses the configuration file, checks the configuration file format, etc. After the format check is passed, it overwrites the device configuration file, the device downloaded version file and other target information, restarts the device, loads the configuration after restarting, applies the configuration, applies other target file information, and completes the start-up.
[0008] Step 7: If an error occurs during the editing of the configuration file, it may affect the loading of the entire configuration file (for example, if a certain configuration is wrong, the configuration of the entire command cannot be loaded, or if some command characters are edited incorrectly, the device may not recognize it).
[0009] Step 8: The user logs into the device and views the initial results.
[0010] The aforementioned zero-configuration setup method relies heavily on a DHCP server. Since there are usually multiple DHCP servers in a local area network, the DHCP messages sent during the device setup process are broadcast messages, which can cause message impact on other non-configuration devices in the local area network. Summary of the Invention
[0011] The purpose of this invention is to provide a zero-configuration commissioning method, apparatus, system, electronic device, and program product that can avoid message impacts on other non-commissioning devices in the local area network during the commissioning process.
[0012] The embodiments of the present invention can be implemented as follows: In a first aspect, the present invention provides a zero-configuration commissioning method, applied to a device to be commissioned, the method comprising: When accessing a local area network, join the IPv6 multicast group to which the initial server belongs; Send an initialization request message to the IPv6 multicast group to request an initialization file; Receive the commissioning response message returned by the commissioning server to the IPv6 multicast group based on the commissioning request message; The device is commissioned based on the commissioning file in the commissioning response message.
[0013] In an optional implementation, the method further includes: When accessing a local area network, IPv6 communication is enabled and a link-local address is generated to send messages based on the link-local address.
[0014] In an optional implementation, before the step of sending an activation request message to the IPv6 multicast group to request the activation file, the following steps are included: The IPv6 multicast group address is used as the destination address, and the start-up request message is generated according to the preset message format. The preset start-up message type field in the start-up request message is a first preset value.
[0015] In an optional implementation, the step of implementing the commissioning of this device based on the commissioning file in the commissioning response message includes: Obtain the necessary setup information for this device from the setup file; A download request message carrying the initial information is generated according to a preset message format and sent to the IPv6 multicast group. The preset initial message type field in the download request message is a second preset value. Receive the target file indicated by the commissioning information returned by the commissioning server to the IPv6 multicast group based on the download request message; The device is started based on the target file.
[0016] In an optional implementation, after the step of implementing the device's initialization based on the target file, the following steps are included: According to the preset message format, a notification message carrying the initialization information of this device is generated and sent to the IPv6 multicast group, so that the initialization server records the initialization information after receiving the notification message. The preset initialization message type field in the notification message is a third preset value.
[0017] Secondly, the present invention provides a zero-configuration start method, applied to a start server, the method comprising: Receive an initialization request message for requesting an initialization file. The initialization request message is sent by the device to be initiated to the IPv6 multicast group after it joins the IPv6 multicast group to which the initialization server belongs when it accesses the local area network. Based on the commissioning request, a commissioning response message carrying the commissioning file is returned to the IPv6 multicast group, so that the device to be commissioned can perform commissioning based on the commissioning file in the commissioning response message.
[0018] In an optional implementation, the method further includes: Receive a message in a preset message format sent by the device to be commissioned; The current commissioning status of the device to be commissioned is determined and recorded based on the preset commissioning message type field in the preset message format.
[0019] Thirdly, the present invention provides a zero-configuration commissioning device, applied to a device to be commissioned, the device comprising: The join module is used to join the IPv6 multicast group to which the initial server belongs when accessing a local area network; The request sending module is used to send an initialization request message to the IPv6 multicast group to request an initialization file. The response receiving module is used to receive the configuration response message returned by the commissioning server to the IPv6 multicast group based on the commissioning request message; The commissioning module is used to perform commissioning of this device based on the commissioning file in the configuration response message.
[0020] Fourthly, the present invention provides a zero-configuration start-up device for use in a start-up server, the device comprising: The request receiving module is used to receive a startup request message for requesting a startup file. The startup request message is sent by the device to be started to the IPv6 multicast group after it joins the IPv6 multicast group to which the startup server belongs when it accesses the local area network. The response sending module is used to return an opening response message carrying the opening file to the IPv6 multicast group based on the opening request, so that the device to be opened can realize the opening of the device based on the opening file in the opening response message.
[0021] Fifthly, the present invention provides an electronic device including a processor and a memory, the memory being used to store a program, and the processor being used to implement the zero-configuration start method described in the first aspect and / or the zero-configuration start method described in the second aspect when executing the program.
[0022] In a sixth aspect, the present invention provides a program product that, when executed by a processor, implements the zero-configuration start method described in the first aspect above, and / or the zero-configuration start method described in the second aspect above.
[0023] In a seventh aspect, the present invention provides a zero-configuration start system, the system comprising a device to be started and a start server, the device to be started being used to execute the zero-configuration start method as described in the first aspect above, and the start server being used to execute the zero-configuration start method as described in the second aspect above.
[0024] Compared with the prior art, the present invention has the following beneficial effects: This invention introduces a pre-joined IPv6 multicast server. When a device to be commissioned connects to the local area network, it joins the IPv6 multicast group to which the pre-commissioning server belongs. The device to be commissioned sends a commissioning request message to the IPv6 multicast group, and the pre-commissioning server replies with a commissioning response message. Since the device to be commissioned and the pre-commissioning server are joined to the same IPv6 multicast group, they communicate with each other via multicast. The impact is controlled within the IPv6 multicast group, avoiding message impact on other non-commissioning devices in the local area network. Attached Figure Description
[0025] To more clearly illustrate the technical solutions of the embodiments of the present invention, the accompanying drawings used in the embodiments will be briefly introduced below. It should be understood that the following drawings only show some embodiments of the present invention and should not be regarded as a limitation on the scope. For those skilled in the art, other related drawings can be obtained based on these drawings without creative effort.
[0026] Figure 1 A network topology diagram that enables zero-configuration setup for existing technologies.
[0027] Figure 2 This is a network topology diagram for zero-configuration startup provided in this embodiment.
[0028] Figure 3 This is a flowchart illustrating the zero-configuration commissioning method for devices to be commissioned, as provided in this embodiment.
[0029] Figure 4 This is a flowchart illustrating the zero-configuration startup method for a startup server provided in this embodiment.
[0030] Figure 5 This is a block diagram illustrating a zero-configuration commissioning device applied to a device to be commissioned, as provided in this embodiment.
[0031] Figure 6 This is a block diagram illustrating a zero-configuration startup device for a startup server provided in this embodiment.
[0032] Figure 7 This is an example diagram illustrating the interaction between the device to be commissioned and the commissioning server provided in this embodiment.
[0033] Figure 8 This is a block diagram of the electronic device provided in this embodiment.
[0034] Icons: 10-Electronic device; 11-Processor; 12-Memory; 13-Bus; 100-Zero-configuration commissioning device applied to the device to be commissioned; 110-Joining module; 120-Request sending module; 130-Response receiving module; 140-Commissioning module; 200-Zero-configuration commissioning device applied to the commissioning server; 210-Request receiving module; 220-Response sending module. Detailed Implementation
[0035] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. The components of the embodiments of the present invention described and shown in the accompanying drawings can generally be arranged and designed in various different configurations.
[0036] Therefore, the following detailed description of the embodiments of the invention provided in the accompanying drawings is not intended to limit the scope of the claimed invention, but merely to illustrate selected embodiments of the invention. All other embodiments obtained by those skilled in the art based on the embodiments of the invention without inventive effort are within the scope of protection of the invention.
[0037] It should be noted that similar labels and letters in the following figures indicate similar items. Therefore, once an item is defined in one figure, it does not need to be further defined and explained in subsequent figures.
[0038] In the description of this invention, it should be noted that if terms such as "upper," "lower," "inner," or "outer" are used to indicate the orientation or positional relationship based on the orientation or positional relationship shown in the accompanying drawings, or the orientation or positional relationship in which the product of this invention is usually placed, they are only for the convenience of describing this invention and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, or be constructed and operated in a specific orientation, and therefore should not be construed as a limitation of this invention.
[0039] Furthermore, the terms "first" and "second" are used only to distinguish descriptions and should not be interpreted as indicating or implying relative importance.
[0040] It should be noted that, where there is no conflict, the features in the embodiments of the present invention can be combined with each other.
[0041] This embodiment first introduces existing application scenarios for zero-configuration startup. Please refer to... Figure 1 , Figure 1 A network topology diagram for zero-configuration setup using existing technologies. Figure 1 The network includes the device to be commissioned, a DHCP server, a file server, and a PC. The DHCP server is pre-deployed with the DHCP options required for commissioning, and the file server pre-stores intermediate files, version files, and other target information files containing device commissioning information, and has file transfer services enabled. The PC communicates with the device to be commissioned via a serial port to track the commissioning process in real time. The zero-configuration commissioning process of existing technologies has been described in detail in the aforementioned background section and will not be repeated here.
[0042] It should be noted that, Figure 1 In the network topology diagram, the PC is optional. If it is not necessary to track the startup process, the PC can be omitted.
[0043] It should also be noted that the DHCP server and file server can be two separate devices, or the DHCP service and file service can be enabled on the same device at the same time, which can also achieve zero-configuration start-up of the device to be started.
[0044] The zero-configuration setup method described above, which relies on a DHCP server, has the following main problems: (1) A DHCP server needs to be deployed in the environment, and the DHCP server needs to strictly deploy the DHCP options required for device startup.
[0045] (2) Since DHCP messages are used to obtain information during the setup process, and DHCP technology is one of the main means of address allocation in a local area network, there may be more than one DHCP server. Moreover, not all the information sent by the DHCP server can support the device to complete the zero-configuration setup. After the device sends a request, there is no priority for the server's message. The request is processed first. If the device receives the message from a non-startup DHCP server, the setup process will fail.
[0046] (3) During the device commissioning process, the server was requested to allocate an IP address. However, this IP address is only used during the zero-configuration commissioning process and will not be used after the device commissioning is completed. However, this IP address resource is always occupied during the commissioning process.
[0047] (4) A file server needs to be deployed in the environment. If multiple devices of the same model need to be started at the same time, such as 1,000 devices, then each device needs to download the version file from the file server once, which will take a total of 1,000 times, which is not efficient.
[0048] (5) Since the DHCP messages sent during the initial setup process are broadcast messages, they still cause some invalid message impact on other devices in the network (non-initial setup devices).
[0049] (6) Neither the DHCP server nor the file server has complete information on the device commissioning process, such as which stage the device commissioning has reached. This information cannot be seen on a single server.
[0050] In view of this, this embodiment provides a zero-configuration commissioning method, apparatus, system, electronic device, and program product. Its core improvement lies in the introduction of a commissioning server. Since it no longer relies on a DHCP server, it avoids the problem of potential commissioning failures caused by receiving information from a non-commissioning DHCP server. By adding the device to be commissioned and the commissioning server to the same IPv6 multicast group, packets during the commissioning process are transmitted only within the IPv6 multicast group, avoiding packet impact on other non-commissioning devices in the local area network during the commissioning process. It also supports simultaneous commissioning of multiple devices. Because the device to be commissioned uses a link-local address, it avoids the problem of address resource temporary use caused by IP address allocation during the commissioning process. During the commissioning process, a preset commissioning packet type field is used in the packets to represent different commissioning stages, making it easier to track the commissioning process. This will be described in detail below.
[0051] First, we introduce the network topology diagram for the zero-configuration start-up application scenario provided in this embodiment. Please refer to... Figure 2 , Figure 2 This is a network topology diagram for zero-configuration startup provided in this embodiment. Figure 2 The network includes two devices to be commissioned: Device 1 and Device 2. Both are connected to the commissioning server through a Layer 2 switch. When Device 1 and Device 2 access the network, they join the same IPv6 multicast group as the commissioning server. Thereafter, the devices to be commissioned and the commissioning server communicate with each other through the IPv6 multicast group until the commissioning of the devices to be commissioned is completed.
[0052] The equipment to be commissioned can be any network device that is newly manufactured, has no configuration, or has a partial configuration. Network devices include, but are not limited to, routing devices (e.g., routers), switching devices (e.g., switches), access devices (e.g., wireless access points), and firewalls.
[0053] The starting server can be an entity or a virtual computer device that provides the services required for starting the game.
[0054] It should be noted that, Figure 2 This is just an example of a network topology. Depending on the actual network requirements, a Layer 2 switch may not be used; instead, a hub can be used to connect the devices to be commissioned and the commissioning server. There can be one or more devices to be commissioned.
[0055] Next, this embodiment will introduce the applications applied to both the device to be commissioned and the commissioning server. Figure 2 For the zero-configuration start method, please refer to Figure 3 , Figure 3 This is a flowchart illustrating a zero-configuration commissioning method for a device to be commissioned, as provided in this embodiment. The method includes the following steps: Step S101: When accessing the local area network, join the IPv6 multicast group to which the initial server belongs.
[0056] In this embodiment, to avoid affecting the normal communication of other devices in the local area network, the address of the IPv6 multicast group can use any reserved IPv6 multicast address, such as ff02::1:aa. The device to be connected automatically joins this IPv6 multicast group when accessing the network using its IPv6 protocol stack functionality, thereby enabling it to process multicast packets sent by the initial connection server.
[0057] Step S102: Send an Opening Request message to the IPv6 multicast group to request an Opening File.
[0058] In this embodiment, the setup file is pre-stored on the setup server. The setup file includes setup information for the devices to be set up. When there are multiple devices to be set up, each device can have its own setup file. Of course, multiple devices can also share a single setup file. In this case, the setup file stores setup information for multiple devices, associating the unique identifier of each device with its corresponding configuration file, version file, and other target file information. The unique identifier of the device to be set up includes, but is not limited to, the device serial number, the device system MAC address, the device hostname, and at least one of other information that can uniquely identify the device to be set up.
[0059] In this embodiment, the commissioning request message is a message constructed by the device to be commissioned to request the commissioning server to obtain the commissioning file of the device. The destination address of the commissioning request message is the IPv6 multicast group. Therefore, all devices in the IPv6 multicast group, including the commissioning server, can listen to the commissioning request message.
[0060] Step S103: Receive the commissioning response message returned by the commissioning server to the IPv6 multicast group based on the commissioning request message.
[0061] In this embodiment, since the commissioning server is also within the IPv6 multicast group, it will also receive the commissioning request message. After receiving the commissioning request message, the commissioning server will find the corresponding commissioning file of the device to be commissioned in the commissioning request message, and send the commissioning response message to all devices in the IPv6 multicast group, carrying the commissioning file. Since the device to be commissioned is within the IPv6 multicast group, the device to be commissioned can receive the commissioning response message.
[0062] Step S104: Perform the commissioning of this device based on the commissioning file in the commissioning response message.
[0063] In this embodiment, the device to be commissioned can obtain the version file and configuration file index information of the device, such as the file name or the storage address of the file, from the commissioning file. Then, based on this index information, it can directly obtain these files to complete the commissioning of the device.
[0064] The method provided in this embodiment adds the device to be commissioned and the commissioning server to the same IPv6 multicast group, and the two communicate with each other via multicast. The impact is controlled within the IPv6 multicast group, avoiding message impact on other non-commissioning devices in the local area network.
[0065] In an optional implementation, to avoid wasting IP address resources, this embodiment provides an implementation method: When accessing a local area network, IPv6 communication is enabled and a link-local address is generated to send messages based on the link-local address.
[0066] In this embodiment, enabling IPv6 communication means that the network protocol stack of the device to be deployed starts the IPv6 protocol module, enabling it to have basic IPv6 data packet sending and receiving capabilities. A link-local address is a special address in the IPv6 address space used for communication within the same link range. This address is automatically configured and generated when the device to be deployed connects to the local area network, ensuring that the device can communicate with other devices within the local link range based on the link-local address.
[0067] In an optional implementation, to facilitate determining the current setup phase, this embodiment also provides a method for generating a setup request message: The IPv6 multicast group address is used as the destination address, and a start request message is generated according to the preset message format. The preset start message type field in the start request message is the first preset value.
[0068] In this embodiment, the preset message format is a message format that can be carried by IPv6, has available reserved value fields for customizing the initialization message identifier, available reserved fields or extended fields, and can be transmitted independently of IP addresses. For example, it could be an ICMPv6 (Internet Control Message Protocol v6) message format or a UDP (User Datagram Protocol) message format. The preset initialization message type field is an available reserved field or extended field in the preset message format, representing the specific type of the initialization message. The message sender can assign different values to the preset initialization message type field at different initialization stages, allowing users to track the initialization process based on the value of the preset initialization message type field in the message. For example, when the preset initialization message type field is the first preset value, it means that the initialization of the device to be initiated has just begun.
[0069] To more intuitively describe the preset message format used in the commissioning process of this embodiment, this embodiment uses ICMPv6 format as an example. The reserved value 150 of the message type field in ICMPv6 format is used as the custom commissioning message identifier in this embodiment. The specific preset message format of this embodiment is shown in Table 1: Table 1
[0070] The meanings of each field in Table 1 are as follows: Type: 1 byte, standard ICMPv6 message field. In this embodiment of the invention, the reserved value of 150 is used as the custom opening message identifier. Other reserved ICMPv6 type values, such as 151, can also be used.
[0071] Code: 1 byte, standard ICMPv6 message field, usually 0.
[0072] Checksum: A standard ICMPv6 message field, representing the checksum of the entire header.
[0073] Identifier: A custom field whose length represents the unique identifier carried by the device during the setup process. When the serial number is used as the unique identifier, this field is the serial number of the device; when the system MAC address of the device is used as the unique identifier, this field is the system MAC address of the device; when the hostname of the device is used as the unique identifier, this field is the hostname of the device; for other identifier types, this field is the corresponding value. When this field is set to all 1s, it indicates the setup server identifier.
[0074] Identifier type: A custom field, 1 byte long, representing the identifier type of the device to be configured. 0 indicates the device serial number, 1 indicates the system MAC address, 2 indicates the device hostname, and other values can be defined as needed. When this field is set to 255, it indicates the configuration server identifier.
[0075] Ztp-type: A custom field, 1 byte long, indicating the specific type of the initiation message. 1 indicates an initiation request message, 2 indicates an initiation response message, 3 indicates a download request message, 4 indicates a download response message, and 5 indicates a notification message used to report the initiation results. Other types can be added as needed.
[0076] C: Custom field, 1 bit long, set to 1 when requesting to download the configuration file.
[0077] I: Custom field, 1 bit long, set to 1 when requesting to download the image file.
[0078] Reserved: A custom reserved field, 6 bits, indicating that when requesting other information, such as stack configuration, patch information, etc., it will be placed in the corresponding position according to the agreement with the launch server.
[0079] Opt Code: A custom reserved field with a length of 1 byte. A value of 0 indicates that the operation was successful, while a non-zero value indicates a different error type.
[0080] data: The message data field carries the main content of the initialization, such as the intermediate files, version files, and configuration files, as well as the initialization result report (if a message cannot carry this content, it can be carried in multiple messages, and can be distinguished by the message sequence number and message identifier in the content).
[0081] Another embodiment of the present invention is illustrated using a UDP packet format. The source port and destination port in the UDP packet format are used to carry the identifier of the custom opening packet of the present invention embodiment (for example, setting both the source port and destination port to 50000 to identify the UDP packet as the custom opening packet of the present invention embodiment). The preset packet format of the present invention embodiment is shown in Table 2: Table 2
[0082] In Table 2 above, Source Port, Destination Port, Length, and Checksum are standard UDP packet fields. The meanings of the custom fields in the UDP packet payload are the same as in Table 1, and will not be repeated here. The preset packet formats in Tables 1 and 2 are only examples and are not intended to limit the specific content of the invention.
[0083] Based on the preset message format in Table 1 or Table 2, the preset initial message type field is the "Ztp-type" field, with a first preset value of 1, a second preset value of 3, and a third preset value of 5.
[0084] In an optional implementation, after receiving the commissioning response message, this embodiment also provides a method for implementing the commissioning of this device based on the commissioning response message: First, obtain the necessary setup information for this device from the setup file; In this embodiment, the initial setup information includes, but is not limited to, image files and configuration files. In addition, it may also include patch files, stack files, etc.
[0085] Secondly, a download request message carrying the initial information is generated according to the preset message format and sent to the IPv6 multicast group. The preset initial message type field in the download request message is the second preset value. In this embodiment, taking the preset message format of Table 1 or Table 2 above as an example, the second preset value is 3. When the initial information is an image file, the identifier of the image file is set in the Option data, and the I bit is set to 1; when the initial information is a configuration file, the identifier of the configuration file is set in the Option data, and the C bit is set to 1.
[0086] Third, receive the target file indicated by the commissioning information returned by the commissioning server to the IPv6 multicast group based on the download request message; In this embodiment, the target file is the file requested by the download request message. Taking the preset message format in Table 1 or Table 2 above as an example, after the initiation server receives two messages with a preset initiation message type field Ztp-type of 3 from the device to be initiated, it determines whether it is requesting an image file or a configuration file based on the settings of the I and C bits. When requesting an image file, the initiation server puts the image file in Data, sets the preset initiation message type field Ztp-type to 4, sets Identifier to all 1s (indicating it is the initiation server), Identifier type to 255, sets the I bit to 1, and the destination address to ff02::1:aa (the address of the IPv6 multicast group). When requesting a configuration file, the initiation server puts the configuration file in Data, sets the preset initiation message type field Ztp-type to 4, sets Identifier to all 1s (indicating it is the initiation server), Identifier type to 255, sets the C bit to 1, and the destination address to ff02::1:aa (the address of the IPv6 multicast group).
[0087] When the requested file is another file, such as a patch file, the initiation server puts the patch file in the Data field, sets the default initiation message type field Ztp-type to 4, sets the Identifier to all 1s (indicating it is the initiation server), sets the Identifier type to 255, sets the first bit of Reserved to 1, and sets the destination address to ff02::1:aa (the address of the IPv6 multicast group).
[0088] Finally, the device is started based on the target file.
[0089] It should be noted that when multiple devices are awaiting commissioning, each device will send a download request message to the IPv6 multicast group. If the target files requested by multiple devices are the same—for example, multiple devices sending download request messages for configuration files to the commissioning server, and the configuration files are identical—the commissioning server can send a download response message to the IPv6 multicast group upon receiving a preset number of download request messages for configuration files. Since all devices are within the IPv6 multicast group, they will all receive the configuration file in the download response message, thus improving file download efficiency. Alternatively, the commissioning server can wait a preset time after receiving the first request message before sending another download response message to the IPv6 multicast group, achieving the same improved file download efficiency.
[0090] It should also be noted that for devices that have already been commissioned, if the user manually triggers commissioning when the image file needs to be updated during the device's operation, and if the device already knows the version file, configuration file name, and other relevant information, then there is no need to resend the commissioning request message to the IPv6 multicast group. Instead, it can directly send a download request message to the IPv6 multicast group and download the corresponding file. This allows commissioning to start directly from an intermediate state, and even if a process fails, there is no need to restart from the initial state, simplifying the commissioning process in this scenario.
[0091] In an optional implementation, to enable the opening server to promptly understand the opening result of the device to be opened, this embodiment also provides an implementation method: According to the preset message format, a notification message carrying the device's commissioning information is generated and sent to the IPv6 multicast group so that the commissioning server can record the commissioning information after receiving the notification message. The preset commissioning message type field in the notification message is the third preset value.
[0092] In this embodiment, based on the preset message format in Table 1 or Table 2, the third preset value of the preset initialization message type field is 5. Since the value of the preset initialization message type field in the preset message format sent by the device to be commissioned at different stages is different, the value of the preset initialization message type field enables the tracking of the commissioning process, facilitating the management of the commissioning process.
[0093] Based on the same inventive concept as the zero-configuration commissioning method applied to the device to be commissioned, this embodiment also provides a zero-configuration commissioning method applied to the commissioning server. Please refer to... Figure 4 , Figure 4This is a flowchart illustrating a zero-configuration startup method for a startup server provided in this embodiment. The method includes the following steps: Step S201: Receive an opening request message for requesting opening files. The opening request message is sent by the device to be opened to the IPv6 multicast group after joining the IPv6 multicast group to which the opening server belongs when accessing the local area network. Step S202: Based on the commissioning request, return a commissioning response message carrying the commissioning file to the IPv6 multicast group, so that the device to be commissioned can perform commissioning based on the commissioning file in the commissioning response message.
[0094] In this embodiment, corresponding to the commissioning request message, the commissioning server will also generate a commissioning response message: one way to generate a commissioning response message is to use the address of the IPv6 multicast group as the destination address and generate a commissioning response message according to a preset message format, wherein the preset commissioning message type field in the commissioning response message is a fourth preset value.
[0095] Based on the preset message format in Table 1 or Table 2, the fourth preset value of the preset opening message type field is 2.
[0096] In addition, corresponding to the download request message, the commissioning server will also generate a download response message, which carries the target file indicated by the commissioning information. One way to generate a download response message is to use the address of the IPv6 multicast group as the destination address and generate a download response message according to a preset message format. The preset commissioning message type field in the download response message is the fifth preset value.
[0097] Based on the preset message format in Table 1, the fifth preset value of the preset opening message type field is 4.
[0098] In an optional implementation, to enable the commissioning service to have a clearer understanding of the commissioning process information of the device to be commissioned, this embodiment also provides an implementation method: First, receive messages in a preset message format sent by the device to be commissioned; Secondly, based on the preset start-up message type field in the preset message format, determine and record the current start-up status of the device to be started.
[0099] In this embodiment, the message in the preset message format can be one of three types of messages: a startup request message, a download request message, and a notification message. The startup server can determine the specific message type based on the value of the preset startup message type field in the preset message format, and thus determine the current startup state of the device to be started. For example, if the value of the preset startup message type field is the first preset value, it means that the startup of the device to be started has just begun; if the value of the preset startup message type field is the second preset value, it means that the device to be started is downloading the required file; and if the value of the preset startup message type field is the third preset value, it means that the startup process of the device to be started has been completed.
[0100] To perform the corresponding steps in the above embodiments and various possible implementations, an implementation of a zero-configuration commissioning device 100 applied to a device to be commissioned is given below. Please refer to... Figure 5 , Figure 5 This is a block diagram of a zero-configuration commissioning device applied to a device to be commissioned, as provided in this embodiment. It should be noted that the basic principle and technical effects of the zero-configuration commissioning device 100 applied to a device to be commissioned provided by the present invention are the same as those of the corresponding embodiments described above. For the sake of brevity, some parts of this embodiment are not mentioned.
[0101] The zero-configuration commissioning device 100 applied to equipment to be commissioned includes a joining module 110, a request sending module 120, and a response receiving module 130.
[0102] Join module 110, used to join the IPv6 multicast group to which the initial server belongs when accessing a local area network; The request sending module 120 is used to send an initialization request message to the IPv6 multicast group to request an initialization file. The response receiving module 130 is used to receive the configuration response message returned by the commissioning server to the IPv6 multicast group based on the commissioning request message; The commissioning module 140 is used to perform commissioning of this device based on the commissioning file in the configuration response message.
[0103] In an optional implementation, module 110 is specifically used for: When accessing a local area network, IPv6 communication is enabled and a link-local address is generated to send messages based on the link-local address.
[0104] In an optional implementation, the request sending module 120 is further configured to: The IPv6 multicast group address is used as the destination address, and a start request message is generated according to the preset message format. The preset start message type field in the start request message is the first preset value.
[0105] In an optional implementation, the initialization module 140 is specifically used for: Obtain the necessary setup information for this device from the setup file; A download request message carrying initial information is generated according to a preset message format and sent to the IPv6 multicast group. The preset initial message type field in the download request message is the second preset value. Receive the target file indicated by the commissioning information returned by the commissioning server to the IPv6 multicast group based on the download request message; This device is started based on the target file.
[0106] In an optional implementation, the initialization module 140 is further configured to: According to the preset message format, a notification message carrying the device's commissioning information is generated and sent to the IPv6 multicast group so that the commissioning server can record the commissioning information after receiving the notification message. The preset commissioning message type field in the notification message is the third preset value.
[0107] To perform the corresponding steps in the above embodiments and various possible implementations, an implementation method of a zero-configuration startup device 200 applied to a startup server is given below. Please refer to... Figure 6 , Figure 6 This is a block diagram of the zero-configuration startup device 200 for a startup server provided in this embodiment. It should be noted that the basic principle and technical effects of the zero-configuration startup device 200 for a startup server provided by this invention are the same as those of the corresponding embodiments described above. For the sake of brevity, some parts of this embodiment are not mentioned.
[0108] The zero-configuration startup device 200 applied to the startup server includes a request receiving module 210 and a response sending module 220.
[0109] The request receiving module 210 is used to receive the commissioning request message for requesting commissioning files. The commissioning request message is sent to the IPv6 multicast group by the commissioning device after it joins the IPv6 multicast group to which the commissioning server belongs when it accesses the local area network. The response sending module 220 is used to return an opening response message carrying an opening file to the IPv6 multicast group based on the opening request, so that the device to be opened can realize the opening of the device based on the opening file in the opening response message.
[0110] In an optional implementation, the request receiving module 210 is further configured to: Receive messages in a preset message format sent by the equipment to be commissioned; Based on the preset initialization message type field in the preset message format, determine and record the current initialization status of the device to be initiated.
[0111] This embodiment provides a zero-configuration commissioning system. The system includes a device to be commissioned and a commissioning server. The device to be commissioned is used to execute the zero-configuration commissioning method applied to the device in this embodiment, and the commissioning server is used to execute the zero-configuration commissioning method applied to the server in this embodiment. For a clearer description of the interaction between the device to be commissioned and the commissioning server, please refer to [reference needed]. Figure 7 , Figure 7 This is an example diagram illustrating the interaction between the device to be commissioned and the commissioning server provided in this embodiment. Figure 7 The interaction process is as follows: S1: The device to be commissioned joins the IPv6 multicast group to which the commissioning server belongs; S2: The device to be commissioned sends a commissioning request message to the IPv6 multicast group; S3: The starting server records the starting status based on the starting request message; S4: The initial server returns an initial response message to the IPv6 multicast group; S5: The device to be commissioned sends a download request message to the IPv6 multicast group; S6: The server records the starting status based on download request messages; S7: The initial server returns a download response message to the IPv6 multicast group; S8: The device to be commissioned sends a notification message to the IPv6 multicast group; S9: The server records the start status based on notification messages.
[0112] This invention also provides a block diagram of an electronic device 10. The electronic device 10 can be a device to be commissioned or a commissioning server. The electronic device 10 implements the zero-configuration commissioning method applied to the device to be commissioned or the zero-configuration commissioning method applied to the commissioning server as described in the foregoing embodiments. Please refer to... Figure 8 , Figure 8 This is a block diagram of the electronic device 10 provided in this embodiment. The electronic device 10 includes a processor 11, a memory 12 and a bus 13. The processor 11 and the memory 12 are connected through the bus 13.
[0113] The processor 11 can be an integrated circuit chip with signal processing capabilities. In implementation, the steps of the zero-configuration commissioning method applied to the device to be commissioned or the zero-configuration commissioning method applied to the commissioning server in the above embodiments can be completed by the integrated logic circuits in the hardware of the processor 11 or by instructions in software form. The processor 11 can be a general-purpose processor, including a CPU (Central Processing Unit), an NP (Network Processor), etc.; it can also be a DSP (Digital Signal Processor), an ASIC (Application Specific Integrated Circuit), an FPGA (Field Programmable Logic Gate Array), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components.
[0114] The memory 12 is used to store programs that implement a zero-configuration commissioning method applied to a device to be commissioned or a zero-configuration commissioning method applied to a commissioning server. The program may be a software function module stored in the memory 12 in the form of software or firmware or embedded in the OS (Operating System) of the electronic device 10.
[0115] After receiving the execution instruction, the processor 11 executes the program to implement the zero-configuration commissioning method applied to the device to be commissioned or the zero-configuration commissioning method applied to the commissioning server as described in the foregoing embodiments.
[0116] This embodiment provides a program product. When the program product is executed by a processor, it implements the zero-configuration commissioning method applied to the device to be commissioned and / or the zero-configuration commissioning method applied to the commissioning server.
[0117] In summary, the embodiments of the present invention provide a zero-configuration commissioning method, apparatus, system, electronic device, and program product. The method includes: joining the IPv6 multicast group to which the commissioning server belongs when accessing a local area network; sending a commissioning request message to the IPv6 multicast group to request a commissioning file; receiving a commissioning response message returned by the commissioning server to the IPv6 multicast group based on the commissioning request message; and performing commissioning of the device based on the commissioning file in the commissioning response message. Compared with the prior art, this embodiment has at least the following advantages: (1) It introduces a pre-joined IPv6 multicast server. When the device to be configured accesses the local area network, it joins the IPv6 multicast group to which the pre-configuration server belongs. The device to be configured sends a configuration request message to the IPv6 multicast group, and the pre-configuration server replies with a configuration response message to the IPv6 multicast group. Since the device to be configured and the pre-configuration server are joined to the same IPv6 multicast group, the two communicate with each other in a multicast manner. The scope of influence is controlled within the IPv6 multicast group, avoiding message impact on other non-configuration devices in the local area network; (2) It eliminates the dependence on DHCP server during the zero-configuration configuration process. At the same time, it avoids the problem of failure of the start-up due to mismatch of information sent by other non-start-up servers; (3) For multiple devices to be started, if the same file (such as version file) is needed next week, the file required by the device to be started only needs to be sent by multicast on the start-up server. Once sent, multiple devices to be started can receive it by multicast, greatly improving the file transmission efficiency and the overall start-up efficiency of multiple devices to be started; (4) The start-up server can clearly know the start-up process information of the device to be started, and then manage the start-up process; (5) The start-up of the device to be started can start directly from a certain state in the middle. Even if a certain process fails, it does not need to start again from the initial state.
[0118] The above descriptions are merely various embodiments of the present invention, but the scope of protection of the present invention is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the technical scope disclosed in the present invention should be included within the scope of protection of the present invention. Therefore, the scope of protection of the present invention should be determined by the scope of the claims.
Claims
1. A zero-configuration start method, characterized in that, Applied to equipment awaiting commissioning, the method includes: When accessing a local area network, join the IPv6 multicast group to which the initial server belongs; Send an initialization request message to the IPv6 multicast group to request an initialization file; Receive the commissioning response message returned by the commissioning server to the IPv6 multicast group based on the commissioning request message; The device is commissioned based on the commissioning file in the commissioning response message.
2. The method according to claim 1, characterized in that, The method further includes: When accessing a local area network, IPv6 communication is enabled and a link-local address is generated to send messages based on the link-local address.
3. The method according to claim 1, characterized in that, Before the step of sending an Opening Request message to the IPv6 multicast group to request an Opening File, the following steps are included: The IPv6 multicast group address is used as the destination address, and the start-up request message is generated according to the preset message format. The preset start-up message type field in the start-up request message is a first preset value.
4. The method according to claim 1, characterized in that, The steps for establishing the device based on the establishment file in the establishment response message include: Obtain the necessary setup information for this device from the setup file; A download request message carrying the initial information is generated according to a preset message format and sent to the IPv6 multicast group. The preset initial message type field in the download request message is a second preset value. Receive the target file indicated by the commissioning information returned by the commissioning server to the IPv6 multicast group based on the download request message; The device is started based on the target file.
5. The method according to claim 4, characterized in that, After the step of implementing the initialization of this device based on the target file, the following steps are included: According to the preset message format, a notification message carrying the initialization information of this device is generated and sent to the IPv6 multicast group, so that the initialization server records the initialization information after receiving the notification message. The preset initialization message type field in the notification message is a third preset value.
6. A zero-configuration start method, characterized in that, Applied to the initial server, the method includes: Receive an initialization request message for requesting an initialization file. The initialization request message is sent by the device to be initiated to the IPv6 multicast group after it joins the IPv6 multicast group to which the initialization server belongs when it accesses the local area network. Based on the commissioning request, a commissioning response message carrying the commissioning file is returned to the IPv6 multicast group, so that the device to be commissioned can perform commissioning based on the commissioning file in the commissioning response message.
7. The method according to claim 6, characterized in that, The method further includes: Receive a message in a preset message format sent by the device to be commissioned; The current commissioning status of the device to be commissioned is determined and recorded based on the preset commissioning message type field in the preset message format.
8. A zero-configuration start-up device, characterized in that, Applied to equipment awaiting commissioning, the device includes: The join module is used to join the IPv6 multicast group to which the initial server belongs when accessing a local area network; The request sending module is used to send an initialization request message to the IPv6 multicast group to request an initialization file. The response receiving module is used to receive the configuration response message returned by the commissioning server to the IPv6 multicast group based on the commissioning request message; The commissioning module is used to perform commissioning of this device based on the commissioning file in the configuration response message.
9. A zero-configuration start-up device, characterized in that, The device, applied to a startup server, includes: The request receiving module is used to receive a startup request message for requesting a startup file. The startup request message is sent by the device to be started to the IPv6 multicast group after it joins the IPv6 multicast group to which the startup server belongs when it accesses the local area network. The response sending module is used to return an opening response message carrying the opening file to the IPv6 multicast group based on the opening request, so that the device to be opened can realize the opening of the device based on the opening file in the opening response message.
10. An electronic device, characterized in that, It includes a processor and a memory, the memory being used to store a program, and the processor being used to implement, when executing the program, the zero-configuration start method according to any one of claims 1-5, and / or, the zero-configuration start method according to any one of claims 6-7.
11. A program product, characterized in that, When the program product is executed by the processor, it implements the zero-configuration start method according to any one of claims 1-5, and / or the zero-configuration start method according to any one of claims 6-7.
12. A zero-configuration start-up system, characterized in that, The system includes a device to be commissioned and a commissioning server. The device to be commissioned is used to execute the zero-configuration commissioning method as described in any one of claims 1-5, and the commissioning server is used to execute the zero-configuration commissioning method as described in any one of claims 6-7.