image
AnonymJan 29, 2013

how to change host name in linux based system?

1
0+
0-
Visible
  • Best answer

  • Others answers (1)

  • image
    Jan 29, 2013

    1.Issue the command: hostname new-host-name 2.Change network configuration file: /etc/sysconfig/network Edit entry: HOSTNAME=new-host-name 3.Restart systems which relied on the hostname (or reboot): Restart network services: service network restart (or: /etc/init.d/network restart) Restart desktop: Bring down system to console mode: init 3 Bring up X-Windows: init 5 One may also want to check the file /etc/hosts for an entry using the system name which allows the system to be self aware. The hostname may be changed at runtime using the command: sysctl -w kernel.hostname="superserver"

    0+
    0-
    Comment
  • image