# dhcpcd doesn't create/update resolv.conf anymore [SOLVED]

## VinzC

Hi.

I've run dhcpcd manually (dhcpcd -h myhost -t 10 eth0) and I can see /etc/resolv.conf is no longer updated. I've rm'd /etc/resolv.conf* and run the dhcpcd command again, the file is no longer created.

Does anybody have an idea on what's going on/where I should look?

Thank you in advance.

----------

## bunder

/etc/conf.d/net ?

cheers

----------

## didymos

Can you run it again and add the "-d" option?  Maybe the debug info will provide a clue.

----------

## VinzC

 *bunder wrote:*   

> /etc/conf.d/net ?

 

Empty. But the problem arises even when I'm running dhcpcd manually, so the network configuration file is out of cause.

----------

## VinzC

 *didymos wrote:*   

> Can you run it again and add the "-d" option?  Maybe the debug info will provide a clue.

 

Woops... I was looking for a -v switch  :Embarassed:  ...

```
Info, eth0: dhcpcd 3.0.16 starting

Info, eth0: hardware address = 00:18:8b:c7:aa:ed

Info, eth0: broadcasting for a lease

Debug, eth0: sending DHCP_DISCOVER with xid 151310584

Debug, eth0: waiting on select for 10 seconds

Debug, eth0: got a packet with xid 151310584

Info, eth0: offered 10.10.2.222 from 10.10.4.20

Debug, eth0: sending DHCP_REQUEST with xid 151310584

Debug, eth0: waiting on select for 10 seconds

Debug, eth0: got a packet with xid 151310584

Info, eth0: leased 10.10.2.222 for 14400 seconds

Debug, eth0: renew in 7200 seconds

Debug, eth0: rebind in 12600 seconds

Info, eth0: adding IP address 10.10.2.222/16

Info, eth0: adding default route via 10.10.5.254 metric 0

Debug, eth0: sending DNS information to resolvconf

Debug, eth0: ntp already configured, skipping

Debug, eth0: writing /var/lib/dhcpcd/dhcpcd-eth0.info

Debug, eth0: forking to background
```

BTW I have net-misc/dhcpcd-3.0.16-r1. Does it mean someting special? And what is that resolvconf thing?... I have no such process  :Shocked:  .

----------

## didymos

Did you maybe emerge net-dns/resolvconf-gentoo at some point?

----------

## VinzC

 *didymos wrote:*   

> Did you maybe emerge net-dns/resolvconf-gentoo at some point?

 

That's where I'm investigating at the moment: I've seen dnsmasq, which I'm using with Qemu virtual machines, has a dependency on resolvconf. I now remember I enabled that use flag, thinking I was going to read further but I didn't  :Very Happy:  as usual ...

I'm currently reading the man pages for that. There is a paragraph about /etc/resolv.conf no longer being updated.

 *man resolvconf wrote:*   

> To  make  the  resolver  use  the dynamically generated resolver configuration file the administrator should ensure that /etc/resolv.conf is a symbolic link to /etc/resolvconf/run/resolvconf/resolv.conf.  This link is never modified by /sbin/resolvconf.  If you find that /etc/resolv.conf is not being updated, check to see that the  link  is intact.

 

Sorry for the silly question. File /etc/resolv.conf has to be a symlink to /etc/resolvconf/run/resolvconf/resolv.conf. BTW won't there be a problem with my PPTP client and resolv.conf as this program directly manipulates the resolv.conf file by creating backups and writing its own file?

----------

## didymos

I don't have any idea.  I installed it once, ages ago, and it played a similar game with my resolv.conf.  I just ditched it and went back to /etc/resolv.conf.  Unless you have a fairly complicated dns setup or need multiple configurations, I'd just get rid of the thing.

----------

## VinzC

 *didymos wrote:*   

> I don't have any idea.  I installed it once, ages ago, and it played a similar game with my resolv.conf.  I just ditched it and went back to /etc/resolv.conf.  Unless you have a fairly complicated dns setup or need multiple configurations, I'd just get rid of the thing.

 

Indeed. There is no such directory /etc/resolvconf/run/resolvconf/. I placed the resolv.conf file in /etc/resolvconf/run/ and symlinked /etc/resolv.conf to that file but it didn't help. Note I expect it doesn't since the directory in which I put the file is not the one mentioned in the man pages. I think I'll cope without resolvconf.

Thanks for your help.

----------

## VinzC

I recompiled dnsmasq with -resolvconf, removed resolvconf-gentoo and recompiled dhcpcd. Problem solved  :Smile:  . Thanks again.

----------

## kiksen

Thanks for the resolvconf-gentoo tip - just saved my day.

resolvconf-gentoo... right. vpnc pulls it in. Actually the merge tells about the symlink change so shame on me.

/kiksen

----------

