Live data from Hacker News

Rapid DHCP: Or, how do Macs get on the network so fast?

cafbit.com

71–80 of 191 posts

Re: Rapid DHCP: Or, how do Macs get on the network so fast?

#72
post #70

Earlier quoted context omitted.

The DHCP stack in iOS does some profiling that should reliably detect whether it is, in fact, on the network that it expects. The most significant of which is the verification of the DHCP server's Ethernet address as correlated to IP. If you are on a known network, your DHCP lease is still active, and network equipment is working as expected, all of these assumptions are safe. The most common failure scenario is wher…

Down-thread of this comment, people have already discussed numerous issues with the assumption that DHCP leases are stable when not in use (such as that servers often choose to allocate out of an artificially small pool of addresses, and ping old addresses to determine if they are in use before simply reclaiming and reassigning them).

Like I said, if you're uncomfortable with the trade-off, avoid Apple devices. Personally, I only see the number of devices like the iPad/iPhone increasing, and I'm relatively confident that your normal user doesn't give a damn about any of this. They want the device to work when they turn it on.

I'd also argue that any DHCP server that applies that policy of artificially limiting the IP pool by re-issuing non-expired leases is an asinine implementation.

Re: Rapid DHCP: Or, how do Macs get on the network so fast?

#74
post #15

> This network recognition technique allows the Mac to very rapidly discover if it is connected to a known network. If the network is recognized (and presumably if the Mac knows that the DHCP lease is still active), it immediately and presumptuously configures its IP interface with the address it knows is good for this network. Ok, seriously? That isn't a bug in an implementation somewhere, but in fact a feature that…

The DHCP stack in iOS does some profiling that should reliably detect whether it is, in fact, on the network that it expects. The most significant of which is the verification of the DHCP server's Ethernet address as correlated to IP. If you are on a known network, your DHCP lease is still active, and network equipment is working as expected, all of these assumptions are safe. The most common failure scenario is wher…

  > If you have to reboot your router frequently, you
  > should replace it
You are assuming that people will only ever use these devices on networks that they control.

Re: Rapid DHCP: Or, how do Macs get on the network so fast?

#75
post #70

Earlier quoted context omitted.

Down-thread of this comment, people have already discussed numerous issues with the assumption that DHCP leases are stable when not in use (such as that servers often choose to allocate out of an artificially small pool of addresses, and ping old addresses to determine if they are in use before simply reclaiming and reassigning them).

Like I said, if you're uncomfortable with the trade-off, avoid Apple devices. Personally, I only see the number of devices like the iPad/iPhone increasing, and I'm relatively confident that your normal user doesn't give a damn about any of this. They want the device to work when they turn it on. I'd also argue that any DHCP server that applies that policy of artificially limiting the IP pool by re-issuing non-expired…

  > They want the device to work when they turn it on.
If there is a collision, then this doesn't 'just work' when the user turns it on. Just sayin'. From the user's perspective the device should never fail, in any situation, for any reason... ever. Users don't care about trade-offs because they don't want to trade anything off, they want it all, 5 minutes ago.

Re: Rapid DHCP: Or, how do Macs get on the network so fast?

#76
post #43

"This whole notion of being so proprietary in every facet of what we do has really hurt us." Steve Jobs, circa 1997

There is nothing proprietary about this.

Do you have any examples of other vendors using the last assigned address as a default?

Re: Rapid DHCP: Or, how do Macs get on the network so fast?

#77
post #70

Earlier quoted context omitted.

Down-thread of this comment, people have already discussed numerous issues with the assumption that DHCP leases are stable when not in use (such as that servers often choose to allocate out of an artificially small pool of addresses, and ping old addresses to determine if they are in use before simply reclaiming and reassigning them).

Like I said, if you're uncomfortable with the trade-off, avoid Apple devices. Personally, I only see the number of devices like the iPad/iPhone increasing, and I'm relatively confident that your normal user doesn't give a damn about any of this. They want the device to work when they turn it on. I'd also argue that any DHCP server that applies that policy of artificially limiting the IP pool by re-issuing non-expired…

Well, sure, but the problem is that the Apple device user doesn't suffer from the negative consequences of the non-standard action. Other users do.

Of course people are going to like devices that allow them to cut in line if there is a little bit of space.

Re: Rapid DHCP: Or, how do Macs get on the network so fast?

#78
post #50

It seems a little unscientific to compare logs from one machine connecting to a new networking and having to get a lease to another connecting to a network it's been on before.

It is unscientific. A more comprehensive study would analyze each device in a variety of well-defined scenarios, but in the interest of time I just took a few captures and put a couple under the microscope. I hope I didn't come across as trying to directly compare the tablet's ~11.8s startup on a fresh network to the Mac's ~0.03s startup on a known network. I know that the Mac is faster than my other devices via subjective observation, so I was mostly just interested in comparing the differences in the packets during this process.

Re: Rapid DHCP: Or, how do Macs get on the network so fast?

#80
post #20

Earlier quoted context omitted.

By the time the problem is "fixed" the other computer on the network has already detected that its IP address is in conflict by ARP, telling the user what happened (interrupting them) and has shifted to a new IP address (losing all of its active connections in the process). (and yes: some routers hold on to only a certain number of inactive leases, and routers actually do get rebooted in home, office, and hotel envir…

If you're having to reboot the router more often than DHCP leases expire, you may want to look into a new router.

Ah yes, the Apple solution: just buy a new one. Because that's always an option for everyone, on every network they use.
Post reply on HN