centos 7修改方式:

hostnamectl  set-hostname   hostuser

reboot 

或者直接vi /etc/hostname

添加内容:

hostuser

 

 检查修改效果

[chenquan@hostuser ~]$ hostname
hostuser
[chenquan@hostuser ~]$ cat /etc/hostname
hostuser
[chenquan@hostuser ~]$

 

相关文章:

  • 2021-12-09
  • 2022-02-05
猜你喜欢
  • 2021-12-18
  • 2021-12-18
  • 2021-12-18
  • 2021-12-18
  • 2022-02-07
相关资源
相似解决方案