Need help trying to understand DHCP

headcaseheadcase Member Posts: 30 ■■□□□□□□□□
I have read an abundance of information on DHCP. However, since I don't have hands on experience with a DHCP server my understanding of how it works is a little shaky at this point.

For example, AOL is your ISP. Every time you connect to AOL, does their DHCP assign you an IP address? Just exactly how does this work?

Comments

  • RussSRussS Member Posts: 2,068 ■■■□□□□□□□
    That my friend is exactly whats happens - unless of course you have asked them for a static IP address (which you pay extra for). Using Dynamic IP addressing an ISP can have say a million clients using only a few IP addresses based on how many % of users they have online at any one time. With smaller ISPs they are usually limited by how many dialin modems they have, and for larger ones it is more using advanced technology.
    www.supercross.com
    FIM website of the year 2007
  • headcaseheadcase Member Posts: 30 ■■□□□□□□□□
    Ok, makes sense.

    RusS,

    Trying to expand on what you have said. Let's say I connect to AOL and their DHCP server assigns 192.168.4.232 as my IP address. As soon as I disconnect their DHCP can then assign 192.168.4.232 to another user who connected after I signed off. Thus, odds are you will never have the same IP address b/c AOL probably has millions of IP addresses they issue out.

    does this make sense, am I getting this?
  • RussSRussS Member Posts: 2,068 ■■■□□□□□□□
    You surely do understand it icon_wink.gif

    The way I checked that was to log on - check my IP and then log off. Doing this at a very busy time for my ISP resulted in 5 different addresses (hey - I'm a slow learner ... lol). i always like to confirm things too ... lol
    www.supercross.com
    FIM website of the year 2007
  • bellboybellboy Member Posts: 1,017
    a dhcp server will "lease" you an ip address for the duration of the connection. whether it is on a lan or via your isp (because the internet uses tcp/ip, your connection via the isp is really a wan ;)), you will have a different isp everytime that you connect.
    A+ Moderator
  • WebmasterWebmaster Admin Posts: 10,292 Admin
    bellboy wrote:
    a dhcp server will "lease" you an ip address for the duration of the connection. whether it is on a lan or via your isp (because the internet uses tcp/ip, your connection via the isp is really a wan ;)), you will have a different isp everytime that you connect.

    In a LAN, the IP addressing is typically not leased for duration of the connection, but rather for a couple of days (fixed amount of hours, days, configured at the server.) Also, a LAN client will typically try to renew the lease before it requests a new address.

    Although the process used in ISP connection uses DHCP (sometimes referred to as a mini-DHCP), it is typically the dial-in software (i.e. RAS server) that is configured with an address pool to use for incoming connections. I believe it is very different from the regular LAN DHCP process which uses a lot of braodcasts (request, offer, ack,nack)
  • WyldstarWyldstar Member Posts: 32 ■■□□□□□□□□
    Webmaster's right. DHCP over a LAN leases the address for a certain number of days (or hours in the case of some routers with built-in DHCP servers, like Linksys stuff). Clients attempt to renew their leases when it is 50% up by unicasting DHCPREQUEST messages to the DHCP server it obtained the address from. Once the lease is 87.5 percent up, it begins multicasting DHCPREQUESTs to try and obtain an IP address from any DHCP server on the network. Ipconfig /all will show you when you recieved the lease for the address and when it will expire.

    MS's Network+ book and O'Reiliey's DHCP book are both really good sources of information on exactly how DHCP works if you want a fairly in-depth understanding of it.

    - WS
  • chmars53chmars53 Member Posts: 10 ■□□□□□□□□□
    Wyldstar is right too - the 50% rule since getting or asking for a lease is the standard, and continues until the lease expires (so said my instructor).

    When you get a lease, the server has a time limit (say 5 days) for the lease. If you log off after 2 days, that number is still assigned to you until the 5 days are up; if you sign back in the next day, you get the same number.

    When you request a lease (broadcast via UDP) the response is sent out 'broadcast fashion' (since you don't have it assigned until your machine responds) with the availabe IP address, subnet mask, IP of the DHCP server, and lease duration (DHCP/BOOTP server in is port 67, out is port 68 ). You (client) accept the first IP address (there could be more than one DHCP server), respond with a broadcast message (so all DHCP servers know you have a number now and release any number they had just set aside for you) and then the server you accepted a number from confirms with a broadcast ACK message and sends you the DNS or gateway addresses you may need.

    (above is short version from my ILT course manual)
    also search Google - "PC Network Advisor" for very good explainations.

    If you know someone with an extra PC & an evaluation copy of Server SW and REALLY want to try things, then set the lease times to real short & see what errors you get. LIKE: you take a portable PC to an office, sign on their network to share files, then go to your office - you will get errors because you have TCP/IP settings from the other server - you will have to 'release & renew' to get new settings.

    Mars
    Repairing Mainframes since 1978 - & still learning
Sign In or Register to comment.