Want DHCP on IP but NOT on DNS. How can I do this?[Solved]

Issues Related to Networking (Wired and Wireless)

Moderator: Moderators

Want DHCP on IP but NOT on DNS. How can I do this?[Solved]

Postby PaulFXH » Thu Jan 10, 2008 21:16

I'm just in the process of setting up Sabayon 3.4f to run on my MacBook and going OK so far.
However, I need to run with specific DNS servers and not just the default DNS (router address).
Now I know I can do this through net-setup but this also requires me to choose just one IP.
What I want, and what I have done in other distros, is to DHCP the IPs but to add my own preferred DNS servers.
In Ubuntu, I use /etc/dhcp3/dhclient.conf for this but there isn't anything exactly similar in Sabayon AFAICS.
I might be able to use /etc/resolv.conf but how do I stop the DHCP from overwriting this?
Can anybody please advise?
Thanks
Paul
PaulFXH
Baby Hen
 
Posts: 15
Joined: Wed Jan 09, 2008 23:46

Re: Want DHCP on IP but NOT on DNS. How can I do this?

Postby PaulFXH » Fri Jan 11, 2008 1:13

OK, I've actually resolved this by using the existing /etc/dhcp/dhclient.conf.sample, modifying the file to prepend the DNSs I wanted and then saving the file as /etc/dhcp/dhclient.conf
Works perfectly although I still can't believe it took so long to see that example file was already there waiting to be modified. :oops:
PaulFXH
Baby Hen
 
Posts: 15
Joined: Wed Jan 09, 2008 23:46


Return to Networking and Wireless

Who is online

Users browsing this forum: No registered users and 2 guests