linux 的机器修改hostname: 修改 /etc/hosts修改 /etc/sysconfig/network重启机器reboot 如果不重启机器,想立即生效:sudo hostname newname