There's no such thing as a stupid question, but they're the easiest to answer.
JoinTour
Login
 
Tag Cloud
access audio avg avg 8 bios blue screen boot bsod computer connection cpu crash css dell desktop dma driver drivers dvd email error excel explorer firefox firefox 3 freeze gimp graphics hard drive hardware hijackthis hjt install internet internet explorer itunes keyboard laptop macro malware monitor motherboard network networking outlook outlook 2003 outlook 2007 outlook express pio problem problems router seo server slow sound sp3 spyware trojan usb video virtumonde virus vista vundo windows windows vista windows xp winxp wireless
DOS/PDA/Other
Search
Search in:
 
Advanced Search
Tech Support Guy Forums > Operating Systems > DOS/PDA/Other >
DOS Command 4 changing IP (Please Help)


HELLO AND WELCOME! Before you can post your question, you'll have to register -- it's completely free! Click here to join today! We highly recommend that you print a copy of our Guide for New Members. Enjoy!

 
Thread Tools
Duckman69's Avatar
Computer Specs
Senior Member with 641 posts.
 
Join Date: Jun 2007
06-Jul-2007, 11:26 PM #1
DOS Command 4 changing IP (Please Help)
Does any1 rember the dos command for changing your ip threw command prompt, thank you for your help in advance it is much appricated...
ghostdog74's Avatar
Member with 90 posts.
 
Join Date: Dec 2005
07-Jul-2007, 06:33 AM #2
here's an example vbscript
Code:
Set Adapters=GetObject("winmgmts:{impersonationLevel=impersonate}!\\" & "." & "\root\cimv2").ExecQuery("select * from Win32_NetworkAdapterConfiguration where IPEnabled=true")

IPArray = Array("192.168.1.100")
MaskArray = Array("255.255.255.0")
GatewayArray = Array("192.168.1.1")
GatewayMetric = Array(1)
For each NIC in Adapters
   NIC.EnableStatic IPArray, MaskArray
   NIC.SetGateways GatewayArray, Gatewaymetric
Next
ViprXX's Avatar
Senior Member with 378 posts.
 
Join Date: May 2007
Experience: Advanced
07-Jul-2007, 06:36 AM #3
do you mean type ipconfig /release and press Enter. Then, type ipconfig /renew in command prompt?
JohnWill's Avatar
Computer Specs
Moderator with 77,380 posts.
 
Join Date: Oct 2002
Location: South Eastern PA, USA
Experience: Advanced age & experience
07-Jul-2007, 01:05 PM #4
Depending on what you're connected to, you can't simply change your IP address. Perhaps if you told us what you are doing, and what environment you're in, that would help.
ChuckE's Avatar
Senior Member with 1,856 posts.
 
Join Date: Aug 2004
Location: Redondo Beach, CA
Experience: Advanced
07-Jul-2007, 05:22 PM #5
If you are getting your IP address from an ISP (Internet Service Provider) you can't change what they assign you. Your IP address is whatever they, usually, dynamically assign you. Meaning, that while your IP address may be the same, from day to day, since they usually use their same assignments from day to day; there is nothing to stop them from changing it on you. That is, UNLESS you are paying more for a fixed IP address, and in that case, you still can't change it.

It you have a home router, and your computer is getting a dynamic address from it, then while you can release the current address and then renew the IP address. The chances are that your home router will give you the same address again, unless you happen to have other devices grabbing dynamic addresses in-between the time you've released and then renewed.

Now, if you do have a home router, and you want to define your own IP address (making it static) you probably can do so (depends upon your router). But to do so, you will still be limited to a range of addresses that your home router can used, most probably in the 192.168.*.* range.

To set your computer to a static address is not done normally from a command line. But, I would not rule out some more elaborate command line calling up some clever registry change file.

To change a computer's static IP address would typically be done by changing your defined Network Connections, Local Area Connection Properties.
__________________
Rehab is for quitters.
Duckman69's Avatar
Computer Specs
Senior Member with 641 posts.
 
Join Date: Jun 2007
08-Jul-2007, 09:38 PM #6
Thanks for the vb script ill have to give it a go later this week & sorry about not having the information at the end of my posts im going to update that soon... im not on my regular computer thats getting fixed by gateway at the moment... shot my mo bo to hell

also thanks for the reply again chucke, with what you said lets say i wanted to change the ip manually the way you mentioned by going to tcp/ip settings & then properties i can assign a static ip ...

if i assign an ip i need to use the ISP range and then i can make the rest up myself... so if i set that up properly, what do i do with the preferred DNS & secondary DNS i havent done this in awhile i left them blank when i tried the 1st time and it wouldnt work no connection to internet... so if you know what i should do for the dns feild i would appricate it thanks...
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are Off
Refbacks are Off

You Are Using:
Server ID
Advertisements do not imply our endorsement of that product or service.
All times are GMT -4. The time now is 10:03 PM.
Copyright © 1996 - 2008 TechGuy, Inc. All rights reserved.
Powered by vBulletin, Copyright © 2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.1.0
Powered by Cermak Technologies, Inc.