?
Solved

Per-user IP configuration on Windows XP

Posted on 2008-09-30
5
Medium Priority
?
958 Views
Last Modified: 2013-11-05
I use a laptop computer to program various network hardware devices.  Each device has it's own default IP address scheme and progamming software.  Each time I need to work with a certain device, I have to reconfigure my TCP/IP settings.

What I would like to set up, is to be able to create seperate Windows logins for each type of device, with the laptop's IP address being automatically set to the correct configuration for that type of device, and with the programming software shortcuts on the desktop.

For a hypothetical example, I should just be able to login as the user "Siemens", and then my IP address is set to 192.168.1.100 or login as "Rockwell" and have my IP address as 10.1.1.1

I know network settings are supposed to be per machine, but I was wondering there was a better way than continuously manually changing settings.  I'd hoped to find something in the local user policies, but no luck.  Perhaps it will have to be a login script?

Thanks in advance

Nicolas
0
Comment
Question by:nicolasn
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
5 Comments
 
LVL 14

Expert Comment

by:igor-1965
ID: 22605256
What you need is a network profile switcher (just google that). There are quite a lot of shareware programs. Here is free for non-commercial use: http://www.netsetman.com/index.php?s=nsm
0
 
LVL 8

Accepted Solution

by:
Seth_zin earned 500 total points
ID: 22605572
You could setup a bat file on each of the accounts (or all on one account if you prefer and just make folders for the different shortcuts, save you some time) to do it for you. Then all you do is double click a bat file when you log into that account.

You said you are advanced on this subject so I won't waste your time, here is a quick set of what you need to type into the bat file .
--To Set IP/Subnet mask/gateway/metric enter the following command:
netsh interface ip set address "Local Area Connection" static IPADDRESS SUBNET GATEWAY 1

--To set dns/secondarydns enter the following commands:
netsh interface ip set dns "Local Area Connection" source=static DNSADDRESS
netsh interface ip add dns name="Local Area Connection" SECONDARYDNS index=2

For anyone who reads this and wants a little more info and a link to a site with other netsh commands read below:
Use the netsh command and make it look something like this:
To change the IP/Subnet/default gateway use
netsh interface ip set address "Local Area Connection" static IPADDRESS SUBNET GATEWAY 1
(Notice the 1 at the end after gateway. it is the "metric". According to some sites you don't need to add that, but if I didn't, it wouldn't work so I changed it to 1 and it worked fine).

Next you you change your DNS (if needed) to do that add something like:
netsh interface ip set dns "Local Area Connection" source=static DNSADDRESS
netsh interface ip add dns name="Local Area Connection" SECONDARYDNS index=2

Notice again one says source=static, if I didn't include that it didn't work but when adding the secondary (using the add command) it didnt work with it lol. Don't know why but the above way is how I tested it on XP Pro SP3 (I imagine it works on 2000 and vista too but I'm not positive).

If you want more information check out http://windowsitpro.com/article/articleid/41111/cool-things-to-do-with-netsh.html Scroll down to the comment section and you will see a post for "The commands in the article need to be corrected as follows" then he list them all. I tested those and they all seem to work. It also has dhcp setup etc. Hope that helps, I see a lot of people that come to work on the machine at our shop here use a bat file like above.
0
 
LVL 1

Author Comment

by:nicolasn
ID: 22621598
Hi Seth_zin,

I like the sound of your suggestions.  This could possibly even be combined with a login script if desired.

Give me a day or two to test it out.

Thanks,
Nicolas
0
 
LVL 1

Author Comment

by:nicolasn
ID: 22667383
Sorry to keep you waiting.  I'm still trying to get a chance to experiment properly with the suggested solutions.

Thanks,
Nicolas
0
 
LVL 1

Author Closing Comment

by:nicolasn
ID: 31501527
Tested and working.  This technique can be used from a batch file with a shortcut on the desktop, or run when I log in.

Thanks for your effort,
Nicolas
0

Featured Post

Turn your laptop into a mobile console!

The CV211 Laptop USB Console Adapter provides a direct Laptop-to-Computer connection for fast and easy remote desktop access with no software to install.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

If your system is showing symptoms of browser hijacks or 'google search redirects' check out my other article (http://rdsrc.us/u3GP7A) first and run the tool TDSSKiller (http://rdsrc.us/GDBBs4) to get rid of the infection. Once done, and if the …
Creating an OSPF network that automatically (dynamically) reroutes network traffic over other connections to prevent network downtime.
Two types of users will appreciate AOMEI Backupper Pro: 1 - Those with PCIe drives (and haven't found cloning software that works on them). 2 - Those who want a fast clone of their boot drive (no re-boots needed) and it can clone your drive wh…
In response to a need for security and privacy, and to continue fostering an environment members can turn to for support, solutions, and education, Experts Exchange has created anonymous question capabilities. This new feature is available to our Pr…

718 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question