dhcpcd-discuss

Re: Multiple static DNS addresses

Roy Marples

Fri Jul 20 13:41:31 2012

On 20/07/2012 14:31, Leonardo Guilherme wrote:
>     A command inside python it is. I am trying to fix an issue with wicd
>     (https://bugs.launchpad.net/wicd/+bug/145405) with static dns. It
>     writes /etc/resolv.conf after a connection is estabilished but
>     everytime dhcpcd renews a lease, /etc/resolv.conf is rewritten with
>     information from the dhcp server, which is not desirable in this case.
> 
>     The command is something like this: 
> 
>     dhcpcd -h host --noipv4ll -S %s eth0 % ' '.join(dns)
> 
> 
> Actually it is
> 
> dhcpcd -h host --noipv4ll -S domain_name_servers=%s eth0 % ' '.join(dns)

I don't know enough python to help sorry.

But maybe you could solve it another way by NOT running the resolv.conf hook

dhcpcd -h host --noipv4ll --nohook resolv.conf eth0

The command is slightly different for dhcpcd-4 and older, but I think
from memory you can use -D in those versions.

Thanks

Roy

Follow-Ups:
Re: Multiple static DNS addressesLeonardo Guilherme
References:
Multiple static DNS addressesLeonardo Guilherme
Re: Multiple static DNS addressesRoy Marples
Re: Multiple static DNS addressesLeonardo Guilherme
Re: Multiple static DNS addressesLeonardo Guilherme
Archive administrator: postmaster@marples.name