CN103905392B - DynamicHost sets protocol DHCP server selection method, apparatus and system - Google Patents

DynamicHost sets protocol DHCP server selection method, apparatus and system Download PDF

Info

Publication number
CN103905392B
CN103905392B CN201210576393.1A CN201210576393A CN103905392B CN 103905392 B CN103905392 B CN 103905392B CN 201210576393 A CN201210576393 A CN 201210576393A CN 103905392 B CN103905392 B CN 103905392B
Authority
CN
China
Prior art keywords
dhcp
host configuration
dynamic host
configuration protocol
protocol server
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.)
Active
Application number
CN201210576393.1A
Other languages
Chinese (zh)
Other versions
CN103905392A (en
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.)
China Mobile Communications Group Co Ltd
Original Assignee
China Mobile Communications Group 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 China Mobile Communications Group Co Ltd filed Critical China Mobile Communications Group Co Ltd
Priority to CN201210576393.1A priority Critical patent/CN103905392B/en
Publication of CN103905392A publication Critical patent/CN103905392A/en
Application granted granted Critical
Publication of CN103905392B publication Critical patent/CN103905392B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Computer And Data Communications (AREA)
  • Small-Scale Networks (AREA)

Abstract

The invention discloses a kind of Dynamic Host Configuration Protocol server system of selection, apparatus and system, wherein the method includes:After dhcp client sends DHCP discovery messages, the DHCP work messages of at least one Dynamic Host Configuration Protocol server feedback in setting duration are received;Determine the load information of each Dynamic Host Configuration Protocol server included in DHCP work message;According to the load information determined, a Dynamic Host Configuration Protocol server for being used to provide service is chosen in each Dynamic Host Configuration Protocol server;Dhcp client receives the DHCP response messages that the Dynamic Host Configuration Protocol server chosen is sent, and determines address allocation information.By above-mentioned technical proposal, Dynamic Host Configuration Protocol server resource can be effectively distributed, preferably improve resource utilization.

Description

DynamicHost sets protocol DHCP server selection method, apparatus and system
Technical field
The present invention relates to Internet protocol processing technology field, agreement is set more particularly, to a kind of DynamicHost(DHCP, Dynamic Host Configuration Protocol)Server selection method, apparatus and system.
Background technology
In Internet protocol(IP, Internet Protocol)In network, each network equipment is required for an IP ground Location is used as from the identification information on network.Wherein, in mininet, network equipment negligible amounts, each network The IP address of equipment can one by one be configured by network manager.But if in catenet, network equipment quantity is relatively more, adopts The mode of configuration IP address is relatively lost time by hand, and cannot also meet demand, based on this, proposes to be moved based on DHCP The method that state distributes IP address.
DHCP is with client-server(CLIENT-SERVER)Pattern works, on system architecture composition, if DHCP In the same physics network segment, then dhcp client can exactly obtain Dynamic Host Configuration Protocol server dynamically point for client and Dynamic Host Configuration Protocol server The IP address matched somebody with somebody.If not needing to set dhcp relay agent in a network in the same physics network segment(DCHP Relay Agent)Equipment.By DHCPRelay Agent equipment may not necessarily the network segment of each physics Dynamic Host Configuration Protocol server is set, add When IP address distribution is carried out after DHCPRelay equipment, the aforementioned four stage is specifically also included, but in message transmission procedure, DHCP Relay equipment can forward dhcp client be sent to not same physical subnets Dynamic Host Configuration Protocol server message, Can forward Dynamic Host Configuration Protocol server issue not same physical subnets dhcp client message.Dhcp client takes from DHCP Business device dynamic access IP address, mainly comprising following four-stages:
First stage:Discovery phase, i.e. dhcp client determine the stage of Dynamic Host Configuration Protocol server.DHCP families end is with broadcast mode DHCP is sent to Dynamic Host Configuration Protocol server to find(DHCP DISCOVER)Message.
Second stage:Offer stage, i.e. Dynamic Host Configuration Protocol server provide the stage of IP address for client.Dynamic Host Configuration Protocol server is received To after the DHCP DISCOVER messages that client is sent, according to the order of priority that IP address is distributed, an IP ground is determined Location, and the IP address that will be determined is together with other specification, is worked by DHCP(DHCP OFFER)Message is sent to client.
Phase III, choice phase, i.e. dhcp client select the stage of IP address.Dhcp client receives multiple After Dynamic Host Configuration Protocol server sends DHCP OFFER messages to the dhcp client, dhcp client is in the multiple DHCP for receiving In OFFER messages, then the DHCP OFFER messages that static receiving is received send DHCP request with broadcast mode (DHCP REQUEST)Message, the IP address distributed in DHCP OFFER messages comprising Dynamic Host Configuration Protocol server in the message.
Fourth stage, the stage of recognition, i.e. Dynamic Host Configuration Protocol server confirm the stage of IP address.Dynamic Host Configuration Protocol server receives DHCP client After the DHCP-REQUEST messages that end is sent, operations described below can be carried out by the Dynamic Host Configuration Protocol server that dhcp client is selected:If really Recognize IP address and distribute to the dhcp client, then return to DHCP responses(DHCP ACK)Message;DHCP will be otherwise returned to deny DHCP NAK messages, show that the IP address can not distribute to the dhcp client.Dhcp client receives server return After DHCP-ACK confirmation messages, address resolution can be in a broadcast manner sent(ARP)Message enters row address detection, if in regulation Time in do not receive responses, dhcp client just use IP address.
From the foregoing, Dynamic Host Configuration Protocol server system of selection in the prior art, when DHCP CLIENT broadcast DHCP After DISCOVER messages, can receive and net the DHCPOFFER messages that interior all of DHCP SERVER are returned, but DHCP CLIENT Only understand first corresponding DHCP SERVER of DHCPOFFER messages of arrival of static selection, and obtained from the DHCP SERVER Corresponding IP address is obtained, but, there are following defects in this kind of mode of the selection Dynamic Host Configuration Protocol server of static state:Assuming that one in network Have three Dynamic Host Configuration Protocol server, respectively with a~c identify, when Dynamic Host Configuration Protocol server b for some reason(Such as:Physical location is former Cause, transmission link failure etc.), the DHCP OFFER that the DHCP OFFER messages that it sends always send than Dynamic Host Configuration Protocol server a and b Message reaches dhcp client a little later, then according to the technical scheme for proposing in the prior art, Dynamic Host Configuration Protocol server b forever will can not Enough to provide service, so that other Dynamic Host Configuration Protocol server need to carry substantial amounts of dhcp client in network, load is heavier, and is somebody's turn to do Dynamic Host Configuration Protocol server b is constantly in idle condition, wastes server resource.
In sum, Dynamic Host Configuration Protocol server system of selection in the prior art, Dynamic Host Configuration Protocol server resource can not be by effective profit With that is, resource utilization is relatively low.
The content of the invention
A kind of Dynamic Host Configuration Protocol server system of selection, apparatus and system are the embodiment of the invention provides, can effectively be distributed Dynamic Host Configuration Protocol server resource, preferably improves resource utilization.
A kind of DynamicHost sets protocol DHCP server selection method, including:Dhcp client sends DHCP and finds report Wen Hou, receives the DHCP work messages of at least one Dynamic Host Configuration Protocol server feedback in setting duration;Determine the DHCP work message In the load information of each Dynamic Host Configuration Protocol server that includes;According to the load information determined, one is chosen in each Dynamic Host Configuration Protocol server Dynamic Host Configuration Protocol server for providing service;Dhcp client receives the DHCP response messages that the Dynamic Host Configuration Protocol server chosen is sent, really Determine address allocation information.
A kind of DynamicHost sets protocol DHCP server selection method, including:DHCP visitors are received in Dynamic Host Configuration Protocol server The DHCP that family end is sent is had found after message, to dhcp client feedback DHCP work messages, wherein, the DHCP work Load information comprising the Dynamic Host Configuration Protocol server in message, after the dhcp client receives DHCP work messages, determines institute State the load information of Dynamic Host Configuration Protocol server;And when it itself is Dynamic Host Configuration Protocol server that the dhcp client is chosen to determine, to The dhcp client sends the DHCP response messages for confirming address allocation information, wherein the dhcp client according to DHCP response messages, determine address allocation information.
A kind of DynamicHost sets protocol DHCP server selection device, and the device is located at dhcp client side, including:Connect Module is received, for after DHCP discovery messages are sent, receiving the DHCP works of at least one Dynamic Host Configuration Protocol server feedback in setting duration Make message;Determining module, the load information of each Dynamic Host Configuration Protocol server for determining to be included in the DHCP work message;Choose mould Block, for according to the load information determined, a Dynamic Host Configuration Protocol server for being used to provide service being chosen in each Dynamic Host Configuration Protocol server; The receiver module, is additionally operable to receive the DHCP response messages that the Dynamic Host Configuration Protocol server chosen is sent, and determines address allocation information.
A kind of DynamicHost sets protocol DHCP server selection device, and the device is located at Dynamic Host Configuration Protocol server side, including:Hair Module is sent, for after the DHCP discovery messages that dhcp client is sent are received, DHCP being fed back to the dhcp client Work message, wherein, the load information comprising Dynamic Host Configuration Protocol server in the DHCP work message, the dhcp client is received After DHCP work messages, the load information of Dynamic Host Configuration Protocol server is determined;And determining module, for determining whether itself is described The Dynamic Host Configuration Protocol server that dhcp client is chosen;The sending module, is additionally operable to determine it itself is the DHCP in determining module During the Dynamic Host Configuration Protocol server that client is chosen, the DHCP response reports for confirming address allocation information are sent to the dhcp client Text, wherein the dhcp client determines address allocation information according to DHCP response messages.
A kind of DynamicHost sets protocol DHCP server selection system, including at least one dhcp client and at least one Individual Dynamic Host Configuration Protocol server, wherein:The dhcp client, finds message, and receive for sending DHCP to the Dynamic Host Configuration Protocol server The DHCP work messages of at least one Dynamic Host Configuration Protocol server feedback in setting duration, determine to include in DHCP work message is each The load information of Dynamic Host Configuration Protocol server, according to the load information determined, one is chosen in each Dynamic Host Configuration Protocol server is used to provide clothes The Dynamic Host Configuration Protocol server of business, and the DHCP response messages that the Dynamic Host Configuration Protocol server chosen is sent are received, determine address allocation information;Institute Dynamic Host Configuration Protocol server is stated, for after the DHCP discovery messages that the dhcp client is sent are received, to the DHCP client End feedback DHCP work messages, wherein, the load information comprising the Dynamic Host Configuration Protocol server in the DHCP work message;And true Make when itself being Dynamic Host Configuration Protocol server that the dhcp client is chosen, sent for confirming address point to the dhcp client DHCP response messages with information.
Using above-mentioned technical proposal, dhcp client receives the DHCP of at least one Dynamic Host Configuration Protocol server feedback in setting duration Work message, and according to DHCP work messages, the load information of Dynamic Host Configuration Protocol server is determined, then according to the load letter determined Breath, selection one is used to provide the Dynamic Host Configuration Protocol server of service, and Dynamic Host Configuration Protocol server is being determined when DHCP request message is received Itself it is after the Dynamic Host Configuration Protocol server that dhcp client is chosen, to be sent for confirming address allocation information to the dhcp client DHCP response messages, dhcp client determines address allocation information according to DHCP response messages, so as to avoid prior art Present in can only static selection Dynamic Host Configuration Protocol server, it is impossible to effectively distribute Dynamic Host Configuration Protocol server resource so that resource utilization compared with Low problem.
Brief description of the drawings
Fig. 1 is in the embodiment of the present invention, the Dynamic Host Configuration Protocol server of proposition selects system architecture composition schematic diagram;
Fig. 2 be the embodiment of the present invention in, the Dynamic Host Configuration Protocol server system of selection flow chart of proposition;
Fig. 3 be the embodiment of the present invention in, the client-side Dynamic Host Configuration Protocol server selection device result schematic diagram of proposition;
Fig. 4 be the embodiment of the present invention in, the server side Dynamic Host Configuration Protocol server selection device result schematic diagram of proposition.
Specific embodiment
For Dynamic Host Configuration Protocol server system of selection present in prior art, Dynamic Host Configuration Protocol server resource can not be by effective profit Problem, in embodiment of the present invention technique proposed herein scheme, by each DHCP service included in DHCP work messages The load information of device, chooses a Dynamic Host Configuration Protocol server for being used to provide service in each Dynamic Host Configuration Protocol server, can effectively distribute Dynamic Host Configuration Protocol server resource, preferably improves resource utilization.
Below in conjunction with each accompanying drawing to the main realization principle of embodiment of the present invention technical scheme, specific embodiment and It is set forth in the beneficial effect that should be able to be reached.
The embodiment of the present invention proposes a kind of Dynamic Host Configuration Protocol server selection system here, as shown in figure 1, its system includes:
Including at least one dhcp client and at least one Dynamic Host Configuration Protocol server, wherein:
The dhcp client(DHCP CLIENT), the dhcp client, for being sent to the Dynamic Host Configuration Protocol server DHCP has found message, and receives the DHCP work messages that at least one Dynamic Host Configuration Protocol server feeds back in setting duration, it is determined that described The load information of each Dynamic Host Configuration Protocol server included in DHCP work messages, according to the load information determined, in each DHCP service A Dynamic Host Configuration Protocol server for being used to provide service is chosen in device, and receives the DHCP response reports that the Dynamic Host Configuration Protocol server chosen is sent Text, determines address allocation information.
Specifically, above-mentioned dhcp client, the identification information write-in DHCP of the Dynamic Host Configuration Protocol server for being additionally operable to select please In seeking message, and broadcast the DHCP request message.
Wherein, the identification information of Dynamic Host Configuration Protocol server can be, but not limited to be Dynamic Host Configuration Protocol server Unique Device numbering, also may be used To be the device identification of Dynamic Host Configuration Protocol server, it is preferred that in embodiment of the present invention technique proposed herein scheme, using DHCP service The device identification of device as Dynamic Host Configuration Protocol server identification information.Dhcp client is in one DHCP clothes for being used to provide service of selection After business device, the device identification of the Dynamic Host Configuration Protocol server of the selection is written to the specific field of DHCP request message, is broadcast to institute There is Dynamic Host Configuration Protocol server.
Specifically, the first quantity information of the dhcp client that load information has been carried comprising Dynamic Host Configuration Protocol server, and should Second quantity information of the dhcp client that Dynamic Host Configuration Protocol server maximum can be carried;The dhcp client, specifically for according to Difference between two quantity informations and the first quantity information, determines the 3rd of the dhcp client that each Dynamic Host Configuration Protocol server can be carried Quantity information, according to the 3rd quantity information, chooses a Dynamic Host Configuration Protocol server for being used to provide service in each Dynamic Host Configuration Protocol server.
Specifically, above-mentioned dhcp client, specifically at least one the 3rd quantity informations that will obtain according to being arranged Sequence, chooses the maximum corresponding Dynamic Host Configuration Protocol server of the 3rd quantity information of numerical value, as providing clothes in the result after sequence The Dynamic Host Configuration Protocol server of business.
Dhcp client according to the load information of each Dynamic Host Configuration Protocol server determine Dynamic Host Configuration Protocol server current loads situation it Afterwards, select one of them for provide service Dynamic Host Configuration Protocol server.Specifically, system of selection can be that selection load is lighter Dynamic Host Configuration Protocol server, if there is the load condition of at least two Dynamic Host Configuration Protocol server identical, can be according to reception DHCP work messages Time order and function come select one for provide service Dynamic Host Configuration Protocol server.
The Dynamic Host Configuration Protocol server, for after the DHCP discovery messages that the dhcp client is sent are received, to institute Dhcp client feedback DHCP work messages are stated, wherein, the load comprising the Dynamic Host Configuration Protocol server is believed in the DHCP work message Breath;And when it itself is Dynamic Host Configuration Protocol server that the dhcp client is chosen to determine, is sent to the dhcp client and used In the DHCP response messages for confirming address allocation information.
Specifically, the Dynamic Host Configuration Protocol server, the identification information specifically for determining to be included in the DHCP request message is It is no identical with the identification information of itself, if identical, it is determined that itself be Dynamic Host Configuration Protocol server that the dhcp client is chosen, instead It, determines it itself is not the Dynamic Host Configuration Protocol server that the dhcp client is chosen.
Wherein, during Dynamic Host Configuration Protocol server feeds back to the work message of dhcp client, the load comprising the Dynamic Host Configuration Protocol server is believed Breath.In specific implementation, the load information of itself is written to Dynamic Host Configuration Protocol server the specific field in DHCP work messages.Specifically Ground, the specific field can be spare field in DHCP work messages, or increase new field in DHCP work messages, For writing load information.It is preferred that in embodiment of the present invention technique proposed herein scheme, the sky of the message that worked using DHCP Not busy field Opition, is designated as OpitionX fields, and Dynamic Host Configuration Protocol server works in DHCP and report after DHCP discovery messages are received The OpitionX fields of text write the load information of itself and are sent to dhcp client.
It is preferred that the system can also include that at least one relaying being located between dhcp client and Dynamic Host Configuration Protocol server sets Standby, the trunking can be communicated with dhcp client, Dynamic Host Configuration Protocol server respectively;The trunking, for inciting somebody to action Dhcp client is broadcast to the message of Dynamic Host Configuration Protocol server by way of unicast message, is sent at least one Dynamic Host Configuration Protocol server; And forward each Dynamic Host Configuration Protocol server to be sent to the message of dhcp client.
Wherein, if dhcp client and Dynamic Host Configuration Protocol server be not in the same physics network segment, need to set trunking, Can avoid being set in each physics network segment the condition of Dynamic Host Configuration Protocol server by trunking, and trunking can be by The message of dhcp client is sent to Dynamic Host Configuration Protocol server not in the same physics network segment, it is also possible to send Dynamic Host Configuration Protocol server Message returns to the dhcp client of the no longer same physics network segment.
Specifically, DHCP message uses UDP transmission means, and the port numbers of dhcp client can be 68, DHCP The port numbers of server are 67.
Using above-mentioned technical proposal, the report between dhcp client and DHCP server side is forwarded by increasing trunking Text, and the analysis of the load condition of Dynamic Host Configuration Protocol server is realized by trunking, therefore the dynamic of Dynamic Host Configuration Protocol server is selected Select and also realized not by trunking, but realized by dhcp client, such that it is able to preferably avoid substantial amounts of DHCP When message is sent to trunking so that trunking turns into the problem of the performance bottleneck of whole system.
Based on the system architecture shown in Fig. 1, the embodiment of the present invention proposes a kind of Dynamic Host Configuration Protocol server system of selection here, such as schemes Shown in 2, the embodiment of the present invention is here with one of dhcp client(DHCPCLIENT)With a Dynamic Host Configuration Protocol server(DHCP SERVER)And be described in detail as a example by a trunking, its specific handling process is for example following:
Step 21, DHCP CLIENT send DHCP and find message to DHCP SERVER sides.
Wherein, DHCP CLIENT can send DHCP and find message by way of broadcast to DHCP SERVER sides.Tool Body ground, DHCP has found that message can be DHCP DISCOVER messages.
Step 22, the trunking for setting in systems receives the DHCPDISCOVER messages of DHCP CLIENT transmissions Afterwards, by the DHCP DISCOVER message relays to DHCP SERVER by way of unicast.
For example, it is assumed that trunking receives the DHCP DISCOVER messages of DHCP CLIENT transmissions, trunking leads to N number of unicast message is crossed by the DHCP DISCOVER message relays to N number of DHCPSERVER.
Step 23, DHCP SERVER receive the DHCP sent by dhcp client that trunking relaying comes After DISCOVER messages, feedback DHCP work messages.
Wherein, the DHCP work message can be DHCP OFFER messages, and being included in DHCP OFFER messages should The load information of Dynamic Host Configuration Protocol server.
In specific implementation, each DHCP SERVER can encapsulate one after DHCP DISCOVER messages are received DHCP OFFER messages, the specific field in DHCP OFFER messages, encapsulate the load information of itself.The specific field can Being spare field in DHCP work messages, or increase new field in DHCP work messages, for writing load information. It is preferred that in embodiment of the present invention technique proposed herein scheme, the spare field Option of the message that worked using DHCP is designated as OptionX fields, Dynamic Host Configuration Protocol server writes after DHCP discovery messages are received in the OptionX fields of DHCP work messages The load information of itself is simultaneously sent to dhcp client.
Specifically, load information can include the first quantity information of the dhcp client that Dynamic Host Configuration Protocol server has been carried, Second quantity information of the dhcp client that can be carried with Dynamic Host Configuration Protocol server maximum.
Step 24, the DHCP OFFER message relays that trunking sends DHCP SERVER give DHCP CLIENT.
Step 25, at least one DHCP SERVER that DHCP CLIENT are received in setting duration by trunking forwarding are anti- The DHCP OFFER messages of feedback.
Specifically, DHCP CLIENT are received in setting duration t, at least one DHCP SERVER forwarded by trunking The DHCP OFFER messages of feedback.
Step 26, DHCP CLIENT determine to be included in DHCPOFFER messages according to the DHCP OFFER messages for receiving Each DHCP SERVER load information.
Step 27, according to the load information determined, one is chosen in each Dynamic Host Configuration Protocol server is used to provide service Dynamic Host Configuration Protocol server, dhcp client receives the DHCP response messages that the Dynamic Host Configuration Protocol server chosen is sent, and determines address allocation information.
Wherein, the of the dhcp client that the load information in DHCP OFFER messages has been carried comprising Dynamic Host Configuration Protocol server One quantity information, and the second quantity information of dhcp client that Dynamic Host Configuration Protocol server maximum can be carried, believe according to the second quantity Difference between breath and the first quantity information, determines the 3rd quantity letter of the dhcp client that each Dynamic Host Configuration Protocol server can be carried Breath, according to the 3rd quantity information, chooses a Dynamic Host Configuration Protocol server for being used to provide service in each Dynamic Host Configuration Protocol server.It is preferred that At least one the 3rd quantity informations that will can be obtained choose maximum the of numerical value according to being ranked up, in the result after sequence The corresponding Dynamic Host Configuration Protocol server of three quantity informations, as the Dynamic Host Configuration Protocol server for providing service.
In specific implementation, DHCP CLIENT, to all of DHCPOFFER messages for receiving, are carried in setting duration t The OptionX field informations in DHCP OFFER messages are taken, and the load feelings of DHCP SERVER are calculated according to the field information Condition, therefrom to select the DHCPSERVER of most lightly loaded.The parameter that load is calculated is carried including the DHCP SERVER DHCP CLIENT quantity N, the maximum DHCP CLIENT quantity M that can be carried etc., the specific formula of calculating can be according to reality Situation is selected.Such as Payload=Fun (N, M).Specifically, system of selection can be the minimum Dynamic Host Configuration Protocol server of selection load, If there is the load condition of at least two Dynamic Host Configuration Protocol server identical, can be come according to the time order and function for receiving DHCP work messages Selection one is used to provide the Dynamic Host Configuration Protocol server of service.
It is preferred that in embodiment of the present invention technique proposed herein scheme, can include:
Step 28, in the identification information write-in DHCP request message of the DHCP SERVER that dhcp client will be selected, and Broadcast the DHCP request message.
Wherein, DHCP request message can be DHCP Request messages, and DHCP CLIENT are according to load information dynamic Choose after DHCP SERVER, determine the device identification of the DHCP SERVER of selection, device identification is written to DHCP In Request messages and it is broadcasted.
Step 29, after trunking receives the DHCP Request messages of DHCP CLIENT broadcast, by the DHCP Request messages are converted to N number of DHCP unicast messages and are sent to N number of DHCPSERVER.
Step 30, Dynamic Host Configuration Protocol server determines whether itself is Dynamic Host Configuration Protocol server that dhcp client is chosen.
Specifically, Dynamic Host Configuration Protocol server can determine to be wrapped in the DHCP request message according to DHCP request message is received The identification information for containing.Wherein, DHCP SERVER are according to DHCP Request messages are received, in DHCP Request messages Determine the identification information carried in the message.
Step 31, DHCP SERVER judge the identification information that carries in DHCP Request messages whether the mark with itself Knowledge information is consistent, when determining that the identification information is identical with the identification information of itself, is sent to the dhcp client and used In the DHCP responses for confirming address allocation information(ACK)Message.
Wherein, the DHCP SERVER unicasts chosen by DHCP CLIENT send DHCP ACK messages and give DHCP CLIENT To confirm that IP address distributes information.
Step 32, the DHCP response messages that the Dynamic Host Configuration Protocol server that DHCP CLIENT receive selection is sent determine that address is distributed Information.
It should be noted that embodiment of the present invention technical scheme set forth above, 21 ~ step 32 of above-mentioned steps and accompanying drawing 2, It is a kind of preferably implementation, you can be deformed according to above-mentioned technical proposal and be reduced respective handling step also at this Within invention protection domain.
Correspondingly, the embodiment of the present invention also proposes a kind of Dynamic Host Configuration Protocol server selection device here, and the device is located at DHCP visitors Family side, as shown in figure 3, including:
Receiver module 401, for after DHCP discovery messages are sent, receiving at least one Dynamic Host Configuration Protocol server in setting duration The DHCP work messages of feedback.
Determining module 402, for according to the DHCP work messages for receiving, determining to be included in the DHCPOFFER messages Each Dynamic Host Configuration Protocol server load information.
Module 403 is chosen, is used to provide for according to the load information determined, choosing one in each Dynamic Host Configuration Protocol server The Dynamic Host Configuration Protocol server of service.
The receiver module 401, is additionally operable to receive the DHCP response messages that the Dynamic Host Configuration Protocol server chosen is sent, and determines address Distribution information.
Alternatively, said apparatus can also include:
Broadcast module 404, for the identification information write-in DHCP request message of the Dynamic Host Configuration Protocol server that will select in, and extensively Broadcast the DHCP request message.
The receiver module 401, is additionally operable to receive the DHCP response messages sent of Dynamic Host Configuration Protocol server chosen and determines address Distribution information, wherein, the DHCP response messages are after Dynamic Host Configuration Protocol server receives DHCP request message, according to DHCP request report The identification information included in text, determine itself be choose Dynamic Host Configuration Protocol server after, send for confirm address distribution letter The DHCP response messages of breath.
Specifically, the first quantity information of the dhcp client that load information has been carried comprising Dynamic Host Configuration Protocol server, and should Second quantity information of the dhcp client that Dynamic Host Configuration Protocol server maximum can be carried;The selection module 403, specifically for according to the Difference between two quantity informations and the first quantity information, determines the 3rd of the dhcp client that each Dynamic Host Configuration Protocol server can be carried Quantity information, according to the 3rd quantity information, chooses a Dynamic Host Configuration Protocol server for being used to provide service in each Dynamic Host Configuration Protocol server.
Specifically, above-mentioned selection module 403, specifically at least one the 3rd quantity informations that will obtain according to being arranged Sequence, chooses the maximum corresponding Dynamic Host Configuration Protocol server of the 3rd quantity information of numerical value, as providing clothes in the result after sequence The Dynamic Host Configuration Protocol server of business.
Correspondingly, the embodiment of the present invention also proposes a kind of Dynamic Host Configuration Protocol server selection device here, and the device takes positioned at DHCP Business device side, as shown in figure 4, including:
Sending module 501, for after the DHCP discovery messages that dhcp client is sent are received, to DHCP visitors Family end feedback DHCP work messages, wherein, the load information comprising Dynamic Host Configuration Protocol server, the DHCP in the DHCP work message After client receives DHCP work messages, the load information of Dynamic Host Configuration Protocol server is determined.
Determining module 502, for determining whether itself is Dynamic Host Configuration Protocol server that the dhcp client is chosen.
The sending module 501, is additionally operable to determine it itself is DHCP that the dhcp client is chosen in determining module During server, the DHCP response messages for confirming address allocation information are sent to the dhcp client, wherein the DHCP Client determines address allocation information according to DHCP response messages.
The device also includes:
Receiver module 503, for receiving the DHCP request message that dhcp client is sent, wherein the DHCP request message In comprising dhcp client according to load information, selected in each Dynamic Host Configuration Protocol server is used to provide the DHCP clothes of service The identification information of business device;.
The determining module 502, specifically for the identification information that determines to be included in the DHCP request message whether and from The identification information of body is identical, if identical, it is determined that itself be Dynamic Host Configuration Protocol server that the dhcp client is chosen, conversely, really Fixed itself is not the Dynamic Host Configuration Protocol server that the dhcp client is chosen.
The sending module 501, is additionally operable to when determining that the identification information is identical with the identification information of itself, to institute State dhcp client and send DHCP response messages for confirming address allocation information.
Using embodiment of the present invention technical scheme set forth above, Dynamic Host Configuration Protocol server is encapsulated by DHCP work messages Load information, and by DHCP work message be sent to dhcp client so that dhcp client can according to DHCP work report The load information of the Dynamic Host Configuration Protocol server encapsulated in text accurately determines the loading condition of each Dynamic Host Configuration Protocol server, existing so as to solve Have Dynamic Host Configuration Protocol server present in technology can only static selection problem.Also, determine Dynamic Host Configuration Protocol server loading condition be by Dhcp client is completed come what is completed rather than by trunking, i.e., it not is to concentrate that the dynamic select of Dynamic Host Configuration Protocol server is calculated Completed on trunking, such that it is able to preferably avoid trunking overload so that trunking turns into the property of system The problem of energy bottleneck.And then Dynamic Host Configuration Protocol server resource can be effectively distributed, preferably improve resource utilization.
It will be understood by those skilled in the art that embodiments of the invention can be provided as method, device(Equipment)Or computer Program product.Therefore, the present invention can be using complete hardware embodiment, complete software embodiment or combination software and hardware aspect Embodiment form.And, the present invention can be used and wherein include the meter of computer usable program code at one or more Calculation machine usable storage medium(Including but not limited to magnetic disk storage, CD-ROM, optical memory etc.)The computer journey of upper implementation The form of sequence product.
The present invention is with reference to method according to embodiments of the present invention, device(Equipment)With the flow chart of computer program product And/or block diagram is described.It should be understood that each flow during flow chart and/or block diagram can be realized by computer program instructions And/or the combination of the flow and/or square frame in square frame and flow chart and/or block diagram.These computer programs can be provided to refer to The processor of all-purpose computer, special-purpose computer, Embedded Processor or other programmable data processing devices is made to produce One machine so that produced for realizing by the instruction of computer or the computing device of other programmable data processing devices The device of the function of being specified in one flow of flow chart or multiple one square frame of flow and/or block diagram or multiple square frames.
These computer program instructions may be alternatively stored in can guide computer or other programmable data processing devices with spy In determining the computer-readable memory that mode works so that instruction of the storage in the computer-readable memory is produced and include finger Make the manufacture of device, the command device realize in one flow of flow chart or multiple one square frame of flow and/or block diagram or The function of being specified in multiple square frames.
These computer program instructions can be also loaded into computer or other programmable data processing devices so that in meter Series of operation steps is performed on calculation machine or other programmable devices to produce computer implemented treatment, so as in computer or The instruction performed on other programmable devices is provided for realizing in one flow of flow chart or multiple flows and/or block diagram one The step of function of being specified in individual square frame or multiple square frames.
, but those skilled in the art once know basic creation although preferred embodiments of the present invention have been described Property concept, then can make other change and modification to these embodiments.So, appended claims are intended to be construed to include excellent Select embodiment and fall into having altered and changing for the scope of the invention.
Obviously, those skilled in the art can carry out various changes and modification without deviating from essence of the invention to the present invention God and scope.So, if these modifications of the invention and modification belong to the scope of the claims in the present invention and its equivalent technologies Within, then the present invention is also intended to comprising these changes and modification.

Claims (18)

1. a kind of DynamicHost sets protocol DHCP server selection method, it is characterised in that including:
After dhcp client sends DHCP discovery messages, the DHCP works of at least one Dynamic Host Configuration Protocol server feedback in setting duration are received Make message;
Determine the load information of each Dynamic Host Configuration Protocol server included in DHCP work message;
According to the load information determined, a Dynamic Host Configuration Protocol server for being used to provide service is chosen in each Dynamic Host Configuration Protocol server;
Dhcp client receives the DHCP response messages that the Dynamic Host Configuration Protocol server chosen is sent, and determines address allocation information.
2. the method for claim 1, it is characterised in that choose a Dynamic Host Configuration Protocol server for being used to providing service it Afterwards, also include:
In the identification information write-in DHCP request message of the Dynamic Host Configuration Protocol server that will be selected, and broadcast the DHCP request message.
3. the method for claim 1, it is characterised in that the load information has been carried comprising Dynamic Host Configuration Protocol server First quantity information of dhcp client, and the second quantity information of dhcp client that Dynamic Host Configuration Protocol server maximum can be carried;
According to the load information determined, a Dynamic Host Configuration Protocol server for being used to provide service, bag are chosen in each Dynamic Host Configuration Protocol server Include:
According to the difference between the second quantity information and the first quantity information, the DHCP visitors that each Dynamic Host Configuration Protocol server can be carried are determined 3rd quantity information at family end, according to the 3rd quantity information, one is chosen in each Dynamic Host Configuration Protocol server is used to provide service Dynamic Host Configuration Protocol server.
4. method as claimed in claim 3, it is characterised in that according to the 3rd quantity information, chooses in each Dynamic Host Configuration Protocol server One Dynamic Host Configuration Protocol server for being used to provide service, including:
At least one the 3rd quantity informations that will be obtained choose maximum the of numerical value according to being ranked up, in the result after sequence The corresponding Dynamic Host Configuration Protocol server of three quantity informations, as the Dynamic Host Configuration Protocol server for providing service.
5. a kind of DynamicHost sets protocol DHCP server selection method, it is characterised in that including:
After Dynamic Host Configuration Protocol server receives the DHCP discovery messages that dhcp client is sent, fed back to the dhcp client DHCP work messages, wherein, the load information comprising the Dynamic Host Configuration Protocol server, the dhcp client in the DHCP work message After receiving DHCP work messages, the load information of the Dynamic Host Configuration Protocol server is determined, and according to the load information for determining, Determine whether the Dynamic Host Configuration Protocol server is for providing the Dynamic Host Configuration Protocol server for servicing;And
When it itself is Dynamic Host Configuration Protocol server that the dhcp client is chosen to determine, sent for true to the dhcp client Recognize the DHCP response messages of address allocation information, wherein the dhcp client is according to DHCP response messages, determine that address is distributed Information.
6. method as claimed in claim 5, it is characterised in that determine whether itself is DHCP that the dhcp client is chosen Server, including:
Receive the DHCP request message sent of dhcp client, wherein in the DHCP request message comprising dhcp client according to Load information, selected in each Dynamic Host Configuration Protocol server is used for the identification information of the Dynamic Host Configuration Protocol server for providing service;
Dynamic Host Configuration Protocol server determines whether the identification information included in the DHCP request message is identical with the identification information of itself, such as It is really identical, it is determined that itself to be Dynamic Host Configuration Protocol server that the dhcp client is chosen, conversely, it itself is not the DHCP visitors to determine The Dynamic Host Configuration Protocol server that family end is chosen.
7. method as claimed in claim 5, it is characterised in that the load information has been carried comprising Dynamic Host Configuration Protocol server First quantity information of dhcp client, and the second quantity information of dhcp client that Dynamic Host Configuration Protocol server maximum can be carried;
After the dhcp client receives DHCP work messages, the load information of the Dynamic Host Configuration Protocol server is determined, including:
According to the difference between the second quantity information and the first quantity information, the DHCP that the Dynamic Host Configuration Protocol server can be carried is determined 3rd quantity information of client.
8. a kind of DynamicHost sets protocol DHCP server selection device, and the device is located at dhcp client side, and its feature exists In, including:
Receiver module, for after DHCP discovery messages are sent, receiving at least one Dynamic Host Configuration Protocol server feedback in setting duration DHCP work messages;
Determining module, the load information of each Dynamic Host Configuration Protocol server for determining to be included in the DHCP work message;
Module is chosen, is used to provide service for according to the load information determined, choosing one in each Dynamic Host Configuration Protocol server Dynamic Host Configuration Protocol server;
The receiver module, is additionally operable to receive the DHCP response messages that the Dynamic Host Configuration Protocol server chosen is sent, and determines address distribution letter Breath.
9. device as claimed in claim 8, it is characterised in that the device also includes:
Broadcast module, for the identification information write-in DHCP request message of the Dynamic Host Configuration Protocol server that will select in, and broadcast described DHCP request message.
10. device as claimed in claim 8, it is characterised in that the load information has been carried comprising Dynamic Host Configuration Protocol server First quantity information of dhcp client, and the second quantity information of dhcp client that Dynamic Host Configuration Protocol server maximum can be carried;
The selection module, specifically for according to the difference between the second quantity information and the first quantity information, determining each DHCP 3rd quantity information of the dhcp client that server can be carried, according to the 3rd quantity information, selects in each Dynamic Host Configuration Protocol server Take one for provide service Dynamic Host Configuration Protocol server.
11. devices as claimed in claim 10, it is characterised in that the selection module, specifically for will obtain at least one Individual 3rd quantity information chooses the 3rd maximum quantity information of numerical value corresponding according to being ranked up in the result after sequence Dynamic Host Configuration Protocol server, as the Dynamic Host Configuration Protocol server for providing service.
A kind of 12. DynamicHosts set protocol DHCP server selection device, and the device is located at Dynamic Host Configuration Protocol server side, and its feature exists In, including:
Sending module, it is anti-to the dhcp client for after the DHCP discovery messages that dhcp client is sent are received Feedback DHCP work messages, wherein, the load information comprising Dynamic Host Configuration Protocol server, the dhcp client in the DHCP work message After receiving DHCP work messages, the load information of Dynamic Host Configuration Protocol server is determined, and according to the load information for determining, it is determined that Whether the Dynamic Host Configuration Protocol server is for providing the Dynamic Host Configuration Protocol server for servicing;And
Determining module, for determining whether itself is Dynamic Host Configuration Protocol server that the dhcp client is chosen;
The sending module, is additionally operable to determine it itself is Dynamic Host Configuration Protocol server that the dhcp client is chosen in determining module When, the DHCP response messages for confirming address allocation information are sent to the dhcp client, wherein the dhcp client According to DHCP response messages, address allocation information is determined.
13. devices as claimed in claim 12, it is characterised in that the device also includes:
Receiver module, for receiving the DHCP request message that dhcp client is sent, wherein being included in the DHCP request message According to load information, selected in each Dynamic Host Configuration Protocol server is used to provide the Dynamic Host Configuration Protocol server of service to dhcp client Identification information;
The determining module, specifically for the identification information that determines to be included in the DHCP request message whether the mark with itself Information is identical, if identical, it is determined that itself be Dynamic Host Configuration Protocol server that the dhcp client is chosen, conversely, determining itself not It is Dynamic Host Configuration Protocol server that the dhcp client is chosen.
A kind of 14. DynamicHosts set protocol DHCP server selection system, it is characterised in that including at least one DHCP client End and at least one Dynamic Host Configuration Protocol server, wherein:
The dhcp client, finds message, and receive in setting duration at least for sending DHCP to the Dynamic Host Configuration Protocol server One DHCP work message of Dynamic Host Configuration Protocol server feedback, determines bearing for each Dynamic Host Configuration Protocol server included in the DHCP work message Information carrying ceases, and according to the load information determined, a Dynamic Host Configuration Protocol server for being used to provide service is chosen in each Dynamic Host Configuration Protocol server, And the DHCP response messages that the Dynamic Host Configuration Protocol server chosen is sent are received, determine address allocation information;
The Dynamic Host Configuration Protocol server, for after the DHCP discovery messages that the dhcp client is sent are received, to described Dhcp client feedback DHCP work messages, wherein, the load information comprising the Dynamic Host Configuration Protocol server in the DHCP work message; And when it itself is Dynamic Host Configuration Protocol server that the dhcp client is chosen to determine, sent for true to the dhcp client Recognize the DHCP response messages of address allocation information.
15. systems as claimed in claim 14, it is characterised in that the dhcp client, are additionally operable to the DHCP that will be selected In the identification information write-in DHCP request message of server, and broadcast the DHCP request message;
The Dynamic Host Configuration Protocol server, specifically for the identification information that determines to be included in the DHCP request message whether the mark with itself Knowledge information is identical, if identical, it is determined that itself be Dynamic Host Configuration Protocol server that the dhcp client is chosen, conversely, determining itself It is not Dynamic Host Configuration Protocol server that the dhcp client is chosen.
16. systems as claimed in claim 14, it is characterised in that the load information has been carried comprising Dynamic Host Configuration Protocol server First quantity information of dhcp client, and the second quantity information of dhcp client that Dynamic Host Configuration Protocol server maximum can be carried;
The dhcp client, specifically for according to the difference between the second quantity information and the first quantity information, it is determined that respectively 3rd quantity information of the dhcp client that Dynamic Host Configuration Protocol server can be carried, according to the 3rd quantity information, in each Dynamic Host Configuration Protocol server It is middle to choose a Dynamic Host Configuration Protocol server for being used to provide service.
17. systems as claimed in claim 16, it is characterised in that the dhcp client, specifically for that will obtain at least One the 3rd quantity information chooses the 3rd maximum quantity information of numerical value corresponding according to being ranked up in the result after sequence Dynamic Host Configuration Protocol server, as the Dynamic Host Configuration Protocol server for providing service.
18. systems as claimed in claim 14, it is characterised in that the system also include at least one be located at dhcp client and Trunking between Dynamic Host Configuration Protocol server, the trunking can be communicated with dhcp client, Dynamic Host Configuration Protocol server respectively;
The trunking, for dhcp client to be broadcast to the message of Dynamic Host Configuration Protocol server by way of unicast message, sends out Give at least one Dynamic Host Configuration Protocol server;And forward each Dynamic Host Configuration Protocol server to be sent to the message of dhcp client.
CN201210576393.1A 2012-12-26 2012-12-26 DynamicHost sets protocol DHCP server selection method, apparatus and system Active CN103905392B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201210576393.1A CN103905392B (en) 2012-12-26 2012-12-26 DynamicHost sets protocol DHCP server selection method, apparatus and system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201210576393.1A CN103905392B (en) 2012-12-26 2012-12-26 DynamicHost sets protocol DHCP server selection method, apparatus and system

Publications (2)

Publication Number Publication Date
CN103905392A CN103905392A (en) 2014-07-02
CN103905392B true CN103905392B (en) 2017-06-20

Family

ID=50996547

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201210576393.1A Active CN103905392B (en) 2012-12-26 2012-12-26 DynamicHost sets protocol DHCP server selection method, apparatus and system

Country Status (1)

Country Link
CN (1) CN103905392B (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105337886A (en) * 2015-11-02 2016-02-17 福建星网锐捷网络有限公司 DHCP address allocation method and DHCP address allocation device
CN106453615A (en) * 2016-11-11 2017-02-22 郑州云海信息技术有限公司 A network communication protocol address configuration method and system
CN114520965B (en) * 2020-11-19 2024-03-01 瑞昱半导体股份有限公司 Wireless relay device and configuration method for wireless relay device
CN113329105B (en) * 2021-06-10 2022-09-06 深圳市炬力北方微电子有限公司 Redundancy method of distributed self-adaptive DHCP service and related equipment

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102244690A (en) * 2011-07-26 2011-11-16 福建星网锐捷网络有限公司 Address allocation method and system of dynamic host configuration protocol (DHCP) as well as client side and servers of same
CN102780790A (en) * 2012-07-13 2012-11-14 深圳市龙视传媒有限公司 Method and system for dynamically allocating IP (Internet Protocol) address
WO2012163178A1 (en) * 2011-07-14 2012-12-06 华为技术有限公司 Method, device, and edge node controller for selecting edge node

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7139816B2 (en) * 2000-12-18 2006-11-21 International Business Machines Corporation Method, apparatus, and program for server based network computer load balancing across multiple boot servers
CN1812398B (en) * 2005-01-26 2010-08-18 华为技术有限公司 Method for realizing DHCP server loading sharing based on DHCP relay
CN101150526B (en) * 2007-11-15 2010-12-01 中国电信股份有限公司 A method and server for realizing load balance service of dynamic host configuration protocol
JP5354637B2 (en) * 2008-01-15 2013-11-27 日本電気株式会社 Communication system, DHCP server, SIP server selection method and program

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2012163178A1 (en) * 2011-07-14 2012-12-06 华为技术有限公司 Method, device, and edge node controller for selecting edge node
CN102244690A (en) * 2011-07-26 2011-11-16 福建星网锐捷网络有限公司 Address allocation method and system of dynamic host configuration protocol (DHCP) as well as client side and servers of same
CN102780790A (en) * 2012-07-13 2012-11-14 深圳市龙视传媒有限公司 Method and system for dynamically allocating IP (Internet Protocol) address

Also Published As

Publication number Publication date
CN103905392A (en) 2014-07-02

Similar Documents

Publication Publication Date Title
CN101692652B (en) Method and device for preventing interrupt of traffics in aggregation link
CN102395144B (en) Wireless access point upgrade method, system thereof and device thereof
CN104243265A (en) Gateway control method, device and system based on virtual machine migration
CN102025630A (en) Load balancing method and load balancing system
CN103929492A (en) Method, devices and system for load balancing of service chain
CN103905392B (en) DynamicHost sets protocol DHCP server selection method, apparatus and system
US10382391B2 (en) Systems and methods for managing network address information
CN108495136A (en) A kind of method and system that direct broadcast service is provided
CN106357542B (en) The method and software defined network controller of multicast service are provided
CN103546315A (en) System, method and equipment for backing up DHCP (dynamic host configuration protocol) server
CN101594258A (en) The method of real-time processing data, system and equipment in a kind of double-machine standby technology
CN104754070A (en) Method and device for learning address resolution protocol table entries and network device
CN101808037B (en) Method and device for traffic management in switch network
CN103401954B (en) The implementation method of virtual DHCP
CN102891851A (en) Access control method, equipment and system of virtual desktop
CN103503413A (en) Method and device for transmitting network information
US20120008627A1 (en) Method and apparatus for assigning device identifier with collision avoidance
CN103716169A (en) Point-to-multipoint multicast realization method, network nodes and system
CN102572012A (en) Message processing method, switchboard and system
CN103441931B (en) A kind of file transmitting method and device
CN105376226A (en) Streaming media server forwarding method and system
EP3481099B1 (en) Load balancing method and associated device
US20170046306A1 (en) Data processing method, processor, and data processing device
CN107306289A (en) A kind of load-balancing method and equipment based on cloud computing
CN106453677A (en) Address allocation method and apparatus

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant