LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Networking (https://www.linuxquestions.org/questions/linux-networking-3/)
-   -   renaming your box (this SHOULD) be easy (https://www.linuxquestions.org/questions/linux-networking-3/renaming-your-box-this-should-be-easy-163623/)

milesstandish 03-29-2004 12:19 AM

renaming your box (this SHOULD) be easy
 
in rh9, you could rename your box just by changing the name from localhost inside of the nic card window. in enterprise this seems to cause an error that gives you a window right before logging in about "can't find _____. try adding it to whatever". i did add it. and i did it under the nic and i played with variations on all of it. and i still get the same thing. help?

maxut 03-29-2004 06:29 AM

edit "/etc/hosts" and add your new hostname..


example: u changed your linux box name to linux.domain.com
your hosts file can be like this:

127.0.0.1 localhost.localdomain localhost linux.domain.com linux


it will work with no problem.



if u want to change your linux hostname edit "/etc/sysconfig/network" like this:

HOSTNAME=linux.domain.com

R4z0r 03-29-2004 07:38 AM

I just do:

# echo newhostname > /etc/hostname
# hostname -F /etc/hostname


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