Embodiment
Below in conjunction with the accompanying drawing in the embodiment of the invention, the technical scheme in the embodiment of the invention is clearly and completely described, obviously, described embodiment only is the present invention's part embodiment, rather than whole embodiment.Based on the embodiment among the present invention, those of ordinary skills belong to the scope of protection of the invention not making the every other embodiment that obtains under the creative work prerequisite.
The invention provides a kind of method, authoritative domain name server and caching nameserver that upgrades the domain name system buffer memory.Technical scheme for a better understanding of the present invention describes in detail embodiment provided by the invention below in conjunction with accompanying drawing.
Referring to Fig. 1, Fig. 1 is the method flow diagram of the renewal domain name system buffer memory that provides of the embodiment of the invention one.
The method of the renewal domain name system buffer memory that the embodiment of the invention one provides comprises:
A1, first domain name mapping in detecting self buffer memory are when the content server of correspondence breaks down or load above threshold value as a result, obtain the second domain name mapping result of the domain name of request analysis, the domain name of this request analysis and first domain name mapping be correspondence as a result, and second domain name mapping operating state of the content server of correspondence as a result is normal.
Concrete, be cached with the first domain name mapping result in the authoritative domain name server, authoritative domain name server detect first domain name mapping as a result the content server of correspondence break down or load when surpassing threshold value, obtain the second domain name mapping result of the domain name of request analysis.
Wherein, the domain name of request analysis and first domain name mapping be correspondence as a result, and second domain name mapping operating state of the content server of correspondence as a result is normal.Wherein, the operating state of content server can be understood as normally that content server is current not to break down, and can provide content service for user terminal normally.In addition, the thresholding of the load of content server can be determined flexibly according to actual conditions.
A2, send the domain name mapping updating message to the domain name corresponding cache name server of request analysis, carry the domain name of above-mentioned request analysis in the domain name mapping updating message, this domain name mapping updating message is used to indicate caching nameserver the first domain name mapping result of buffer memory is updated to the second domain name mapping result.
Concrete, authoritative domain name server is after obtaining the second domain name mapping result, to the domain name corresponding cache name server transmission domain name mapping updating message of request analysis.
Wherein, the authoritative domain name server address that can obtain the corresponding cache name server according to the corresponding relation of the domain name of request analysis and caching nameserver.The domain name corresponding cache name server of request analysis had all sent the domain name mapping request at this domain name to authoritative domain name server.
Need to prove that the domain name of request analysis can corresponding a plurality of caching nameservers, namely a plurality of caching nameservers of the domain name of corresponding same request analysis all can receive the domain name mapping updating message.
Caching nameserver is updated to the second domain name mapping result with the first domain name mapping result in self buffer memory, can follow-up receive the domain name mapping request after, the second domain name mapping result of buffer memory is sent to terminal, thereby make terminal to second domain name mapping content server request content of correspondence as a result.
The method of the renewal domain name system buffer memory that the embodiment of the invention provides can be applied in first domain name mapping as a result the content server of correspondence break down or load in the scene above threshold value, the embodiment of the invention is by sending the domain name mapping updating message to caching nameserver, make that the first domain name mapping result of caching nameserver deletion self buffer memory is the second domain name mapping result, avoid returning the first wrong domain name mapping result to terminal.Caching nameserver is after the domain name mapping request that receives terminal subsequently, return the second domain name mapping result to terminal, and second domain name mapping content server operating state of correspondence is normal as a result, terminal can be to the normal content server request content of operating state.
Referring to Fig. 2, authoritative domain name server specifically can comprise in the step of execution to the domain name corresponding cache name server transmission domain name mapping updating message of request analysis in the embodiment of the invention one:
B1, in self buffer memory, search address with the domain name corresponding cache name server of request analysis according to the corresponding relation of preserving in advance.
Concrete, authoritative domain name server is according to the corresponding relation of preserving in advance, be the domain name of request analysis and the corresponding relation between the caching nameserver, in self buffer memory, search the address with the domain name corresponding cache name server of request analysis, the IP address that obtains this caching nameserver.
B2, send the domain name mapping updating message to the caching nameserver that finds.
Concrete, authoritative domain name server sends the domain name mapping updating message according to the IP address of caching nameserver to the caching nameserver that finds, so that receive the domain name mapping result of caching nameserver deletion self buffer memory of updating message.
Further, also comprise buffer update indication information and the second domain name mapping result in the domain name mapping updating message that the embodiment of the invention provides.The buffer update indication information is used to indicate caching nameserver the first domain name mapping result of buffer memory is updated to the second domain name mapping result.Caching nameserver is deleted the first domain name mapping result of self buffer memory according to this renewal indication information after receiving the domain name mapping updating message.
Referring to Fig. 3, Fig. 3 is the method flow diagram of the renewal domain name system buffer memory that provides of the embodiment of the invention two.
In embodiments of the present invention, terminal sends domain name mapping request, the domain name of carried terminal request analysis in this domain name mapping request to caching nameserver.Caching nameserver sends the domain name mapping request to authoritative domain name server.
The method of the renewal domain name system buffer memory that the embodiment of the invention two provides can comprise:
C1, receive the domain name mapping request that caching nameserver sends, comprise the domain name of request analysis in this domain name mapping request.
Concrete, authoritative domain name server receives the domain name mapping request that caching nameserver sends, and comprises the domain name of request analysis in this domain name mapping request.
The domain name mapping request that C2, basis receive is resolved the domain name of request analysis, obtains the first domain name mapping result.
Concrete, authoritative domain name server is resolved the domain name of request analysis according to the domain name mapping request that receives, and obtains the first domain name mapping result.Wherein, comprise the address of content server of this domain name correspondence and this first domain name mapping result's life span among the first domain name mapping result.In embodiments of the present invention, the first domain name mapping result's life span is called first life span.
Corresponding relation between the domain name of C3, the buffer memory first domain name mapping result and request analysis, and the domain name of request analysis and the corresponding relation between the caching nameserver, send the domain name mapping response to this caching nameserver, comprise the domain name of the first domain name mapping result and request analysis in this domain name mapping response.
Concrete, authoritative domain name server is carried out buffer memory with domain name and the corresponding relation between the caching nameserver of the corresponding relation between the domain name of the first domain name mapping result and request analysis, request analysis.Wherein, the time of the above-mentioned corresponding relation of authoritative domain name server buffer memory can come to determine flexibly as required, for example in second or hour calculate.
Authoritative domain name server also sends the domain name mapping response according to the domain name mapping request to caching nameserver, comprises the domain name of this first domain name mapping result and request analysis in the domain name mapping response.
Wherein, after caching nameserver receives domain name mapping response, send the first domain name mapping result to the terminal of correspondence, make terminal according to visiting corresponding content server according to the first domain name mapping result.
C4, first domain name mapping in detecting self buffer memory content server of correspondence are as a result broken down or are loaded above threshold value, obtain the second domain name mapping result of the domain name of request analysis, the domain name of this request analysis and first domain name mapping be correspondence as a result, and this second domain name mapping operating state of the content server of correspondence as a result is normal.
In embodiments of the present invention, authoritative domain name server is after sending the domain name mapping response to the corresponding cache name server, if subsequently detect first domain name mapping as a result the content server of correspondence break down or load above threshold value, then authoritative domain name server is carried out domain name mapping again to the domain name of request analysis, obtain the second domain name mapping result of the domain name of request analysis, second domain name mapping content server current working state of correspondence as a result is normal.
C5, send the domain name mapping updating message to the domain name corresponding cache name server of request analysis, carry the domain name of above-mentioned request analysis in the domain name mapping updating message, this domain name mapping updating message is used to indicate caching nameserver the first domain name mapping result of buffer memory is updated to the second domain name mapping result.
Concrete, authoritative domain name server is after obtaining the second domain name mapping result, to the domain name corresponding cache name server transmission domain name mapping updating message of request analysis.
Wherein, the authoritative domain name server address that can obtain the corresponding cache name server according to the corresponding relation of the domain name of request analysis and caching nameserver.The domain name corresponding cache name server of request analysis had all sent the domain name mapping request at this domain name to authoritative domain name server.Need to prove that the domain name of request analysis can corresponding a plurality of caching nameservers, namely a plurality of caching nameservers of the domain name of corresponding same request analysis all can receive the domain name mapping updating message.
In embodiments of the present invention, carry the domain name of request analysis in the domain name mapping updating message that authoritative domain name server sends, the domain name mapping updating message is used to indicate caching nameserver the first domain name mapping result of buffer memory is updated to the second domain name mapping result.
Caching nameserver is updated to the second domain name mapping result with the first domain name mapping result in self buffer memory, can follow-up receive the domain name mapping request after, the second domain name mapping result of buffer memory is sent to terminal, thereby make terminal to second domain name mapping content server request content of correspondence as a result.
Further, the embodiment of the invention two can also be after the first domain name mapping result's first life span be overtime, automatically delete the first domain name mapping result in self buffer memory and the address of caching nameserver, not only spatial cache can be saved, the performance of authoritative domain name server can also be improved.
The method of the renewal domain name system buffer memory that provides in the embodiment of the invention two can also be carried out following steps:
C6, the first domain name mapping result in self buffer memory is updated to the second domain name mapping result.
Concrete, authoritative domain name server can also be after obtaining the second domain name mapping result corresponding with the domain name of request analysis, and the first domain name mapping result in self buffer memory is updated to the second domain name mapping result.
Need to prove that the execution sequence between above-mentioned steps C5 and the step C6 is that time slot is irrelevant, its priority execution sequence does not constitute the restriction to the embodiment of the invention.
In the method for the renewal domain name system buffer memory that the embodiment of the invention one, two provides, authoritative domain name server detect domain name mapping as a result the content server of correspondence break down can be in the following way:
1) receives the domain name mapping fault reporting message of the content server transmission of correspondence as a result, judge that then content server breaks down.
Concrete, authoritative domain name server judges then that receiving first domain name mapping fault reporting message of the content server transmission of correspondence as a result this content server breaks down.
2) in preset time, do not receive the domain name mapping state reporting message of the content server transmission of correspondence as a result, judge that content server breaks down.
Concrete, authoritative domain name server does not receive first domain name mapping state reporting message of the content server transmission of correspondence as a result in preset time, judge that then content server breaks down.Wherein, preset time can be determined according to concrete content server.
It is pointed out that the above two kinds of possible state obtain manners that only provide, authoritative domain name server knows that whether breaking down of content server can also have other implementation.
Referring to Fig. 4, Fig. 4 is the flow chart of the method for the renewal domain name system buffer memory that provides of the embodiment of the invention three.
The method of the renewal domain name system buffer memory that the embodiment of the invention three provides mainly comprises:
D1, first domain name mapping in detecting self buffer memory are when the content server of correspondence breaks down or load above threshold value as a result, generate the domain name mapping result and delete message, this domain name mapping result deletes the first domain name mapping result that message is used for deletion caching nameserver buffer memory, this domain name mapping result deletes the domain name of carrying request analysis in the message, the domain name correspondence of the first domain name mapping result and request analysis.
Concrete, authoritative domain name server is cached with the first domain name mapping result, authoritative domain name server is when detecting first domain name mapping content server of correspondence breaks down or load above threshold value as a result, then generate the domain name mapping result and delete message, the domain name mapping result deletes the first domain name mapping result that message is used for deletion caching nameserver buffer memory.Wherein, the domain name mapping result deletes the domain name of carrying request analysis in the message, has corresponding relation between the first domain name mapping result of buffer memory and the domain name of request analysis.
D2, send the domain name mapping result to caching nameserver and delete message, so that the first domain name mapping result in this caching nameserver deletion self buffer memory, the domain name correspondence of caching nameserver and request analysis.
Concrete, authoritative domain name server sends this message to the domain name corresponding cache name server of request analysis after generating the domain name mapping result and deleting message.The domain name that it is pointed out that request analysis can corresponding a plurality of caching nameservers.
Caching nameserver is receiving after the domain name mapping result deletes message, with the first corresponding domain name mapping result of the domain name with request analysis in deletion self buffer memory.After the first domain name mapping result of caching nameserver in self buffer memory of deletion, can follow-up receive the domain name mapping request after, again to authoritative domain name server request domain name analysis result, and then obtain correct domain name mapping result.
The method of the renewal domain name system buffer memory that the embodiment of the invention provides can be applied in first domain name mapping as a result the content server of correspondence break down or load and be higher than in the scene of default thresholding, the embodiment of the invention is deleted message by sending the domain name mapping result to caching nameserver, make caching nameserver delete the first domain name mapping result of buffer memory, avoid returning the first wrong domain name mapping result to terminal.Caching nameserver is after the domain name mapping request that receives terminal subsequently, again to the correct domain name mapping result of authoritative domain name server request, correct domain name mapping result is sent to caching nameserver, and then make that terminal can be to correct content server request content.
Referring to Fig. 5, authoritative domain name server specifically can comprise to the step (step D2) that caching nameserver transmission domain name mapping result deletes message in execution in the embodiment of the invention three:
E1, in self buffer memory, search address with the domain name corresponding cache name server of request analysis according to the corresponding relation of preserving in advance.
Concrete, authoritative domain name server is according to the corresponding relation of preserving in advance, the i.e. domain name of the corresponding relation between the domain name of the first domain name mapping result and request analysis, request analysis and the corresponding relation between the caching nameserver, in self buffer memory, search and first domain name mapping address of corresponding cache name server as a result, the IP address that obtains this caching nameserver.
E2, send the domain name mapping result to the caching nameserver that finds and delete message.
Concrete, authoritative domain name server is deleted message according to the IP address of caching nameserver to the caching nameserver transmission domain name result who finds, so that receive caching nameserver deletion self the first domain name mapping result corresponding with domain name request analysis buffer memory of this deletion message.
Referring to Fig. 6, Fig. 6 is the method flow diagram of the renewal domain name system buffer memory that provides of the embodiment of the invention four.
In embodiments of the present invention, terminal sends the domain name mapping request to caching nameserver, carries the domain name of request analysis in this domain name mapping request.Caching nameserver sends the domain name mapping request to authoritative domain name server.
The method of the renewal domain name system buffer memory that the embodiment of the invention four provides can comprise:
F1, receive the domain name mapping request that caching nameserver sends, comprise the domain name of request analysis in this domain name mapping request.
Concrete, authoritative domain name server receives the domain name mapping request that caching nameserver sends, and comprises the domain name of request analysis in this domain name mapping request.
F2, according to this domain name mapping request the domain name of request analysis is resolved, obtain the first domain name mapping result.
Concrete, authoritative domain name server is resolved the domain name of request analysis according to the domain name mapping request that receives, and obtains the first domain name mapping result.Wherein, comprise the address of content server of this domain name correspondence and this first domain name mapping result's life span among the first domain name mapping result.In embodiments of the present invention, the first domain name mapping result's life span is called first life span.
Corresponding relation between the domain name of F3, this first domain name mapping result of buffer memory and request analysis and the domain name of request analysis and the corresponding relation between this caching nameserver, send the domain name mapping response to this caching nameserver, comprise the domain name of the first domain name mapping result and request analysis in this domain name mapping response.
Concrete, authoritative domain name server is carried out buffer memory with the domain name of the corresponding relation between the domain name of the first domain name mapping result and request analysis, request analysis and the corresponding relation that sends between the caching nameserver of domain name mapping request.Wherein, the time of the above-mentioned corresponding relation of authoritative domain name server buffer memory can come to determine flexibly as required, for example in second or hour calculate.The embodiment of the invention is by the above-mentioned corresponding relation of buffer memory, domain name mapping that can be in detecting self buffer memory is when the content server of correspondence breaks down as a result, obtain the address of corresponding cache name server according to the corresponding relation of buffer memory, so that upgrade the domain name mapping result of buffer memory in this caching nameserver.
Authoritative domain name server also sends the domain name mapping response according to the domain name mapping request to caching nameserver, comprises the domain name of this first domain name mapping result and request analysis in the domain name mapping response.
Wherein, after caching nameserver receives domain name mapping response, send the first domain name mapping result to the terminal of correspondence, terminal is visited corresponding content server according to the first domain name mapping result.
F4, detect first domain name mapping as a result the content server of correspondence break down or load above threshold value, generate the domain name mapping result and delete message, this domain name mapping result deletes message and is used for the first domain name mapping result that the deletion caching nameserver carries, the domain name mapping result deletes the domain name of carrying request analysis in the message, the domain name correspondence of this first domain name mapping result and request analysis.
Wherein, domain name mapping result deletes message and is used for the first domain name mapping result that the deletion caching nameserver carries.The domain name mapping result deletes the domain name of carrying request analysis in the message, has corresponding relation between the first domain name mapping result of buffer memory and the domain name of request analysis.
F5, send domain name mapping result to this caching nameserver and delete message, so that the first domain name mapping result in this caching nameserver deletion self buffer memory, the domain name correspondence of this caching nameserver and request analysis.
Concrete, authoritative domain name server can generate the domain name mapping result delete message after, send this message to the domain name corresponding cache name server of request analysis.It is to be noted, the domain name of request analysis can corresponding a plurality of caching nameservers, authoritative domain name server can send the domain name mapping results to a plurality of caching nameservers delete message, and then makes the first domain name mapping result in a plurality of caching nameservers deletions self buffer memory.
Caching nameserver is receiving after the domain name mapping result deletes message, with the first corresponding domain name mapping result of the domain name with request analysis in deletion self buffer memory.After the first domain name mapping result of caching nameserver in deletion self buffer memory, can follow-up receive the domain name mapping request of terminal pins to this request analysis after, again to authoritative domain name server request domain name analysis result, and then obtain correct domain name mapping result.
In the method for the renewal domain name system buffer memory that the embodiment of the invention three, four provides, authoritative domain name server detect domain name mapping as a result the content server of correspondence break down can be in the following way:
1) receives the domain name mapping fault reporting message of the content server transmission of correspondence as a result, judge that then content server breaks down.
Concrete, authoritative domain name server judges then that receiving first domain name mapping fault reporting message of the content server transmission of correspondence as a result this content server breaks down.
2) in preset time, do not receive the domain name mapping state reporting message of the content server transmission of correspondence as a result, judge that content server breaks down.
Concrete, authoritative domain name server does not receive first domain name mapping state reporting message of the content server transmission of correspondence as a result in preset time, judge that then content server breaks down.Wherein, preset time can be determined according to concrete content server.
It is pointed out that the above two kinds of possible obtain manners that only provide, authoritative domain name server knows that whether breaking down of content server can also have other implementation.
More than from authoritative domain name server one side the method for the update system buffer memory that the embodiment of the invention provides has been described, the method for the update system buffer memory that the embodiment of the invention provides is described from domain name caching server one side below.
Referring to Fig. 7, Fig. 7 is the flow chart of the method for the renewal domain name system buffer memory that provides of the embodiment of the invention five.
In the embodiment of the invention five, comprise the domain name of request analysis and the first domain name mapping result of this domain name correspondence in self buffer memory of caching nameserver.The domain name mapping of authoritative domain name server buffer memory in needs deletion self buffer memory domain name service is as a result the time, for example detect first domain name mapping as a result the content server of correspondence break down or load and be higher than default thresholding, then send the domain name mapping updating message to caching nameserver.The method of the renewal domain name system buffer memory that the embodiment of the invention five provides can comprise:
The domain name mapping updating message that G1, reception authoritative domain name server send, this domain name mapping updating message is used to indicate caching nameserver the first domain name mapping result of buffer memory is updated to the second domain name mapping result, carries the domain name of request analysis in this domain name mapping updating message.
Concrete, caching nameserver receives the domain name mapping updating message that authoritative domain name server sends, this domain name mapping updating message is used to indicate caching nameserver the first domain name mapping result of buffer memory is updated to the second domain name mapping result, carries the domain name of request analysis in the domain name mapping updating message.
Wherein, the caching nameserver first domain name mapping result that can in self buffer memory, upgrade to needs according to the domain name lookup of this request analysis.
G2, the first domain name mapping result in self buffer memory is updated to the second domain name mapping result, the domain name correspondence of this first domain name mapping result and request analysis.
Concrete, caching nameserver is updated to the second domain name mapping result according to upgrading indication information with first corresponding with the domain name of request analysis in the buffer memory domain name mapping result.
In embodiments of the present invention, caching nameserver is by being updated to the second domain name mapping result with the first domain name mapping result corresponding with the domain name of request analysis in self buffer memory, can be after receiving the domain name mapping request subsequently, with the domain name mapping result who upgrades, namely the second domain name mapping result sends to terminal.Compare with prior art, the embodiment of the invention can avoid terminal to the content server request content that breaks down by the domain name mapping result in deletion self buffer memory, further makes terminal to current available content server request content.
Further, also comprise life span among the second domain name mapping result of buffer memory in the caching nameserver, the second domain name mapping result's life span is called second life span in embodiments of the present invention, and then the embodiment of the invention can also comprise:
G3, after second life span is overtime, delete the second domain name mapping result in self buffer memory.
The embodiment of the invention not only can be saved the cache resources of caching nameserver by the second domain name mapping result of deletion above life span, can also make terminal obtain newer domain name mapping result.
Referring to Fig. 8, caching nameserver is specifically as follows the process (above-mentioned steps G2) that the first domain name mapping result in self buffer memory is updated to the second domain name mapping result in the embodiment of the invention five:
H1, in self buffer memory, search the first domain name mapping result corresponding with the domain name of request analysis according to the corresponding relation of preserving in advance.
Concrete, caching nameserver is according to the corresponding relation of preserving in advance, i.e. corresponding relation between the domain name of request analysis and the first domain name mapping result is searched the first domain name mapping result corresponding with the domain name of request analysis in self buffer memory.
Wherein, preserve the domain name of request analysis and the corresponding relation between the first domain name mapping result in the caching nameserver in advance.Caching nameserver can be after receiving the domain name mapping response that authoritative domain name server sends, and preserves the corresponding relation between the domain name of the first domain name mapping result in the domain name mapping response and request analysis in advance.
H2, the first domain name mapping result that will find are updated to the second domain name mapping result.
Concrete, the first domain name mapping result that caching nameserver will find is updated to the second domain name mapping result.
Referring to Fig. 9, Fig. 9 is the flow chart of the method for the renewal domain name system buffer memory that provides of the embodiment of the invention six.
In the embodiment of the invention six, comprise the domain name of request analysis and the first domain name mapping result of this domain name correspondence in self buffer memory of caching nameserver.The domain name mapping of authoritative domain name server buffer memory in needs deletion self caching nameserver is as a result the time, for example detect this first domain name mapping as a result the content server of correspondence break down or load and be higher than default thresholding, then send the domain name mapping result to caching nameserver and delete message.The method of the renewal domain name system buffer memory that the embodiment of the invention six provides can comprise:
The domain name mapping result that J1, reception authoritative domain name server send deletes message, this domain name mapping result deletes the domain name of carrying request analysis in the message, this domain name mapping result deletes message and is used for the first domain name mapping result that the deletion caching nameserver carries, the domain name correspondence of this first domain name mapping result and request analysis.
Concrete, the domain name mapping result that caching nameserver receives the authoritative domain name server transmission deletes message, this domain name mapping result deletes the domain name of carrying request analysis in the message, the domain name mapping result deletes message and is used for the first domain name mapping result that the deletion caching nameserver carries, the domain name correspondence of the first domain name mapping result and request analysis.
J2, delete the first domain name mapping result corresponding with the domain name of request analysis in self buffer memory.
Concrete, caching nameserver is deleted the first domain name mapping result corresponding with the domain name of request analysis according to this domain name mapping result information of deleting from buffer memory.
In embodiments of the present invention, if first domain name mapping content server of correspondence is as a result broken down or is loaded above default thresholding, caching nameserver is by the first domain name mapping result corresponding with the domain name of this request analysis in deletion self buffer memory, thereby after receiving the domain name mapping request subsequently, judge and do not have corresponding domain name mapping result in the buffer memory, then again to authoritative domain name server request domain name analysis result, namely send the domain name mapping request to authoritative domain name server, and then the domain name mapping result who to upgrade from authoritative domain name server, caching nameserver then sends the domain name mapping result that upgrades to the terminal of correspondence.
Compared with prior art, the embodiment of the invention can be avoided sending the address that exists fault or load to surpass the content server of thresholding to terminal, can avoid terminal to the content server request content that breaks down or load above thresholding, on the contrary can so that terminal to current available content server request content.
Further, in the method for the renewal domain name system buffer memory that the embodiment of the invention six provides, the first domain name mapping result's corresponding with the domain name of request analysis step (step J2) can be revised as 0 by the first domain name mapping result's that the domain name of request analysis is corresponding life span in caching nameserver deletion self buffer memory, be about to first life span and be revised as 0, caching nameserver will be deleted this first domain name mapping result automatically.
Referring to Figure 10, the first domain name mapping result's corresponding with the domain name of request analysis process (above-mentioned steps F2) in caching nameserver deletion self buffer memory in the embodiment of the invention six is specifically as follows:
L1, in self buffer memory, search the first domain name mapping result corresponding with the domain name of request analysis according to the corresponding relation of preserving in advance.
Concrete, caching nameserver is according to the corresponding relation of preserving in advance, i.e. corresponding relation between the domain name of request analysis and the first domain name mapping result is searched the first domain name mapping result corresponding with the domain name of request analysis in self buffer memory.
Wherein, preserve the domain name of request analysis and the corresponding relation between the first domain name mapping result in the caching nameserver in advance.Caching nameserver can be after receiving the domain name mapping response that authoritative domain name server sends, and preserves the corresponding relation between the domain name of the first domain name mapping result in the domain name mapping response and request analysis in advance.
L2, the first domain name mapping result deletion that will find.
Concrete, the first domain name mapping result deletion that caching nameserver will find.
More than the method for renewal domain name system buffer memory that the embodiment of the invention is provided describe in detail, for understanding the embodiment of the invention in more detail, provide the concrete application scenarios that the embodiment of the invention is upgraded the method for domain name system buffer memory below.
Referring to Figure 11, Figure 11 is the application scenarios figure of the method for the renewal domain name system buffer memory that provides of the embodiment of the invention seven.
Among this embodiment, certain content supplier (domain name is www.abc.com) disposes 2 content server Server1 and Server2 in certain zone, authoritative domain name server is in charge of the state of Server1 and Server2, Server1 and Server2 periodically send the state reporting message to authoritative domain name server under situation working properly.Local DNS is this regional caching nameserver, has some user terminals, for example UE1 and UE2 in this zone.
The method of the renewal domain name system buffer memory that the embodiment of the invention seven provides mainly comprises:
S1, Local DNS receive the domain name mapping request that UE1 sends.
In the embodiment of the invention seven, carry the domain name www.abc.com of request analysis and the address of terminal in the domain name mapping request that UE1 sends.
S2, Local DNS send the domain name mapping request to authoritative domain name server.
Concrete, Local DNS does not have this domain name of buffer memory www.abc.com correspondence in this locality domain name mapping is as a result the time, send domain name mapping request, the address of carrying domain name www.abc.com and the caching nameserver of request analysis in this domain name mapping request to authoritative domain name server.Wherein, the address of caching nameserver can be the IP address of caching nameserver.
S3, authoritative domain name server are carried out domain name mapping according to the domain name mapping request, obtain the first domain name mapping result.
Concrete, authoritative domain name server can be searched the first domain name mapping result corresponding with the domain name of request analysis, comprises the address of content server among the first domain name mapping result.In embodiments of the present invention, working properly as Server1, can think when user terminal provides content service, comprise the address ip1 of Server1 and the first domain name mapping result's life span among the first domain name mapping result.
Corresponding relation between the domain name of the corresponding relation between the domain name of S4, the authoritative domain name server buffer memory first domain name mapping result and request analysis, the address of Local DNS and request analysis, and to Local DNS transmission domain name mapping response.
Concrete, authoritative domain name server sends the domain name mapping response according to the domain name mapping request that receives to Local DNS, carries the first domain name mapping result in this domain name mapping response.
The corresponding relation of authoritative domain name server between the caching nameserver of the domain name of the corresponding relation between the domain name of self buffer memory first domain name mapping result and request analysis, request analysis and request domain name analysis.In embodiments of the present invention, authoritative domain name server between the address of self buffer memory domain name www.abc.com and LocalDNS corresponding relation and the corresponding relation between domain name www.abc.com and the first domain name mapping result.
S5, authoritative domain name server send the domain name mapping response to Local DNS.
Concrete, authoritative domain name server sends the domain name mapping response according to the domain name mapping request to Local DNS, wherein carries the first domain name mapping result.
S6, the response of Local DNS acceptance domain name analysis, the buffer memory first domain name mapping result.
S7, Local DNS send the domain name mapping response to UE1, wherein carry the first domain name mapping result.
S8, UE1 according to the first domain name mapping result to content server S erver1 request content.
S9-S10, authoritative domain name server detect Server1 and break down, and obtain the second domain name mapping result.
Concrete, authoritative domain name server receives the fault reporting message that Server1 sends, or judges the Server1 fault after not receiving the state reporting message of Server1 in the preset time, obtains the second domain name mapping result.In embodiments of the present invention, authoritative domain name server is at the fault reporting message that does not receive Server 2 transmissions or receive the state reporting message that Server 2 sends in preset time, the state of then judging Server 2 is normal, obtains the IP address of Server2.The IP address and second life span that comprise server2 among the second domain name mapping result.
S11, authoritative domain name server are updated to the second domain name mapping result with the first domain name mapping result corresponding with www.abc.com in self buffer memory.
Authoritative domain name server is searched the first domain name mapping result of www.abc.com correspondence in self buffer memory in the embodiment of the invention seven, the first domain name mapping result is updated to the second domain name mapping result, comprise that specifically the address with the Server1 among the first domain name mapping result is updated to the address of Server 2, and the first domain name mapping result's life span (i.e. first life span) is updated to the second domain name mapping result's life span (i.e. second life span).
S12, authoritative domain name server send the domain name mapping updating message to Local DNS, comprise buffer update indication information, the second domain name mapping result and domain name www.abc.com in the domain name mapping updating message.
Concrete, the domain name mapping updating message can be the newly-increased type of message of the embodiment of the invention, comprises buffer update indication information, the second domain name mapping result and domain name www.abc.com in this message.
Wherein, the life span (second life span) that comprises the address of the address of Server 2 and Server 2 among the second domain name mapping result.
S13, Local DNS acceptance domain name analysis updating message are updated to the second domain name mapping result with first corresponding with Server1 in the buffer memory domain name mapping result.
In embodiments of the present invention, Local DNS is updated to the second domain name mapping result with first corresponding with domain name www.abc.com in the buffer memory domain name mapping result.Renewal process comprises that specifically the address of the Server1 among the first domain name mapping result just is updated to the address of Server 2, and the first domain name mapping result's life span (i.e. first life span) is updated to the second domain name mapping result's life span (i.e. second life span).
Whether wherein, Local DNS also can authenticate the legitimacy of this updating message after receiving the domain name mapping updating message, for example, the IP address of transmit leg is authenticated, consistent with the source IP address that sent the domain name mapping response last time.Authoritative domain name server can also be carried the authentication code that generates according to certain key simultaneously, and the cryptographic algorithm of key and use can return to Local DNS in advance in the domain name mapping response message.After Local DNS receives the domain name mapping updating message, according to the password that obtains in advance and cryptographic algorithm, recomputate authentication code, judge whether the authentication code that receives is consistent with the authentication code that calculates, if it is consistent, then authentication is passed through, according to the first domain name mapping result of the deletion of the indication information in the domain name mapping updating message self buffer memory.
The embodiment of the invention can strengthen the fail safe of domain name system by increasing the legitimacy authentication to the domain name mapping updating message.
In the embodiment of the invention seven, UE2 can be to Local DNS request domain name analysis.
S14, Local DNS receive the domain name mapping request that UE2 sends.
In embodiments of the present invention, carry the domain name www.abc.com of request analysis in the domain name mapping request that UE2 sends.
S15, Local DNS obtain the analysis result of this domain name in self buffer memory, return domain name mapping response, the address of wherein carrying Server 2 to UE2.
Wherein, Local DNS searches the domain name mapping result corresponding with domain name www.abc.com in self buffer memory, be the second domain name mapping result in embodiments of the present invention, wherein comprises the address of Server 2.
S16, UE2 according to the second domain name mapping result to content server S erver 2 request contents.
In embodiments of the present invention, the operating state of Server is normal, and UE2 can be to the required content of Server 2 requests.
In embodiments of the present invention, Local DNS and the authoritative domain name server domain name mapping result in the overtime back of TTL deletion self buffer memory.Local DNS is behind deletion domain name mapping result, if after receiving the domain name mapping request again, do not exist this domain name mapping result then in the buffer memory this moment, send the domain name mapping request to authoritative domain name server, authoritative domain name server is then carried out domain name mapping according to the domain name mapping request, return the result of domain name mapping, and the result of domain name mapping is carried out buffer memory.After Local DNS receives the domain name mapping result, carry out this domain name mapping of buffer memory result in this locality, and return the domain name mapping result and give the requesting users terminal.
The method of the renewal domain name system buffer memory that the embodiment of the invention seven provides can still used on the former TTL manufacturing basis, and the result of the domain name mapping of buffer memory avoids terminal request content service failure or service delay on the Local DNS that upgrades in time.
More than the method for renewal domain name system buffer memory that the embodiment of the invention is provided have been described in detail.
Referring to Figure 12, Figure 12 is the structural representation of the authoritative domain name server that provides of the embodiment of the invention eight.
The authoritative domain name server that the embodiment of the invention eight provides comprises:
Analysis result acquiring unit 110, be used in first domain name mapping that detects self buffer memory when the content server of correspondence breaks down or load above threshold value as a result, obtain the second domain name mapping result of the domain name of request analysis, the domain name of this request analysis and this first domain name mapping be correspondence as a result, and this second domain name mapping operating state of the content server of correspondence as a result is normal;
Updating message transmitting element 120, be used for sending the domain name mapping updating message to the domain name corresponding cache name server of request analysis, carry the domain name of request analysis in this domain name mapping updating message, this domain name mapping updating message is used to indicate this caching nameserver the first domain name mapping result of buffer memory is updated to the second domain name mapping result.
Wherein, the authoritative domain name server that the embodiment of the invention eight provides can be used in the method embodiment one of the renewal domain name system buffer memory of aforementioned correspondence, and details are referring to the description of above-described embodiment one.The authoritative domain name server that the embodiment of the invention provides is by sending the domain name mapping updating message to caching nameserver, make that the first domain name mapping result of caching nameserver deletion self buffer memory is the second domain name mapping result, avoid returning the first wrong domain name mapping result to terminal.Caching nameserver is after the domain name mapping request that receives terminal subsequently, return the second domain name mapping result to terminal, and second domain name mapping content server operating state of correspondence is normal as a result, terminal can be to the normal content server request content of operating state.
The authoritative domain name server that the embodiment of the invention eight provides can also comprise:
First updating block 130 is used for after above-mentioned analysis result acquiring unit 110 obtains the second domain name mapping result of domain name of request analysis, and the first domain name mapping result in self buffer memory is updated to the second domain name mapping result.
Referring to Figure 13, Figure 13 is the structural representation of the authoritative domain name server that provides of the embodiment of the invention nine.
The authoritative domain name server that the embodiment of the invention nine provides comprises:
First receiving element 210 is used for receiving the domain name mapping request that caching nameserver sends, and comprises the domain name of request analysis in this domain name mapping request;
Domain name mapping unit 220 is used for according to this domain name mapping request the domain name of request analysis being resolved, and obtains the first domain name mapping result;
Buffer unit 230 is for corresponding relation and the domain name of request analysis and the corresponding relation between this caching nameserver between the domain name of this first domain name mapping result of buffer memory and request analysis;
Resolution response transmitting element 240 is used for sending the domain name mapping response to this caching nameserver, comprises the domain name of the above-mentioned first domain name mapping result and above-mentioned request analysis in this domain name mapping response;
Analysis result acquiring unit 250, be used in first domain name mapping that detects self buffer memory when the content server of correspondence breaks down or load above threshold value as a result, obtain the second domain name mapping result of the domain name of request analysis, the domain name of request analysis and above-mentioned first domain name mapping be correspondence as a result, and this second domain name mapping operating state of the content server of correspondence as a result is normal;
Updating message transmitting element 260, be used for sending the domain name mapping updating message to the domain name corresponding cache name server of request analysis, carry the domain name of above-mentioned request analysis in this domain name mapping updating message, this domain name mapping updating message is used to indicate this caching nameserver the first domain name mapping result of buffer memory is updated to the second domain name mapping result.
Wherein, the authoritative domain name server that the embodiment of the invention nine provides can be used in the method embodiment two of the renewal domain name system buffer memory of aforementioned correspondence, and details are referring to the description of above-described embodiment two.
Further, the authoritative domain name server that provides of the embodiment of the invention nine also comprises:
First updating block 270 is used for after analysis result acquiring unit 250 obtains the second domain name mapping result of domain name of request analysis, and the first domain name mapping result in self buffer memory is updated to the second domain name mapping result.
Referring to Figure 14, Figure 14 is the structural representation of updating message transmitting element in the authoritative domain name server that provides of the embodiment of the invention nine.
Updating message transmitting element 260 can comprise in the authoritative domain name server that the embodiment of the invention nine provides:
First searches module 261, is used for searching address with the domain name corresponding cache name server of request analysis according to the corresponding relation of preserving in advance at self buffer memory;
Updating message sending module 262, be used for sending the domain name mapping updating message to the caching nameserver that finds, carry the domain name of request analysis in this domain name mapping updating message, this domain name mapping updating message is used to indicate this caching nameserver the first domain name mapping result of buffer memory is updated to the above-mentioned second domain name mapping result.
The concrete structure of the updating message transmitting element 260 among the concrete structure that it is pointed out that the updating message transmitting element 120 that the embodiment of the invention eight provides and the embodiment nine is identical, is not described in detail here.
Be the structural representation of the authoritative domain name server that provides of the embodiment of the invention ten referring to 15, Figure 15.
The authoritative domain name server that the embodiment of the invention ten provides can comprise:
Deletion message generation unit 310, be used in first domain name mapping that detects self buffer memory when the content server of correspondence breaks down or load above threshold value as a result, generate the domain name mapping result and delete message, this domain name mapping result deletes message and is used for the first domain name mapping result that the deletion caching nameserver carries, this domain name mapping result deletes the domain name of carrying request analysis in the message, and the domain name of request analysis and above-mentioned first domain name mapping be correspondence as a result;
Deletion message sending unit 320, be used for sending this domain name mapping result to this caching nameserver and delete message, so that the first domain name mapping result in this caching nameserver deletion self buffer memory, the domain name correspondence of this this caching nameserver and above-mentioned request analysis.
Wherein, the authoritative domain name server that the embodiment of the invention ten provides can be used in the method embodiment three of the renewal domain name system buffer memory of aforementioned correspondence, and details are referring to the description of above-described embodiment three.The authoritative domain name server that the embodiment of the invention provides is deleted message by sending the domain name mapping result to caching nameserver, make caching nameserver delete the first domain name mapping result of buffer memory, avoid returning the first wrong domain name mapping result to terminal.Caching nameserver is after the domain name mapping request that receives terminal subsequently, again to the correct domain name mapping result of authoritative domain name server request, correct domain name mapping result is sent to caching nameserver, and then make that terminal can be to correct content server request content.
Referring to Figure 16, Figure 16 is the structural representation of deletion message sending unit in the authoritative domain name server that provides of the embodiment of the invention ten.
Deletion message sending unit 320 specifically can comprise in the authoritative domain name server that the embodiment of the invention ten provides:
Second searches module 321, is used for searching address with the domain name corresponding cache name server of request analysis according to the corresponding relation of preserving in advance at self buffer memory;
Deletion message transmission module 322, be used for sending the domain name mapping result to the caching nameserver that finds and delete message, so that the first domain name mapping result in this caching nameserver deletion self buffer memory, the domain name correspondence of this caching nameserver and request analysis.
Referring to Figure 17, Figure 17 is the structural representation of the authoritative domain name server that provides of the embodiment of the invention 11.
The authoritative domain name server that the embodiment of the invention 11 provides can comprise:
First receiving element 410 is used for receiving the domain name mapping request that caching nameserver sends, and comprises the domain name of request analysis in this domain name mapping request;
Domain name mapping unit 420 is used for according to this domain name mapping request the domain name of request analysis being resolved, and obtains the first domain name mapping result;
Buffer unit 430 is for corresponding relation and the domain name of request analysis and the corresponding relation between this caching nameserver between the domain name of the buffer memory first domain name mapping result and request analysis;
Resolution response transmitting element 440 is used for sending the domain name mapping response to this caching nameserver, comprises the domain name of the above-mentioned first domain name mapping result and above-mentioned request analysis in this domain name mapping response.
Deletion message generation unit 450, be used in first domain name mapping that detects self buffer memory when the content server of correspondence breaks down or load above threshold value as a result, generate the domain name mapping result and delete message, this domain name mapping result deletes message and is used for the first domain name mapping result that the deletion caching nameserver carries, this domain name mapping result deletes the domain name of carrying request analysis in the message, and the domain name of request analysis and first domain name mapping be correspondence as a result;
Deletion message sending unit 460, be used for sending this domain name mapping result to this caching nameserver and delete message, so that the first domain name mapping result in this caching nameserver deletion self buffer memory, the domain name correspondence of this caching nameserver and above-mentioned request analysis.
Wherein, the authoritative domain name server that the embodiment of the invention 11 provides can be used in the method embodiment four of the renewal domain name system buffer memory of aforementioned correspondence, and details are referring to the description of above-described embodiment four.
The concrete structure of the deletion message sending unit 320 among the concrete structure that it is pointed out that the deletion message sending unit 460 that the embodiment of the invention 11 provides and the embodiment ten is identical, is not described in detail here.
Referring to Figure 18, Figure 18 is the structural representation of the caching nameserver that provides of the embodiment of the invention 12.
The caching nameserver that the embodiment of the invention 12 provides comprises:
Updating message receiving element 510, be used for receiving the domain name mapping updating message that authoritative domain name server sends, this domain name mapping updating message is used to indicate this caching nameserver the first domain name mapping result of buffer memory is updated to the above-mentioned second domain name mapping result, carries the domain name of request analysis in this domain name mapping updating message;
Second updating block 520 is used for the first domain name mapping result of self buffer memory is updated to the above-mentioned second domain name mapping result, the domain name correspondence of the first domain name mapping result and request analysis.
The caching nameserver that the embodiment of the invention 12 provides can use in the method embodiment five of the renewal domain name system buffer memory of aforementioned correspondence, and details are referring to the description of above-described embodiment five.At caching nameserver that the embodiment of the invention provides by the first domain name mapping result corresponding with the domain name of request analysis in self buffer memory is updated to the second domain name mapping result, can be after receiving the domain name mapping request subsequently, with the domain name mapping result who upgrades, namely the second domain name mapping result sends to terminal.Compare with prior art, the embodiment of the invention can avoid terminal to the content server request content that breaks down by the domain name mapping result in deletion self buffer memory, further makes terminal to current available content server request content.
Further, the caching nameserver that provides of the embodiment of the invention 12 can further include:
Overtime delete cells 530 is used for after second life span is overtime, deletes this second domain name mapping result in self buffer memory.
Referring to Figure 19, Figure 19 is the structural representation of second updating block in the caching nameserver that provides of the embodiment of the invention 12.
Second updating block 520 can comprise in the caching nameserver that the embodiment of the invention 12 provides:
The 3rd searches module 521, is used for searching the first domain name mapping result corresponding with the domain name of request analysis, the domain name correspondence of this first domain name mapping result and above-mentioned request analysis according to the corresponding relation of preserving in advance at self buffer memory;
Buffer update module 522, the first domain name mapping result who is used for finding is updated to this second domain name mapping result.
Referring to Figure 20, Figure 20 is the structural representation of the caching nameserver that provides of the embodiment of the invention 13.
The caching nameserver that the embodiment of the invention 13 provides comprises:
Deletion message sink unit 610, the domain name mapping result who is used for the transmission of reception authoritative domain name server deletes message, this domain name mapping result deletes the domain name of carrying request analysis in the message, this domain name mapping result deletes message and is used for the first domain name mapping result that the deletion caching nameserver carries, the domain name correspondence of this first domain name mapping result and above-mentioned request analysis;
Deletion performance element 620 is used for self buffer memory of deletion first domain name mapping result corresponding with the domain name of request analysis.
The caching nameserver that the embodiment of the invention 13 provides can use in the method embodiment six of the renewal domain name system buffer memory of aforementioned correspondence, and details are referring to the description of above-described embodiment six.The caching nameserver that the embodiment of the invention provides is by the first domain name mapping result corresponding with the domain name of this request analysis in deletion self buffer memory, thereby after receiving the domain name mapping request subsequently, judge and do not have corresponding domain name mapping result in the buffer memory, then again to authoritative domain name server request domain name analysis result, namely send the domain name mapping request to authoritative domain name server, and then the domain name mapping result who to upgrade from authoritative domain name server, caching nameserver sends the domain name mapping result that upgrades to the terminal of correspondence.Compared with prior art, the embodiment of the invention can be avoided sending the address that exists fault or load to surpass the content server of thresholding to terminal, can avoid terminal to the content server request content that breaks down or load above thresholding, on the contrary can so that terminal to current available content server request content.
Referring to Figure 21, Figure 21 is the structural representation of deletion performance element in the caching nameserver that provides of the embodiment of the invention 13.
Deletion performance element 620 can comprise in the caching nameserver that the embodiment of the invention 13 provides:
The 4th searches module 621, is used for searching the first domain name mapping result corresponding with the domain name of request analysis according to the corresponding relation of preserving in advance at self buffer memory;
Buffer memory removing module 622 is used for the first domain name mapping result deletion that will find.
Need to prove, contents such as the information interaction in above-mentioned caching nameserver and the authoritative domain name server between each unit, implementation, since with the inventive method embodiment based on same design, particular content can repeat no more referring to the narration among the inventive method embodiment herein.
One of ordinary skill in the art will appreciate that all or part of flow process that realizes in above-described embodiment method, be to instruct relevant hardware to finish by computer program, program can be stored in the computer read/write memory medium, this program can comprise the flow process as the embodiment of above-mentioned each side method when carrying out.Wherein, storage medium can be magnetic disc, CD, read-only storage memory body (Read-Only Memory, ROM) or at random store memory body (RandomAccess Memory, RAM) etc.
More than method and authoritative domain name server, the caching nameserver of renewal domain name system buffer memory that the embodiment of the invention is provided be described in detail, for one of ordinary skill in the art, thought according to the embodiment of the invention, the part that all can change in specific embodiments and applications, this description should not be construed as limitation of the present invention.