XP & 2000 users that use static ip\’s in one office & dhcp in another office
We have clients that have laptops with a static IP in one office & use dhcp in the main office. These are some bat files that can be used to switch from static to dhcp & back so they can log on to either part of the domain with as little inconvenience as possible. All the client has to do is double click the appropriate .bat file for thier location. These have saved me a lot of time changing configs when the clients are in the main office.
The dhcp bat is:
netsh interface ip set address “Local Area Connection” dhcp
The Static bat is:
netsh interface ip set address “Local Area Connection” static 127.0.0.1 255.xxx.xxx.xxx 127.xxx.xxx.xxx 1
The first series of numbers is the IP, the second series is the Subnet Mask, the third series is the Gateway, & the last number is the multiplier
And of course you create these in notepad & save as dhcp.bat & static.bat.
or you can name them by location Topeka.bat & Lawrence.bat
There is also a .bat to check the config after you run one of the batch files which is:
Netsh interface ip show config
pause





