Ask Leo!

What is DHCP?

Home » Networking » Network IP Addressing

Summary: DHCP is the protocol computers use to request and receive a "dynamic" IP address.

What is DHCP?

DHCP stands for "Dynamic Host Configuration Protocol".

So I can hear you thinking, "great ... what's that?"

In a nutshell, it's the request your computer makes and the response it receives that assigns it a "dynamic" IP address.

Let's look at that a little more closely.

First, a refresher. Every computer on the internet has an "address". That address is just a number, but it uniquely identifies that computer; no other computer on the internet can have the same address.

There are two types of IP addresses: static and dynamic. Static IP addresses are just that - unchanging. They refer to a particular computer, whether that computer is turned on or not, connected or not. Most typically domain names like "ask-leo.com" map to a single static IP address.

Dynamic IP addresses are assigned to a computer on-the-fly. The most common scenario is dial-up. When you dial-up to your ISP, part of the connection sequence is your computer asking for an IP address, and your ISP assigning it one of the addresses it has available. When you disconnect, that IP address is returned to the list of available addresses and may be reused by another computer when it dials in.

Because most home users tend to turn their computers off, even broadband connections such as DSL and Cable continue to use dynamic addresses. If your computer is off, you don't need an address so someone else might get to use it.

Dynamic addresses are also used by NAT routers. Not necessarily on their internet connection, though it can, but rather on the local area network side. Each computer that you connect to your router will ask for an IP address, and that router will respond with an IP address that's available within your LAN.

The actual DHCP protocol is fairly simple. The computer in need of an IP address broadcasts a request, meaning it sends out a request to anyone who'll listen. That, in essence, says "Hey, anyone? I need an IP address!" By definition on any network (or more correctly, sub-network), there should at most one device who's job it is to answer back "Sure, here ya go, have this one." That's a DHCP server. Along with that answer is additional information as well, such as what machines to ask for domain name (DNS) look-ups and what address to forward all outgoing network traffic, too (the gateway).

In Windows, if your computer doesn't get a response from a DHCP server within a certain amount of time, it will give up or it may fall back to only asking every few minutes. It may "make up" an answer as well. In fact if your IP address begins with "169.", that's probably exactly what's happened; no IP address was assigned, and Windows made one up. And I'll bet your networking and internet don't work.

Related:

Article 330 | Posted June 17, 2004

Recent Comments
0 Comments

ok so how do you fix this?

Posted by: mike at November 10, 2004 2:44 PM

Fix what?

Posted by: Leo at November 10, 2004 2:51 PM

I've read some of your Network solution to some of the difficulty problems that everyone posted. And I think it's very very helpful and visually details.

Thank you for your information. Myself encountered problem with my network.

I'm using a Linksys switch with 4 ports. port#1 to my primary computer to access internet, port#2 go to my kids computer which occassionally permission to get on the internet, and the third connect to my X-box (game console). Recently I bought another Xbox which will provide connect to share the gaming experience by challenging each other on difference screen and differences xbox.

But the problem is only one Xbox can get on xbox-live at a time. Then I saw your article and thought of the similar problem that I encountered, your solution may aslo solve my Gaming connection problem.

Thank you in advance. (I will try to buy a router and install it to see if provide two IPs address for both Xbox to access on the net)

Posted by: John at June 7, 2005 2:03 PM

I have been satisfied with the explanations given on DHCP

Posted by: TUFURAHI VIAYEUR at December 15, 2005 7:48 AM

Leo,

I'm at wits end.

When my wife plays Everquest, the computer freezes almost randomly. In the event viewer-system, various errors occur: DHCP IP address lease has been denied or cannot be renewed (or something similiar) event 1000,1001,1002, or 1003, cannot obtain DHCP address.

I've spent hours talking to the ISP only to have them say its the PC (the connection from the ISP to the cable modem). The LAN card shows as being connected and sending infromation to out, but not receiving any informaton. The computer only faulters running on-line video games.

I've also updated the drivers, reinstalled XP, replaced the video card, replaced the LAN and replaced the memory. I've even connected the computer directly to the cable modem without any network.

I've also ran spyware, and antivirus programs.

Can you point me in the right direction?

Here are the PC particulars:
P4 1.8A
MS9118E Motherboard
2GB PC3200/replacing 1GB PC2100
ATI 9550 replacing ATI7500
Linksys 10/100 LAN card replacing on-board
XP Prof SP2
Linksys B/G wireless router/switch
ISP Timewarner/RoadRunner

BTW: Matsonic responded saying its the OS
Linksys responded saying its the ISP
ISP says take PC to the repair shop
ATI says its not their problem

Thanks for having a great site!
Tom


Posted by: Tom at March 14, 2006 8:23 PM

A1 site to learn networking and its basics.

Posted by: huma at June 26, 2006 10:21 PM

Based on what I've just read about this DHCP thing....and, even this 75 yr old unreconstructed "bookie" i.e. non- techie could understand it, I believe now that dial-up access may have its advantages in anonymity..am I correct? Could you perhaps make it the subject of another column?
Best,
Charlie G.

Posted by: Charlie Griffith at July 20, 2007 7:20 PM

I have a 2 MBps broadband connection which uses a dialer to connect to the internet. Now, when I check whether or not DHCP is enabled through ipconfig, it shows "no" sometimes and "yes" sometimes. What could be a possible reason?

Posted by: Ritwik at December 18, 2007 12:58 AM

wonderful information about DHCP protocol , thank you Leo.
http://www.fosdir.com

Posted by: peter at June 20, 2008 9:34 PM

Post a comment on "What is DHCP?":






(Email Address will not be published.)

Remember Me?

By popular demand...
my tip jar
Cuppa Joe
Buy Leo a Latte!

(you may use HTML tags for style)

New!

RSS feed Subscribe to the RSS Feed specifically for comments on this article.

Before commenting, please...

Please wait. Your comment is being processed ...


Ask Your Question:


ask-leo.com
Web

Stay Informed

Weekly Newsletter

Archives

By Category
By Date

Advertisers

Advertise on Ask Leo!

««   »»

Question? - Ask Leo!
Who is Leo?
Link to Leo!

Terms, Conditions & Privacy