Changing hostname on RHEL/CentOS.

2013-03-19

Changing hostname on RHEL/CentOS.

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.

More information:
http://kbase.redhat.com/faq/FAQ_45_2062.shtm

分类:Linux操作系统 | 标签: |

相关日志

评论被关闭!