LoginSignup
38
37

More than 5 years have passed since last update.

Ubuntuでのresolv.confの扱い

Last updated at Posted at 2014-10-08

ubuntu 12.04 からは、/etc/resolv.confで直接編集は行なわない。

/etc/network/interfacesで以下のように設定する。

/etc/network/interfaces
dns-nameservers 8.8.8.8

再起動で設定が反映される。

shell
sudo service networking restart

dns-nameserversの設定は不要だろうと思って消してしまい、
しばらく経って設定が更新されたタイミングで、名前解決ができなくなってしまってハマった。

参考

ubuntu での /etc/resolv.conf の設定
http://d.hatena.ne.jp/yamionp/20131231/1388510334

38
37
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
38
37