Page 1 of 2 12 LastLast
Results 1 to 10 of 13

Thread: How to change hostname?

  1. #1
    Join Date
    Jun 2008
    Location
    Belgi
    Posts
    183

    Default How to change hostname?

    Currently my hostname is "unknown0015f26474fe", how can I change this? I've tried via /etc/hosts in KDE before but it didn't work, even after a reboot. I found it before in KDE but forgot where it was...

    OpenSUSE should really add this feature to the installer because it's annoying that I can't set this at install time.

  2. #2
    ab@novell.com NNTP User

    Default Re: How to change hostname?

    -----BEGIN PGP SIGNED MESSAGE-----
    Hash: SHA1

    During the installation on the Network section you there is a checkbox
    that says, basically, "Set hostname via DHCP" so it could be anything.
    You can uncheck that and set your host name permanently along with
    anything else name-ish (like DNS).

    Good luck.





    EarthMind wrote:
    | Currently my hostname is "unknown0015f26474fe", how can I change this?
    | I've tried via /etc/hosts in KDE before but it didn't work, even after
    | a reboot. I found it before in KDE but forgot where it was...
    |
    | OpenSUSE should really add this feature to the installer because it's
    | annoying that I can't set this at install time.
    |
    |
    -----BEGIN PGP SIGNATURE-----
    Version: GnuPG v1.4.2 (GNU/Linux)
    Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

    iD8DBQFIak/i3s42bA80+9kRAg7EAJ99S/jpcXDigRirXc4kvo1EouYPKQCfSBxH
    g5z81YmH+kxEXzOef4zxxtg=
    =OWfF
    -----END PGP SIGNATURE-----

  3. #3

    Default Re: How to change hostname?

    You can find this in the Networksettings in Yast. There is a tab "Hostname".

  4. #4
    Join Date
    Jun 2008
    Location
    Belgi
    Posts
    183

    Default Re: How to change hostname?

    Thank you both, I remember it was there I found it before

  5. #5
    Join Date
    Jun 2008
    Location
    Netherlands
    Posts
    15,616

    Default Re: How to change hostname?

    And maybe the following because I probably see a slight misunderstanding here (when you don't mind).

    As usualy there are more interpretations of the word hostname.

    In network terms the hostname is a name given to an IP address to be better understandable by human beings. To translate between hostnames and IP addresses we have of course DNS and /etc/hosts. But as your system may have more IP addresses (more NICs or more IP addresses on one NIC or both) this does not define the hostname. It is the habbit to have the hostname (type hostname in a console) the same as the hostname of one of the (the most important?) IP address of the system (that is with the domain part cut off at the end).

    So by changing the name in /etc/hosts, you change the name bound to an IP address as know inside your host.

    By changing the hostname (with domain) in the DNS world you change the name bound to the IP address as known to the world.

    By changing the hostname with the hostname command you change a name of the host internal in your system (that is used by the kernel and other software).

    By using YaST (as was advised above) this changing is made easier then by hand.
    Henk van Velden

  6. #6
    Join Date
    Apr 2010
    Location
    Chicago, IL
    Posts
    158

    Default Re: How to change hostname?

    This might be an old topic, but I changed my hostname in the "Hostname" section of YaST, but my prompt still uses the old hostname. Am I missing something?

  7. #7
    Join Date
    Jun 2008
    Location
    Podunk
    Posts
    16,025
    Blog Entries
    14

    Default Re: How to change hostname?

    Quote Originally Posted by kog13
    This might be an old topic, but I changed my hostname in the "Hostname"
    section of YaST, but my prompt still uses the old hostname. Am I missing
    something?
    Hi
    Have you logged out/logged in? If it's a terminal session you need to
    close and re-open for the profile to re-read.

    --
    Cheers Malcolm (Linux Counter #276890)
    SUSE Linux Enterprise Desktop 11 (x86_64) Kernel 2.6.27.45-0.1-default
    up 7 days 6:28, 3 users, load average: 0.13, 0.23, 0.20
    GPU GeForce 8600 GTS Silent - CUDA Driver Version: 190.53


  8. #8
    Join Date
    Apr 2010
    Location
    Chicago, IL
    Posts
    158

    Default Re: How to change hostname?

    I didn't log out and in, but I have rebooted, which should have done the same thing.

    The other part about using YaST is that I'm not sure exactly which fields I'm supposed to change. Hostname or Host alias for 127.0.0.1, or one/both of those values for 127.0.0.2? What's the difference, exactly?

    I think I may have been able to get a different hostname at the command prompt by editing /etc/HOSTNAME, but everything I've read says that YaST can do the same thing, which in my experience, it doesn't.

  9. #9
    Join Date
    Jun 2008
    Location
    Podunk
    Posts
    16,025
    Blog Entries
    14

    Default Re: How to change hostname?

    Quote Originally Posted by kog13
    I didn't log out and in, but I have rebooted, which should have done the
    same thing.

    The other part about using YaST is that I'm not sure exactly which
    fields I'm supposed to change. Hostname or Host alias for 127.0.0.1, or
    one/both of those values for 127.0.0.2? What's the difference, exactly?

    I think I may have been able to get a different hostname at the command
    prompt by editing /etc/HOSTNAME, but everything I've read says that YaST
    can do the same thing, which in my experience, it doesn't.
    Hi
    A strange one, did you only use YaST for the hostname change?

    Is the hostname present in /etc/HOSTNAME and /etc/hosts did you also
    add add a domain in the box to the right of where you entered the
    hostname in YaST?

    --
    Cheers Malcolm (Linux Counter #276890)
    SUSE Linux Enterprise Desktop 11 (x86_64) Kernel 2.6.27.45-0.1-default
    up 7 days 13:48, 3 users, load average: 0.35, 0.34, 0.29
    GPU GeForce 8600 GTS Silent - CUDA Driver Version: 190.53


  10. #10
    Join Date
    Apr 2010
    Location
    Chicago, IL
    Posts
    158

    Default Re: How to change hostname?

    Changing the values in YaST changed them in /etc/hosts, but not in /etc/HOSTNAME. I had to change /etc/HOSTNAME manually. What exactly do you mean by a domain? The only box to the right of Hostname is "Host alias".

Page 1 of 2 12 LastLast

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •