To change hostname permanently in CentOS, use the following hostnamectl command (not hostname).
1 |
hostnamectl set-hostname myhostname --static |
To change hostname permanently in CentOS, use the following hostnamectl command (not hostname).
1 |
hostnamectl set-hostname myhostname --static |