LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices



Reply
 
Search this Thread
Old 02-01-2002, 06:52 PM   #1
glock19
Member
 
Registered: Aug 2001
Distribution: Debian Etch
Posts: 510

Rep: Reputation: 31
changing hostname


What is the right way to change my system's hostname, through the command line?
 
Old 02-01-2002, 08:33 PM   #2
kbaldor
LQ Newbie
 
Registered: Jan 2002
Distribution: Red Hat 7.2
Posts: 21

Rep: Reputation: 15
hostname command

The hostname command will allow you to change your hostname, but this didn't solve all of my networking problems.

The change that seems to have worked best was to manually change /etc/hosts to reflect my new name. The address 127.0.0.1 corresponds to the local machine.

Note: when I changed the name, my printer daemon stopped working, to fix this, I put my old name localhost.localdomain.com as a second 127.0.0.1 computer. I put this line under my correct name just in case, but I don't think that this mattered.

P.S. have you visited GlockTalk, I'm called "whirled peas" over there
 
Old 02-01-2002, 08:35 PM   #3
glock19
Member
 
Registered: Aug 2001
Distribution: Debian Etch
Posts: 510

Original Poster
Rep: Reputation: 31
I've been there, I remember your name even.

But lately I've been hanging at sigforum.com.
 
Old 02-01-2002, 10:26 PM   #4
DavidPhillips
Guru
 
Registered: Jun 2001
Location: South Alabama
Distribution: Fedora / RedHat / SuSE
Posts: 7,155

Rep: Reputation: 56
put this in /etc/sysconfig/network

HOSTNAME=yourhostname


and setup /etc/hosts
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
changing hostname sh4d0w13 Debian 4 06-14-2005 11:45 AM
hostname changing rusty_slacker Linux - General 2 04-15-2005 07:49 PM
Changing hostname? Alf829 Linux - Networking 2 03-08-2004 09:31 AM
Hostname changing Neorio Linux - Networking 2 01-03-2004 08:11 PM
Changing hostname tristan2600 Linux - Newbie 1 10-17-2003 09:18 PM


All times are GMT -5. The time now is 06:01 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration