Sei sulla pagina 1di 4

In this capacity DHCP acts as BOOTP does.

It is backwardcompatible
with BOOTP, which means a host running the BOOTP client can request
astatic address from a DHCP server. A DHCP server has a database that
statically binds physical addresses to IP addresses.

Transition states
The dhcp client transitions from one state to another depending on
messages it recieve or sends

Initalizing State
When dhccp clent first starts, it is the initializing state.
The client broadcasts DHCPDISCOVER messageusing port 67

Selecting stage
After sending the DHCPDISCOVER message, the client goes to the
selecting state. Thoase servers that can provide this type of service
respond with DHCPOFFER message. In these messages server offer an
ip address. They can also offer the lease duration. The default is 1h. The
server that sends the DHCPOFFER lockas the offered IPaddress so that it
is not available to any of the other clients.
The clients choose one of the offers and sends DHCPREQUEST message
to the selected server.
It then goes to the requested state.
However if the cloient recieves no DHCPOFFER message,it tries four
more times, each with the span of 2s.
If there is no reply to any of these DHCPDISCOVER, the client sleps for
5 minutes before trying again.

Requesting State
The client remains in the requesting state until it recieves a DHCPACK
message from the server which creates the binding between the client
physical address and its IP address. After reciept of the DHCPACK, the
client goes to the bound state.

Bound state
In this state client can use the IP adddress until the lease expires.
When 50percent of the lease period is reached, the client sends another
DHCPREQUEST to ask for renewal.
It then goes to the renewing state.When the bound state, the client can
also cancel the lease and go to the initializing state.

Renewing State
The client remains in the renewing state until one of two event happens.
It can recieve a DHCPACK, which renews the lease agreement.In this
case client resets its timer and goes back to the bound state.Or if a
DHCPACK is not recieved, and 87.5% of the lease time expires, the client
goes to the rebinding state.

Rebinding state:
The client remains in the rebinding state until oe of the three events
happen.
If the client recieves the DHCPNACK or the lease expires, it goes back to
the initializing state and tries to get another ip address.
If the client recieves a DHCPACK it goes to the bound state and resets the
timer.

Recursive Resolution
The client (resolver) can ask for a recursive answer from a name server. This means that
the resolver expects the server to supply the final answer. If the server is the authority
for the domain name, it checks its database and responds. If the server is not the authority,
it sends the request to another server (the parent usually) and waits for the response.
If the parent is the authority, it responds; otherwise, it sends the query to yet another
server. When the query is finally resolved, the response travels back until it finally
reaches the requesting client. This is called recursive resolution

Iterative Resolution
If the client does not ask for a recursive answer, the mapping can be done iteratively. If
the server is an authority for the name, it sends the answer. If it is not, it returns (to the
client) the IP address of the server that it thinks can resolve the query. The client is
responsible for repeating the query to this second server. If the newly addressed server
can resolve the problem, it answers the query with the IP address; otherwise, it returns
the IP address of a new server to the client. Now the client must repeat the query to the
third server. This process is called iterative resolution because the client repeats the
same query to multiple servers.
Caching
Each time a server receives a query for a name that is not in its domain, it needs to
search its database for a server IP address. Reduction of this search time would increase
efficiency. DNS handles this with a mechanism called caching. When a server asks for
a mapping from another server and receives the response, it stores this information in
its cache memory before sending it to the client. If the same or another client asks for
the same mapping, it can check its cache memory and solve the problem. However, to
inform the client that the response is coming from the cache memory and not from an
authoritative source, the server marks the response as unauthoritative.
Caching speeds up resolution, but it can also be problematic. If a server caches a
mapping for a long time, it may send an outdated mapping to the client. To counter this,
two techniques are used. First, the authoritative server always adds information to the
mapping called time-to-live (TTL). It defines the time in seconds that the receiving
server can cache the information. After that time, the mapping is invalid and any query
must be sent again to the authoritative server. Second, DNS requires that each server
keep a TTL counter for each mapping it caches. The cache memory must be searched
periodically, and those mappings with an expired TTL must be purged.

Potrebbero piacerti anche