Tips of How to Switch between DHCP and Static IP Network Automatically in Windows
If you are a mobile computer user and need to work in DHCP and static IP network environment from time to time, you may need to keep on changing the network TCP/IP properties on your laptop. It is really annoying and irritating to repeat this routine task each and every time when switching from one network to another especially when you are in the hurry to solve an urgent issue or need to get the task completed as sooner as possible. Now with this Alternate Configuration functionality offered by Microsoft, it will auto detect the network change and switch for you automatically without the hassle to manually configure it anymore.
The feature of Alternate Configuration is it enable TCP/IP uses alternative configuration if no DHCP server is detected. With such a design, your laptop will be auto switched from dynamic to static IP setting automatically. To enable Alternate Configuration, follow below steps:
i) Click Start menu -> Control Panel.
ii) Click Network Connections.
iii) Right click Local Area Connection and select Properties.
iv) Under General tab, scroll down until you see Internet Protocol (TCP/IP). Click on it and click Properties button.
v) Under General tab, select Obtain an IP address automatically. This setting is to obtain dynamic IP address if DHCP server is found in the network.
vi) Go to Alternate Configuration tab, select User configured. Enter the static IP of your alternate location. This setting is to allow TCP/IP uses static IP once DHCP server is not found.
After getting above steps done, if you work in office with DHCP server enabled, your laptop will use primary configuration to obtain dynamic IP automatically. Once your laptop switch to static IP network environement such as at home or production, your laptop will be auto switched to alternate configuration with the static IP you have configured.
Related Articles
- Tips of How to Restart Crashed Applications Automatically in Windows PC
- Installing and Configuring DHCP Server (DHCPd) on FreeBSD
- Enable Automatically Logon/Login Into Windows XP
- Hack to Activate and Switch Window in Windows 7 By Mouse Over Hover Without Click
- Automatically Expand Navigation Pane Tree to Current Folder in Windows 7
- Force Windows to Login Automatically After Logging Out with ForceAutoLogon
- Free Windows Server 2003, 2008 AD, SharePoint (MCTS/MCP/MCSE), CompTIA Network+ and Cisco Certified Network Associate (CCNA) Exam Study Guide E-Book Download
- Microsoft Network Monitor 3.3 Beta Supports Windows 7: Available For Download
- Turn On and Enable UPnP or Network Discovery in Windows Vista
- WGA Notifications 1.8.0031.0 Silent Update Adds Black Desktop and Static Watermark Nagware to Windows XP










































October 19th, 2009 03:12
Very useful information. If I may add, using dynamic IP can allow you to frequently change your IP address and thus give some security and privacy protection.
However, even better solution would be to use an IP Changer software in combination with surfing through multiple proxy servers. This routes your internet connection through these servers and thus rapidly and frequently change your IP. It effectively hides your real IP and you can thus safely, anonymously and securely surf the internet. Of course there is no fool froof safety on the net but this goes a long way.
February 10th, 2009 17:41
as you all know m$ got many ways to do one thing. this is one way m$ to do this
i’ve got 2 (3,4,5, many) network configurations
/home,work, at my brother, etc./
i create 2 files for every net
first file is batch file /for exxample home.bat
second file is netsh config in clear text /home-static.txt
batch file is calling nets with text file for config
iii.iii.iii.iii – this is ip address
mmm.mmm.mmm.mmm – this is netmask
ggg.ggg.ggg.ggg – this is ip of gateway
yyy.yyy.yyy.yyy – this is primary dns
xxx.xxx.xxx.xxx – this is secondary dns
and something else THIS IS for network connection called “Local Area Connection”
if you renamed this net just replace name here too !!!
working ok for me in windows xp /sp1,sp2,sp3/
file home.bat
-=-=-=
netsh -f “home-static.txt”
-=-=-=
file home-static.txt
-=-=-=
#========================
# Interface configuration
#========================
pushd interface
reset all
popd
# End of interface configuration
#========================
# Interface configuration
#========================
pushd interface ipv6
uninstall
popd
# End of interface configuration
# ———————————-
# ISATAP Configuration
# ———————————-
pushd interface ipv6 isatap
popd
# End of ISATAP configuration
# ———————————-
# 6to4 Configuration
# ———————————-
pushd interface ipv6 6to4
reset
popd
# End of 6to4 configuration
#========================
# Port Proxy configuration
#========================
pushd interface portproxy
reset
popd
# End of Port Proxy configuration
# ———————————-
# Interface IP Configuration
# ———————————-
pushd interface ip
# Interface IP Configuration for “Local Area Connection”
set address name=”Local Area Connection” source=static addr=iii.iii.iii.iii mask=mmm.mmm.mmm.mmm
set address name=”Local Area Connection” gateway=ggg.ggg.ggg.ggg gwmetric=0
set dns name=”Local Area Connection” source=static addr=yyy.yyy.yyy.yyy register=PRIMARY
add dns name=”Local Area Connection” addr=xxx.xxx.xxx.xxx index=2
set wins name=”Local Area Connection” source=static addr=none
popd
# End of interface IP configuration
-=-=-=-=-=-=-=-=-=-=-=-
January 18th, 2009 06:16
yah, too bad it doesnt work.
I set it up like this…
Router > dhcp off.
computer > primary automatic ip
> alternate 192.168.1.102
subnet normal
gateway 192.168.1.1
dns my router’s dns
I get an error ip
November 14th, 2008 01:25
AHA! just found the reason! you need to be on DHCP already!
thanks again!
November 14th, 2008 01:24
thanks for that, its a great help! Although the person im trying to do this for doesnt have the alternate configuration box.. any ideas? They are connected to a server but I wouldnt think that this would block access to this feature since he can change his IP etc.
November 8th, 2008 10:46
hey gracias me ayudo mucho. muy buena tu explicacion, te deceo suerte y gracias de nuevo…