Welcome to the most active Linux Forum on the web.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 09-28-2005, 02:18 PM   #1
LQ Newbie
Registered: Sep 2005
Location: New York
Distribution: Asplinux 10
Posts: 4

Rep: Reputation: 0
Question How do you change your Hostname?

I am new to Linux and my Distro is Asplinux ver. 10, I would like to know how do I change my hostname via terminal or desktop, I can not figure it out if my life depended on it.

Joe G.
Old 09-28-2005, 02:40 PM   #2
Registered: Mar 2003
Location: Scotland
Distribution: Slackware, RedHat, Debian
Posts: 12,047

Rep: Reputation: 66
Welcome to LQ.

You just need to run the hostname command:

Also make sure that your new hostname is specified next to the loopback address in your hosts file - /etc/hosts

If you want the change to be permenant then there is usually a text file containing the hostname. In ASPLinux it appears to be /etc/HOSTNAME so just:
echo > /etc/HOSTNAME
Old 09-28-2005, 03:02 PM   #3
LQ Newbie
Registered: Sep 2005
Location: New York
Distribution: Asplinux 10
Posts: 4

Original Poster
Rep: Reputation: 0
Thanks a lot David, I will do as you instructed me to do and yes there is a file in /etc/called "hostname" I will edit this file to reflect the hostname I want.

Thanks again.

Joe G.


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
How do you change your hostname? Thaidog Linux - Newbie 6 07-24-2005 09:52 PM
Change hostname garlam Slackware 2 10-13-2004 03:19 AM
How to change hostname blackbart Linux - Newbie 2 02-01-2004 03:56 PM
change hostname dincer80 Linux - Networking 3 07-31-2003 02:30 AM
change hostname kafnir Linux - Networking 1 10-21-2002 12:10 PM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 09:29 AM.

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