- 首先我們需要先把centos的網(wǎng)絡配置文件胚膊,/etc/sysconfig/network 把hostname欄目修改
[root@localhost ~]# vi /etc/sysconfig/network
[root@localhost ~]# cat /etc/sysconfig/network
# Created by anaconda
HOSTNAME=hm01
vi /etc/hosts
127.0.0.1 localhost.localdomain #修改localhost.localdomain為orcl1
[root@localhost ~]# cat /etc/hostname
hm01
[root@localhost ~]# ^C
- 重啟電腦
shutdown -r now 或者 reboot
[root@hm01 ~]# hostname
hm01
[root@hm01 ~]# ^C
[root@hm01 ~]#
最后編輯于 :
?著作權(quán)歸作者所有,轉(zhuǎn)載或內(nèi)容合作請聯(lián)系作者