LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   embarassing hosts question (https://www.linuxquestions.org/questions/linux-newbie-8/embarassing-hosts-question-164197/)

ryedunn 03-30-2004 11:54 AM

embarassing hosts question
 
my hosts file is something like this
127.0.0.1 localhost.localdomain localhost
192.168.1.1 www.mydomain.org <value of HOSTNAME>

after rebooting, it sets my hostname as 192 (ie.. root@192 username)
What in the heck is going on?

R

Gates1026 03-30-2004 12:36 PM

On slackware if I do cat /etc/HOSTNAME it will give me the value of the hostname (ex:Ryan.example.com). What does your output look like?

ryedunn 03-30-2004 12:43 PM

heres the deal
 
ok after entering that into the /etc/hosts file I ran the command
hostname --file /etc/hosts
which would pull the hostname from that file... apparently I made it harder than what it needed to be as
hostname ryan
would have worked just fine

well it looks good now and I appreciate the effort.

BTW
cat /etc/HOSTNAME
cat: /etc/HOSTNAME: No such file or directory

Ryan II


All times are GMT -5. The time now is 11:07 AM.