ITPub博客

首页 > Linux操作系统 > Linux操作系统 > SUSE修改主机名

SUSE修改主机名

原创 Linux操作系统 作者:fjzcau 时间:2015-01-24 19:35:41 0 删除 编辑

方法1)通过修改配置文件的方式并运行命令修改主机名
修改/etc/HOSTNAME文件,在此文件中保存主机名,例如:
linuxserv1
然后运行命令设置主机名
# /etc/rc.d/boot.localnet start
方法2) 通过yast2管理工具进行配置
在console中运行yast2工具修改主机名(hostname)
# yast2 network
     yast2 修改主机名时变更的文件有:
     /etc/sysconfig/SuSEfirewall2
     /etc/sysconfig/windowmanager
     /etc/sysconfig/network/config
     /etc/sysconfig/network/ifcfg-eth0    IP设置
     /etc/hosts.YaST2save
     /etc/init.d/.depend.boot
     /etc/init.d/.depend.start
     /etc/init.d/.depend.stop
     /etc/init.d/.depend.halt
     /etc/postfix
     /etc/postfix/main.cf
     /etc/modprobe.conf.YaST2save
     /etc/modprobe.d/50-ipv6.conf
     /etc/HOSTNAME
     /etc/udev/rules.d/79-yast2-drivers.rules
     /etc/udev/rules.d/70-persistent-net.rules   网卡MAC配置文件
     /etc/modprobe.conf
     /etc/hosts

来自 “ ITPUB博客 ” ,链接:https://blog.itpub.net/22661144/viewspace-1413424/ ,如需转载,请注明出处,否则将追究法律责任。

下一篇: SUSE 配置 rsh rlogin
请登录后发表评论 登录
全部评论

注册时间:2011-04-03

  • 博文量
    208
  • 访问量
    547159