hostname 的更改 Oracle Linux 6.5 && RHEL 7.0-Adela
Example:将bogon 改为 adelababyOracle Linux 6.5
# hostname
bogon
# hostname adelababy
# hostname
adelababy
# vim /etc/sysconfig/network
NETWORKING=yes
HOSTNAME=adelababy
# reboot
# hostname
adelababy
# vim /etc/hosts
127.0.0.1 localhost adelababy
# ping adelababy
PING localhost (127.0.0.1) 56(84) bytes of data.
64 bytes from localhost (127.0.0.1): icmp_seq=1 ttl=64 time=0.025 ms
64 bytes from localhost (127.0.0.1): icmp_seq=2 ttl=64 time=0.069 ms
RHEL 7.0
#sethostname adelababy
#hostname
页:
[1]