新网创想网站建设,新征程启航

为企业提供网站建设、域名注册、服务器等服务

OracleLinux7修改hostname-创新互联

Linux修改hostname的常用操作方法是——手工在/etc/sysconfig/network中追加"HOSTNAME=xxxxx"并重启系统,这个方法在Oracle Linux 7中是不生效的。
那么在Oracle Linux 7中怎么配置hostname?
来源于:
How to Configure hostname in Oracle Linux 7 (Doc ID 2049221.1)
解决方案:
请使用如下三种方法的任意一种来修改Oracle Linux 7中的主机名
1. use hostname control utility: hsotnamectl
2. use NetworkManager command line tool: nmcli
3. edit /etc/hostname file directly (a reboot afterwards is required)

1. Use hsotnamectl which is a command-line client to systemd-hostnamed service

Get current hostname status:

成都创新互联公司坚持“要么做到,要么别承诺”的工作理念,服务领域包括:网站设计、做网站、企业官网、英文网站、手机端网站、网站推广等服务,满足客户于互联网时代的苍溪网站设计、移动媒体设计的需求,帮助企业找到有效的互联网解决方案。努力成为您成熟可靠的网络建设合作伙伴! [root@localhost ~]# hostnamectl status
   Static hostname: localhost.localdomain
  Operating System: Oracle Linux Server 7.1
       CPE OS Name: cpe:/o:oracle:linux:7:1
            Kernel: Linux 3.8.13-55.1.6.el7uek.x86_64
      Architecture: x86_64
本文标题:OracleLinux7修改hostname-创新互联
分享路径:http://www.wjwzjz.com/article/csjeip.html
在线咨询
服务热线
服务热线:028-86922220
TOP