IP Addresses and Their Assignment.

Yeah, I know I could maybe look it up.

But it’s kind of slow in here, so at least this isn’t yet another zombie thread.

AIUI, if a person has thier own server, they get a unique IP address.

I think a dedicated DSL/Cable modem will probably get a unique IP address.

What about dial-up?
Does the ISP get assigned a range of numbers and assign them ad hoc or are dial-ups still assigned fixed IP addresses, even if that IP address ‘blinks off’ when they disconnect?

You young-un’s and your fancy intertubes are confusing me.

Unless you pay extra for a static IPv4 address, even xDSL and fibre users will get a dynamic IP assigned by their ISP. The ISP has a pool of addresses to allocate, and users will get one of those. Dial-up IP addresses are allocated on a very short term basis, and broadband users usually have quite a long lease time. Often, the modem will keep renewing the lease so that while the modem is on, it will keep the same IP address.

Of course, now that most of the IPv4 address space has been allocated, ISPs are using a number of techniques to maximise customers and minimise IPv4 requirements. Network Address Translation is what your modem/router uses to map all the internal devices on your home network to the single IPv4 address on the real internet.
Carrier Grade Network Address Translation is used to provide a second layer of NAT, so an ISP can give a customer modem a non-internet IPv4 address (probably a 10.0.0.0/8 address) which they then NAT (a second time) into a smaller range of real IPv4 addresses. This can be done with greater or lesser success, and it may well break some internet connectivity (end-to-end principle) - CGNATted devices are not equivalent to a directly connected device, but many users may not know that their ISP is using it.

The answer is IPv6 migration where every device has a valid IPv6 address and there is no NAT at all. However, ISPs find it cheaper to continue using existing IPv4 gear and pay for kludges like CGNAT than rebuild their network. However, there are large chunks of the internet that do not support IPv6, so I guess it isn’t surprising.

In general, most with Internet service will have a unique IP address. But there’s a distinction that needs to be made - while the IP address is unique, it is typically not dedicated. As such it may change upon restarting the modem/router/computer that is receiving the IP address from the provider from a DHCP request. If it does change, it will receive the unique IP address from the pool of available IP addresses in the provider’s block.

Many ISPs allow you to purchase a service package that includes a static IP address, and these packages are typically more expensive. However, for most home users that need access to their home network from outside or run servers (often against your standard terms of service for basic Internet), dynamic DNS makes static IP addresses unnecessary.

A vast majority of dial-up services are assigned ad-hoc.

In apartments, an entire building can have the same IP address. In fact, my neighbor, who lives in a different building of the same complex, has the same IP address as me. So, I guess if she gets banned by a message board, so do I.

For years I had an IP that was both unique and also externally accessible. (By-product of the installer not working correctly and me futzing with the settings to get it working manually). Then I had a hub or switch and had multiple computers each with their own unique and externally-accessible IP addresses for the price of $29.99/month.

Eventually they did something that killed my ability to fetch one IP for each box. I had to get a standard router, then when I upgraded to FiOS the device they sent me has multiple ports and obviates the need for a separate router. The device as a whole gets an IP that is externally accessible and unique, then parses out individual non-unique non-externally accessible 192.168.xx.yy type addresses to each computer. I use port forwarding to set up one specific computer to be externally accessible.

Thanks for the replies - they solve a few mysteries.

The catch is that the world is running out of (ran out of) real IP addresses. As a result, you will see more and more of the tricks like CGNAT where entire apartment complexes, or even all customers of an ISP in a city, have the same external address. AFAIK ISp’s have to pay for these rare IP addresses, and if they exceed their quota, then the NAT tricks are a simpler solution. The older and bigger ISP’s have the advantage that they probably got their ranges early, so they have more available.

Dynamic IP’s are randomly assigned. Fixed IP’s, the ISP charges (usually) for the privilege. To run a server where DNS translates your name (URL) to a fixed IP, you need that fixed IP. Sometimes you may keep your home dynamic IP for a long time, but if the ISP thinks you are running a server from your home, they may shift your dynamic IP to something else just to reinforce the revenue opportunity.

Another issue I’ve run across - some ISP’s block port 25 on dynamic addresses, making it impossible to use your own email server at home - because so much virus spam comes from infected home PC’s. Some Email blacklists will cause email servers to refuse connections from dynamic addresses for the same reason (which are dynamic is information they get from the ISPs)

The there’ the ability to stack multiple web servers on the same IP address using “host headers”, a trick most web hosting companies use. You may think “mycompany.com” is on 11.22.33.44 - but really so are 500 other web sites on the one IP address. You get the right web site because the master web service looks at the URL requested and replies with the website that matches “mycompany.com”. You can see this by determining the IP address (“ping mycompany,com”) then attempting to connect to the IP address instead. odds are, for smaller companies using rented hosted sites, you get a completely different web site, probably the host provider.

What we used to do back in the day, and I assume pretty much all ISPs did the same, is assign an address to each dial-up modem. So if you connect to modem 10 you get address 192.0.2.10. If you then hang up and call back and get modem 65 you get address 192.0.2.65.

Getting the addresses is the easy part (ISPs get them from ARIN in North America), the hard part is making sure the rest of the world knows they’re your addresses so they know where to send the packets to those addresses.

Every device that connects to and can route on the internet must have it’s own, unique IP address. What’s called a ‘public address’. This would be on any public facing device or interface. Behind that device if you are using NAT then you can have what’s called a ‘private address’, one of the RFC1918 addresses that are non-route-able on the internet (basically they are 10.0.0.0/8, 172.16.0.0/16 and 192.168.x.0/24 generally).

Yes, though it doesn’t have to be this way. An ISP COULD create a private network and then NAT out a bunch of home users through a pool of public addresses…similar to how you could have a bunch of remote business offices tied back to a corporate network and using the ISP connect at that corporate network to go out to the internet. Usually, however, ISPs that give you a DSL router/Cable Modem will have it’s public facing interface use a (usually DHCP, i.e. dynamically assigned) public IP address that’s route-able on the internet, but as I said you don’t have to do it that way.

Same as the above. You could assign a dial-up user an RFC-1918 private address then route them out and use a NAT pool, or you could give them a public address. Depends on how you have them coming into the network and what you are trying to do. I think most ISPs still doing dial up generally assign a public address still, but like I said you don’t have to do it that way.

ISPs are assigned a (generally large) block of public addresses that they can then assign to their customers. A customer, in turn, can request from their ISP a block of addresses if they need them which the ISP assigns from their own block. Generally they will set up blocks for specific things that will be assigned either via DHCP or in a NAT pool (or statically assigned if that’s the customers request…obviously, if a customer requests a block of addresses they have to be associated and statically assigned, since you don’t want them in a pool that others could use).
Hopefully this was helpful. Tried to keep this as straight forward and non-technical as possible. :slight_smile:

For my own amusement I setup a recurring process on one of my computers that checks the IP addresses assigned to my home by Time Warner. I have had the same IP address since June 23 of this year. Interestingly there was a planned power outage a few weeks ago at my house. The power was down for about 7 hours one night. My cable modem was assigned the same IP addresses. Both IPv4 and Ipv6 after the power came back on.

So the dynamic IP addresses assigned to cable modems are not that dynamic.

In my experience, a DHCP address is given to you for a certain amount of time. In my company, this is, I think, a week. So if there was a power outage, and your lease was still in effect, I could see why you still have the same address. But if you went on vacation for a month and shut off your cable modem while you were gone, you’re unlikely to have the same address when you return.

Yeah. It’s more like: they stay the same until/unless there’s a reason for them to change. But those reasons are essentially for the ISP’s benefit and at their option, not the subscriber’s.

So from the POV of a subscriber a dynamic IP address is a slippery thing that *may *be pulled out from under you at any moment with zero advance warning, and no notice after the fact either.

So if you are using that dynamic address for any public purpose, you need to design the rest of your end-to-end system with this slipperiness in mind. And once you’ve designed your system to counteract that slipperiness, it becomes almost moot whether it changes on average every few minutes or every few months. Either way you’re set up to deal with it robustly.

Standard DHCP (no reason for ISP to use other) - there is a lease life; default from MS is 8 days. Halfway through, the lease is renewed. if that fails, then 3/4 ay through, then try again 7/8 through and at end of lease.

So if things are not disturbed at the HCP server end, and your device is not typically off, then you keep that address until something changes; the server reboots, etc.

One DSL provider I talked to said DSL addresses, for them anyway, were provided by user login on PPPoE over the DSL. No matter which DSL cable you connect to, if you use your login you would get your IP address. They just don’t guarantee you keep the same address forever.

(An interesting glitch in some businesses - they change their internal DHCP to a new server and a few days later computers stop working. DHCP client attempts to renew their lease from the DHCP server by IP address. If that address no longer responds, DHCP service is moved elsewhere - then eventually the lease will expire, the network no longer works for that client. This is most interesting where the lease is 30 days or more; when people randomly fail 2 weeks or more later, what are the odds you’ll spot the connection? Forcing the client to do a broadcast for a new IP fixes this by looking for ANY DHCP; by either unplugging the network cable, or reboot of the client, etc.)

Just to add to this, the lease is associate with the MAC that made the request. The default in Microsoft is 8 hours, though this is configurable. I’m not sure what it is in Unix systems, but I know it’s also configurable. What generally happens is that halfway through the lease, the machine that originally requested the lease will begin requesting again. If that happens then the DHCP server will generally just renew the lease for another 8 hours, leaving the IP the same. You can, of course, also set up for a DHCP server to give what amounts to a static address even though it’s being given by the DHCP server using a reservation, but that’s probably beyond the discussion.