WO2017054140A1 - 主从型网络的ip地址分配方法、装置及系统 - Google Patents

主从型网络的ip地址分配方法、装置及系统 Download PDF

Info

Publication number
WO2017054140A1
WO2017054140A1 PCT/CN2015/091125 CN2015091125W WO2017054140A1 WO 2017054140 A1 WO2017054140 A1 WO 2017054140A1 CN 2015091125 W CN2015091125 W CN 2015091125W WO 2017054140 A1 WO2017054140 A1 WO 2017054140A1
Authority
WO
WIPO (PCT)
Prior art keywords
address
segment
address sub
sub
master device
Prior art date
Application number
PCT/CN2015/091125
Other languages
English (en)
French (fr)
Inventor
朱冲
吕鑫
杨俊�
Original Assignee
华为技术有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 华为技术有限公司 filed Critical 华为技术有限公司
Priority to CN201580082540.1A priority Critical patent/CN107925684B/zh
Priority to US15/764,270 priority patent/US10757069B2/en
Priority to PCT/CN2015/091125 priority patent/WO2017054140A1/zh
Priority to JP2018535215A priority patent/JP6574906B2/ja
Priority to EP15905052.5A priority patent/EP3349420B1/en
Publication of WO2017054140A1 publication Critical patent/WO2017054140A1/zh

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/2866Architectures; Arrangements
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L61/00Network arrangements, protocols or services for addressing or naming
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L61/00Network arrangements, protocols or services for addressing or naming
    • H04L61/50Address allocation
    • H04L61/5007Internet protocol [IP] addresses
    • H04L61/5014Internet protocol [IP] addresses using dynamic host configuration protocol [DHCP] or bootstrap protocol [BOOTP]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L61/00Network arrangements, protocols or services for addressing or naming
    • H04L61/50Address allocation
    • H04L61/5038Address allocation for local use, e.g. in LAN or USB networks, or in a controller area network [CAN]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L61/00Network arrangements, protocols or services for addressing or naming
    • H04L61/50Address allocation
    • H04L61/5061Pools of addresses
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L2101/00Indexing scheme associated with group H04L61/00
    • H04L2101/60Types of network addresses
    • H04L2101/668Internet protocol [IP] address subnets

Definitions

  • the present invention relates to the field of wireless communication technologies, and in particular, to a method, an apparatus, and a system for allocating an IP address of a master-slave network.
  • a master-slave network usually includes a master device (Master Device, MD for short), a slave device (SD), and a user device (User Device, UD for short).
  • the MD is responsible for managing the SD attributed to the management area and, if necessary, performing communication interaction with other MDs based on the communication protocol between the MDs, and the MD may simultaneously assume the business functions possessed by the SD and provide services externally.
  • the SD cooperates with the MD to complete the service function and provides external services, and can provide management signaling channels and service forwarding channels for the next-level SD.
  • UD can connect to the autonomous network to get services.
  • the UD In a master-slave network, the UD needs to obtain an IP address to obtain services from the autonomous network.
  • IP Internet Protocol
  • the SD receives the Dynamic Host Configuration Protocol (DHCP) IP request from the UD, the request is processed step by step. Pass through to the MD. The MD then assigns an IP address to the UD based on the request, and transparently transmits the assigned IP address to the UD.
  • DHCP Dynamic Host Configuration Protocol
  • the invention provides a method, a device and a system for allocating an IP address of a master-slave network for improving communication efficiency of a master-slave network.
  • a first aspect of the embodiments of the present invention provides a method for allocating an IP address of a master-slave network, where the master-slave network includes a master device and at least one slave device in a management area of the master device, and the method includes:
  • the master device generates an internet protocol IP address sub-segment group, the IP address sub-segment group includes at least one IP address sub-segment, and each of the IP address sub-segments includes at least one IP address;
  • the master device separately sends the at least one IP address sub-segment in the IP address sub-segment group And sending the at least one slave device, so that the at least one slave device receives the received IP address sub-segment as a dynamic host configuration protocol DHCP server address, and assigns an IP address to the user equipment according to the DHCP server address.
  • DHCP server address a dynamic host configuration protocol
  • the master device separately sends the at least one IP address sub-segment in the IP address sub-segment group to the at least one slave device Previously, it also included:
  • the master device receives an IP address sub-segment request message sent by the slave device, where the IP address sub-segment request message is used to request the master device to allocate N IP address sub-segments for the slave device, where N is a positive integer. ;
  • the master device obtains N IP address sub-segments from the allocatable IP address sub-segments;
  • the master device reclaims the assignable IP address sub-segments to other slave devices in the management area of the master device until the There are N assignable IP address sub-segments in the IP address sub-segment group, and the master device obtains N IP address sub-segments from the allocatable IP address sub-segments.
  • the master device separately sends the at least one IP address sub-segment in the IP address sub-segment group to the at least one slave device Previously, it also included:
  • the master device Receiving, by the master device, a specific IP address sub-segment request message sent by the slave device, where the IP address sub-segment request message carries an identifier of a specific IP address sub-segment required by the slave device, for requesting the master
  • the device allocates the specific IP address subsection to the slave device;
  • the master device acquires the specific IP address sub-segment
  • the master device reclaims the specific IP address from other slave devices in the management area of the master device. a sub-section, the master device acquires the reclaimed specific IP address sub-segment.
  • the method further includes:
  • the master device sends a reclaim message to the at least one slave device, where the reclaim message is used to request the slave device to return an IP address sub-segment required by the master device to the master device;
  • the return response message carries an identifier of all or part of an IP address subsection required by the slave device returned by the slave device.
  • the return response message indicates that the slave device does not have an IP address sub-segment required by the master device.
  • a second aspect of the embodiments of the present invention provides a method for allocating an IP address of a master-slave network, where the master-slave network includes a master device and at least one slave device in a management area of the master device, and the method includes:
  • the slave device receives the IP address sub-segment sent by the master device, and uses the IP address sub-segment as the dynamic host configuration protocol DHCP server address, where the IP address sub-segment includes at least one IP address;
  • the slave device allocates an IP address to the user equipment according to the DHCP server address.
  • the method before the slave device receives the IP address sub-segment sent by the master device, the method further includes:
  • the slave device sends an IP address sub-segment request message to the master device, where the IP address sub-segment request message is used to request the master device to allocate N IP address sub-segments for the slave device, where N is positive Integer.
  • the method before the slave device receives the IP address sub-segment sent by the master device, the method further includes:
  • the slave device sends a specific IP address sub-segment request message to the master device, where the IP address sub-segment request message carries an identifier of a specific IP address sub-segment required by the slave device, and is used to request the master device Assigning the specific IP address subsection to the slave device.
  • the method further includes:
  • the slave device queries whether the DHCP server address includes an IP address sub-segment required by the master device;
  • the slave device sends a return response message to the master device, where the return response message carries the DHCP server address. All or part of the IP address required by the master device included in The identifier of the subsection; or,
  • the slave device sends a return response message to the master device, where the return response message indicates that the master device is the slave device. There is no sub-segment of IP addresses required by the master device.
  • the method further includes:
  • the slave device receives a request message sent by the user equipment, where the request message is used to request the slave device to allocate an IP address to the user equipment.
  • a third aspect of the embodiments of the present invention provides a master device, where the master device belongs to a master-slave network, and the master-slave network includes at least one slave device in the management region of the master device and the master device.
  • the main equipment includes:
  • a generating module configured to generate an Internet Protocol IP address sub-segment group, the IP address sub-segment group includes at least one IP address sub-segment, and each of the IP address sub-segments includes at least one IP address;
  • a sending module configured to send the at least one IP address sub-segment in the IP address sub-segment group to the at least one slave device, so that the at least one slave device will receive the IP address sub-sub
  • the segment acts as the dynamic host configuration protocol DHCP server address, and assigns an IP address to the user device according to the DHCP server address.
  • the master device further includes: a first receiving module and a first acquiring module;
  • the first receiving module is configured to receive, before the sending module sends the at least one IP address sub-segment in the IP address sub-segment group to the at least one slave device, An IP address sub-segment request message, where the IP address sub-segment request message is used to request the master device to allocate N IP address sub-segments for the slave device, where N is a positive integer;
  • the first obtaining module is configured to obtain N IP address sub-segments from the assignable IP address sub-segments if there are N assignable IP address sub-segments in the IP address sub-segment group; or If there are no N assignable IP address sub-segments in the IP address sub-segment group, reclaim the assignable IP address sub-segments to other slave devices in the management area of the master device until the IP address There are N assignable IP address sub-segments in the sub-segment group, and N IP address sub-segments are obtained from the assignable IP address sub-segments.
  • the master device further The method includes: a second receiving module and a second acquiring module;
  • the second receiving module is configured to receive, before the sending module sends the at least one IP address sub-segment in the IP address sub-segment group to the at least one slave device, a specific IP address sub-segment request message, where the IP address sub-segment request message carries an identifier of a specific IP address sub-segment required by the slave device, and is used to request the master device to allocate the specific IP address to the slave device.
  • Address subsection
  • the second obtaining module is configured to acquire the specific IP address sub-segment if the specific IP address sub-segment exists in the assignable IP address sub-segment in the IP address sub-segment group; or, if If the specific IP address sub-segment does not exist in the assignable IP address sub-segment in the IP address sub-segment group, the specific IP address sub-segment is reclaimed from other slave devices in the management area of the master device, and the reclaimed location is obtained. Describe the specific IP address subsection.
  • the main device further includes: a third receiving module
  • the sending module is further configured to send a reclaim message to the at least one slave device, where the reclaim message is used to request the slave device to return an IP address sub-segment required by the master device to the master device;
  • the third receiving module is configured to receive a return response message sent by the slave device according to the reclaim message, where the return response message carries all or part of an IP address required by the master device returned by the slave device.
  • the identifier of the sub-section, or the return response message indicates that the slave device does not have the IP address sub-segment required by the master device.
  • a fourth aspect of the embodiments of the present invention provides a slave device, where the slave device belongs to a master-slave network, and the master-slave network includes a master device and at least one slave device in a management area of the master device,
  • the slave device includes:
  • a receiving module configured to receive an IP address sub-segment sent by the primary device, and use the IP address sub-segment as a dynamic host configuration protocol DHCP server address, where the IP address sub-segment includes at least one IP address;
  • an allocating module configured to allocate an IP address to the user equipment according to the DHCP server address.
  • the slave device further includes: a first sending module
  • the first sending module is configured to send an IP address sub-segment request message to the master device before the receiving module receives the IP address sub-segment sent by the master device, where the IP address sub-segment requests cancellation
  • the information is used to request the master device to allocate N IP address sub-segments for the slave device, where N is a positive integer.
  • the slave device further includes: a second sending module
  • the second sending module is configured to: before the receiving module receives the IP address sub-segment sent by the master device, send a specific IP address sub-segment request message to the master device, where the IP address sub-segment request message carries An identifier of a specific IP address sub-segment required by the slave device, configured to request the master device to allocate the specific IP address sub-segment for the slave device.
  • the slave device further includes: a query module and a third sending module;
  • the receiving module is further configured to receive a reclaim message sent by the master device, where the reclaim message is used to request the slave device to return an IP address sub-segment required by the master device to the master device;
  • the query module is configured to query whether the DHCP server address includes an IP address sub-segment required by the master device;
  • the third sending module is configured to send a return response message to the primary device if the DHCP server address includes all or part of the IP address sub-section required by the primary device, where the return response message is carried An identifier of all or part of the IP address subsection required by the master device included in the DHCP server address; or, if the DHCP server address does not include the IP address subsection required by the master device, The master device sends a return response message, the return response message indicating that the master device does not have an IP address sub-segment required by the master device.
  • the receiving module is further configured to receive a request message sent by the user equipment.
  • the request message is used to request the slave device to allocate an IP address to the user equipment.
  • a fifth aspect of the embodiments of the present invention provides a master device, where the master device belongs to a master-slave network, and the master-slave network includes at least one slave device in the management region of the master device and the master device.
  • the main equipment includes:
  • a processor configured to generate an Internet Protocol IP address sub-segment group, the IP address sub-segment group includes at least one IP address sub-segment, and each of the IP address sub-segments includes at least one IP address;
  • a transmitter configured to separately use the at least one IP address sub-segment in the IP address sub-segment group Sending to the at least one slave device, so that the at least one slave device receives the received IP address sub-segment as a dynamic host configuration protocol DHCP server address, and assigns an IP address to the user equipment according to the DHCP server address.
  • the master device further includes: a receiver, configured, by the sender, the at least one of the group of IP address sub-segments Receiving an IP address sub-segment request message sent by the slave device before the IP address sub-segment is sent to the at least one slave device, where the IP address sub-segment request message is used to request the master device to allocate the slave device N IP address subsections, N is a positive integer;
  • the processor is configured to obtain N IP address sub-segments from the assignable IP address sub-segment if there are N assignable IP address sub-segments in the IP address sub-segment group; or, if If there are no N assignable IP address sub-segments in the IP address sub-segment group, the assignable IP address sub-segments are reclaimed to other slave devices in the management area of the master device until the IP address sub-segments There are N assignable IP address sub-segments in the group, and the master device obtains N IP address sub-segments from the assignable IP address sub-segments.
  • the method further includes: a receiver, configured, by the sender, the at least one IP address sub-segment in the IP address sub-segment group Before receiving the at least one slave device, receiving a specific IP address sub-segment request message sent by the slave device, where the IP address sub-segment request message carries an identifier of a specific IP address sub-segment required by the slave device Used to request the master device to allocate the specific IP address sub-segment for the slave device;
  • the processor is configured to acquire the specific IP address sub-segment if the specific IP address sub-segment exists in the assignable IP address sub-segment in the IP address sub-segment group; or, if the IP address If the specific IP address sub-segment does not exist in the sub-segment IP address sub-segment, the specific IP address sub-segment is reclaimed from other slave devices in the management area of the master device, and the master device acquires the reclaimed The specific IP address subsection.
  • the transmitter is further configured to send a reclaim message to the at least one slave device, where Retrieving a message for requesting the slave device to return to the master device an IP address sub-segment required by the master device;
  • the receiver is further configured to receive a return response sent by the slave device according to the reclaim message a message, the return response message carries an identifier of all or part of the IP address subsection required by the master device returned by the slave device, or the return response message indicates that the slave device does not have the master device The required IP address subsection.
  • a sixth aspect of the embodiments of the present invention provides a slave device, where the slave device belongs to a master-slave network, and the master-slave network includes a master device and at least one slave device in a management area of the master device,
  • the slave device includes:
  • a receiver configured to receive an IP address sub-segment sent by the master device, where the IP address sub-segment is a dynamic host configuration protocol DHCP server address, where the IP address sub-segment includes at least one IP address;
  • a processor configured to allocate an IP address to the user equipment according to the DHCP server address.
  • the method further includes: a transmitter, configured to send an IP to the primary device before the receiver receives the IP address sub-segment sent by the primary device An address sub-segment request message, where the IP address sub-segment request message is used to request the master device to allocate N IP address sub-segments for the slave device, where N is a positive integer.
  • the method further includes: sending, by the receiver, the specific IP address to the master device before receiving the IP address sub-segment sent by the master device a sub-segment request message, where the IP address sub-segment request message carries an identifier of a specific IP address sub-segment required by the slave device, and is used to request the master device to allocate the specific IP address sub-segment for the slave device .
  • the receiver is further configured to receive a reclaim message sent by the master device, Retrieving a message for requesting the slave device to return to the master device an IP address sub-segment required by the master device;
  • the processor is further configured to query whether the DHCP server address includes an IP address sub-segment required by the master device;
  • the sender is further configured to send a return response message to the master device if the DHCP server address includes all or part of the IP address sub-segments required by the master device, where the return response message carries the The identifier of all or part of the IP address subsection required by the master device included in the DHCP server address; or, if the DHCP server address does not include the IP address subsection required by the master device, The master device sends a return response message, and the return response is cancelled.
  • the information indicates that the slave device of the master device does not have the IP address sub-segment required by the master device.
  • the receiver is further configured to receive a request message sent by the user equipment.
  • the request message is used to request the slave device to allocate an IP address to the user equipment.
  • the master device generates an IP address sub-segment group, and sends at least one IP address sub-segment in the IP address sub-segment group to at least one slave device
  • the slave device can use the received IP address sub-segment as the DHCP server address, and assign an IP address to the user equipment according to the DHCP server address, that is, the slave device can directly allocate an IP address to the user equipment, thereby greatly reducing the IP address.
  • the allocation time increases the communication efficiency of the master-slave network.
  • FIG. 1 is a schematic structural diagram of a master-slave network according to an embodiment of the present invention
  • Embodiment 1 of an IP address allocation method of a master-slave network according to the present invention
  • Embodiment 3 is a schematic flowchart of Embodiment 2 of an IP address allocation method of a master-slave network according to the present invention
  • Embodiment 4 is a schematic flowchart of Embodiment 3 of an IP address allocation method of a master-slave network according to the present invention
  • Embodiment 4 is a schematic flowchart of Embodiment 4 of an IP address allocation method of a master-slave network according to the present invention
  • Embodiment 5 is a schematic flowchart of Embodiment 5 of an IP address allocation method of a master-slave network according to the present invention
  • FIG. 7 is a flowchart of Embodiment 6 of an IP address allocation method of a master-slave network according to the present invention. schematic diagram;
  • Embodiment 8 is a schematic flowchart of Embodiment 7 of an IP address allocation method of a master-slave network according to the present invention.
  • FIG. 9 is a schematic structural diagram of Embodiment 1 of a master device according to the present invention.
  • Embodiment 2 of a master device according to the present invention.
  • Embodiment 3 is a schematic structural diagram of Embodiment 3 of a master device according to the present invention.
  • Embodiment 4 of a master device according to the present invention.
  • FIG. 13 is a schematic structural diagram of Embodiment 1 of a slave device according to the present invention.
  • FIG. 14 is a schematic structural diagram of a second embodiment of a slave device according to the present invention.
  • FIG. 15 is a schematic structural diagram of a third embodiment of a slave device according to the present invention.
  • 16 is a schematic structural diagram of a fourth embodiment of a slave device according to the present invention.
  • Embodiment 5 of a master device according to the present invention is a schematic structural diagram of Embodiment 5 of a master device according to the present invention.
  • FIG. 18 is a schematic structural diagram of Embodiment 5 of a slave device provided by the present invention.
  • FIG. 1 is a schematic structural diagram of a master-slave network according to an embodiment of the present invention.
  • the master-slave network includes: a master device (MD), and at least one of the master device management areas. a slave device (Slave Device, SD for short) and at least one user device (User Device, UD for short);
  • the functions of the MD are: responsible for managing the slave devices belonging to the management area; and, if necessary, performing communication interaction with other master devices based on the communication protocol between the master devices;
  • the greatest improvement of the MD in the technology is that the MD provided by the embodiment of the present invention can divide the IP address segment into multiple IP address sub-segments and allocate different IP address sub-segments to different SDs. Further: MD can also redistribute IP addresses and recover IP addresses by dynamically configuring IP addresses.
  • the functions of the SD are: to cooperate with the master device to complete the service function and provide external services; to provide the management signaling channel and service forwarding channel for the next-level slave device.
  • the maximum improvement of the SD provided by the embodiment of the present invention and the SD in the prior art is that the SD supporting the DHCP protocol provided by the embodiment of the present invention can establish a DHCP server address pool according to the IP address sub-segment allocated by the MD, and directly allocate the UD to the UD.
  • the IP address which avoids the IP address request being transparently transmitted when the IP address is assigned to the UD, reduces the unnecessary interaction process in the configuration process, reduces the delay, and improves the communication efficiency of the master-slave network.
  • the SD also has the function of managing, maintaining, and updating the address pool of the DHCP server.
  • the schematic diagram of the architecture shown in FIG. 1 is only an example.
  • the MD and other MDs can also communicate through the protocol, and the UD can also be directly connected to the MD.
  • the deployment structure of the system for configuring the IP address of the master-slave network is not specifically limited.
  • Embodiment 1 is a schematic flowchart of Embodiment 1 of an IP address allocation method of a master-slave network according to the present invention.
  • the method is performed by an MD in the master-slave network.
  • the method includes:
  • the master device generates an IP address sub-segment group, where the IP address sub-segment group includes at least one IP address sub-segment, and each IP address sub-segment includes at least one IP address.
  • the master device divides the IP address into multiple IP address sub-segments, and then divides the multiple IP address sub-segments into IP address sub-segment groups.
  • the master device sends the at least one IP address sub-segment of the IP address sub-segment group to the at least one slave device, so that the at least one slave device uses the received IP address sub-segment as the DHCP server address, and according to The DHCP server address assigns an IP address to the user equipment.
  • the MD allocates an IP address sub-segment to the slave device in the management area.
  • the slave device supports the DHCP protocol, and after the slave device receives the IP address sub-segment sent by the master device, the DHCP server address pool can be established. It is used to accommodate the DHCP server address, and then assign an IP address to the user equipment according to the needs of the user equipment.
  • the IP address sub-segments allocated by the MD for each SD are not mutually exclusive.
  • the MD will mark the assigned IP address subsection as assigned in the IP address subgroup.
  • the master device generates an IP address sub-segment group, and sends at least one IP address sub-segment in the IP address sub-segment group to at least one slave device, and the slave device can use the received IP address sub-segment as DHCP.
  • the server address is assigned to the user equipment according to the DHCP server address, that is, the slave device can directly allocate an IP address to the user equipment, which greatly reduces the allocation time of the IP address, and improves the communication efficiency of the master-slave network.
  • the master device receives the IP address sub-segment request sent by the slave device in the management area, that is, actively requests the master device to allocate the IP address sub-segment.
  • FIG. 3 is a schematic flowchart diagram of Embodiment 2 of an IP address allocation method of a master-slave network according to the present invention.
  • the method may further include:
  • the master device receives an IP address sub-segment request message sent by the slave device, where the IP address sub-segment request message is used to request the master device to allocate N IP address sub-segments for the slave device.
  • N is a positive integer.
  • the slave device here may be any slave device in the master-slave network that has an IP address allocation requirement.
  • the master device After receiving the IP address sub-segment request message, the master device will view the IP address sub-segments that can be allocated in the sub-group of its own IP address.
  • the IP address sub-segment that can be assigned here refers to the sub-segment of the IP address that has not been assigned to the slave device.
  • the master device obtains N IP address sub-segments from the assignable IP address sub-segments. Further, the master device can allocate N IP address sub-segments to the slave device.
  • the master device determines whether there are N IP address sub-segments requested by the device in the IP address sub-segments that can be allocated in the IP address sub-segment group, and the IP address sub-segments that have been allocated to the slave device are not in the determination range.
  • the master device may preset a preset threshold k of the assignable IP address sub-segment, that is, the master device itself has a minimum of k IP address sub-segments, so as to meet the requirements of the slave device in time, that is, if a slave device requests
  • the master device allocates N IP address sub-segments, and the master device has at least N+k assignable IP address sub-segments. If the assignable IP address sub-segments in the master device are smaller than N+k, then the slave device needs to be sent to other slave devices. Reclaim the IP address sub-segment.
  • k is a positive integer greater than or equal to zero.
  • the master device If there are no N assignable IP address sub-segments in the IP address sub-segment group, the master device reclaims the assignable IP address sub-segments to other slave devices in the management area of the master device until the IP address There are N assignable IP address sub-segments in the address sub-segment group, and the master device obtains N IP address sub-segments from the above-mentioned assignable IP address sub-segments.
  • the master device can allocate N IP address sub-segments to the above-mentioned slave device. If the master device sets the threshold k, the master device needs to reclaim the allocated IP address sub-segment from other slave devices, and the master device may divide the reclaimed IP address sub-segment, update or generate the above-mentioned IP address sub-segment group until the master There are N+k assignable IP address sub-segments in the device's IP address sub-segment group.
  • the master device may randomly request to reclaim M assignable IP address sub-segments from a certain slave device in the management area. If there are only m IP address sub-segments in the slave device, which are less than M, then The slave device returns m assignable IP address sub-segments to the master device, and the master device requests the other slave devices to reclaim the assignable Mm IP address sub-segments, and so on, until the IP address sub-segment group can be The allocated IP address subsection is greater than or equal to N after the number of preset thresholds is removed.
  • FIG. 4 is a schematic flowchart diagram of Embodiment 3 of an IP address allocation method of a master-slave network according to the present invention. As shown in FIG. 4, on the basis of the embodiment of FIG. 2, before the master device sends the at least one IP address sub-segment of the IP address sub-segment group to the at least one slave device, the method may further include:
  • the master device receives a specific IP address sub-segment request message sent by the slave device, where the IP address sub-segment request message carries an identifier of a specific IP address sub-segment required by the slave device, and is used to request the master device to allocate the slave device.
  • a specific IP address subsection A specific IP address subsection.
  • the slave device requests the master device to allocate certain specific IP address sub-segments, and the slave device can carry the identifier of the specific IP address sub-segment in the IP address sub-segment request message to inform the master device of the requested IP address. Address subsection.
  • the master device After receiving the sub-segment request message of the specific IP address, the master device checks the sub-segment of the IP address that can be allocated to see if there is a specific IP address sub-segment.
  • the master device acquires the specific IP address sub-segment. The master device can then assign the particular IP address sub-segment to the slave device.
  • the master device reclaims the specific IP address sub-segment to the other slave devices in the management area of the master device, and the master device acquires the reclaimed specific IP address sub-segment. In turn, the reclaimed specific IP address sub-segment can be assigned to the first slave device.
  • the master device may randomly request a certain slave device in the management area to reclaim a specific IP address sub-segment, and if the slave device has a specific IP address sub-segment, return to the master device, and the master device may reclaim the specific IP address.
  • the address sub-segment is allocated to the above-mentioned slave device requesting the specific IP address sub-segment. If the master device requests to reclaim the slave device of the specific IP address sub-segment and does not have the specific IP address sub-segment, the master device is notified that the master device does not, and the master device goes to the other slave device. The device reclaims a specific IP address subsection.
  • a slave device may refuse to return to the master device if it has a specific IP address sub-segment. In this case, the master device cannot allocate a specific IP address sub-segment to the slave device requesting the specific IP address sub-segment, and the process ends. The master device can also notify the slave device that there is no specific IP address sub-segment.
  • the master device needs to reclaim the previously assigned IP address sub-segment to the slave device in the management area, for example: (1)
  • the IP address sub-segment of the MD cannot satisfy the new IP address or the new IP address.
  • the IP address sub-segment is added to the SD request, or the SD request occupies an IP address that has been allocated to other UDs.
  • the MD periodically triggers each SD to reclaim the assignable IP address, or each SD periodically reports the respective assignable IP address to the MD.
  • this is not limited to the above.
  • FIG. 5 is a schematic flowchart of Embodiment 4 of an IP address allocation method of a master-slave network according to the present invention. As shown in FIG. 5, the method includes:
  • the master device sends a reclaim message to the at least one slave device, where the reclaim message is used to request the slave device to return an IP address subsection required by the master device to the master device.
  • the reclaim message is used to request the slave device to return the IP address required by the master device to the master device.
  • the master device may randomly send a reclaim message to at least one slave device of the slave device. If the slave device does not have the IP address sub-segment required by the master device, or only a partial IP address sub-segment, the master device reclaims from the other slave device. And so on.
  • the master device receives a return response message sent by the slave device according to the reclaim message, where the return response message carries an identifier of all or part of the IP address subsection required by the master device returned by the slave device, or the return response message Instructing the slave device not to have the IP address required by the master device described above Subsection of the address.
  • the above reclaim message carries the identifier of at least one IP address sub-segment that the master device needs to reclaim. That is, the specific IP address sub-segment in the retract message indicating the master device to reclaim.
  • the master device receives a return response message sent by the slave device according to the reclaim message, where the return response message carries all or part of the IP address sub-segment in at least one IP address sub-segment that the master device needs to reclaim.
  • the return response message indicates that the first slave device does not have a sub-segment of IP addresses that can be returned.
  • the master device needs to reclaim three IP address sub-segments: IP address sub-segment A, IP address sub-segment B, and IP address sub-segment C. If the three IP address sub-segments are not in the device, the indication is returned in the response message. The slave device does not have a sub-segment of IP addresses that can be returned. If the slave device has the three IP address sub-segments, the three IP address sub-segment identifiers may be carried in the return response message, or the slave device has one of the IP addresses. Address sub-segment A, then the identifier of the IP address sub-segment A can be carried in the return response message.
  • the slave device may not give up the IP address.
  • the master device can be informed that the IP address sub-segment A is not returned.
  • the master device may reclaim the IP address sub-segment containing a specific IP address, and reclaim the identifier of the specific IP address in the message. If the slave device has an IP address sub-segment containing the IP address, the slave device may directly Returning the response message to return the IP address sub-segment containing the IP address. If the slave device has the IP address but the IP address sub-segment where the IP address was originally no longer exists, the slave device can separately return the IP address in the return response message. The master device generates a new IP address sub-segment based on the IP address.
  • the reclaim message carries the number N of IP address sub-segments that the master device needs to reclaim, where N is a positive integer. That is, the master device only informs the number of sub-segments of IP addresses that need to be reclaimed, and does not require a specific IP address sub-segment.
  • the master device receives a return response message sent by the slave device according to the reclaim message, where the return response message carries an identifier of the n IP address sub-segments returned from the device, where n is a positive integer and less than or equal to N.
  • a return response message indicates that the slave device does not have a sub-segment of IP addresses that can be returned.
  • the slave device can determine the number of returned IP address sub-segments based on the number of sub-segments of IP addresses that can be assigned.
  • the slave device can set its own assignable IP address sub-segment to not less than k, and k is greater than or equal to 0. For example, if the slave device has M assignable IP address sub-segments, M is greater than k, then The slave device can return up to M-k IP address sub-segments to the master device. If the IP address sub-segment that can be allocated from the device is less than or equal to k, it indicates that the slave device does not have a sub-segment of IP addresses that can be returned.
  • the master device can also send the reclaim message only to the slave device, that is, the number of reclaimed is not indicated, and the sub-segment identification of the specific IP address is not indicated.
  • the slave device can return one or more to the master device according to its own situation.
  • the master device sends a reclaim message sent by the slave device to the slave device other than the slave device.
  • the reclaim message is used to request the slave device to return the IP address sub-segment required by the master device to the master device, and so on, until the master device reclaims the required IP address sub-segment.
  • the master device may further send a reclaim message to a slave device other than the slave device in the management region.
  • the reclaim message is used to request the slave device to return the remaining IP address sub-section required by the master device to the master device, where the remaining IP address sub-segment is the IP address sub-segment required by the master device, and the partial IP returned from the slave device is removed.
  • the master device requests 10 IP address sub-segments from the first slave device, the first slave device returns 6 IP address sub-segments to the master device, and the master device requests the second slave device to reclaim 4 IP address sub-segments.
  • the second slave device determines the number that can be returned in the same manner as the first slave device. If the master device still does not reclaim 10 IP address sub-segments, it can continue to request from other slave devices until 10 are obtained. Similarly, the master device reclaims multiple specific IP address sub-segments, which can also be reclaimed from different slave devices.
  • the master device may randomly select the slave device to reclaim when the IP address sub-segment is reclaimed, which is not limited herein.
  • each slave device can be scheduled to periodically report the DHCP server address maintained by the slave device.
  • the message periodically reported by each slave device may include: a DHCP server.
  • the IP address information that can be assigned in the address pool, the total number of IP addresses that can be assigned, and so on.
  • the master device reclaims the IP address sub-segment, it can select based on the message reported by the slave device.
  • the master device may periodically send a query message to the slave device, where the query message is used to request the slave device to report the DHCP server address maintained by the device.
  • the master device may also directly allocate the IP address sub-segment to the user equipment.
  • the master device may set the IP address sub-segment group.
  • the user equipment IP address sub-segment in the user equipment is sent to the user equipment, the user equipment
  • the IP address is at least one IP address sub-segment in the above-mentioned IP address sub-segment group.
  • the MD may allocate at least one IP address sub-segment in the generated IP address sub-segment group as a user equipment IP address sub-segment for allocating an IP address for the UD.
  • the master device can send the user equipment IP address sub-segment in the sub-segment group of the IP address to the user equipment
  • the master device can also send a reclaim message to the user equipment, and the reclaim message is sent.
  • FIG. 6 is a schematic flowchart of Embodiment 5 of an IP address allocation method of a master-slave network according to the present invention.
  • the execution entity of the method is a slave device, and the slave device may be any slave device in the management area of the master device.
  • the slave device supports the DHCP protocol.
  • the method includes:
  • the slave device receives the IP address sub-segment sent by the master device, and uses the IP address sub-segment as the DHCP server address, where the IP address sub-segment includes at least one IP address.
  • the slave device allocates an IP address to the user according to the DHCP server address.
  • the master device directly sends an IP address sub-segment to the slave device, and the IP address sub-segment includes at least one IP address, so that the slave device can directly assign an IP address to the user equipment in the IP address sub-segment allocated by the master device.
  • the slave device receives the IP address sub-segment sent by the master device, uses the IP address sub-segment as the DHCP server address, and assigns an IP address to the user according to the DHCP server address, so that the slave device can directly directly provide the user device. Assigning an IP address greatly reduces the allocation time of the IP address and improves the communication efficiency of the master-slave network.
  • the slave device also needs to actively request the master device to allocate an IP address sub-segment. For example, when there is a new UD access, an IP address needs to be allocated, but there is no assignable IP address in the DHCP server address, or A UD requests a specific IP address, but the specific IP address is not included in the IP address that can be assigned by the device, and is not limited thereto.
  • the slave device Before receiving the first IP address sub-segment sent by the master device, the slave device may send an IP address sub-segment request message to the master device, where the IP address sub-segment request message is used to request the master device to allocate N devices for the slave device. IP address subsection. Where N is a positive integer.
  • the slave device can go to the master device before receiving the IP address sub-segment sent by the master device Sending a specific IP address sub-segment request message, the IP address sub-segment request message carries an identifier of a specific IP address sub-segment required by the slave device, and is used to request the master device to allocate the specific IP address sub-segment for the slave device.
  • the slave device can request the master device to allocate a specific IP address sub-segment containing the IP address A.
  • the SD in the prior art does not need an IP address itself, so the SD usually does not apply for an IP address to the MD as a requester.
  • FIG. 7 is a schematic flowchart of Embodiment 6 of an IP address allocation method of a master-slave network according to the present invention. As shown in FIG. 7, the method further includes:
  • the slave device receives a reclaim message sent by the master device, where the reclaim message is used to request the slave device to return an IP address subsection required by the master device to the master device.
  • the slave device queries whether the DHCP server address includes an IP address sub-section required by the master device.
  • the slave device sends a return response message to the master device, where the return response message carries the master device included in the DHCP server address.
  • the slave device sends a return response message to the master device, where the return response message indicates that the master device does not have the IP address required by the master device. Subsection.
  • the above reclaim message carries the identifier of at least one IP address sub-segment that the master device needs to reclaim.
  • the foregoing S702 may be specifically: the slave device queries whether the DHCP server address includes all or part of the IP address sub-segments in the at least one IP address sub-segment that the master device needs to reclaim.
  • S703 is specifically: if the DHCP server address includes all or part of the IP address sub-segment in the at least one IP address sub-segment that the master device needs to reclaim, the slave device sends a return response message to the master device, where the return response message carries DHCP
  • the above-mentioned master device includes the identifier of all or part of the IP address sub-segments in the at least one IP address sub-segment to be reclaimed.
  • the slave device may not respond to the master device or inform the master device that the retraction fails.
  • N is a positive integer.
  • the foregoing S702 may be specifically: the slave device queries the number of sub-sections of the IP address that can be allocated in the DHCP server address.
  • S703 is specifically: if the number of the assignable IP address sub-segments in the DHCP server address is n, n is a positive integer and is greater than or equal to N, the slave device sends a return response message to the primary device, where the return response message carries An identifier of the N IP address sub-segments that can be allocated in the DHCP server address. It should be noted that if the slave device is set with the threshold k, k is a positive integer, that is, the slave device can allocate less than k IP address sub-segments, then when n is greater than or equal to N+k, the slave device will The master device returns N IP address sub-segments.
  • S703 is specifically: if the number of the IP address sub-segments that can be allocated in the DHCP server address is n, n is a positive integer and is less than N, the slave device sends a return response message to the master device, where the return response message carries The identifier of the n IP address sub-segments that can be assigned in the DHCP server address. At this time, the master device still lacks N-n IP address sub-segments, and the master device continues to request to reclaim the IP address sub-segment to other slave devices in the management area.
  • the UD may actively request the slave device to allocate an IP address, that is, the slave device receives a request message sent by the user equipment, where the request message is used to request the slave device to allocate an IP address to the user equipment.
  • it may also include at least the following two cases:
  • the slave device receives the first request message sent by the user equipment, where the first request message is used to request the slave device to allocate a new IP address to the user equipment. That is, if there is a UD access network, and the UD has not been assigned an IP address before, a new IP address needs to be allocated.
  • the foregoing S602 specifically includes: the slave device queries whether the DHCP server address has an assignable IP address, and if yes, the slave device allocates an IP address to the user equipment from the assignable IP address; if not, the slave device first requests The master device allocates a new IP address sub-segment, and assigns an IP address to the user equipment from the new IP address sub-segment after receiving the new IP address sub-segment allocated by the master device.
  • the slave device receives the second request message sent by the user equipment, where the second request message carries the identifier of the first IP address that is previously allocated by the user equipment, and the second request message is used to request the slave device to the user.
  • the device allocates the first IP address for multiplexing. That is, the UD has been assigned the first IP address, and the UD requires multiplexing the IP address instead of the new IP address.
  • the foregoing S602 specifically includes: the slave device queries whether the first IP address is included in the assignable IP address in the DHCP server address, and if yes, marks the first IP address as being allocated; if not, the slave device requests the master device The IP address sub-segment including the first IP address is allocated, and after receiving the sub-segment of the IP address containing the first IP address allocated by the master device, the IP address is marked as allocated. Specifically, after receiving the IP address sub-segment of the first IP address allocated by the master device, the slave device first refreshes the assignable IP address in the DHCP server address, and then marks the first IP address in the DHCP server address. Is already assigned.
  • the slave device when the slave device requests to allocate the IP address sub-segment including the first IP address, if the master device has the IP address sub-segment including the first IP address, the slave device may directly allocate the sub-segment to the slave device. If not, the master device When another slave device reclaims the IP address sub-segment containing the first IP address, if a slave device has an IP address sub-segment containing the first IP address, the entire IP address sub-segment containing the first IP address may be directly returned to the master.
  • the device also has a special case.
  • the slave device may only be the master.
  • the device returns a first IP address, and the master device generates a new IP address sub-segment according to the first IP address and sends the sub-segment to the slave device.
  • the master device and the slave device are connected through a Wide Area Network (WAN) interface, that is, a logical interface or a physical interface that usually connects the SD device and the MD device is defined as the WAN.
  • WAN Wide Area Network
  • Interface in an IP network, usually does not assign an IP address to the WAN interface.
  • the SD after receiving the request message for the IP address sent by the UD, the SD first determines whether the message is from the WAN interface, and if so, ignores the request message, and if not, assigns the IP to the UD according to the above process. address.
  • the following describes an IP address allocation method of the master-slave network provided by the embodiment of the present invention by taking an MD, two SDs (the first SD and the second SD), and two UDs (the first UD and the second UD) as an example.
  • the first SD and the second SD are SD in the MD management area.
  • FIG. 8 is a flowchart of Embodiment 7 of an IP address allocation method for a master-slave network according to the present invention
  • the schematic diagram, as shown in FIG. 8, the IP address allocation method interaction process of the master-slave network can be as follows:
  • the MD generates an IP address sub-segment group, where the IP address sub-segment group includes at least one IP address sub-segment, and each IP address sub-segment includes at least one IP address.
  • the MD allocates the IP address sub-segment A in the address sub-segment group to the first SD, and allocates the IP address sub-segment B to the second SD.
  • the IP address subsection A includes an IP address a3 and an IP address b4; the IP address subsection B includes an IP address c and an IP address d.
  • the first SD starts a DHCP server, and establishes a DHCP server address pool.
  • the DHCP server address pool includes an IP address sub-segment A.
  • the second SD starts a DHCP server, and establishes a DHCP server address pool.
  • the DHCP server address pool includes an IP address. Subsection B.
  • the second UD is an UD that can allocate an IP address
  • the second UD sends an IP address request message to the second SD.
  • the second SD determines that the IP address request message is not from the WAN interface, and the assignable IP address c and the IP address d exist in the DHCP server address pool of the second SD;
  • the second SD allocates the IP address c to the second UD, and marks the IP address c as allocated in its DHCP server address pool.
  • the first UD accesses the first SD.
  • the first UD is a UD that has been assigned an IP address
  • the assigned IP address is an IP address d.
  • the first UD sends an IP address request message to the first SD, and is configured to request the first SD to allocate an IP address d for the first UD for multiplexing.
  • the first SD determines that the IP address request message is not from the WAN interface, and the DHCP server address pool of the first SD does not have an IP address d.
  • the first SD sends an IP address sub-segment request message to the MD, where the requesting MD allocates an IP address sub-section including the IP address d to the SD.
  • the MD queries the sub-segment of the IP address that can be allocated in the sub-segment group of the IP address, and determines that there is no sub-segment of the IP address including the IP address d.
  • the MD sends a reclaim request message to the second SD, where the second SD is requested to the MD. Returns the IP address subsection containing the IP address d.
  • the assignable IP address in the second SD self-DHCP server address pool includes an IP address d.
  • the second SD sends a return response to the MD, where the return response carries the IP address d, and the second SD updates the DHCP server address pool, and deletes the IP address d from the DHCP server address pool.
  • the MD sends a new IP address sub-segment according to the IP address d to the first SD.
  • S817 The first SD updates the DHCP server address pool, and marks the updated IP address d of the DHCP server address pool as allocated.
  • FIG. 8 is only an example of a specific embodiment, and is not limited to this example.
  • the MD After the network is powered on, the MD generates an IP address sub-segment group, that is, the IP address is divided into several IP address sub-segments.
  • the MD After the SD joins the MD-controlled autonomous network, the MD obtains its own IP address sub-segment group. Assign an IP address subsection to the SD.
  • FIG. 9 is a schematic structural diagram of Embodiment 1 of a master device according to the present invention.
  • the master device is a master device in the foregoing master-slave network.
  • the master device includes: a generating module 901 and a sending module 902. :
  • the generating module 901 is configured to generate an IP address sub-segment group, where the IP address sub-segment group includes at least one IP address sub-segment, and each of the IP address sub-segments includes at least one IP address.
  • the sending module 902 is configured to separately send the at least one IP address sub-segment in the IP address sub-segment group to the at least one slave device, so that the at least one slave device will receive the IP address.
  • the sub-section acts as the DHCP server address and assigns an IP address to the user equipment according to the DHCP server address.
  • FIG. 10 is a schematic structural diagram of Embodiment 2 of a main device according to the present invention. As shown in FIG. 10, the main device further includes: a first receiving module 110 and a first acquiring module 120, specifically based on the foregoing embodiments:
  • the first receiving module 110 is configured to receive the IP address sent by the slave device before the sending module 902 separately sends the at least one IP address sub-segment in the IP address sub-segment group to the at least one slave device a sub-segment request message, where the IP address sub-segment request message is used to request the master device to allocate N IP address sub-segments for the slave device, where N is a positive integer.
  • the first obtaining module 120 is configured to: if there are N assignables in the IP address sub-segment group The IP address sub-segment obtains N IP address sub-segments from the assignable IP address sub-segment; or, if there are no N assignable IP address sub-segments in the IP address sub-segment group, Retrieving an assignable IP address sub-segment from other slave devices in the management area of the master device until there are N assignable IP address sub-segments in the IP address sub-segment group, from the assignable IP address sub- Obtain N IP address subsections in the segment.
  • FIG. 11 is a schematic structural diagram of Embodiment 3 of a main device according to the present invention. As shown in FIG. 11, the main device further includes: a second receiving module 111 and a second acquiring module 112, specifically:
  • the second receiving module 111 is configured to receive the specific IP sent by the slave device before the sending module 902 separately sends the at least one IP address sub-segment in the IP address sub-segment group to the at least one slave device An address sub-segment request message, where the IP address sub-segment request message carries an identifier of a specific IP address sub-segment required by the slave device, and is used to request the master device to allocate the specific IP address to the slave device. segment.
  • the second obtaining module 112 is configured to acquire the specific IP address sub-segment if the specific IP address sub-segment exists in the assignable IP address sub-segment in the IP address sub-segment group; or, if the IP If the specific IP address sub-segment does not exist in the assignable IP address sub-segment in the address sub-segment group, the specific IP address sub-segment is reclaimed from other slave devices in the management area of the master device, and the reclaimed A specific IP address subsection.
  • FIG. 12 is a schematic structural diagram of Embodiment 4 of a master device according to the present invention.
  • the master device further includes: a third receiving module 121.
  • the embodiment shown in FIG. 12 may further include: a first receiving module 110 and a first acquiring module 120, or a second receiving module 111 and a second acquiring module 112.
  • the sending module 902 is further configured to send a reclaim message to the at least one slave device, where the reclaim message is used to request the slave device to return an IP address sub-segment required by the master device to the master device.
  • the third receiving module 121 is configured to receive a return response message sent by the slave device according to the reclaim message, where the return response message carries all or part of an IP address sub-section required by the master device returned by the slave device.
  • the identifier, or the return response message indicates that the slave device does not have an IP address sub-segment required by the master device.
  • FIG. 13 is a schematic structural diagram of a first embodiment of a slave device according to the present invention.
  • the slave device is a slave device in the foregoing master-slave network. As shown in FIG. 13, the slave device includes: a receiving module 131 and an allocating module 132. :
  • the receiving module 131 is configured to receive an IP address sub-segment sent by the primary device, and use the IP address sub-segment as a dynamic host configuration protocol DHCP server address, where the IP address sub-segment includes at least one IP address.
  • the allocating module 132 is configured to allocate an IP address to the user equipment according to the DHCP server address.
  • FIG. 14 is a schematic structural diagram of a second embodiment of a slave device according to the present invention. As shown in FIG. 14, the slave device further includes: a first sending module 141.
  • the first sending module 141 is configured to send an IP address sub-segment request message to the master device, where the receiving module 131 receives the IP address sub-segment sent by the master device, where the IP address sub-segment request message is used to request the main
  • the device allocates N IP address sub-segments for the slave device, where N is a positive integer.
  • FIG. 15 is a schematic structural diagram of a third embodiment of a slave device according to the present invention. As shown in FIG. 15, the slave device further includes: a second sending module 151.
  • the second sending module 151 is configured to: before the receiving module 131 receives the IP address sub-segment sent by the master device, send a specific IP address sub-segment request message to the master device, where the IP address sub-segment request message carries the slave An identifier of a specific IP address sub-segment required by the device, configured to request the master device to allocate the specific IP address sub-segment for the slave device.
  • FIG. 16 is a schematic structural diagram of a fourth embodiment of a slave device according to the present invention.
  • the slave device may further include: a query module 161 and a third sending module 162.
  • the first transmitting module 141 or the second transmitting module 151 may also be included.
  • the receiving module 131 is further configured to receive a reclaim message sent by the master device, where the reclaim message is used to request the slave device to return an IP address sub-segment required by the master device to the master device.
  • the querying module 161 is configured to query whether the DHCP server address includes an IP address sub-section required by the master device.
  • the third sending module 162 is configured to send a return response message to the primary device if the DHCP server address includes all or part of the IP address sub-segments required by the primary device, and the return The response message carries the identifier of all or part of the IP address subsection required by the master device included in the DHCP server address; or, if the DHCP server address does not include the IP address required by the master device And the sub-segment sends a return response message to the master device, where the return response message indicates that the master device does not have the IP address sub-segment required by the master device.
  • the receiving module 131 is further configured to receive a request message sent by the user equipment, where the request message is used to request the slave device to allocate an IP address to the user equipment.
  • FIG. 17 is a schematic structural diagram of Embodiment 5 of a master device according to the present invention.
  • the master device is a master device in the foregoing master-slave network. As shown in FIG. 17, the master device includes: a processor 171 and a transmitter 172. :
  • the processor 171 is configured to generate an internet protocol IP address sub-segment group, where the IP address sub-segment group includes at least one IP address sub-segment, and each of the IP address sub-segments includes at least one IP address.
  • the sender 172 is configured to separately send the at least one IP address sub-segment in the IP address sub-segment group to the at least one slave device, so that the at least one slave device will receive the IP address.
  • the sub-section acts as the dynamic host configuration protocol DHCP server address, and assigns an IP address to the user equipment according to the DHCP server address.
  • the master device further includes: a receiver 173, configured to send, at the transmitter 172, the at least one IP address sub-segment in the IP address sub-segment group to the at least one slave device And receiving an IP address sub-segment request message sent by the slave device, where the IP address sub-segment request message is used to request the master device to allocate N IP address sub-segments for the slave device, where N is a positive integer.
  • the processor 171 obtains N IP address sub-segments from the allocatable IP address sub-segments. If there are no N assignable IP address sub-segments in the IP address sub-segment group, the processor 171 reclaims the assignable IP address sub-segments to other slave devices in the management area of the master device until the There are N assignable IP address sub-segments in the IP address sub-segment group, and N IP address sub-segments are obtained from the assignable IP address sub-segments. Specifically, in the reclaiming process, the processor 171 can transmit a request through the transmitter 172 and receive a response or the like through the receiver 173.
  • the sender 172 sends the acquired N assignable IP address sub-segments to the slave device.
  • the receiver 173 is configured to receive a specific IP address sub-segment request message sent by the slave device, where the IP address sub-segment request message carries a specific IP address sub-segment required by the slave device. And the identifier is used to request the master device to allocate the specific IP address sub-segment for the slave device.
  • the processor 171 acquires the specific IP address sub-segment; if the IP address sub-segment group is assignable The specific IP address sub-segment does not exist in the IP address sub-segment, and the processor 171 reclaims the specific IP address sub-segment to other slave devices in the management area of the master device, and acquires the reclaimed specific IP address sub-segment .
  • the transmitter 172 is further configured to send a reclaim message to the at least one slave device, where the reclaim message is used to request the slave device to return an IP address required by the master device to the master device. segment.
  • a receiver configured to receive a return response message sent by the slave device according to the reclaim message, where the return response message carries an identifier of all or part of an IP address subsection required by the master device returned by the slave device Or, the return response message indicates that the slave device does not have an IP address sub-segment required by the master device.
  • the foregoing main device is used to perform the method embodiment corresponding to the foregoing main device, and the implementation principle and technical effects are similar, and details are not described herein again.
  • FIG. 18 is a schematic structural diagram of a fifth embodiment of a slave device according to the present invention.
  • the slave device is a slave device in the foregoing master-slave network. As shown in FIG. 18, the slave device includes: a receiver 181 and a processor 182.
  • the receiver 181 is configured to receive an IP address sub-segment sent by the primary device, and use the IP address sub-segment as a DHCP server address, where the IP address sub-segment includes at least one IP address.
  • the processor 182 is configured to allocate an IP address to the user equipment according to the DHCP server address.
  • the slave device may further include: a transmitter 183.
  • the sender 183 is configured to send an IP address sub-segment request message to the master device, where the receiver 181 receives the IP address sub-segment sent by the master device, where the IP address sub-segment request message is used to request the master device to be
  • the slave device allocates N IP address sub-segments, where N is a positive integer.
  • the transmitter 183 is configured to receive the IP address sent by the master device at the receiver 181. Before the sub-segment, the device sends a specific IP address sub-segment request message to the master device, where the IP address sub-segment request message carries an identifier of a specific IP address sub-segment required by the slave device, and is used to request the main The device allocates the specific IP address sub-segment for the slave device.
  • the receiver 181 is specifically configured to receive the specific IP address sub-segment allocated by the master device, and use the specific IP address sub-segment as a DHCP server address.
  • the receiver 181 is further configured to receive a reclaim message sent by the master device, where the reclaim message is used to request the slave device to return an IP address sub-segment required by the master device to the master device.
  • the processor 182 is configured to query whether the DHCP server address includes an IP address sub-segment required by the master device.
  • the sender 183 is configured to send a return response message to the master device if the DHCP server address includes all or part of the IP address sub-segments required by the master device, where the return response message carries the DHCP server.
  • the receiver 161 is further configured to receive a request message sent by the user equipment, where the request message is used to request the slave device to allocate an IP address to the user equipment.
  • the foregoing program may be stored in a computer readable storage medium, and the program is executed when executed.
  • the foregoing steps include the steps of the foregoing method embodiments; and the foregoing storage medium includes: a medium that can store program codes, such as a ROM, a RAM, a magnetic disk, or an optical disk.

Abstract

本发明提供一种主从型网络的IP地址分配方法、装置及系统,主设备生成IP地址子段组,并将IP地址子段组中至少一个IP地址子段分别发送给至少一个从设备,从设备就可以将接收到的IP地址子段作为DHCP服务器地址,并为用户设备分配IP地址,实现了从设备可以直接为用户设备分配IP地址,减少了IP地址的分配时间。

Description

主从型网络的IP地址分配方法、装置及系统 技术领域
本发明涉及无线通信技术领域,尤其涉及主从型网络的IP地址分配方法、装置及系统。
背景技术
主从型网络通常包括主设备(Master Device,简称:MD)、从设备(Slave Device,简称:SD)和用户设备(User Device,简称:UD)。其中,MD负责管理归属于管理区域的SD,以及在必要的情况下,基于MD之间通信协议与其它MD完成通信交互,MD也可能同步承担SD具备的业务功能,对外提供服务。SD配合MD完成业务功能,对外提供服务,并且可以为下一级SD提供管理信令通道及业务转发通道。UD则可以连接自治网络获得服务。
主从型网络中,UD要从自治网络获得服务,首先要获取一个IP地址。通常,互联网协议(Internet Protocol,简称IP)地址分配均由MD进行集中管理,当SD收到UD的动态主机配置协议(Dynamic Host Configuration Protocol,简称:DHCP)IP请求后,会逐级将该请求透传到MD。再由MD基于该请求为UD分配IP地址,并且将分配的IP地址逐级透传给该UD。
但是,现有IP地址分配的延迟过长,导致主从型网络的通信效率不高。
发明内容
本发明提供一种主从型网络的IP地址分配方法、装置及系统,用于提高主从型网络的通信效率。
本发明实施例第一方面提供一种主从型网络的IP地址分配方法,所述主从型网络包括一个主设备和所述主设备的管理区域中的至少一个从设备,该方法包括:
所述主设备生成互联网协议IP地址子段组,所述IP地址子段组包含至少一个IP地址子段,每个所述IP地址子段包括至少一个IP地址;
所述主设备将所述IP地址子段组中的所述至少一个IP地址子段分别发 送给所述至少一个从设备,以使所述至少一个从设备将接收到的所述IP地址子段作为动态主机配置协议DHCP服务器地址,并根据所述DHCP服务器地址为用户设备分配IP地址。
结合第一方面,在第一方面的第一种可能的实施方式中,所述主设备将所述IP地址子段组中的所述至少一个IP地址子段分别发送给所述至少一个从设备之前,还包括:
所述主设备接收所述从设备发送的IP地址子段请求消息,所述IP地址子段请求消息用于请求所述主设备为所述从设备分配N个IP地址子段,N为正整数;
若所述IP地址子段组中存在N个可分配的IP地址子段,则所述主设备从所述可分配的IP地址子段中获取N个IP地址子段;
若所述IP地址子段组中不存在N个可分配的IP地址子段,则所述主设备向所述主设备的管理区域中的其它从设备收回可分配的IP地址子段,直到所述IP地址子段组中存在N个可分配的IP地址子段,所述主设备从所述可分配的IP地址子段中获取N个IP地址子段。
结合第一方面,在第一方面的第二种可能的实施方式中,所述主设备将所述IP地址子段组中的所述至少一个IP地址子段分别发送给所述至少一个从设备之前,还包括:
所述主设备接收所述从设备发送的特定IP地址子段请求消息,所述IP地址子段请求消息中携带所述从设备所需的特定IP地址子段的标识,用于请求所述主设备为所述从设备分配所述特定IP地址子段;
若所述IP地址子段组中可分配的IP地址子段中存在所述特定IP地址子段,则所述主设备获取所述特定IP地址子段;
若所述IP地址子段组中可分配的IP地址子段中不存在所述特定IP地址子段,则所述主设备向所述主设备的管理区域中其它从设备收回所述特定IP地址子段,所述主设备获取收回的所述特定IP地址子段。
结合第一方面的第一或第二种可能的实施方式,在第一方面的第三种可能的实施方式中,所述方法还包括:
所述主设备向所述至少一个从设备发送收回消息,所述收回消息用于请求所述从设备向所述主设备返回所述主设备所需的IP地址子段;
所述主设备接收所述从设备根据所述收回消息发送的返回响应消息,所述返回响应消息中携带所述从设备返回的所述主设备所需的全部或部分IP地址子段的标识,或者,所述返回响应消息指示所述从设备不具有所述主设备所需的IP地址子段。
本发明实施例第二方面提供一种主从型网络的IP地址分配方法,所述主从型网络包括一个主设备和所述主设备的管理区域中的至少一个从设备,该方法包括:
从设备接收主设备发送的IP地址子段,将所述IP地址子段作为动态主机配置协议DHCP服务器地址,其中,所述IP地址子段中包括至少一个IP地址;
所述从设备根据所述DHCP服务器地址向用户设备分配IP地址。
结合第二方面,在第二方面的第一种可能的实施方式中,所述从设备接收主设备发送的IP地址子段之前,还包括:
所述从设备向所述主设备发送IP地址子段请求消息,所述IP地址子段请求消息用于请求所述主设备为所述从设备分配N个IP地址子段,其中,N为正整数。
结合第二方面,在第二方面的第二种可能的实施方式中,所述从设备接收主设备发送的IP地址子段之前,还包括:
所述从设备向所述主设备发送特定IP地址子段请求消息,所述IP地址子段请求消息中携带所述从设备所需的特定IP地址子段的标识,用于请求所述主设备为所述从设备分配所述特定IP地址子段。
结合第二方面的第一或第二种可能的实施方式,在第二方面的第三种可能的实施方式中,所述方法还包括:
所述从设备接收所述主设备发送的收回消息,所述收回消息用于请求所述从设备向所述主设备返回所述主设备所需的IP地址子段;
所述从设备查询所述DHCP服务器地址中是否包含所述主设备所需的IP地址子段;
若所述DHCP服务器地址中包含所述主设备所需的全部或部分IP地址子段,则所述从设备向所述主设备发送返回响应消息,所述返回响应消息中携带所述DHCP服务器地址中包含的所述主设备所需的全部或部分IP地址 子段的标识;或者,
若所述DHCP服务器地址中不包含所述主设备所需的IP地址子段,则所述从设备向所述主设备发送返回响应消息,所述返回响应消息指示所述主设备所述从设备不具有所述主设备所需的IP地址子段。
结合第二方面至第二方面的第三种可能的实施方式中任一项,在第二方面的第四种可能的实施方式中,所述方法还包括:
所述从设备接收用户设备发送的请求消息,所述请求消息用于请求所述从设备向所述用户设备分配IP地址。
本发明实施例第三方面提供一种主设备,所述主设备属于主从型网络,所述主从型网络包括所述主设备和所述主设备的管理区域中的至少一个从设备,所述主设备包括:
生成模块,用于生成互联网协议IP地址子段组,所述IP地址子段组包含至少一个IP地址子段,每个所述IP地址子段包括至少一个IP地址;
发送模块,用于将所述IP地址子段组中的所述至少一个IP地址子段分别发送给所述至少一个从设备,以使所述至少一个从设备将接收到的所述IP地址子段作为动态主机配置协议DHCP服务器地址,并根据所述DHCP服务器地址为用户设备分配IP地址。
结合第三方面,在第三方面的第一种可能的实施方式中,所述主设备还包括:第一接收模块和第一获取模块;
所述第一接收模块,用于在所述发送模块将所述IP地址子段组中的所述至少一个IP地址子段分别发送给所述至少一个从设备之前,接收所述从设备发送的IP地址子段请求消息,所述IP地址子段请求消息用于请求所述主设备为所述从设备分配N个IP地址子段,N为正整数;
所述第一获取模块,用于若所述IP地址子段组中存在N个可分配的IP地址子段,则从所述可分配的IP地址子段中获取N个IP地址子段;或者,若所述IP地址子段组中不存在N个可分配的IP地址子段,则向所述主设备的管理区域中的其它从设备收回可分配的IP地址子段,直到所述IP地址子段组中存在N个可分配的IP地址子段,从所述可分配的IP地址子段中获取N个IP地址子段。
结合第三方面,在第三方面的第二种可能的实施方式中,所述主设备还 包括:第二接收模块和第二获取模块;
所述第二接收模块,用于在所述发送模块将所述IP地址子段组中的所述至少一个IP地址子段分别发送给所述至少一个从设备之前,接收所述从设备发送的特定IP地址子段请求消息,所述IP地址子段请求消息中携带所述从设备所需的特定IP地址子段的标识,用于请求所述主设备为所述从设备分配所述特定IP地址子段;
所述第二获取模块,用于若所述IP地址子段组中可分配的IP地址子段中存在所述特定IP地址子段,则获取所述特定IP地址子段;或者,若所述IP地址子段组中可分配的IP地址子段中不存在所述特定IP地址子段,则向所述主设备的管理区域中其它从设备收回所述特定IP地址子段,获取收回的所述特定IP地址子段。
结合第三方面的第一或第二种可能的实施方式,在第三方面的第三种可能的实施方式中,所述主设备还包括:第三接收模块;
所述发送模块,还用于向所述至少一个从设备发送收回消息,所述收回消息用于请求所述从设备向所述主设备返回所述主设备所需的IP地址子段;
所述第三接收模块,用于接收所述从设备根据所述收回消息发送的返回响应消息,所述返回响应消息中携带所述从设备返回的所述主设备所需的全部或部分IP地址子段的标识,或者,所述返回响应消息指示所述从设备不具有所述主设备所需的IP地址子段。
本发明实施例第四方面提供一种从设备,所述从设备属于主从型网络,所述主从型网络包括一个主设备和所述主设备的管理区域中的至少一个从设备,所述从设备包括:
接收模块,用于接收主设备发送的IP地址子段,将所述IP地址子段作为动态主机配置协议DHCP服务器地址,其中,所述IP地址子段中包括至少一个IP地址;
分配模块,用于根据所述DHCP服务器地址向用户设备分配IP地址。
结合第四方面,在第四方面的第一种可能的实施方式中,所述从设备还包括:第一发送模块;
所述第一发送模块,用于在所述接收模块接收主设备发送的IP地址子段之前,向所述主设备发送IP地址子段请求消息,所述IP地址子段请求消 息用于请求所述主设备为所述从设备分配N个IP地址子段,其中,N为正整数。
结合第四方面,在第四方面的第二种可能的实施方式中,所述从设备还包括:第二发送模块;
所述第二发送模块,用于在所述接收模块接收主设备发送的IP地址子段之前,向所述主设备发送特定IP地址子段请求消息,所述IP地址子段请求消息中携带所述从设备所需的特定IP地址子段的标识,用于请求所述主设备为所述从设备分配所述特定IP地址子段。
结合第四方面的第一或第二种可能的实施方式,在第四方面的第三种可能的实施方式中,所述从设备还包括:查询模块和第三发送模块;
所述接收模块,还用于接收所述主设备发送的收回消息,所述收回消息用于请求所述从设备向所述主设备返回所述主设备所需的IP地址子段;
所述查询模块,用于查询所述DHCP服务器地址中是否包含所述主设备所需的IP地址子段;
所述第三发送模块,用于若所述DHCP服务器地址中包含所述主设备所需的全部或部分IP地址子段,则向所述主设备发送返回响应消息,所述返回响应消息中携带所述DHCP服务器地址中包含的所述主设备所需的全部或部分IP地址子段的标识;或者,若所述DHCP服务器地址中不包含所述主设备所需的IP地址子段,则向所述主设备发送返回响应消息,所述返回响应消息指示所述主设备所述从设备不具有所述主设备所需的IP地址子段。
结合第四方面至第四方面的第三种可能的实施方式中任一项,在第四方面的第四种可能的实施方式中,所述接收模块,还用于接收用户设备发送的请求消息,所述请求消息用于请求所述从设备向所述用户设备分配IP地址。
本发明实施例第五方面提供一种主设备,所述主设备属于主从型网络,所述主从型网络包括所述主设备和所述主设备的管理区域中的至少一个从设备,所述主设备包括:
处理器,用于生成互联网协议IP地址子段组,所述IP地址子段组包含至少一个IP地址子段,每个所述IP地址子段包括至少一个IP地址;
发送器,用于将所述IP地址子段组中的所述至少一个IP地址子段分别 发送给所述至少一个从设备,以使所述至少一个从设备将接收到的所述IP地址子段作为动态主机配置协议DHCP服务器地址,并根据所述DHCP服务器地址为用户设备分配IP地址。
结合第五方面,在第五方面的第一种可能的实施方式中,所述主设备还包括:接收器,用于在所述发送器将所述IP地址子段组中的所述至少一个IP地址子段分别发送给所述至少一个从设备之前,接收所述从设备发送的IP地址子段请求消息,所述IP地址子段请求消息用于请求所述主设备为所述从设备分配N个IP地址子段,N为正整数;
所述处理器,用于若所述IP地址子段组中存在N个可分配的IP地址子段,则从所述可分配的IP地址子段中获取N个IP地址子段;或者,若所述IP地址子段组中不存在N个可分配的IP地址子段,则向所述主设备的管理区域中的其它从设备收回可分配的IP地址子段,直到所述IP地址子段组中存在N个可分配的IP地址子段,所述主设备从所述可分配的IP地址子段中获取N个IP地址子段。
结合第五方面,在第五方面的第二种可能的实施方式中,还包括:接收器,用于在所述发送器将所述IP地址子段组中的所述至少一个IP地址子段分别发送给所述至少一个从设备之前,接收所述从设备发送的特定IP地址子段请求消息,所述IP地址子段请求消息中携带所述从设备所需的特定IP地址子段的标识,用于请求所述主设备为所述从设备分配所述特定IP地址子段;
所述处理器,用于若所述IP地址子段组中可分配的IP地址子段中存在所述特定IP地址子段,则获取所述特定IP地址子段;或者,若所述IP地址子段组中可分配的IP地址子段中不存在所述特定IP地址子段,则向所述主设备的管理区域中其它从设备收回所述特定IP地址子段,所述主设备获取收回的所述特定IP地址子段。
结合第五方面的第一或第二种可能的实施方式,在第五方面的第三种可能的实施方式中,所述发送器,还用于向所述至少一个从设备发送收回消息,所述收回消息用于请求所述从设备向所述主设备返回所述主设备所需的IP地址子段;
所述接收器,还用于接收所述从设备根据所述收回消息发送的返回响应 消息,所述返回响应消息中携带所述从设备返回的所述主设备所需的全部或部分IP地址子段的标识,或者,所述返回响应消息指示所述从设备不具有所述主设备所需的IP地址子段。
本发明实施例第六方面提供一种从设备,所述从设备属于主从型网络,所述主从型网络包括一个主设备和所述主设备的管理区域中的至少一个从设备,所述从设备包括:
接收器,用于接收主设备发送的IP地址子段,将所述IP地址子段作为动态主机配置协议DHCP服务器地址,其中,所述IP地址子段中包括至少一个IP地址;
处理器,用于根据所述DHCP服务器地址向用户设备分配IP地址。
结合第六方面,在第六方面的第一种可能的实施方式中,还包括:发送器,用于在所述接收器接收主设备发送的IP地址子段之前,向所述主设备发送IP地址子段请求消息,所述IP地址子段请求消息用于请求所述主设备为所述从设备分配N个IP地址子段,其中,N为正整数。
结合第六方面,在第六方面的第二种可能的实施方式中,还包括:发送器,在所述接收器接收主设备发送的IP地址子段之前,向所述主设备发送特定IP地址子段请求消息,所述IP地址子段请求消息中携带所述从设备所需的特定IP地址子段的标识,用于请求所述主设备为所述从设备分配所述特定IP地址子段。
结合第六方面的第一或第二种可能的实施方式,在第六方面的第三种可能的实施方式中,所述接收器,还用于接收所述主设备发送的收回消息,所述收回消息用于请求所述从设备向所述主设备返回所述主设备所需的IP地址子段;
所述处理器,还用于查询所述DHCP服务器地址中是否包含所述主设备所需的IP地址子段;
所述发送器,还用于若所述DHCP服务器地址中包含所述主设备所需的全部或部分IP地址子段,则向所述主设备发送返回响应消息,所述返回响应消息中携带所述DHCP服务器地址中包含的所述主设备所需的全部或部分IP地址子段的标识;或者,若所述DHCP服务器地址中不包含所述主设备所需的IP地址子段,则向所述主设备发送返回响应消息,所述返回响应消 息指示所述主设备所述从设备不具有所述主设备所需的IP地址子段。
结合第六方面至第六方面的第三种可能的实施方式中任一项,在第六方面的第四种可能的实施方式中,所述接收器,还用于接收用户设备发送的请求消息,所述请求消息用于请求所述从设备向所述用户设备分配IP地址。
本发明实施例提供的主从型网络的IP地址分配方法、装置及系统,主设备生成IP地址子段组,并将IP地址子段组中至少一个IP地址子段分别发送给至少一个从设备,从设备就可以将接收到的IP地址子段作为DHCP服务器地址,并根据该DHCP服务器地址为用户设备分配IP地址,即实现了从设备可以直接为用户设备分配IP地址,大大减少了IP地址的分配时间,提高了主从型网络的通信效率。
附图说明
为了更清楚地说明本发明实施例或现有技术中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图做一简单地介绍,显而易见地,下面描述中的附图是本发明的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动性的前提下,还可以根据这些附图获得其他的附图。
图1为本发明实施例提供的一种主从型网络的架构示意图;
图2为本发明提供的主从型网络的IP地址分配方法实施例一的流程示意图;
图3为本发明提供的主从型网络的IP地址分配方法实施例二的流程示意图;
图4为本发明提供的主从型网络的IP地址分配方法实施例三的流程示意图;
图5为本发明提供的主从型网络的IP地址分配方法实施例四的流程示意图;
图6为本发明提供的主从型网络的IP地址分配方法实施例五的流程示意图;
图7为本发明提供的主从型网络的IP地址分配方法实施例六的流程 示意图;
图8为本发明提供的主从型网络的IP地址分配方法实施例七的流程示意图;
图9为本发明提供的主设备实施例一的结构示意图;
图10为本发明提供的主设备实施例二的结构示意图;
图11为本发明提供的主设备实施例三的结构示意图;
图12为本发明提供的主设备实施例四的结构示意图;
图13为本发明提供的从设备实施例一的结构示意图;
图14为本发明提供的从设备实施例二的结构示意图;
图15为本发明提供的从设备实施例三的结构示意图;
图16为本发明提供的从设备实施例四的结构示意图;
图17为本发明提供的主设备实施例五的结构示意图;
图18为本发明提供的从设备实施例五的结构示意图。
具体实施方式
为使本发明实施例的目的、技术方案和优点更加清楚,下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例是本发明一部分实施例,而不是全部的实施例。基于本发明中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都属于本发明保护的范围。
图1为本发明实施例提供的一种主从型网络的架构示意图,参照图1,该主从型网络包括:一个主设备(Master Device,简称:MD),该主设备管理区域中的至少一个从设备(Slave Device,简称:SD)和至少一个用户设备(User Device,简称:UD);
其中,MD的功能为:负责管理归属于管理区域的从设备;以及在必要的情况下,基于主设备之间通信协议,与其他主设备完成通信交互;本发明实施例提供的MD与现有技术中的MD最大的改进在于:本发明实施例提供的MD能够将IP地址段划分为多个IP地址子段,并将不同的IP地址子段分别分配给不同的SD。进一步的:MD还可以通过动态配置IP地址,实现IP地址的再分配与IP地址的回收。
SD的功能为:配合主设备完成业务功能,对外提供服务;为下一级从设备提供管理信令通道及业务转发通道。本发明实施例提供的SD与现有技术中的SD最大的改进在于:本发明实施例提供的SD支持DHCP协议,可以根据MD分配的IP地址子段,建立DHCP服务器地址池,直接为UD分配IP地址,从而避免了在为UD分配IP地址时,逐级透传IP地址请求,减少了配置过程中不必要的交互流程,降低了延迟,提高了主从型网络的通信效率。进一步的:对应MD针对IP地址子段的动态调整,SD也具有管理、维护和更新DHCP服务器地址池的功能。
需要说明的是,图1所示的架构示意图,其仅为一种示例。MD与其他MD也可以通过协议进行通信,UD也可以直接与MD连接,此处对于主从型网络配置IP地址的系统的部署结构不做具体限定。
下面通过具体实施例,对本发明实施例提供的MD与SD进行详细说明。
图2为本发明提供的主从型网络的IP地址分配方法实施例一的流程示意图,该方法执行主体为上述主从型网络中的MD,参照图2,该方法包括:
S201、主设备生成IP地址子段组,该IP地址子段组包含至少一个IP地址子段,每个IP地址子段包括至少一个IP地址。
即主设备将IP地址进行划分,分成多个IP地址子段,再将多个IP地址子段分成IP地址子段组。
S202、主设备将上述IP地址子段组中的至少一个IP地址子段分别发送给至少一个从设备,以使该至少一个从设备将将接收到的IP地址子段作为DHCP服务器地址,并根据该DHCP服务器地址为用户设备分配IP地址。
具体地,MD会给管理区域中的从设备分配IP地址子段,本发明实施例中,从设备支持DHCP协议,从设备接收到主设备发送的IP地址子段后,可以建立DHCP服务器地址池,用于容纳DHCP服务器地址,进而根据用户设备的需求给用户设备分配IP地址。
需要说明的是,当主从型网络中,MD的管理区域中存在多个SD时,MD为每个SD分配的IP地址子段是相互不重复的。MD会在IP地址子段组中将分配出去的IP地址子段标记为已分配。
本实施例中,主设备生成IP地址子段组,并将IP地址子段组中至少一个IP地址子段分别发送给至少一个从设备,从设备就可以将接收到的IP地址子段作为DHCP服务器地址,并根据该DHCP服务器地址为用户设备分配IP地址,即实现了从设备可以直接为用户设备分配IP地址,大大减少了IP地址的分配时间,提高了主从型网络的通信效率。
一些情况下,主设备会接收到管理区域内从设备主动发送的IP地址子段请求,即主动请求主设备分配IP地址子段。
图3为本发明提供的主从型网络的IP地址分配方法实施例二的流程示意图。如图3所示,在上述主设备将上述IP地址子段组中的至少一个IP地址子段分别发送给至少一个从设备之前,还可以包括:
S301、主设备接收从设备发送的IP地址子段请求消息,该IP地址子段请求消息用于请求该主设备为上述从设备分配N个IP地址子段。
N为正整数。
这里的从设备可以是主从型网络中任意一个有IP地址分配需求的从设备。
主设备接收到该IP地址子段请求消息后会查看自己IP地址子段组中可分配的IP地址子段。这里可分配的IP地址子段是指还没有分给从设备的IP地址子段。
S302、若上述IP地址子段组中存在N个可分配的IP地址子段,则该主设备从上述可分配的IP地址子段中获取N个IP地址子段。进而,主设备可以向上述从设备分配N个IP地址子段。
需要说明的是,主设备在IP地址子段组中可分配的IP地址子段中进行判断是否存在从设备请求的N个IP地址子段,已经分配给从设备的IP地址子段不在判断范围内。
具体地,主设备可以预先设置可分配IP地址子段的预设阈值k,即主设备自身保持最少具有k个IP地址子段,以便于及时满足从设备的需求,即如果某个从设备请求主设备分配N个IP地址子段,那么主设备至少具有N+k个可分配的IP地址子段,如果主设备中可分配的IP地址子段小于N+k个,则需要向其它从设备收回IP地址子段之后再分配。其中,k为大于或等于0的正整数。
S303、若上述IP地址子段组中不存在N个可分配的IP地址子段,则该主设备向该主设备的管理区域中的其它从设备收回可分配的IP地址子段,直到上述IP地址子段组中存在N个可分配的IP地址子段,主设备从上述可分配的IP地址子段中获取N个IP地址子段。
然后,主设备可以向上述从设备分配N个IP地址子段。如果主设备设置了阈值k,则主设备需要从其他从设备收回分配的IP地址子段,主设备可以将收回的IP地址子段进行划分,更新或生成上述IP地址子段组,直到该主设备的IP地址子段组中存在N+k个可分配的IP地址子段。
具体地,假设主设备可以随机向管理区域中的某一从设备请求收回M个可分配的IP地址子段,如果这个从设备中可分配的IP地址子段只有m个,小于M个,那么该从设备向主设备返回m个可分配的IP地址子段,进而主设备再向其它从设备请求收回可分配的M-m个IP地址子段,依此类推,直到上述IP地址子段组中可分配的IP地址子段除去预设阈值的个数后大于或等于N个为止。
图4为本发明提供的主从型网络的IP地址分配方法实施例三的流程示意图。如图4所示,在图2实施例的基础上,在上述主设备将上述IP地址子段组中的至少一个IP地址子段分别发送给至少一个从设备之前,还可以包括:
S401、主设备接收从设备发送的特定IP地址子段请求消息,该IP地址子段请求消息中携带该从设备所需的特定IP地址子段的标识,用于请求主设备为该从设备分配特定IP地址子段。
即这种情况下,从设备请求主设备分配某些特定的IP地址子段,从设备可以在IP地址子段请求消息中携带该特定IP地址子段的标识,以告知主设备所请求的IP地址子段。
主设备接收到该特定IP地址子段请求消息后会查看自己可分配的IP地址子段,看是否存在特定IP地址子段。
S402、若上述IP地址子段组中可分配的IP地址子段中存在上述特定IP地址子段,则主设备获取该特定IP地址子段。进而主设备可以将该特定的IP地址子段分配给上述从设备。
S403、若上述IP地址子段组中可分配的IP地址子段中不存在上述特 定IP地址子段,则主设备向该主设备的管理区域中其它从设备收回上述特定IP地址子段,该主设备获取收回的上述特定IP地址子段。进而可以将收回的特定IP地址子段分配给第一从设备。
具体地,假设主设备可以随机向管理区域中的某一从设备请求收回特定IP地址子段,该从设备如果有特定IP地址子段,则返回给主设备,主设备可以将收回的特定IP地址子段分配给上述请求该特定IP地址子段的从设备,如果主设备请求收回特定IP地址子段的从设备也没有特定IP地址子段,则告知主设备没有,主设备再向其它从设备收回特定IP地址子段。回收过程中,某个从设备如果有特定IP地址子段也可以拒绝返回给主设备,这种情况下主设备无法给请求该特定IP地址子段的从设备分配特定IP地址子段,流程结束,主设备也可以通知从设备没有特定IP地址子段。
由上述实施例可知,在一些情况下,主设备需要向管理区域中的从设备收回之前分配的IP地址子段,例如:(1)MD的IP地址子段无法满足新IP地址或新IP地址子段申请请求要求时,向SD请求新增IP地址子段,或者,SD请求占用某个已分配给其它UD的IP地址。(2)MD周期性触发各个SD收回可分配的IP地址,或者,各个SD周期性的将各自可分配的IP地址上报给MD。当然并不以上述情况为限。
图5为本发明提供的主从型网络的IP地址分配方法实施例四的流程示意图,如图5所示,该方法包括:
S501、主设备向至少一个从设备发送收回消息,该收回消息用于请求该从设备向上述主设备返回该主设备所需的IP地址子段。
或者,某些情况下还收回消息用于请求该从设备向上述主设备返回该主设备所需的IP地址。
主设备可以随机想至少一个从设备中的一个从设备发送收回消息,如果这个从设备没有主设备所需的IP地址子段,或者只有部分IP地址子段,主设备再向其它从设备收回,依次类推。
S502、主设备接收从设备根据上述收回消息发送的返回响应消息,该返回响应消息中携带该从设备返回的上述主设备所需的全部或部分IP地址子段的标识,或者,该返回响应消息指示该从设备不具有上述主设备所需的IP地 址子段。
具体地,有下述两种常见情况,但并不以此为限:
1)上述收回消息中携带主设备需要收回的至少一个IP地址子段的标识。即收回消息中会指示主设备要收回的特定IP地址子段。
这种情况下,主设备接收从设备根据收回消息发送的返回响应消息,该返回响应消息中携带该从设备返回的上述主设备需要收回的至少一个IP地址子段中全部或部分IP地址子段的标识。或者,该返回响应消息指示该第一从设备不具有可返回的IP地址子段。
例如主设备要收回3个IP地址子段:IP地址子段A、IP地址子段B、IP地址子段C,如果这3个IP地址子段从设备都没有,则在返回响应消息中指示该从设备不具有可返回的IP地址子段,如果从设备有这3个IP地址子段,则可以在返回响应消息中携带这3个IP地址子段标识,或者,从设备有其中一个IP地址子段A,那么可以在返回响应消息中携带IP地址子段A的标识,当然,从设备如果已经将IP地址子段A分配给UD或者有其它用途,从设备也可以不放弃IP地址子段A,则可以告知主设备不返回IP地址子段A。
某些特殊情况下,主设备可能要收回包含某个特定IP地址的IP地址子段,收回消息中携带特定IP地址的标识,从设备如果刚好有包含该IP地址的IP地址子段则可以直接通过返回响应消息返回包含这个IP地址的IP地址子段,如果从设备具有该IP地址,但是IP地址原所在的IP地址子段已经不存在,那么从设备可以在返回响应消息单独返回该IP地址,由主设备根据该IP地址生成新的IP地址子段。
2)上述收回消息中携带主设备需要收回的IP地址子段的个数N,其中N为正整数。即主设备只告知需要收回的IP地址子段的个数,无需特定的IP地址子段。相应地,
主设备接收从设备根据收回消息发送的返回响应消息,该返回响应消息中携带从设备返回的n个IP地址子段的标识,其中,n为正整数且小于或等于N。或者,返回响应消息指示该从设备不具有可返回的IP地址子段。
从设备具体可以根据自己可分配的IP地址子段的个数决定返回的IP地址子段的个数。其中,从设备可以设置自己可分配的IP地址子段不少于k个,k大于或等于0。例如从设备有M个可分配的IP地址子段,M大于k,那么 从设备最多可以向主设备返回M-k个IP地址子段。如果从设备中可分配的IP地址子段小于或等于k,则指示该从设备不具有可返回的IP地址子段。
当然,主设备也可以仅向从设备发送收回消息,即不指示收回的个数,也不指示特定的IP地址子段标识,此时,从设备可以根据自身情况向主设备返回一个或多个可分配的IP地址子段,或者,一个或多个可分配的IP地址。
在上述实施例的基础上,对于上述返回响应消息指示从设备不具有可返回的IP地址子段的情况,主设备向管理区域中除上述从设备之外的一个从设备发送的收回消息,该收回消息用于请求这个从设备向主设备返回主设备所需的IP地址子段,以此类推,直到主设备收回所需的IP地址子段。
另外,对于上述返回响应消息中携带从设备返回的主设备所需的部分IP地址子段标识的情况,主设备还可以向管理区域中除上述从设备之外的某一从设备发送收回消息,该收回消息用于请求这个从设备向主设备返回主设备所需的剩余IP地址子段,该剩余IP地址子段为主设备需要的IP地址子段中除去上述从设备返回的所述部分IP地址子段之外的IP地址子段。例如,主设备向第一从设备请求10个IP地址子段,第一从设备向主设备返回了6个IP地址子段,主设备再向第二从设备请求收回4个IP地址子段,第二从设备采用和第一从设备同样的方式确定可以返回的个数,如果主设备还是没有收回10个IP地址子段,可以继续向其它从设备请求,直到获得10个。同样,主设备收回多个特定的IP地址子段,也可以分别从不同的从设备收回。
上述主设备在收回IP地址子段时可以随机选择从设备进行收回,在此不作限定。当然,为了更好地提高IP地址分配效率,也可以预设每个从设备周期性的上报各自维护的DHCP服务器地址情况,具体地,每个从设备周期性上报的消息中可以包括:DHCP服务器地址池中可分配的IP地址信息、可分配的IP地址的总个数等。主设备在收回IP地址子段时,可以基于从设备上报的消息进行选择。当然,如果不预设从设备周期性上报的话,也可以由主设备周期性地向从设备发送查询消息,该查询消息用于请求从设备上报各自维护的DHCP服务器地址情况。
本发明实施例中,某些情况下,例如主设备直接与用户设备连接的情况等,主设备还可以直接给用户设备分配IP地址子段,具体地,主设备可以将上述IP地址子段组中的用户设备IP地址子段发送给用户设备,该用户设备 IP地址为上述IP地址子段组中的至少一个IP地址子段。具体地实现过程中,MD可以在生成的IP地址子段组中划分至少一个IP地址子段作为用户设备IP地址子段,用于为UD分配IP地址。
与发送给从设备同样,某些情况下,主设备可以将上述IP地址子段组中的用户设备IP地址子段发送给用户设备之后,主设备还可以向用户设备发送收回消息,该收回消息用于请求用户设备向主设备返回该主设备所需的IP地址子段。具体地收回方式可以参照前述从设备,在此不再赘述。
图6为本发明提供的主从型网络的IP地址分配方法实施例五的流程示意图,该方法的执行主体是从设备,该从设备可以指前述主设备管理区域内的任一从设备,该从设备支持DHCP协议。
如图6所示,该方法包括:
S601、从设备接收主设备发送的IP地址子段,将上述IP地址子段作为DHCP服务器地址,其中,该IP地址子段中包括至少一个IP地址。
S602、从设备根据该DHCP服务器地址向用户分配IP地址。
即主设备会直接给从设备发送IP地址子段,该IP地址子段中包括至少一个IP地址,这样从设备就可以直接在主设备分配的IP地址子段中给用户设备分配IP地址。
本实施例中,从设备接收主设备发送的IP地址子段,将上述IP地址子段作为DHCP服务器地址,并可以根据该DHCP服务器地址向用户分配IP地址,实现了从设备可以直接给用户设备分配IP地址,大大减少了IP地址的分配时间,提高了主从型网络的通信效率。
进一步地,某些情况下从设备还需要主动请求主设备分配IP地址子段,例如有新的UD接入时,需要分配IP地址,但是DHCP服务器地址中没有可分配的IP地址了,或者,某UD请求分配特定的IP地址,但是从设备可分配的IP地址中没有该特定的IP地址等,并不以此为限。
具体地:
1)从设备接收主设备发送的第一IP地址子段之前,该从设备可以向主设备发送IP地址子段请求消息,IP地址子段请求消息用于请求主设备为该从设备分配N个IP地址子段。其中N为正整数。
2)从设备接收主设备发送的IP地址子段之前,该从设备可以向主设备 发送特定IP地址子段请求消息,IP地址子段请求消息中携带该从设备所需的特定IP地址子段的标识,用于请求主设备为该从设备分配该特定IP地址子段。
例如,UD请求从设备分配IP地址A,从设备查看自己可分配的DHCP服务器地址,发现其中没有IP地址A,则从设备可以向主设备请求分配包含该IP地址A的特定IP地址子段。
相比而言,现有技术中的SD,其本身不需要IP地址,因此SD通常不会作为请求者向MD申请IP地址。
图7为本发明提供的主从型网络的IP地址分配方法实施例六的流程示意图,如图7所示,在图6所示实施例的基础上,该方法还包括:
S701、从设备接收主设备发送的收回消息,该收回消息用于请求该从设备向上述主设备返回主设备所需的IP地址子段。
S702、从设备查询上述DHCP服务器地址中是否包含主设备所需的IP地址子段。
S703、若上述DHCP服务器地址中包含主设备所需的全部或部分IP地址子段,则该从设备向主设备发送返回响应消息,该返回响应消息中携带DHCP服务器地址中包含的上述主设备所需的全部或部分IP地址子段的标识。当然,该从设备也可以不返回,则流程结束。
S704、若上述DHCP服务器地址中不包含主设备所需的IP地址子段,则从设备向主设备发送返回响应消息,该返回响应消息指示主设备该从设备不具有主设备所需的IP地址子段。
具体实施过程中,至少包括下述情况:
1)上述收回消息中携带主设备需要收回的至少一个IP地址子段的标识。相应地,
上述S702可以具体为:从设备查询DHCP服务器地址中是否包含主设备需要收回的至少一个IP地址子段中全部或部分IP地址子段。
S703具体为:若上述DHCP服务器地址中包含主设备需要收回的至少一个IP地址子段中全部或部分IP地址子段,则该从设备向主设备发送返回响应消息,该返回响应消息中携带DHCP中包含的上述主设备需要收回的至少一个IP地址子段中全部或部分IP地址子段的标识。
这种情况下,如果主设备需要收回的IP地址子段已经分配给UD了,从设备可以不响应主设备,或者告知主设备收回失败。
2)上述收回消息中携带主设备需要收回IP地址子段的个数N,其中,N为正整数。相应地,
上述S702可以具体为:从设备查询DHCP服务器地址中可分配的IP地址子段的个数。
S703具体为:若上述DHCP服务器地址中可分配的IP地址子段的个数为n,n为正整数且大于或等于N,则从设备向主设备发送返回响应消息,该返回响应消息中携带所述DHCP服务器地址中可分配的N个IP地址子段的标识。需要说明的是,如果该从设备设置有阈值k,k为正整数,即该从设备可分配的IP地址子段不能小于k个,那么n大于或等于N+k时,从设备才会向主设备返回N个IP地址子段。
或者,S703具体为:若上述DHCP服务器地址中可分配的IP地址子段的个数为n,n为正整数且小于N,则从设备向主设备发送返回响应消息,该返回响应消息中携带DHCP服务器地址中可分配的n个IP地址子段的标识。此时主设备还缺少N-n个IP地址子段,主设备会向管理区域中其它从设备继续请求收回IP地址子段。
在上述实施例的基础上,UD可以向从设备主动请求分配IP地址,即从设备接收用户设备发送的请求消息,该请求消息用于请求该从设备向用户设备分配IP地址。
具体地也可以至少包括下述两种情况:
1、上述从设备接收用户设备发送的第一请求消息,该第一请求消息用于请求从设备向该用户设备分配新的IP地址。即有UD接入网络,且该UD之前未被分配过IP地址,需要分配新的IP地址。相应地,
上述S602具体包括:从设备查询上述DHCP服务器地址中是否存在可分配的IP地址,若是,则该从设备从可分配的IP地址中向该用户设备分配IP地址;若否,则从设备先请求主设备分配新的IP地址子段,在接收到主设备分配的新的IP地址子段后从该新的IP地址子段中向用户设备分配IP地址。
或者,
2、上述从设备接收用户设备发送的第二请求消息,该第二请求消息中携带该用户设备在先分配过的第一IP地址的标识,该第二请求消息用于请求该从设备向用户设备分配该第一IP地址进行复用。即UD曾被分配过第一IP地址,UD要求复用该IP地址而不要新的IP地址。相应地,
上述S602具体包括:从设备查询上述DHCP服务器地址中可分配的IP地址中是否包含上述第一IP地址,若是,则将该第一IP地址标记为已分配;若否,则从设备请求主设备分配包含上述第一IP地址的IP地址子段,并在接收到主设备分配的包含第一IP地址的IP地址子段后,将该IP地址标记为已分配。具体地,从设备接收到主设备分配的包含所述第一IP地址的IP地址子段后,先刷新自己DHCP服务器地址中可分配的IP地址,然后将DHCP服务器地址中的第一IP地址标记为已分配。
上述实施例中,从设备请求分配包含第一IP地址的IP地址子段时,如果主设备具有包含第一IP地址的IP地址子段则可以直接分配给该从设备,如果没有,主设备向其它从设备收回包含第一IP地址的IP地址子段时,如果某个从设备具有包含第一IP地址的IP地址子段,可以直接将整个包含第一IP地址的IP地址子段返回给主设备,也有特殊情况,例如某个从设备有第一IP地址,但是原第一IP地址所在的IP地址子段已经不存在,例如其它IP地址已经分配等原因,那么该从设备可以仅向主设备返回第一IP地址,主设备根据第一IP地址生成新的IP地址子段再发送给上述从设备。
需要说明的是,主从型网络中主设备和从设备之间通过广域网(Wide Area Network,简称WAN)接口连接,即通常将SD设备与MD设备相连的逻辑接口或物理接口定义成所述WAN接口,在IP网络中,通常不会为所述WAN接口分配IP地址。具体实施过程中,SD接收到UD发送的请求分配IP地址的请求消息后,先判断该消息是否来自于WAN接口,如果是,则忽略该请求消息,如果不是,则按照上述流程为UD分配IP地址。
下面以一个MD、两个SD(第一SD和第二SD)和两个UD(第一UD和第二UD)为例,对本发明实施例提供的主从型网络的IP地址分配方法进行说明,其中,第一SD和第二SD为MD管理区域内的SD。
图8为本发明提供的主从型网络的IP地址分配方法实施例七的流程 示意图,如图8所示,主从型网络的IP地址分配方法交互流程可以如下所示:
S801、MD生成IP地址子段组,该IP地址子段组包含至少一个IP地址子段,每个IP地址子段包括至少一个IP地址。
S802、MD将上述地址子段组中的IP地址子段A分配给第一SD,并将IP地址子段B分配给第二SD。
具体的,该IP地址子段A包含IP地址a3和IP地址b4;IP地址子段B包括IP地址c和IP地址d。
S803、第一SD启动DHCP服务器,建立DHCP服务器地址池,所述DHCP服务器地址池包含IP地址子段A,第二SD启动DHCP服务器,建立DHCP服务器地址池,所述DHCP服务器地址池包含IP地址子段B。
S804、第二UD接入第二SD;
具体的,第二UD为可分配IP地址的UD;
S805、第二UD向第二SD发送IP地址请求消息;
S806、第二SD确定该IP地址请求消息并非来自WAN接口,且该第二SD的DHCP服务器地址池中存在可分配的IP地址c和IP地址d;
S807、第二SD将IP地址c分配给第二UD,并在其DHCP服务器地址池中将IP地址c标记为已分配。
S808、第一UD接入第一SD。
具体的,第一UD为曾经已分配过IP地址的UD,其分配的IP地址为IP地址d。
S809、第一UD向第一SD发送IP地址请求消息,用于请求第一SD为第一UD分配IP地址d进行复用。
S810、第一SD确定该IP地址请求消息并非来自广域网WAN接口,且该第一SD的DHCP服务器地址池不存在IP地址d。
S811、第一SD向MD发送IP地址子段请求消息,用于请求MD为该SD分配包含IP地址d的IP地址子段。
S812、MD查询自己的IP地址子段组中可分配的IP地址子段,确定不存在包含IP地址d的IP地址子段。
S813、MD向第二SD发送收回请求消息,用于请求第二SD向该MD 返回包含IP地址d的IP地址子段。
S814、第二SD自身DHCP服务器地址池中可分配的IP地址包含IP地址d。
S815、第二SD向MD发送返回响应,该返回响应中携带IP地址d,且第二SD更新DHCP服务器地址池,将IP地址d从DHCP服务器地址池中删除。
S816、MD将根据IP地址d生成新的IP地址子段发送给第一SD。
S817、第一SD更新DHCP服务器地址池,并将更新后的DHCP服务器地址池的IP地址d标记为已分配。
需要说明的是,图8仅是一个具体实施例的示例,并不以该例为限。
具体地实施过程中,网络上电后,MD生成IP地址子段组,即将自身IP地址划分成若干个IP地址子段,SD加入该MD控制的自治网络后,MD从自己IP地址子段组中分配一IP地址子段给SD。
图9为本发明提供的主设备实施例一的结构示意图,该主设备为前述主从型网络中的主设备,如图9所示,该主设备包括:生成模块901和发送模块902,其中:
生成模块901,用于生成IP地址子段组,所述IP地址子段组包含至少一个IP地址子段,每个所述IP地址子段包括至少一个IP地址。
发送模块902,用于将所述IP地址子段组中的所述至少一个IP地址子段分别发送给所述至少一个从设备,以使所述至少一个从设备将接收到的所述IP地址子段作为DHCP服务器地址,并根据所述DHCP服务器地址为用户设备分配IP地址。
图10为本发明提供的主设备实施例二的结构示意图,如图10所示,该主设备还包括:第一接收模块110和第一获取模块120,具体地在上述实施例的基础上:
第一接收模块110,用于在发送模块902将所述IP地址子段组中的所述至少一个IP地址子段分别发送给所述至少一个从设备之前,接收所述从设备发送的IP地址子段请求消息,所述IP地址子段请求消息用于请求所述主设备为所述从设备分配N个IP地址子段,N为正整数。
第一获取模块120,用于若所述IP地址子段组中存在N个可分配的 IP地址子段,则从所述可分配的IP地址子段中获取N个IP地址子段;或者,若所述IP地址子段组中不存在N个可分配的IP地址子段,则向所述主设备的管理区域中的其它从设备收回可分配的IP地址子段,直到所述IP地址子段组中存在N个可分配的IP地址子段,从所述可分配的IP地址子段中获取N个IP地址子段。
图11为本发明提供的主设备实施例三的结构示意图,如图11所示,该主设备还包括:第二接收模块111和第二获取模块112,具体地:
第二接收模块111,用于在发送模块902将所述IP地址子段组中的所述至少一个IP地址子段分别发送给所述至少一个从设备之前,接收所述从设备发送的特定IP地址子段请求消息,所述IP地址子段请求消息中携带所述从设备所需的特定IP地址子段的标识,用于请求所述主设备为所述从设备分配所述特定IP地址子段。
第二获取模块112,用于若所述IP地址子段组中可分配的IP地址子段中存在所述特定IP地址子段,则获取所述特定IP地址子段;或者,若所述IP地址子段组中可分配的IP地址子段中不存在所述特定IP地址子段,则向所述主设备的管理区域中其它从设备收回所述特定IP地址子段,获取收回的所述特定IP地址子段。
图12为本发明提供的主设备实施例四的结构示意图,如图12所示,该主设备还包括:第三接收模块121。图12所示的实施例中也可以包括:第一接收模块110和第一获取模块120,或者,包括第二接收模块111和第二获取模块112。
具体地:
上述发送模块902还用于向所述至少一个从设备发送收回消息,所述收回消息用于请求所述从设备向所述主设备返回所述主设备所需的IP地址子段。
第三接收模块121用于接收所述从设备根据所述收回消息发送的返回响应消息,所述返回响应消息中携带所述从设备返回的所述主设备所需的全部或部分IP地址子段的标识,或者,所述返回响应消息指示所述从设备不具有所述主设备所需的IP地址子段。
该主设备用于执行前述主设备执行的方法实施例,其实现原理和技术 效果类似,在此不再赘述。
图13为本发明提供的从设备实施例一的结构示意图,该从设备为前述主从型网络中的从设备,如图13所示,该从设备包括:接收模块131和分配模块132,其中:
接收模块131,用于接收主设备发送的IP地址子段,将所述IP地址子段作为动态主机配置协议DHCP服务器地址,其中,所述IP地址子段中包括至少一个IP地址。
分配模块132,用于根据所述DHCP服务器地址向用户设备分配IP地址。
图14为本发明提供的从设备实施例二的结构示意图,如图14所示,在图13的基础上,该从设备还包括:第一发送模块141。
第一发送模块141,用于在接收模块131接收主设备发送的IP地址子段之前,向所述主设备发送IP地址子段请求消息,所述IP地址子段请求消息用于请求所述主设备为所述从设备分配N个IP地址子段,其中,N为正整数。
图15为本发明提供的从设备实施例三的结构示意图,如图15所示,在图13的基础上,该从设备还包括:第二发送模块151。
第二发送模块151,用于在接收模块131接收主设备发送的IP地址子段之前,向所述主设备发送特定IP地址子段请求消息,所述IP地址子段请求消息中携带所述从设备所需的特定IP地址子段的标识,用于请求所述主设备为所述从设备分配所述特定IP地址子段。
图16为本发明提供的从设备实施例四的结构示意图,如图16所示,在上述实施例的基础上,该从设备还可以包括:查询模块161和第三发送模块162,图16中也可以包括第一发送模块141或第二发送模块151。
接收模块131,还用于接收所述主设备发送的收回消息,所述收回消息用于请求所述从设备向所述主设备返回所述主设备所需的IP地址子段。
查询模块161,用于查询所述DHCP服务器地址中是否包含所述主设备所需的IP地址子段。
第三发送模块162,用于若所述DHCP服务器地址中包含所述主设备所需的全部或部分IP地址子段,则向所述主设备发送返回响应消息,所述返 回响应消息中携带所述DHCP服务器地址中包含的所述主设备所需的全部或部分IP地址子段的标识;或者,若所述DHCP服务器地址中不包含所述主设备所需的IP地址子段,则向所述主设备发送返回响应消息,所述返回响应消息指示所述主设备所述从设备不具有所述主设备所需的IP地址子段。
进一步地,在上述实施例的基础上,接收模块131,还用于接收用户设备发送的请求消息,所述请求消息用于请求所述从设备向所述用户设备分配IP地址。
图17为本发明提供的主设备实施例五的结构示意图,该主设备为前述主从型网络中的主设备,如图17所示,该主设备包括:处理器171和发送器172,其中:
处理器171,用于生成互联网协议IP地址子段组,所述IP地址子段组包含至少一个IP地址子段,每个所述IP地址子段包括至少一个IP地址。
发送器172,用于将所述IP地址子段组中的所述至少一个IP地址子段分别发送给所述至少一个从设备,以使所述至少一个从设备将接收到的所述IP地址子段作为动态主机配置协议DHCP服务器地址,并根据所述DHCP服务器地址为用户设备分配IP地址。
进一步地,参照图17,该主设备还包括:接收器173,用于在发送器172将所述IP地址子段组中的所述至少一个IP地址子段分别发送给所述至少一个从设备之前,接收所述从设备发送的IP地址子段请求消息,所述IP地址子段请求消息用于请求所述主设备为所述从设备分配N个IP地址子段,N为正整数。
若所述IP地址子段组中存在N个可分配的IP地址子段,则处理器171从所述可分配的IP地址子段中获取N个IP地址子段。若所述IP地址子段组中中不存在N个可分配的IP地址子段,则处理器171向所述主设备的管理区域中的其它从设备收回可分配的IP地址子段,直到所述IP地址子段组中存在N个可分配的IP地址子段,从所述可分配的IP地址子段中获取N个IP地址子段。具体地,收回过程中,处理器171可以通过发送器172发送请求,并通过接收器173接收响应等。
相应地,发送器172将获取到的N个可分配的IP地址子段发送给所述从设备。
另一种实施例中,接收器173,用于接收所述从设备发送的特定IP地址子段请求消息,所述IP地址子段请求消息中携带所述从设备所需的特定IP地址子段的标识,用于请求所述主设备为所述从设备分配所述特定IP地址子段。
若所述IP地址子段组中可分配的IP地址子段中存在所述特定IP地址子段,处理器171获取所述特定IP地址子段;若所述IP地址子段组中可分配的IP地址子段中不存在所述特定IP地址子段,则处理器171向所述主设备的管理区域中其它从设备收回所述特定IP地址子段,获取收回的所述特定IP地址子段。
具体实施例过程中,发送器172还用于向所述至少一个从设备发送收回消息,所述收回消息用于请求所述从设备向所述主设备返回所述主设备所需的IP地址子段。
接收器,用于接收所述从设备根据所述收回消息发送的返回响应消息,所述返回响应消息中携带所述从设备返回的所述主设备所需的全部或部分IP地址子段的标识,或者,所述返回响应消息指示所述从设备不具有所述主设备所需的IP地址子段。
上述主设备用于执行前述主设备对应的方法实施例,其实现原理和技术效果类似,在此不再赘述。
图18为本发明提供的从设备实施例五的结构示意图,该从设备为前述主从型网络中的从设备,如图18所示,该从设备包括:接收器181和处理器182。
接收器181,用于接收主设备发送的IP地址子段,将所述IP地址子段作为DHCP服务器地址,其中,所述IP地址子段中包括至少一个IP地址。
处理器182,用于根据所述DHCP服务器地址向用户设备分配IP地址。
进一步地,另一实施例中,参照图18,该从设备还可以包括:发送器183。
发送器183,用于在接收器181接收主设备发送的IP地址子段之前,向所述主设备发送IP地址子段请求消息,所述IP地址子段请求消息用于请求所述主设备为所述从设备分配N个IP地址子段,其中,N为正整数。
另一实施例中,发送器183用于在接收器181接收主设备发送的IP地 址子段之前,向所述主设备发送特定IP地址子段请求消息,所述IP地址子段请求消息中携带所述从设备所需的特定IP地址子段的标识,用于请求所述主设备为所述从设备分配所述特定IP地址子段。
相应地,接收器181具体用于接收所述主设备分配的所述特定IP地址子段,并将所述特定IP地址子段作为DHCP服务器地址。
进一步地,接收器181还用于接收所述主设备发送的收回消息,所述收回消息用于请求所述从设备向所述主设备返回所述主设备所需的IP地址子段。
处理器182用于查询所述DHCP服务器地址中是否包含所述主设备所需的IP地址子段。
发送器183用于若所述DHCP服务器地址中包含所述主设备所需的全部或部分IP地址子段,则向所述主设备发送返回响应消息,所述返回响应消息中携带所述DHCP服务器地址中包含的所述主设备所需的全部或部分IP地址子段的标识;或者,若所述DHCP服务器地址中不包含所述主设备所需的IP地址子段,则向所述主设备发送返回响应消息,所述返回响应消息指示所述主设备所述从设备不具有所述主设备所需的IP地址子段。
在上述实施例的基础上,接收器161还用于接收用户设备发送的请求消息,所述请求消息用于请求所述从设备向所述用户设备分配IP地址。
本领域普通技术人员可以理解:实现上述方法实施例的全部或部分步骤可以通过程序指令相关的硬件来完成,前述的程序可以存储于一计算机可读取存储介质中,该程序在执行时,执行包括上述方法实施例的步骤;而前述的存储介质包括:ROM、RAM、磁碟或者光盘等各种可以存储程序代码的介质。
最后应说明的是:以上各实施例仅用以说明本发明的技术方案,而非对其限制;尽管参照前述各实施例对本发明进行了详细的说明,本领域的普通技术人员应当理解:其依然可以对前述各实施例所记载的技术方案进行修改,或者对其中部分或者全部技术特征进行等同替换;而这些修改或者替换,并不使相应技术方案的本质脱离本发明各实施例技术方案的范围。

Claims (27)

  1. 一种主从型网络的IP地址分配方法,所述主从型网络包括一个主设备和所述主设备的管理区域中的至少一个从设备,其特征在于,该方法包括:
    所述主设备生成互联网协议IP地址子段组,所述IP地址子段组包含至少一个IP地址子段,每个所述IP地址子段包括至少一个IP地址;
    所述主设备将所述IP地址子段组中的所述至少一个IP地址子段分别发送给所述至少一个从设备,以使所述至少一个从设备将接收到的所述IP地址子段作为动态主机配置协议DHCP服务器地址,并根据所述DHCP服务器地址为用户设备分配IP地址。
  2. 根据权利要求1所述的方法,其特征在于,所述主设备将所述IP地址子段组中的所述至少一个IP地址子段分别发送给所述至少一个从设备之前,还包括:
    所述主设备接收所述从设备发送的IP地址子段请求消息,所述IP地址子段请求消息用于请求所述主设备为所述从设备分配N个IP地址子段,N为正整数;
    若所述IP地址子段组中存在N个可分配的IP地址子段,则所述主设备从所述可分配的IP地址子段中获取N个IP地址子段;
    若所述IP地址子段组中不存在N个可分配的IP地址子段,则所述主设备向所述主设备的管理区域中的其它从设备收回可分配的IP地址子段,直到所述IP地址子段组中存在N个可分配的IP地址子段,所述主设备从所述可分配的IP地址子段中获取N个IP地址子段。
  3. 根据权利要求1所述的方法,其特征在于,所述主设备将所述IP地址子段组中的所述至少一个IP地址子段分别发送给所述至少一个从设备之前,还包括:
    所述主设备接收所述从设备发送的特定IP地址子段请求消息,所述IP地址子段请求消息中携带所述从设备所需的特定IP地址子段的标识,用于请求所述主设备为所述从设备分配所述特定IP地址子段;
    若所述IP地址子段组中可分配的IP地址子段中存在所述特定IP地址子段,则所述主设备获取所述特定IP地址子段;
    若所述IP地址子段组中可分配的IP地址子段中不存在所述特定IP地址子段,则所述主设备向所述主设备的管理区域中其它从设备收回所述特定IP地址子段,所述主设备获取收回的所述特定IP地址子段。
  4. 根据权利要求2或3所述的方法,其特征在于,所述方法还包括:
    所述主设备向所述至少一个从设备发送收回消息,所述收回消息用于请求所述从设备向所述主设备返回所述主设备所需的IP地址子段;
    所述主设备接收所述从设备根据所述收回消息发送的返回响应消息,所述返回响应消息中携带所述从设备返回的所述主设备所需的全部或部分IP地址子段的标识,或者,所述返回响应消息指示所述从设备不具有所述主设备所需的IP地址子段。
  5. 一种主从型网络的IP地址分配方法,所述主从型网络包括一个主设备和所述主设备的管理区域中的至少一个从设备,其特征在于,所述方法包括:
    从设备接收主设备发送的IP地址子段,将所述IP地址子段作为动态主机配置协议DHCP服务器地址,其中,所述IP地址子段中包括至少一个IP地址;
    所述从设备根据所述DHCP服务器地址向用户设备分配IP地址。
  6. 根据权利要求5所述的方法,其特征在于,所述从设备接收主设备发送的IP地址子段之前,还包括:
    所述从设备向所述主设备发送IP地址子段请求消息,所述IP地址子段请求消息用于请求所述主设备为所述从设备分配N个IP地址子段,其中,N为正整数。
  7. 根据权利要求5所述的方法,其特征在于,所述从设备接收主设备发送的IP地址子段之前,还包括:
    所述从设备向所述主设备发送特定IP地址子段请求消息,所述IP地址子段请求消息中携带所述从设备所需的特定IP地址子段的标识,用于请求所述主设备为所述从设备分配所述特定IP地址子段。
  8. 根据权利要求6或7所述的方法,其特征在于,所述方法还包括:
    所述从设备接收所述主设备发送的收回消息,所述收回消息用于请求所述从设备向所述主设备返回所述主设备所需的IP地址子段;
    所述从设备查询所述DHCP服务器地址中是否包含所述主设备所需的IP地址子段;
    若所述DHCP服务器地址中包含所述主设备所需的全部或部分IP地址子段,则所述从设备向所述主设备发送返回响应消息,所述返回响应消息中携带所述DHCP服务器地址中包含的所述主设备所需的全部或部分IP地址子段的标识;或者,
    若所述DHCP服务器地址中不包含所述主设备所需的IP地址子段,则所述从设备向所述主设备发送返回响应消息,所述返回响应消息指示所述主设备所述从设备不具有所述主设备所需的IP地址子段。
  9. 根据权利要求5-8任一项所述的方法,其特征在于,所述方法还包括:
    所述从设备接收用户设备发送的请求消息,所述请求消息用于请求所述从设备向所述用户设备分配IP地址。
  10. 一种主设备,所述主设备属于主从型网络,所述主从型网络包括所述主设备和所述主设备的管理区域中的至少一个从设备,其特征在于,所述主设备包括:
    生成模块,用于生成互联网协议IP地址子段组,所述IP地址子段组包含至少一个IP地址子段,每个所述IP地址子段包括至少一个IP地址;
    发送模块,用于将所述IP地址子段组中的所述至少一个IP地址子段分别发送给所述至少一个从设备,以使所述至少一个从设备将接收到的所述IP地址子段作为动态主机配置协议DHCP服务器地址,并根据所述DHCP服务器地址为用户设备分配IP地址。
  11. 根据权利要求10所述的主设备,其特征在于,还包括:第一接收模块和第一获取模块;
    所述第一接收模块,用于在所述发送模块将所述IP地址子段组中的所述至少一个IP地址子段分别发送给所述至少一个从设备之前,接收所述从设备发送的IP地址子段请求消息,所述IP地址子段请求消息用于请求所述主设备为所述从设备分配N个IP地址子段,N为正整数;
    所述第一获取模块,用于若所述IP地址子段组中存在N个可分配的IP地址子段,则从所述可分配的IP地址子段中获取N个IP地址子段;或者,若所述IP地址子段组中不存在N个可分配的IP地址子段,则向所述 主设备的管理区域中的其它从设备收回可分配的IP地址子段,直到所述IP地址子段组中中存在N个可分配的IP地址子段,从所述可分配的IP地址子段中获取N个IP地址子段。
  12. 根据权利要求10所述的主设备,其特征在于,还包括:第二接收模块和第二获取模块;
    所述第二接收模块,用于在所述发送模块将所述IP地址子段组中的所述至少一个IP地址子段分别发送给所述至少一个从设备之前,接收所述从设备发送的特定IP地址子段请求消息,所述IP地址子段请求消息中携带所述从设备所需的特定IP地址子段的标识,用于请求所述主设备为所述从设备分配所述特定IP地址子段;
    所述第二获取模块,用于若所述IP地址子段组中可分配的IP地址子段中存在所述特定IP地址子段,则获取所述特定IP地址子段;或者,若所述IP地址子段组中可分配的IP地址子段中不存在所述特定IP地址子段,则向所述主设备的管理区域中其它从设备收回所述特定IP地址子段,获取收回的所述特定IP地址子段。
  13. 根据权利要求11或12所述的主设备,其特征在于,还包括:第三接收模块;
    所述发送模块,还用于向所述至少一个从设备发送收回消息,所述收回消息用于请求所述从设备向所述主设备返回所述主设备所需的IP地址子段;
    所述第三接收模块,用于接收所述从设备根据所述收回消息发送的返回响应消息,所述返回响应消息中携带所述从设备返回的所述主设备所需的全部或部分IP地址子段的标识,或者,所述返回响应消息指示所述从设备不具有所述主设备所需的IP地址子段。
  14. 一种从设备,所述从设备属于主从型网络,所述主从型网络包括一个主设备和所述主设备的管理区域中的至少一个从设备,其特征在于,所述从设备包括:
    接收模块,用于接收主设备发送的IP地址子段,将所述IP地址子段作为动态主机配置协议DHCP服务器地址,其中,所述IP地址子段中包括至少一个IP地址;
    分配模块,用于根据所述DHCP服务器地址向用户设备分配IP地址。
  15. 根据权利要求14所述的从设备,其特征在于,还包括:第一发送模块;
    所述第一发送模块,用于在所述接收模块接收主设备发送的IP地址子段之前,向所述主设备发送IP地址子段请求消息,所述IP地址子段请求消息用于请求所述主设备为所述从设备分配N个IP地址子段,其中,N为正整数。
  16. 根据权利要求14所述的从设备,其特征在于,还包括:第二发送模块;
    所述第二发送模块,用于在所述接收模块接收主设备发送的IP地址子段之前,向所述主设备发送特定IP地址子段请求消息,所述IP地址子段请求消息中携带所述从设备所需的特定IP地址子段的标识,用于请求所述主设备为所述从设备分配所述特定IP地址子段。
  17. 根据权利要求15或16所述的从设备,其特征在于,还包括:查询模块和第三发送模块;
    所述接收模块,还用于接收所述主设备发送的收回消息,所述收回消息用于请求所述从设备向所述主设备返回所述主设备所需的IP地址子段;
    所述查询模块,用于查询所述DHCP服务器地址中是否包含所述主设备所需的IP地址子段;
    所述第三发送模块,用于若所述DHCP服务器地址中包含所述主设备所需的全部或部分IP地址子段,则向所述主设备发送返回响应消息,所述返回响应消息中携带所述DHCP服务器地址中包含的所述主设备所需的全部或部分IP地址子段的标识;或者,若所述DHCP服务器地址中不包含所述主设备所需的IP地址子段,则向所述主设备发送返回响应消息,所述返回响应消息指示所述主设备所述从设备不具有所述主设备所需的IP地址子段。
  18. 根据权利要求14-17任一项所述的从设备,其特征在于,所述接收模块,还用于接收用户设备发送的请求消息,所述请求消息用于请求所述从设备向所述用户设备分配IP地址。
  19. 一种主设备,所述主设备属于主从型网络,所述主从型网络包括所述主设备和所述主设备的管理区域中的至少一个从设备,其特征在于,所述主设备包括:
    处理器,用于生成互联网协议IP地址子段组,所述IP地址子段组包含至少一个IP地址子段,每个所述IP地址子段包括至少一个IP地址;
    发送器,用于将所述IP地址子段组中的所述至少一个IP地址子段分别发送给所述至少一个从设备,以使所述至少一个从设备将接收到的所述IP地址子段作为动态主机配置协议DHCP服务器地址,并根据所述DHCP服务器地址为用户设备分配IP地址。
  20. 根据权利要求19所述的主设备,其特征在于,还包括:接收器,用于在所述发送器将所述IP地址子段组中的所述至少一个IP地址子段分别发送给所述至少一个从设备之前,接收所述从设备发送的IP地址子段请求消息,所述IP地址子段请求消息用于请求所述主设备为所述从设备分配N个IP地址子段,N为正整数;
    所述处理器,用于若所述IP地址子段组中存在N个可分配的IP地址子段,则从所述可分配的IP地址子段中获取N个IP地址子段;或者,若所述IP地址子段组中不存在N个可分配的IP地址子段,则向所述主设备的管理区域中的其它从设备收回可分配的IP地址子段,直到所述IP地址子段组中存在N个可分配的IP地址子段,所述主设备从所述可分配的IP地址子段中获取N个IP地址子段。
  21. 根据权利要求19所述的主设备,其特征在于,还包括:接收器,用于在所述发送器将所述IP地址子段组中的所述至少一个IP地址子段分别发送给所述至少一个从设备之前,接收所述从设备发送的特定IP地址子段请求消息,所述IP地址子段请求消息中携带所述从设备所需的特定IP地址子段的标识,用于请求所述主设备为所述从设备分配所述特定IP地址子段;
    所述处理器,用于若所述IP地址子段组中可分配的IP地址子段中存在所述特定IP地址子段,则获取所述特定IP地址子段;或者,若所述IP地址子段组中可分配的IP地址子段中不存在所述特定IP地址子段,则向所述主设备的管理区域中其它从设备收回所述特定IP地址子段,所述主设备获取收回的所述特定IP地址子段。
  22. 根据权利要求20或21所述的主设备,其特征在于,所述发送器,还用于向所述至少一个从设备发送收回消息,所述收回消息用于请求所述从 设备向所述主设备返回所述主设备所需的IP地址子段;
    所述接收器,还用于接收所述从设备根据所述收回消息发送的返回响应消息,所述返回响应消息中携带所述从设备返回的所述主设备所需的全部或部分IP地址子段的标识,或者,所述返回响应消息指示所述从设备不具有所述主设备所需的IP地址子段。
  23. 一种从设备,所述从设备属于主从型网络,所述主从型网络包括一个主设备和所述主设备的管理区域中的至少一个从设备,其特征在于,所述从设备包括:
    接收器,用于接收主设备发送的IP地址子段,将所述IP地址子段作为动态主机配置协议DHCP服务器地址,其中,所述IP地址子段中包括至少一个IP地址;
    处理器,用于根据所述DHCP服务器地址向用户设备分配IP地址。
  24. 根据权利要求23所述的从设备,其特征在于,还包括:发送器,用于在所述接收器接收主设备发送的IP地址子段之前,向所述主设备发送IP地址子段请求消息,所述IP地址子段请求消息用于请求所述主设备为所述从设备分配N个IP地址子段,其中,N为正整数。
  25. 根据权利要求23所述的从设备,其特征在于,还包括:发送器,在所述接收器接收主设备发送的IP地址子段之前,向所述主设备发送特定IP地址子段请求消息,所述IP地址子段请求消息中携带所述从设备所需的特定IP地址子段的标识,用于请求所述主设备为所述从设备分配所述特定IP地址子段。
  26. 根据权利要求24或25所述的从设备,其特征在于,所述接收器,还用于接收所述主设备发送的收回消息,所述收回消息用于请求所述从设备向所述主设备返回所述主设备所需的IP地址子段;
    所述处理器,还用于查询所述DHCP服务器地址中是否包含所述主设备所需的IP地址子段;
    所述发送器,还用于若所述DHCP服务器地址中包含所述主设备所需的全部或部分IP地址子段,则向所述主设备发送返回响应消息,所述返回响应消息中携带所述DHCP服务器地址中包含的所述主设备所需的全部或部分IP地址子段的标识;或者,若所述DHCP服务器地址中不包含所述主设 备所需的IP地址子段,则向所述主设备发送返回响应消息,所述返回响应消息指示所述主设备所述从设备不具有所述主设备所需的IP地址子段。
  27. 根据权利要求23-26任一项所述的从设备,其特征在于,所述接收器,还用于接收用户设备发送的请求消息,所述请求消息用于请求所述从设备向所述用户设备分配IP地址。
PCT/CN2015/091125 2015-09-29 2015-09-29 主从型网络的ip地址分配方法、装置及系统 WO2017054140A1 (zh)

Priority Applications (5)

Application Number Priority Date Filing Date Title
CN201580082540.1A CN107925684B (zh) 2015-09-29 2015-09-29 主从型网络的ip地址分配方法、装置及系统
US15/764,270 US10757069B2 (en) 2015-09-29 2015-09-29 IP address allocation method for master-slave network, apparatus, and system
PCT/CN2015/091125 WO2017054140A1 (zh) 2015-09-29 2015-09-29 主从型网络的ip地址分配方法、装置及系统
JP2018535215A JP6574906B2 (ja) 2015-09-29 2015-09-29 マスター・スレーブ・ネットワークのためのipアドレス割り当て方法、装置、およびシステム
EP15905052.5A EP3349420B1 (en) 2015-09-29 2015-09-29 Ip address allocation method, apparatus and system for master-slave type network

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/CN2015/091125 WO2017054140A1 (zh) 2015-09-29 2015-09-29 主从型网络的ip地址分配方法、装置及系统

Publications (1)

Publication Number Publication Date
WO2017054140A1 true WO2017054140A1 (zh) 2017-04-06

Family

ID=58422521

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2015/091125 WO2017054140A1 (zh) 2015-09-29 2015-09-29 主从型网络的ip地址分配方法、装置及系统

Country Status (5)

Country Link
US (1) US10757069B2 (zh)
EP (1) EP3349420B1 (zh)
JP (1) JP6574906B2 (zh)
CN (1) CN107925684B (zh)
WO (1) WO2017054140A1 (zh)

Families Citing this family (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
FR3072238B1 (fr) * 2017-10-10 2019-09-27 Commissariat A L'energie Atomique Et Aux Energies Alternatives Dispositif et procede de transmission de donnees
CN111147619B (zh) * 2019-12-20 2022-07-19 海丰通航科技有限公司 本地实现rs485从机设备自动分配地址的方法和系统
CN114513491B (zh) * 2020-10-28 2023-04-11 华为技术有限公司 获取地址的方法、装置及系统
CN114301731B (zh) * 2021-12-31 2023-12-22 德力西电气有限公司 地址管理方法、主设备及从设备
CN116485702A (zh) 2022-01-17 2023-07-25 株式会社理光 图像处理方法、装置以及存储介质

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102098354A (zh) * 2011-02-28 2011-06-15 北京星网锐捷网络技术有限公司 动态主机配置协议地址分配方法及服务器
WO2014094937A1 (fr) * 2012-12-21 2014-06-26 Cassidian Sas Procede de fusion de deux sous-reseaux en un unique reseau ad hoc implementant le protocole d2hcp
CN104160655A (zh) * 2011-02-23 2014-11-19 泰科消防及安全有限公司 用于网络上的主/从设备的自动配置的系统和方法
CN104243632A (zh) * 2014-10-13 2014-12-24 三星电子(中国)研发中心 使非ip设备接入虚拟ip网络的方法和系统

Family Cites Families (27)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7051089B1 (en) * 2001-10-24 2006-05-23 Cisco Technology, Inc. Techniques for automatically delegating address spaces among dynamic host configuration servers
JP2005210554A (ja) 2004-01-26 2005-08-04 Fujitsu Access Ltd Dhcp代理サーバ
US8451833B2 (en) * 2004-05-14 2013-05-28 Motorola Mobility Llc System and method for transparent virtual routing
US20070002833A1 (en) 2005-06-30 2007-01-04 Symbol Technologies, Inc. Method, system and apparatus for assigning and managing IP addresses for wireless clients in wireless local area networks (WLANs)
JP4974287B2 (ja) 2007-06-29 2012-07-11 Kddi株式会社 Dhcpサーバのアドレス割当容量を制御する割当容量制御サーバ及びプログラム
FI20080345A0 (fi) * 2008-05-09 2008-05-09 Joikusoft Oy Ltd Symbian S60 puhelin 3G kaistanyhdistäjänä
US8190697B2 (en) * 2009-05-20 2012-05-29 Square D Company Automated configuration of device communication settings
CN102231725B (zh) 2010-03-25 2014-09-10 北京星网锐捷网络技术有限公司 一种动态主机配置协议报文的认证方法、设备及系统
US8458303B2 (en) * 2010-07-12 2013-06-04 Cisco Technology, Inc. Utilizing a gateway for the assignment of internet protocol addresses to client devices in a shared subset
CN102025798B (zh) * 2010-12-15 2013-12-04 华为技术有限公司 地址分配处理方法、装置和系统
CN106850444B (zh) * 2011-08-17 2020-10-27 Nicira股份有限公司 逻辑l3路由
US9055121B2 (en) * 2011-10-08 2015-06-09 Broadcom Corporation Social processing member offering fixed and intelligent services
CN102594933B (zh) 2011-12-20 2015-04-08 华为技术有限公司 一种公网地址分配的方法、装置及系统
CN103297254B (zh) * 2012-02-23 2017-06-20 华为技术有限公司 管理地址资源的方法及网关设备
US8856296B2 (en) * 2012-06-28 2014-10-07 Alcatel Lucent Subnet prioritization for IP address allocation from a DHCP server
CN104158917B (zh) 2013-05-14 2017-12-15 新华三技术有限公司 回收动态主机配置协议客户端的ip地址的方法及设备
US9537818B2 (en) * 2013-05-15 2017-01-03 Mediatek Inc. Enhanced DHCP method
WO2015021629A1 (zh) 2013-08-15 2015-02-19 华为技术有限公司 一种资源发放方法
TWI548246B (zh) 2013-12-02 2016-09-01 緯創資通股份有限公司 叢集伺服器部署方法以及使用該方法的裝置
JP2014143697A (ja) 2014-02-27 2014-08-07 Huawei Technologies Co Ltd スケーラブルwlanゲートウェイ
US20150281947A1 (en) * 2014-03-26 2015-10-01 Qualcomm Incorporated Method and apparatus for fast ip address assignment
US9398629B2 (en) * 2014-06-13 2016-07-19 Alcatel Lucent System and method for a distributed wireless network
CN104092790B (zh) 2014-07-02 2017-09-29 京信通信系统(中国)有限公司 基站主从站通信方法和系统
CA2962020A1 (en) * 2014-09-30 2016-04-07 Sercel Method for dynamically configuring a network comprising a plurality of subnets
WO2016148676A1 (en) * 2015-03-13 2016-09-22 Hewlett Packard Enterprise Development Lp Determine anomalous behavior based on dynamic device configuration address range
US9769115B2 (en) * 2015-04-24 2017-09-19 Fortinet, Inc. DHCP agent assisted routing and access control
US10713062B2 (en) * 2017-12-07 2020-07-14 Dell Products, L.P. System and method for configuring an information handling system

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104160655A (zh) * 2011-02-23 2014-11-19 泰科消防及安全有限公司 用于网络上的主/从设备的自动配置的系统和方法
CN102098354A (zh) * 2011-02-28 2011-06-15 北京星网锐捷网络技术有限公司 动态主机配置协议地址分配方法及服务器
WO2014094937A1 (fr) * 2012-12-21 2014-06-26 Cassidian Sas Procede de fusion de deux sous-reseaux en un unique reseau ad hoc implementant le protocole d2hcp
CN104243632A (zh) * 2014-10-13 2014-12-24 三星电子(中国)研发中心 使非ip设备接入虚拟ip网络的方法和系统

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
See also references of EP3349420A4 *

Also Published As

Publication number Publication date
US10757069B2 (en) 2020-08-25
EP3349420B1 (en) 2022-02-23
JP2018531563A (ja) 2018-10-25
CN107925684A (zh) 2018-04-17
EP3349420A1 (en) 2018-07-18
CN107925684B (zh) 2021-02-09
US20180287993A1 (en) 2018-10-04
EP3349420A4 (en) 2018-08-29
JP6574906B2 (ja) 2019-09-11

Similar Documents

Publication Publication Date Title
WO2017054140A1 (zh) 主从型网络的ip地址分配方法、装置及系统
US20170195282A1 (en) Address Processing Method, Related Device, and System
EP3361387B1 (en) Data transmission method, equipment and system
EP3905054B1 (en) File management method, distributed storage system, and management node
EP3592033A1 (en) Communication method and device
JP2013514588A5 (zh)
JP2018531563A6 (ja) マスター・スレーブ・ネットワークのためのipアドレス割り当て方法、装置、およびシステム
WO2011116715A2 (zh) 一种虚拟网络迁移方法、相关装置以及系统
WO2016184317A1 (zh) 一种对ap进行配置的方法、装置和系统
CN104506654B (zh) 云计算系统及动态主机配置协议服务器备份方法
CN105245629A (zh) 基于dhcp的主机通信方法及装置
US20210092090A1 (en) Domain name resolution method and apparatus based on a plurality of availability zones az
US20160234311A1 (en) Memory access method, device, and system
RU2016137564A (ru) Способ, устройство и система обработки передаваемых данных
JP6338257B2 (ja) ネットワーク要素データアクセス方法および装置、およびネットワーク管理システム
JP6291628B2 (ja) 端局装置及び帯域割当方法
WO2016187783A1 (zh) 一种数据传输方法及装置
KR20170005274A (ko) 사용자 정의 클라우드 서비스 제공을 위한 자원 서비스 중개 제공장치 및 그 방법
CN104486215A (zh) 一种消息发送方法及设备
KR20070061420A (ko) 서비스 플로우 식별자를 분산 관리하는 무선 통신 시스템및 그 시스템에서의 서비스 플로우 식별자 관리 방법
WO2018033113A1 (zh) 一种信息传输的方法、设备和系统
JP2018503928A (ja) ネットワーク・ファイル・システムにおいてi/o要求を処理するための方法及び装置
WO2018188447A1 (zh) 一种ip地址配置方法及装置
JP7380878B2 (ja) アドレス設定システム、アドレス設定方法、アドレス設定管理装置及びプログラム
KR101374475B1 (ko) 인터넷 접속 서비스의 끊김 없는 제공을 위한 이동네트워크의 동적 분할/병합 방법

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 15905052

Country of ref document: EP

Kind code of ref document: A1

WWE Wipo information: entry into national phase

Ref document number: 15764270

Country of ref document: US

Ref document number: 2018535215

Country of ref document: JP

NENP Non-entry into the national phase

Ref country code: DE

WWE Wipo information: entry into national phase

Ref document number: 2015905052

Country of ref document: EP