LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   /etc/hosts help! (https://www.linuxquestions.org/questions/linux-newbie-8/etc-hosts-help-185624/)

setska 05-25-2004 08:55 AM

/etc/hosts help!
 
Guys!
I'v screwed everything up.... again. Tell me how the line in /etc/hosts should look like, pleeeeaaase.

thannks much for any help.

setska 05-25-2004 08:57 AM

sorry, almost forgot.
I'm using RH EL

lugoteehalt 05-25-2004 09:23 AM

Code:

#lugo The next line is all that was in the file. I am commenting it out.
#127.0.0.1      debian  localhost
#
#lugo Put in next block to try to get networking.
127.0.0.1      localhost
192.168.1.1    debian.domain.org      debian
192.168.1.2    apricot.domain.org      apricot

This is mine but on Debian.

Grasshopper 05-25-2004 09:23 AM

At the very least your /etc/hosts file should read:

127.0.0.1 localhost.localdomain localhost

If you have changed your hostname and your domain then you will have to make some minor changes.

For example we'll pretend your hostname is my_hostname and your domain is my_domain.com , then your /etc/hosts would read:


127.0.0.1 my_hostname.my_domain.com localhost.localdomain localhost my_hostname

setska 05-25-2004 09:33 AM

IT DID WORK!!
Thank you guys very much.
have a good day.
I'm pretty sure I'll be back later with more screw ups though :)


All times are GMT -5. The time now is 09:38 PM.