Skip to content

Instantly share code, notes, and snippets.

@Zhann
Created August 9, 2015 19:57
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Zhann/5f8e03744495e70e1f38 to your computer and use it in GitHub Desktop.
Save Zhann/5f8e03744495e70e1f38 to your computer and use it in GitHub Desktop.
# hostnamectl
core@coreos-2 ~ $ sudo hostnamectl set-hostname web-001.coreos.banteng.be
core@coreos-2 ~ $ hostname --fqdn
web-001.coreos.banteng.be
core@coreos-2 ~ $ hostname --domain
coreos.banteng.be
# even manually
core@coreos-1 ~ $ vim /etc/hostname
core@coreos-1 ~ $ hostnamectl
Static hostname: web-002.coreos.banteng.be
core@coreos-1 ~ $ hostname --domain
coreos.banteng.be
core@coreos-1 ~ $ hostname --fqdn
web-002.coreos.banteng.be
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment