[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: switching to DHCP in a clean manner ...



Glenn Becker wrote:

Hi all -

I just moved from the NY metro area to the Boston metro area, and in the process changed ISPs. My service is now significantly faster and cheaper, but my account now assigns IPs dynamically -- previously, I'd had a static IP.

I have the /option/ with the new provider to get a static IP but I decided to try the DHCP thing since the static is an extra charge ... all I have done is add the line "exec dhclient" to /etc/rc.local. Now, this _works_, but I don't know that it is the best solution and I suspect I may have config files in there with the old IP/gate/and so forth numbers in them. It has been so long since I set that networking up that I've kind of forgotten the Best Way to Do It ... and the best way to clean it up and switch over to something else.

Can someone point me toward a good doc to read on this, or let me know if I am going about this in an absurdly inelegant way. Like I say, it works but I don't know that it is as good as it could be.

Maybe I'm worrying it too much.

Thanks,

GB



Probably the best thing to do is edit /etc/network/interfaces to reflect your new network settings. You will probably want to have something like this:
auto eth0
iface eth0 inet dhcp

where eth0 is your network device, if you have one that has static in the line, comment that out and any other lines, such as address, network or gateway.


--
8 out of 10 Owners who Expressed a Preference said Their Cats Preferred Techno.


Reply to: