Solved

Swapping TCP/IPv4 Settings

Posted on 2015-01-12
6
121 Views
Last Modified: 2015-01-16
I'm working on four to six small Windows based networks a day installing firewalls. The networks I run into either utilize a 10.1.10.x, 192.168.1.x or other addressing scheme. I'm always changing my Laptop to a different IP scheme.

Is there an app I can run from a flash drive that  stores each IP scheme in a small DB and allows me to select which scheme I want that Pc to use?
0
Comment
Question by:Tony Giangreco
[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
  • 4
  • 2
6 Comments
 
LVL 9

Accepted Solution

by:
Trenton Knew earned 500 total points
ID: 40545066
you can probably accomplish this by using a pair of small batch files.

just need a couple lines like this...
netsh int ip set address name="Local Area Connection" address=10.1.10.x/24 gateway=10.41.10.x source=static

Open in new window


if you need to define alternate DNS servers, you can add the following line as well.
netsh int ip set dnsservers name="Local Area Connection" source=static address="10.1.10.x"

Open in new window

0
 
LVL 25

Author Comment

by:Tony Giangreco
ID: 40545245
I've tested the IP address command in a batch file and it works well.  I don't find a way to set the secondary dns. The primary works well.

Any suggestion?
0
 
LVL 9

Expert Comment

by:Trenton Knew
ID: 40545268
yes, repeat the command with index=2

netsh int ip set dnsservers name="Local Area Connection" source=static address="10.1.10.x" index=2

Open in new window

0
Don't Miss ATEN at InfoComm 2017!

Visit booth #2167 to see the  new ATEN VM3200 32 x 32 Modular Matrix Switch. Other highlights include the VE8950 4K HDMI Over IP Extender, VS1912 12-Port DP Video Wall Media Player  and VK2100 ATEN Control System. Register now with Free Pass Code ATEN288!

 
LVL 25

Author Comment

by:Tony Giangreco
ID: 40545321
I'm running this on Win 7 pro. I'm getting a syntax error when I tried index. Can you see if something is missing?
0
 
LVL 9

Expert Comment

by:Trenton Knew
ID: 40545369
my apologies... need to do ADD instead of SET

netsh int ip add dnsservers name="Local Area Connection 2" address="10.x.x.x" index=2

"source=static" becomes unnecessary
0
 
LVL 9

Expert Comment

by:Trenton Knew
ID: 40545374
Final file should look like this...

netsh int ip set address name="Local Area Connection" address=10.1.10.x/24 gateway=10.1.10.x source=static
netsh int ip set dnsservers name="Local Area Connection" source=static address="10.x.x.x"
netsh int ip add dnsservers name="Local Area Connection" address="10.x.x.x" index=2

Open in new window

0

Featured Post

How Do You Stack Up Against Your Peers?

With today’s modern enterprise so dependent on digital infrastructures, the impact of major incidents has increased dramatically. Grab the report now to gain insight into how your organization ranks against your peers and learn best-in-class strategies to resolve incidents.

Question has a verified solution.

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

Creating an OSPF network that automatically (dynamically) reroutes network traffic over other connections to prevent network downtime.
As companies replace their old PBX phone systems with Unified IP Communications, many are finding out that legacy applications such as fax do not work well with VoIP. Fortunately, Cloud Faxing provides a cost-effective alternative that works over an…
In this tutorial you'll learn about bandwidth monitoring with flows and packet sniffing with our network monitoring solution PRTG Network Monitor (https://www.paessler.com/prtg). If you're interested in additional methods for monitoring bandwidt…
In this video we outline the Physical Segments view of NetCrunch network monitor. By following this brief how-to video, you will be able to learn how NetCrunch visualizes your network, how granular is the information collected, as well as where to f…

705 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