WeaponX 0 Report post Posted January 18, 2006 Hi, I want to configure a laptop so it will work in both static and dynamic (DHCP) environments. I have setup my home network using static IP addressing but the college uses dynamic addressing. Home is using wireless and I guess if it's used at the college, it will probably be wireline.Was thinking about this over the other day and just want to verify if this will work (since the laptop doesn't belong to me...and I don't have access to it a lot of times). If I set the default connection (TCP/IP Properties) to be automatic obtain IP and the alternate connection to static, will that work? I have SSID and password for my home network...I just don't want to reconfigure everything again each time the laptop is used at home. The user is not computer savvy...so I would have to do it if there is no way around it.Thanks. Share this post Link to post Share on other sites
blackbart 0 Report post Posted January 29, 2006 Would be easier to address if you gave us some information on your operating system. If you are in linux you could set up two network configuration files on slackware the file is /etc/rc.d/ rc.inet1.conf Config information for eth0:IPADDR[0]="192.168.1.125"NETMASK[0]="255.255.255.0"USE_DHCP[0]="no"DHCP_HOSTNAME[0]=""...........# Default gateway IP address:GATEWAY="192.168.1.1" As yu can see there are settings for the address, using DHCP and the default gateway. there are many more entries in the file for how ever many interfces you may have. open the file in your favorite editor and set it up for a fixed IP by entering your config in the appropriate lines. save this file as rc.inet1.fixednow remove the mask, address and gateway values and replace the value for "USE_DHCP[0]" to "yes."Save this file as rc.inet1.dhcp. you can now write a simple shell script to copy the proper file to rc.inet1.conf. #!/bin/shcp /etc/rc.d/rc.inet1.$1 /etc/rc.d/rc.inet1.confsave it as chnetconf, or whatever, chmod it to 755 and call it with "chnetconf (fixed or dhcp)"This is all real basic and there are other aspects to consider such as user rights and chmodding the files to writable, etc. but if you'e linux geek it oughta be cakeIF, you have windoze:You'll have to be comforatable working in regedit you can export the TCPIP configuration for your fixed ip config from within regedit to a fixed.reg file then go in through control panel and change the config to DHCP and export the settings again to a dhcp.reg file.These files can be double clicked to update the registry for the desired effect or, yu can write a .cmd file to call regedit with the proper file name depending on the desired effect. My Windoze is rusty so do a little msn search on "parameters in .cmd files" for your answer to that one.I'd just put shortcuts to the .reg files on the desktop or in the menu with labels like 'Change to DHCP" & "Change to Fixed IP" Share this post Link to post Share on other sites
iGuest 3 Report post Posted March 20, 2011 Configure Laptop To Work On Static And DHCPConfigure Laptop To Work On Static And DHCPIn most versions of windows on the properties of the internet protocol version 4 there is a general tab and a alternate tab Set the general tab up for automatic (DHCP) and the alternate tab to your static settings your computer will try to get a address automatically via DHCP and if it can't get a address because there is no DHCP server on the network it will use the alternate static setup you entered. for most versions of windows START>Settings>Control panel> Network > find the LAN network connection and look for properties on one of the tabs. Then in the list look for Internet protocol version 4 TC/IP V4 and double click or highlight and click properties. Vista it is - Start>control panel> all control panel items>Network and sharing center... Then look for and click Local Area Connection > properties then double click TCP/IPv4 and setup the general and alternate tabs as described. I will not be coming back here anytime soon so if you have problems ask others.-reply by Gilbert Share this post Link to post Share on other sites