Resetting Your Dynamic IP Address & DNS Entries

Here is something for the Windows user having trouble with network connectivity when traveling, or after hibernation. Basically, Windows likes to try previously known good settings to see if they work, again. With network settings, Windows sometimes is "reluctant" to clear them and ask for new settings. See if one of these scenarios comes close to matching your situation:

  • Broadband at home and a network at the office, or hotel. Upon first arriving at a new location, the laptop seems to have an active network connection, but won't connect to any network or Internet.
  • In an office environment, or a network with a number of other computers. Your computer hibernates after not being used for a while. The next day, you wake up your computer. Not only does it not connect to the network, but someone in the office starts getting messages that someone else on the network is using their IP address.

I am addressing two things in this document -- Losing your IP address & connectivity issues for travelers regarding incorrect DNS (Domain Name Server) IP addresses. In a small network or office, either a router or server is assigning IP addresses and supply DNS resolution (converts web & network names to IP addresses) for users. Here is what's happening:

  • IP Addresses -- In a company with multiple offices that are interconnected, they usually have their own servers to service their local office. But, since their networks are interconnected, the servers can "see" each other. They have to have different names & IP addresses to keep their identities distinguished from each other. So, when a person travels to another office and boots up their computer, it will try to contact the server from its previous office to connect to the network. And, it may not be locatable. The same holds true when going to a hotel or home network from the office. And, if your computer hibernates, it basically freezes in time. After a default period, the router or server determines your system is off the network and reassigns your IP address to the next person logging on. Then, you wake up your computer. It doesn't know what has happened while it was asleep. When it tries to go about its routines, it stumbles over another system.
  • DNS -- So, you type a web site or computer name, and it figures out how to connect to it for you. And, the DNS server has an IP address. Your computer remembers the last known good IP address, and will try to connect to it. And, it won't be there to help. From then on out, You will need to know the IP address of every computer and web site you want to connect to.

Luckily, there are two commands in windows that will set you up, quickly. One will release the IP address and ask for a new one. The other will drop the DNS server information, ask for DNS connect information. I like to run both of these commands, to be sure the computer is properly connected to the network. It doesn't hurt anything to run. Here are the commands...

ipconfig /release
ipconfig /flushdns
ipconfig /renew
ipconfig /registerdns

I usually open NOTEPAD and insert these commands, just as I've listed them. Then I save it with a name, like FixIPDNS.cmd. Keep it where you can find it... On the Desktop or a shortcut pointing to it.

I originally started doing this back around 1998. My company had issues with traveling employees going to hotels or other offices on our WAN. They would work at one location and travel to another. For those with PCMCIA network cards, they could just eject them and reinsert them into their laptops. And Windows would reset without any coaxing. But, today's systems have built-in network cards. So, this is a viable way to correct those traveling/hibernating blues!

 

Updated: 11/02/2005