變更hostname(不用reboot可生效)
發表於 : 2012-05-08 13:07:30
http://www.brandonhutchinson.com/Changi ... _RHEL.html
1. Change the ^HOSTNAME line in /etc/sysconfig/network
2. Change the hostname (FQDN and alias) in /etc/hosts
3. Run /bin/hostname new_hostname for the hostname change to take effect immediately.
4. Run /sbin/service syslog restart for syslog to log using the new hostname.
A reboot is not required to change the system hostname.
1. Change the ^HOSTNAME line in /etc/sysconfig/network
2. Change the hostname (FQDN and alias) in /etc/hosts
3. Run /bin/hostname new_hostname for the hostname change to take effect immediately.
4. Run /sbin/service syslog restart for syslog to log using the new hostname.
A reboot is not required to change the system hostname.