CN106453690A - IP address allocation method and apparatus - Google Patents

IP address allocation method and apparatus Download PDF

Info

Publication number
CN106453690A
CN106453690A CN201611057807.4A CN201611057807A CN106453690A CN 106453690 A CN106453690 A CN 106453690A CN 201611057807 A CN201611057807 A CN 201611057807A CN 106453690 A CN106453690 A CN 106453690A
Authority
CN
China
Prior art keywords
unp
address
client
mask
request
Prior art date
Legal status (The legal status 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 status listed.)
Pending
Application number
CN201611057807.4A
Other languages
Chinese (zh)
Inventor
周迪
王连朝
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Zhejiang Uniview Technologies Co Ltd
Original Assignee
Zhejiang Uniview Technologies Co Ltd
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 Zhejiang Uniview Technologies Co Ltd filed Critical Zhejiang Uniview Technologies Co Ltd
Priority to CN201611057807.4A priority Critical patent/CN106453690A/en
Publication of CN106453690A publication Critical patent/CN106453690A/en
Pending legal-status Critical Current

Links

Classifications

    • 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/5046Resolving address allocation conflicts; Testing of addresses
    • 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

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)
  • Small-Scale Networks (AREA)

Abstract

The invention provides an IP address allocation method and apparatus. The method comprises the following steps: receiving an address application request sent by a UNP client, wherein the address application request carries an MAC address of an access device connected with the UNP client; determining a sub address pool corresponding to the UNP client; selecting an idle IP address from the corresponding sub address pool to serve as a destination address; and sending the destination address to the UNP client, so that the UNP client allocates the destination address to the access device according to the MAC address. By adoption of the method, the IP addresses of the access devices in a private network can be uniformly planned and managed, and meanwhile the network communication between a public network and the private network is realized.

Description

IP address distribution method and device
Technical field
The application is related to network communication technology field, more particularly to a kind of IP address distribution method and device.
Background technology
With the development of Video Supervision Technique, it is all that Video Supervision Technique is widely used in social security, education, national defence etc. Multi-field.In each field, the networking of video monitoring is also increasingly sophisticated, by respectively connecing in the management apparatus access private network in public network Entering the video resource on equipment has become the conventional means of video monitoring.In order to realize the network service between public network and private network, lead to NAT (Network Address Translation, network address translation) technology is often used, by the private network IP ground of access device Location is converted to public network IP address.
However, private network IP address arbitrarily can be converted to public affairs by the networking complexity of video monitoring, each private network application NAT technology Net IP address, it is more likely that cause overlap and the conflict of IP address, also, the IP address being unfavorable for access device in each private network Carry out unified planning management.
Content of the invention
In view of this, the application provides a kind of IP address distribution method and device, to realize to access device in private network IP address carries out unified planning management, meanwhile, realize the network service between public network and private network.
Specifically, the application is achieved by the following technical solution:
According to the embodiment of the present application in a first aspect, a kind of IP address distribution method is provided, video monitoring system is applied to In UNP service end, the UNP service end is configured with DHCP service, includes dhcp address pool in the UNP service end, described Dhcp address pool is divided at least two subaddressing ponds;Also include at least one UNP client in the video monitoring system, The UNP client is arranged in heterogeneous networks with the UNP service end, and the UNP client and the UNP service end it Between set up have UNP connect;The UNP client is connected with least one access device, and the UNP client is connected to be connect Enter equipment to be arranged in consolidated network;Methods described includes:
The application IP addresses request of UNP client transmission is received, in the application IP addresses request, carries UNP visitor The MAC Address of the access device connected by family end;
Determine the corresponding subaddressing pond of the UNP client;
Free IP addresses are selected in the corresponding subaddressing pond as destination address;
The destination address is sent to the UNP client, so that the destination address is distributed to by the UNP client The corresponding access device of the MAC Address.
Optionally, methods described also includes:
Detecting mask and request being updated, the mask updates request and itself updated for representing the UNP client request The mask-length of IP address;
Request being updated according to the mask, mask being sent to the UNP client and update response message, the mask updates The mask-length of IP address in the dhcp address pool is carried in response message, so that the UNP client is according to the mask Update the mask-length that the mask-length of own IP address is updated to response message IP address in the dhcp address pool.
Optionally, methods described also includes:
If there are no free IP addresses in the corresponding subaddressing pond, a free time is selected in other subaddressing ponds IP address is used as the destination address.
According to the second aspect of the embodiment of the present application, another kind of IP address distribution method is provided, is applied to video monitoring system UNP client in system, the UNP client is connected with least one access device, and the UNP client is connected to be connect Enter equipment to be arranged in consolidated network;Also include UNP service end in the video monitoring system, include in the UNP service end Dhcp address pool, the UNP client is arranged in heterogeneous networks with the UNP service end, and the UNP client with described Setting up between UNP service end has UNP to connect;Methods described includes:
The application IP addresses request of access device transmission is received, and described access is carried in the application IP addresses request and is set Standby MAC Address;
Application IP addresses request is sent to the UNP service end, so that the UNP service end is according to the address Shen Please ask to determine a destination address, and the destination address is sent to the UNP client;
Receive the destination address of UNP service end transmission;
The destination address is distributed to the corresponding access device of the MAC Address.
Optionally, methods described also includes:
The corresponding relation that sets up between the destination address and the MAC Address so that the UNP server is connect with described Enter equipment to be communicated according to the corresponding relation.
Optionally, methods described also includes:
Often primary address application request being sent to the UNP service end, default statistic is added 1, the statistical number The initial value of value is 0;
When the statistic reaches predetermined threshold value, mask is sent to the UNP service end and update request, the mask Updating request the mask-length of own IP address is updated for representing the UNP client request;
Receive the UNP service end and request is updated according to the mask, update to the mask that the UNP client sends Response message, the mask updates the mask-length for carrying IP address in the dhcp address pool in response message;
Update response message according to the mask mask-length of own IP address is updated in the dhcp address pool The mask-length of IP address.
According to the third aspect of the embodiment of the present application, a kind of IP address distributor is provided, is applied to video monitoring system In UNP service end, the UNP service end is configured with DHCP service, includes dhcp address pool in the UNP service end, described Dhcp address pool is divided at least two subaddressing ponds;Also include at least one UNP client in the video monitoring system, The UNP client is arranged in heterogeneous networks with the UNP service end, and the UNP client and the UNP service end it Between set up have UNP connect;The UNP client is connected with least one access device, and the UNP client is connected to be connect Enter equipment to be arranged in consolidated network;Described device includes:
First receiver module, for receiving the application IP addresses request of UNP client transmission, the application IP addresses please Seek the middle MAC Address for carrying the access device connected by the UNP client;
Determining module, for determining the corresponding subaddressing pond of the UNP client;
Selecting module, for selecting free IP addresses as destination address in the corresponding subaddressing pond;
Address sending module, for sending the destination address to the UNP client, so that the UNP client will The destination address distributes to the corresponding access device of the MAC Address.
Optionally, described device also includes:
Detection module, updates request for detecting mask, and the mask updates request for representing the UNP client Request updates the mask-length of own IP address;
Message transmission module, for updating request according to the mask, sends mask to the UNP client and updates response Message, the mask updates the mask-length for carrying IP address in the dhcp address pool in response message, so that the UNP is objective Family end updates response message according to the mask and the mask-length of own IP address is updated to IP ground in the dhcp address pool The mask-length of location.
Optionally, the selecting module is additionally operable to:
If there are no free IP addresses in the corresponding subaddressing pond, a free time is selected in other subaddressing ponds IP address is used as the destination address.
According to the fourth aspect of the embodiment of the present application, a kind of IP address distributor is provided, is applied to video monitoring system In UNP client, the UNP client is connected with least one access device, the connected access of the UNP client Equipment is arranged in consolidated network;Also include UNP service end in the video monitoring system, include in the UNP service end Dhcp address pool, the UNP client is arranged in heterogeneous networks with the UNP service end, and the UNP client with described Setting up between UNP service end has UNP to connect;Described device includes:
Second receiver module, for receiving the application IP addresses request of access device transmission, the application IP addresses please Seek the middle MAC Address for carrying the access device;
Address requests sending module, for sending application IP addresses request to the UNP service end, so that described UNP service end asks to determine a destination address according to the application IP addresses, and the destination address is sent to UNP visitor Family end;
3rd receiver module, for receiving the destination address of UNP service end transmission;
Distribute module, for distributing to the corresponding access device of the MAC Address by the destination address.
Optionally, described device also includes:
Relation sets up module, for the corresponding relation that sets up between the destination address and the MAC Address so that described UNP server is communicated according to the corresponding relation with the access device.
Optionally, described device also includes:
Statistical module, for often sending primary address application request to the UNP service end, default statistic is added 1, the initial value of the statistic is 0;
Request sending module is updated, for when the statistic reaches predetermined threshold value, sending to the UNP service end Mask updates request, and the mask renewal request is long for the mask for representing UNP client request renewal own IP address Degree;
Message reception module, updates request for receiving the UNP service end according to the mask, to UNP visitor The mask that family end sends updates response message, and the mask updates in response message and carries IP address in the dhcp address pool Mask-length;
The mask-length of own IP address is updated to by mask update module for updating response message according to the mask The mask-length of IP address in the dhcp address pool.
In the present embodiment, by, after the application IP addresses request for receiving the transmission of UNP client, determining the UNP client Hold corresponding subaddressing pond;From the corresponding subaddressing pond, preferentially select free IP addresses to send to UNP client, with So that the free IP addresses are distributed to its access device for being connected by UNP client.As UNP service end is same for being connected to The IP address that access device in UNP client distributes in same subaddressing pond, so as to, it is achieved that UNP service end is to accessing The IP address of equipment is managed collectively, meanwhile, the IP of the access device connected by different UNP clients can be effectively prevented from Address overlap or the problem of conflict.
Description of the drawings
Fig. 1 illustrates the application scenarios schematic diagram that the application realizes IP address distribution method;
Fig. 2 illustrates one embodiment flow chart of the application IP address distribution method;
Fig. 3 illustrates another embodiment flow chart of the application IP address distribution method;
Fig. 4 illustrates one embodiment block diagram of the application IP address distributor;
Fig. 5 illustrates another embodiment block diagram of the application IP address distributor.
Specific embodiment
Here in detail exemplary embodiment will be illustrated, its example is illustrated in the accompanying drawings.Explained below is related to During accompanying drawing, unless otherwise indicated, the same numbers in different accompanying drawings represent same or analogous key element.Following exemplary embodiment Described in embodiment do not represent all embodiments consistent with the application.Conversely, they be only with as appended by The example of consistent apparatus and method in terms of some that described in detail in claims, the application.
It is the purpose only merely for description specific embodiment in term used in this application, and is not intended to be limiting the application. " one kind ", " described " and " being somebody's turn to do " of singulative used in the application and appended claims is also intended to include majority Form, unless context clearly shows that other implications.It is also understood that term "and/or" used herein is referred to and is wrapped Containing one or more associated any or all possible combination for listing project.
It will be appreciated that though term first, second, third, etc. may be adopted in the application describe various information, but this A little information should not necessarily be limited by these terms.These terms are only used for same type of information is distinguished from each other out.For example, without departing from In the case of the application scope, the first information can also be referred to as the second information, and similarly, the second information can also be referred to as One information.Depending on linguistic context, word as used in this " if " can be construed to " ... when " or " when ... When " or " in response to determining ".
Fig. 1 is referred to, the application scenarios schematic diagram that the application realizes IP address distribution method is illustrated, wrap in Fig. 1 Include UNP (Universal Network Passport, omnipotent network passport) service end 11, UNP client 12, and UNP visitor Family end 13, wherein, UNP client 12 can also be connected at least one access device, for example, UNP with UNP client 13 Client 12 is connected with access device 121, access device 122, UNP client 13 and is connected with access device 131, access device 132.In FIG, UNP service end is located in heterogeneous networks with UNP client, the access device is connected with which by UNP client In consolidated network.
In this application, DHCP (Dynamic Host Configuration is configured with UNP service end 11 Protocol, DHCP) service, and dhcp address pool is preset with, the dhcp address pool can also be advance At least two subaddressing ponds are divided into, for example, the IP address of UNP service end 11 is 192.168.1.1, its default dhcp address IP address in pond includes 192.168.10.0/28~192.168.10.15/28.In FIG, UNP service end 11 is connected with two Individual UNP client, then can be divided into two sub- address pool by the dhcp address pool in UNP service end 11, one of son ground IP address in the pond of location includes 192.168.10.0/29~192.168.10.7/29, the IP address bag in another subaddressing pond Include 192.168.10.8/29~192.168.10.15/29.
It should be noted that the UNP service end 11 shown in Fig. 1 to be connected with two UNP clients merely exemplary, In actual applications, UNP service end 11 can be connected with more than two UNP client, and the application is not restricted to this.And And, in order to realize subsequently carrying out unified planning management to the IP address of the access device connected by each UNP client, UNP takes Business end 11 can determine the quantity in subaddressing pond according to the quantity of the UNP client connected by which.
UNP client, such as UNP client 12 can carry out dial-up connection to UNP service end 11, to ask UNP to service UNP interface IP address is distributed for which in end 11, it is assumed that UNP service end 11 is 192.168.1.2 for its UNP interface IP address for distributing, should IP address 192.168.1.1 of IP address and UNP service end 11 in same address field, so as to, UNP client 12 and UNP UNP connection being set up between service end 11, being connected by UNP, UNP client 12 can be communicated with UNP service end 11.
In this application, set up between UNP client and UNP service end after UNP is connected, can also service in UNP The corresponding relation of UNP client and subaddressing pond is set on end, for example, as shown in table 1 below, UNP client is illustrated with son ground The corresponding relation in location pond:
Table 1
UNP client host is identified Subaddressing pond
UNP client 12 192.168.10.0/29~192.168.10.7/29
UNP client 13 192.168.10.8/29~192.168.10.15/29
In table 1 above, the corresponding relation with UNP client host mark with subaddressing pond represents UNP client and son The corresponding relation of address pool.
Set up between UNP client 12 and UNP service end 11 after UNP is connected, UNP client 12 can open DHCP Relay services, and application IP addresses request message is sent to UNP service end 11, the destination address in the application IP addresses request message is For the IP address of UNP service end 11, for example, 192.168.1.1.
After UNP service end 11 receives the application IP addresses request message, can according to the UNP client exemplified by table 1 with The corresponding relation in subaddressing pond, the host identification according to UNP client 12 determines the corresponding subaddressing pond of UNP client 12, from An IP address is selected in the corresponding subaddressing pond, and such as 192.168.10.1/29 distributes to UNP client 12.
Subsequently, UNP client 12 is connected access device 121, access device 122 can pass through UNP client 12 to The request distribution IP address of UNP service end 11.It should be noted that having the free time in the corresponding subaddressing pond of UNP client 12 In the case of IP address, the free IP addresses in subaddressing pond corresponding to 11 prioritizing selection UNP client 12 of UNP service end divide The access device connected by dispensing UNP client 12.
Seen from the above description, it is generally the case that UNP service end 11 is set for the access being connected in same UNP client Back-up joins the IP address in same subaddressing pond, so as to, it is achieved that UNP service end is unified to the IP address of access device Management, meanwhile, the IP address overlap of the access device connected by different UNP clients or asking for conflict can be effectively prevented from Topic.
In order to describe the IP address distribution method of the application offer in detail, in the application, from UNP service end and UNP visitor Two, family end angle is described respectively.
As follows, the angle first from UNP service end is described:
Fig. 2 is referred to, illustrates one embodiment flow chart of the application IP address distribution method, flow process shown in the Fig. 2 On the basis of flow process shown in above-mentioned Fig. 1, by shown in Fig. 1 UNP service end 11 execute the method as a example by, can include with Lower step:
Step S201:The application IP addresses request of UNP client transmission is received, in application IP addresses request, carries UNP client The MAC Address of the connected access device in end.
In this application, so that access device 121 asks access network as an example, access device 121 can be connected to which UNP client 12 sends application IP addresses request, and carries the MAC Address of access device 121 in the application IP addresses request.
After UNP client 12 receives the application IP addresses request, directly the application IP addresses request can be sent to UNP and take Business end 11, it is also possible to after being packaged processing to the application IP addresses request, retransmit to UNP service end 11, to this in the application It is not restricted.
Subsequently, UNP service end 11 can receive the application IP addresses request of the transmission of UNP client 12.
Step S202:Determine the corresponding subaddressing pond of UNP client.
In this application, after UNP service end 11 receives the application IP addresses request of UNP client transmission, UNP service end 11 can be according to the host identification of the UNP client, and for example, " UNP client 12 " inquires about above-mentioned table 1, such that it is able to find The corresponding subaddressing pond of the UNP client is " 192.168.10.0/29~192.168.10.7/29 "
Step S203:Free IP addresses are selected in corresponding subaddressing pond as destination address.
Seen from the above description, in subaddressing pond, the quantity of IP address is limited, and wherein, each IP address is being distributed to Access device, and in the case of lease is not yet due, the IP address does not allow to be reallocated to other access devices.In this application, it is Description is convenient, unassigned IP address in subaddressing pond can be referred to as free IP addresses.
In this step, UNP service end 11 can select one in corresponding subaddressing pond determined by step S202 Individual free IP addresses, for example, select 192.168.10.2/29, using the free IP addresses as destination address.Specifically how from Select free IP addresses as destination address at least one free IP addresses, the application is not restricted.
Additionally, in this application, if UNP service end 11 does not find sky in the subaddressing pond corresponding to UNP client 12 Not busy IP address, then it is considered that current no assignable IP address in the corresponding subaddressing pond, now, UNP service end 11 Free IP addresses can be selected from other subaddressing ponds, for example, selects 192.168.10.9/29, by the idle IP ground Location is used as destination address.
Step S204:Destination address is sent to UNP client, so that destination address is distributed to MAC Address by UNP client Corresponding access device.
In this application, after UNP service end 11 determines destination address, the destination address can be sent to UNP client 12, so that the destination address can be distributed to access device 121 by UNP client 12.
Additionally, in this application, UNP service end 11 can also detect the mask of the transmission of UNP client 12 and update request, Concrete UNP client 12 is how to send mask to UNP service end 11 to update request, may refer to retouching in following embodiments State, here is not first described further.
It should be noted that when UNP service end 11 detects the mask renewal request of the transmission of UNP client 12, UNP client Hold in 12 corresponding subaddressing ponds and there are no free IP addresses.As described above, working as in the corresponding subaddressing pond of UNP client 12 When there are no free IP addresses, UNP service end 11 can determine free IP addresses as target from other subaddressing ponds Address, it is assumed that for 192.168.10.9/29.And now, the IP address of UNP client 12 is 192.168.10.1/29, this two Address is not belonging to same address field, cannot pass through UNP client 12 so as to UNP service end 11, be led to access device 121 Letter.
In order to solve the above problems, UNP service end 11 detect UNP client 12 transmission mask update request after, Determine the mask-length of IP address in dhcp address pool, for example, 28, the mask-length of IP address in the dhcp address pool is taken Band is updated in response message in mask, the mask is updated response message and is sent to UNP client 12.
After UNP client 12 receives mask renewal response message, the mask-length of own IP address is updated to DHCP The mask-length of IP address in address pool, for example, after renewal, the IP address of UNP client 12 is 192.168.10.1/28.So Operation, the IP address of UNP client 12 belongs to same address field with the IP address of access device 121, and UNP service end 11 is then permissible By UNP client 12, communicated with access device 121.
As seen from the above-described embodiment, by, after the application IP addresses request for receiving the transmission of UNP client, determining the UNP The corresponding subaddressing pond of client;From the corresponding subaddressing pond, preferentially select free IP addresses to send to UNP client End, so that the free IP addresses are distributed to its access device for being connected by UNP client.As UNP service end is connection The IP address that access device in same UNP client distributes in same subaddressing pond, so as to, it is achieved that UNP service end The IP address of access device is managed collectively, meanwhile, the access connected by different UNP clients can be effectively prevented from and set The problem that standby IP address is overlapped or conflicted.
Secondly, it is described from the angle of UNP client:
Fig. 3 is referred to, illustrates another embodiment flow chart of the application IP address distribution method, flow process shown in the figure On the basis of flow process shown in above-mentioned Fig. 1, by shown in Fig. 1 UNP client 12 execute the method as a example by, can include with Lower step:
Step S301:The application IP addresses request of access device transmission is received, in application IP addresses request, carries access device MAC Address.
In this application, so that access device 121 asks access network as an example, access device 121 can be connected to which UNP client 12 sends application IP addresses request, and carries the MAC Address of access device 121 in the application IP addresses request.
UNP client 12 can receive the application IP addresses request of access device transmission.
Step S302:Application IP addresses request is sent to UNP service end, so that UNP service end is asked according to application IP addresses Determine a destination address, and destination address is sent to UNP client.
After UNP client 12 receives the application IP addresses request, directly the application IP addresses request can be sent to UNP and take Business end 11, it is also possible to after being packaged processing to the application IP addresses request, retransmit to UNP service end 11, to this in the application It is not restricted.
After UNP service end 11 receives the application IP addresses request, a target can be determined according to the application IP addresses request Address, concrete UNP service end 11 is how to determine a destination address according to the application IP addresses request, may refer to above-mentioned figure Associated description in 2 illustrated embodiments, will not be described in detail herein.
After UNP service end 11 determines destination address, the destination address can be sent to UNP client 12.
Step S303:Receive the destination address that UNP service end sends.
Step S304:Destination address is distributed to the corresponding access device of MAC Address.
UNP client 12 can receive the destination address of the transmission of UNP service end 11, and afterwards, UNP client 12 can be by The destination address distributes to access device 121.
Additionally, UNP client 12 can also set up the target after the destination address for receiving the transmission of UNP service end 11 Corresponding relation between address and the MAC Address of access device 121.Subsequently, between UNP server 11 and access device 121 then Can be communicated according to the corresponding relation.
Additionally, in this application, seen from the above description, IP address in each the subaddressing pond on UNP server 11 Quantity is limited, and in concrete subaddressing pond, the quantity of IP address can be calculated by the network segment and mask-length.
UNP client can count the number of times for sending application IP addresses request, and for example, UNP client is often sent out to UNP service end Send primary address application to ask, default statistic is added 1, the initial value of the statistic is 0.When UNP client is to UNP When the number of times of server transmission application IP addresses request reaches predetermined threshold value, the predetermined threshold value can be corresponding to the UNP client Subaddressing pond in IP address quantity, it is believed that the no free IP addresses in the subaddressing pond corresponding to UNP client.
From the description in above-mentioned embodiment illustrated in fig. 2, when no free time IP ground in the corresponding subaddressing pond of UNP client During location, UNP service end can select the free IP addresses in other subaddressing ponds.But now, in order to ensure to be subsequently the UNP visitor After the free IP addresses that the access device connected by family end distributes in other subaddressing ponds, UNP server still can be with the UNP visitor The access device connected by family end carries out proper communication, and UNP client can update the mask-length of own IP address so that The IP address of UNP client belongs to same address field with the IP address of access device.
Specifically, when above-mentioned statistic reaches predetermined threshold value, UNP client can send mask to UNP service end Request is updated, and the mask updates request and the mask-length of own IP address updated for representing UNP client request.
UNP service end 11 determines IP in dhcp address pool after the mask for detecting the transmission of UNP client 12 updates request The mask-length of address, for example, 28, the mask-length of IP address in the dhcp address pool is carried and is disappeared in mask renewal response In breath, and mask renewal response message is sent to UNP client 12.
After UNP client 12 receives mask renewal response message, the mask-length of own IP address is updated to DHCP The mask-length of IP address in address pool, for example, after renewal, the IP address of UNP client 12 is 192.168.10.1/28.So Operation, the IP address of UNP client 12 belongs to same address field with the IP address of access device 121, and UNP service end 11 then passes through UNP client 12, is communicated with access device 121.
Additionally, in this application, when above-mentioned statistic reaches predetermined threshold value, UNP client can also pass through on ground Location is renewed a contract to carry in asking and asks, for representing, the labelling for updating itself mask-length, receives the address so as to UNP server Renew a contract after request, the labelling of itself mask-length can be updated according to the address renewed treaty request detection to UNP client request.
Specifically, it is possible to use in the renewed treaty request of address, whether the first byte record of " flags " field asks to update itself Mask-length.For example, when the value of the first byte is " 00 ", represents and be not required to update itself mask-length;Value when the first byte During for " 01 ", represent that request updates itself mask-length.Processed by this kind, as extra signaling message need not be increased, from And can compatible existing DHCP protocol.
As seen from the above-described embodiment, by after the application IP addresses request for receiving access device transmission, by the address Shen Please ask to send to UNP service end, distribute IP address by UNP service end for the access device.As UNP service end is for being connected to The IP address that access device in same UNP client distributes in same subaddressing pond, so as to, it is achieved that UNP service end pair The IP address of access device is managed collectively, meanwhile, the access device connected by different UNP clients can be effectively prevented from IP address overlap or conflict problem.
Corresponding with the embodiment of aforementioned IP address distribution method, present invention also provides the enforcement of IP address distributor Example.
First, the IP address distributor of the application offer is provided from UNP service end angle:
Fig. 4 is referred to, one embodiment block diagram of the application IP address distributor is illustrated, Fig. 4 shown device can To apply in UNP service end, the device can include:First receiver module 41, determining module 42, selecting module 43, address Sending module 44.
Wherein, first receiver module 41, can be used for receiving the application IP addresses request of UNP client transmission, The MAC Address of the access device connected by the UNP client is carried in the application IP addresses request;
The determining module 42, is determined for the corresponding subaddressing pond of the UNP client;
The selecting module 43, can be used for selecting free IP addresses in the corresponding subaddressing pond as target Address;
The address sending module 44, can be used for sending the destination address to the UNP client, so that the UNP The destination address is distributed to the corresponding access device of the MAC Address by client.
In one embodiment, the device can also include (not showing that in Fig. 4):Detection module, message transmission module.
The detection module, can be used for detecting mask renewal request, and the mask updates request for representing the UNP Client request updates the mask-length of own IP address;
The message transmission module, can be used for updating request according to the mask, sends mask more to the UNP client New response message, the mask updates the mask-length for carrying IP address in the dhcp address pool in response message, so that institute State UNP client and the mask-length of own IP address is updated to by the dhcp address pool according to mask renewal response message The mask-length of middle IP address.
In one embodiment, the selecting module 43, can be also used for:
If there are no free IP addresses in the corresponding subaddressing pond, a free time is selected in other subaddressing ponds IP address is used as the destination address.
Secondly, the IP address distributor of the application offer is provided from UNP client angle:
Fig. 5 is referred to, illustrates another embodiment block diagram of the application IP address distributor, Fig. 5 shown device Can apply in UNP client, the device can include:Second receiver module 51, Address requests sending module the 52, the 3rd connect Receive module 53, distribute module 54.
Wherein, second receiver module 51, can be used for receiving the application IP addresses request of access device transmission, institute State the MAC Address that the access device is carried in application IP addresses request;
The Address requests sending module 52, can be used for sending application IP addresses request to the UNP service end, with Make the UNP service end ask to determine a destination address according to the application IP addresses, and the destination address is sent to institute State UNP client;
3rd receiver module 53, can be used for receiving the destination address of UNP service end transmission;
The distribute module 54, can be used for for the destination address distributing to the corresponding access device of the MAC Address.
In one embodiment, the device can also include (not showing that in Fig. 5):Relation sets up module.
The relation sets up module, can be used for the corresponding relation that sets up between the destination address and the MAC Address, makes Obtain the UNP server to be communicated according to the corresponding relation with the access device.
In one embodiment, the device can also include (not showing that in Fig. 5):Statistical module, renewal request send mould Block, message reception module, mask update module.
Wherein, the statistical module, can be used for every send primary address application request to the UNP service end, will be default Statistic add 1, the initial value of the statistic be;
The renewal request sending module, can be used for, when the statistic reaches predetermined threshold value, servicing to the UNP End sends mask and updates request, and the mask updates request and updates own IP address for representing the UNP client request Mask-length;
The message reception module, can be used for receiving the UNP service end and updates request according to the mask, to described The mask that UNP client sends updates response message, and the mask updates in response message and carries IP in the dhcp address pool The mask-length of address;
The mask update module, can be used for updating response message by the mask-length of own IP address according to the mask It is updated to the mask-length of IP address in the dhcp address pool.
In said apparatus, the process of realizing of the function of unit and effect specifically refers to corresponding step in said method Process is realized, be will not be described here.
For device embodiment, as which corresponds essentially to embodiment of the method, so related part is referring to method reality Apply the part explanation of example.Device embodiment described above is only schematically, wherein described as separating component The unit of explanation can be or may not be physically separate, as the part that unit shows can be or can also It is not physical location, you can be located at a place, or can also be distributed on multiple NEs.Can be according to reality Need to select some or all of module therein to realize the purpose of application scheme.Those of ordinary skill in the art are not paying In the case of going out creative work, you can to understand and implement.
The preferred embodiment of the application is the foregoing is only, not in order to limit the application, all essences in the application Within god and principle, any modification, equivalent substitution and improvement that is done etc., should be included within the scope of the application protection.

Claims (10)

1. a kind of IP address distribution method, the omnipotent network passport UNP service end being applied in video monitoring system, its feature exists In, the UNP service end is configured with dynamic host configuration protocol DHCP service, includes dhcp address pool in the UNP service end, The dhcp address pool is divided at least two subaddressing ponds;Also include at least one UNP visitor in the video monitoring system Family end, the UNP client is arranged in heterogeneous networks with the UNP service end, and the UNP client is taken with the UNP Setting up between business end has UNP to connect;The UNP client is connected with least one access device, and the UNP client is with which even The access device for connecing is arranged in consolidated network;Methods described includes:
The application IP addresses request of UNP client transmission is received, in the application IP addresses request, carries the UNP client The MAC Address of the access device for being connected;
Determine the corresponding subaddressing pond of the UNP client;
Free IP addresses are selected in the corresponding subaddressing pond as destination address;
The destination address is sent to the UNP client so that the UNP client destination address is distributed to described The corresponding access device of MAC Address.
2. method according to claim 1, it is characterised in that methods described also includes:
Detecting mask and request being updated, the mask updates request and itself IP ground updated for representing the UNP client request The mask-length of location;
Request being updated according to the mask, mask being sent to the UNP client and update response message, the mask updates response The mask-length of IP address in the dhcp address pool is carried in message, so that the UNP client is updated according to the mask The mask-length of own IP address is updated to response message the mask-length of IP address in the dhcp address pool.
3. method according to claim 1, it is characterised in that methods described also includes:
If there are no free IP addresses in the corresponding subaddressing pond, a free time IP ground is selected in other subaddressing ponds Location is used as the destination address.
4. a kind of IP address distribution method, the UNP client being applied in video monitoring system, it is characterised in that the UNP visitor Family end is connected with least one access device, and the connected access device of the UNP client is arranged in consolidated network;Institute Stating in video monitoring system also includes UNP service end, in the UNP service end include dhcp address pool, the UNP client with The UNP service end is arranged in heterogeneous networks, and setting up between the UNP client and the UNP service end has UNP to connect Connect;Methods described includes:
The application IP addresses request of access device transmission is received, in the application IP addresses request, carries the access device MAC Address;
Application IP addresses request is sent to the UNP service end, so that the UNP service end please according to the application IP addresses One destination address of determination is sought, and the destination address is sent to the UNP client;
Receive the destination address of UNP service end transmission;
The destination address is distributed to the corresponding access device of the MAC Address.
5. method according to claim 4, it is characterised in that methods described also includes:
The corresponding relation that sets up between the destination address and the MAC Address so that the UNP server is set with described access Standby communicated according to the corresponding relation.
6. method according to claim 4, it is characterised in that methods described also includes:
Often primary address application request is sent to the UNP service end, default statistic is added 1, the statistic Initial value is 0;
When the statistic reaches predetermined threshold value, mask being sent to the UNP service end and updating request, the mask updates Ask the mask-length for representing UNP client request renewal own IP address;
Receiving the UNP service end and request is updated according to the mask, response is updated to the mask that the UNP client sends Message, the mask updates the mask-length for carrying IP address in the dhcp address pool in response message;
Response message is updated according to the mask mask-length of own IP address is updated to IP ground in the dhcp address pool The mask-length of location.
7. a kind of IP address distributor, the UNP service end being applied in video monitoring system, it is characterised in that the UNP clothes Business end is configured with DHCP service, includes dhcp address pool in the UNP service end, and the dhcp address pool is divided at least two Individual sub- address pool;Also include at least one UNP client in the video monitoring system, the UNP client is taken with the UNP Business end is arranged in heterogeneous networks, and setting up between the UNP client and the UNP service end has UNP to be connected;The UNP Client is connected with least one access device, and the connected access device of the UNP client is arranged in consolidated network; Described device includes:
First receiver module, for receiving the application IP addresses request of UNP client transmission, in the application IP addresses request Carry the MAC Address of the access device connected by the UNP client;
Determining module, for determining the corresponding subaddressing pond of the UNP client;
Selecting module, for selecting free IP addresses as destination address in the corresponding subaddressing pond;
Address sending module, for sending the destination address to the UNP client, so that the UNP client will be described Destination address distributes to the corresponding access device of the MAC Address.
8. device according to claim 7, it is characterised in that described device also includes:
Detection module, updates request for detecting mask, and the mask updates request for representing the UNP client request Update the mask-length of own IP address;
Message transmission module, for updating request according to the mask, sends mask renewal response to the UNP client and disappears Breath, the mask updates the mask-length for carrying IP address in the dhcp address pool in response message, so that the UNP client End updates response message according to the mask and the mask-length of own IP address is updated to IP address in the dhcp address pool Mask-length.
9. a kind of IP address distributor, the UNP client being applied in video monitoring system, it is characterised in that the UNP visitor Family end is connected with least one access device, and the connected access device of the UNP client is arranged in consolidated network;Institute Stating in video monitoring system also includes UNP service end, in the UNP service end include dhcp address pool, the UNP client with The UNP service end is arranged in heterogeneous networks, and setting up between the UNP client and the UNP service end has UNP to connect Connect;Described device includes:
Second receiver module, for receiving the application IP addresses request of access device transmission, in the application IP addresses request Carry the MAC Address of the access device;
Address requests sending module, for sending application IP addresses request to the UNP service end, so that UNP clothes Business end asks to determine a destination address according to the application IP addresses, and the destination address is sent to the UNP client;
3rd receiver module, for receiving the destination address of UNP service end transmission;
Distribute module, for distributing to the corresponding access device of the MAC Address by the destination address.
10. device according to claim 9, it is characterised in that described device also includes:
Statistical module, for often sending primary address application request to the UNP service end, default statistic is added 1, institute The initial value for stating statistic is 0;
Request sending module is updated, for when the statistic reaches predetermined threshold value, mask being sent to the UNP service end Request is updated, and the mask updates request and the mask-length of own IP address updated for representing the UNP client request;
Message reception module, updates request for receiving the UNP service end according to the mask, to the UNP client The mask of transmission updates response message, and the mask updates the mask for carrying IP address in the dhcp address pool in response message Length;
Mask update module, described in being updated to the mask-length of own IP address according to mask renewal response message The mask-length of IP address in dhcp address pool.
CN201611057807.4A 2016-11-24 2016-11-24 IP address allocation method and apparatus Pending CN106453690A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201611057807.4A CN106453690A (en) 2016-11-24 2016-11-24 IP address allocation method and apparatus

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201611057807.4A CN106453690A (en) 2016-11-24 2016-11-24 IP address allocation method and apparatus

Publications (1)

Publication Number Publication Date
CN106453690A true CN106453690A (en) 2017-02-22

Family

ID=58218581

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201611057807.4A Pending CN106453690A (en) 2016-11-24 2016-11-24 IP address allocation method and apparatus

Country Status (1)

Country Link
CN (1) CN106453690A (en)

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107508811A (en) * 2017-08-28 2017-12-22 浙江宇视科技有限公司 A kind of secure registration querying method and system based on UNP
CN107690052A (en) * 2017-08-14 2018-02-13 浙江宇视科技有限公司 A kind of method and device of video monitoring image superposition watermark
CN110113674A (en) * 2019-03-19 2019-08-09 视联动力信息技术股份有限公司 Method and apparatus are transferred in a kind of monitoring
CN110311994A (en) * 2019-08-05 2019-10-08 深圳创维数字技术有限公司 The distribution request method, apparatus and readable storage medium storing program for executing of IP address
CN111245974A (en) * 2020-02-10 2020-06-05 深信服科技股份有限公司 Address allocation method, device, equipment and storage medium
CN112367256A (en) * 2020-10-15 2021-02-12 深信服科技股份有限公司 Creation method, apparatus and storage medium

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102801798A (en) * 2012-08-03 2012-11-28 浙江宇视科技有限公司 Method and device for distributing IP (Internet Protocol) address
CN102833363A (en) * 2012-08-20 2012-12-19 大唐移动通信设备有限公司 IP (Internet Protocol) address allocation method, device and system
CN105872128A (en) * 2016-05-31 2016-08-17 浙江宇视科技有限公司 Virtual IP address allocation method and device

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102801798A (en) * 2012-08-03 2012-11-28 浙江宇视科技有限公司 Method and device for distributing IP (Internet Protocol) address
CN102833363A (en) * 2012-08-20 2012-12-19 大唐移动通信设备有限公司 IP (Internet Protocol) address allocation method, device and system
CN105872128A (en) * 2016-05-31 2016-08-17 浙江宇视科技有限公司 Virtual IP address allocation method and device

Cited By (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107690052A (en) * 2017-08-14 2018-02-13 浙江宇视科技有限公司 A kind of method and device of video monitoring image superposition watermark
CN107690052B (en) * 2017-08-14 2020-07-28 浙江宇视科技有限公司 Method and device for overlaying watermark on video monitoring image
CN107508811A (en) * 2017-08-28 2017-12-22 浙江宇视科技有限公司 A kind of secure registration querying method and system based on UNP
CN107508811B (en) * 2017-08-28 2020-05-19 浙江宇视科技有限公司 UNP-based secure registration query method and system
CN110113674A (en) * 2019-03-19 2019-08-09 视联动力信息技术股份有限公司 Method and apparatus are transferred in a kind of monitoring
CN110113674B (en) * 2019-03-19 2021-08-13 视联动力信息技术股份有限公司 Monitoring and calling method and device
CN110311994A (en) * 2019-08-05 2019-10-08 深圳创维数字技术有限公司 The distribution request method, apparatus and readable storage medium storing program for executing of IP address
CN110311994B (en) * 2019-08-05 2022-04-29 深圳创维数字技术有限公司 IP address allocation request method, device and readable storage medium
CN111245974A (en) * 2020-02-10 2020-06-05 深信服科技股份有限公司 Address allocation method, device, equipment and storage medium
CN111245974B (en) * 2020-02-10 2022-09-30 深信服科技股份有限公司 Address allocation method, device, equipment and storage medium
CN112367256A (en) * 2020-10-15 2021-02-12 深信服科技股份有限公司 Creation method, apparatus and storage medium
CN112367256B (en) * 2020-10-15 2022-09-30 深信服科技股份有限公司 Creation method, device and storage medium

Similar Documents

Publication Publication Date Title
CN106453690A (en) IP address allocation method and apparatus
CN101827134B (en) Automatically releasing resources reserved for subscriber devices within a broadband access network
CN102025798B (en) Address allocation processing method, device and system
US10361970B2 (en) Automated instantiation of wireless virtual private networks
EP2169877B1 (en) Processing method and device for qinq termination configuration
CN102027732B (en) Providing access over ip network to server application program
EP2780815B1 (en) Selective ip address allocation for probes that do not have assigned ip addresses
CN101534329A (en) IP address assignment method and system
CN105979202B (en) Data transmission method and device
CN108429824B (en) Address allocation method and device
CN105245629A (en) DHCP-based host communication method and device
CN108418907A (en) IP address distribution method and device
WO2016202016A1 (en) Device management method, apparatus and system
CN106878481B (en) Method, device and system for acquiring Internet Protocol (IP) address
CN109040334B (en) Static intranet mapping method, extranet server, intranet communication equipment and system
CN104219337A (en) IP address allocation method and device applied to SDN
CN107579988B (en) Method and device for configuring security policy
EP3010209A1 (en) Docsis provisioning of point-to-point ethernet
US10728171B2 (en) Governing bare metal guests
CN113014680B (en) Broadband access method, device, equipment and storage medium
CN110636149B (en) Remote access method, device, router and storage medium
CN103141072B (en) IP address acquiring method and network access equipment
CN101309154B (en) Datagram sending method, sending apparatus and transmission system
CN116366525A (en) Message forwarding method, electronic device and computer readable storage medium
KR101374487B1 (en) System and method for providing multimedia service using virtual ip in home gateway

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20170222