Posted at

/etc/resolv.confが空の場合、/etc/resolvconf/resolv.conf.d/baseに書くとよい

More than 3 years have passed since last update.


参考


現象


/etc/network/interfaces

 auto vmbr0

iface vmbr0 inet static
address 10.0.1.2
netmask 255.255.255.0
gateway 10.0.1.1
+ dns-nameservers 8.8.8.8 8.8.4.4
...

と指定しているのに、/etc/resolv.confが空になる場合の対策


対策


  • /etc/resolvconf/resolv.conf.d/base に書く


/etc/resolvconf/resolv.conf.d/base

nameserver 8.8.8.8

nameserver 8.8.4.4


反映

sudo resolvconf -u