Hacker News new | ask | show | jobs
by jlgaddis 3022 days ago
Presumably, you mean:

  echo 8.8.8.8 > /etc/resolv.conf
2 comments

Usually you need "nameserver 8.8.8.8", not just the IP. Or is a plain IP accepted as well?
:D its funny how many mistakes you can do in a single command:

- yes, I wanted to write to /etc/resolv.conf

- yes, I wanted to write "nameserver 8.8.8.8"

- overwriting the file was intentional as otherwise the old nameserver would still be first.

  echo "nameserver 8.8.8.8" > /etc/resolv.conf
Too bad, I can't edit my initial post and correct the complete nonsense.
I'm guessing you want to append instead of overwriting, too? :)