修改centos系统hostname

简单来说,uname -a 可以看到hostname,修改步骤如下:

#uname –a

查看hostname

#hostname Prohost

修改下,让hostname立刻生效。

#vi /etc/hosts

修改原hostname为 Prohost

#vi  /etc/sysconfig/network

修改原hostname为 Prohost,这样可以让reboot重启后也生效

reboot重启,uname -a 重新检查下。

发表评论?

0 条评论。

发表评论


注意 - 你可以用以下 HTML tags and attributes:
<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>