Results 1 to 4 of 4

Thread: mystery: how does hostname get set on karmic

  1. #1
    Join Date
    Mar 2010
    Beans
    11

    mystery: how does hostname get set on karmic

    I just set up a new karmic server, and the hostname is being set properly, but I'm not exactly sure how, since there is no longer an init script that sets it (it used to be /etc/init.d/hostname.sh on my older servers). Now I'm curious: what is the new mechanism by which the server's hostname is set at boot time?

  2. #2
    Join Date
    Nov 2009
    Beans
    Hidden!
    Distro
    Kubuntu 10.10 Maverick Meerkat

    Re: mystery: how does hostname get set on karmic

    Ask the Oracle: "man hostname"

  3. #3
    Join Date
    Mar 2010
    Beans
    11

    Re: mystery: how does hostname get set on karmic

    I'm not sure you understand the question. Used to be, there was a script, /etc/init.d/hostname.sh, which read the file /etc/hostname, then called 'hostname' (the program you mention) in order to actually set the hostname. Who calls 'hostname' now? None of the rc scripts do it, so how does it get done?

  4. #4
    Join Date
    Nov 2009
    Beans
    Hidden!
    Distro
    Kubuntu 10.10 Maverick Meerkat

    Re: mystery: how does hostname get set on karmic

    To detail it more, Ubuntu uses upstart mostly and is trying to get away from the old System V init scripts. You should see a hostname.conf job that sets the hostname from the files you mentioned at boot time.

Bookmarks

Posting Permissions

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