I was hoping to set my local host in my resolv.conf to hermes. So in affect if I type in hermes:8080 into the browser, I get the localhost:8080
How is this accomplished?
Please and thank you.
I was hoping to set my local host in my resolv.conf to hermes. So in affect if I type in hermes:8080 into the browser, I get the localhost:8080
How is this accomplished?
Please and thank you.
You need it in /etc/hosts
, not /etc/resolv.conf
.
And your host name should already appear in /etc/hosts
.
What does it say when you run this from the terminal?
grep '127.0.1.1' /etc/hosts
What about:
cat /etc/hostname
You can add it to /etc/hosts, like this:
127.0.0.1 hermes
(127.0.0.1 is the same as localhost)
127.0.0.1
entry, things will break. It should be added using a separate entry 127.0.1.1 hermes
, but it should have already been added by NetworkManager, so there is another problem.
127.0.0.1
and 127.0.1.1
. You said 127.0.0.1
, which should just be 127.0.0.1 localhost
(or 127.0.0.1 localhost.localdomain localhost
or similar).
127.0.0.1
entry, then some things will work, but reverse lookups (e.g. getent hosts 127.0.0.1
) won't return your host name, which could break some things.