I installed Fedora 26 for testing under GCC 7. F26 is installed in a 64-bit VirtualBox VM. I ran the following commands to configure the system post-install, and then rebooted:
localhost:~$ sudo hostnamectl set-chassis desktop localhost:~$ sudo hostnamectl set-deployment production localhost:~$ sudo hostnamectl set-hostname --static --transient --pretty asus-f26-x64.
After logon, the hostname is:
asus-f26-x64:~$ hostname asus-f26-x64
It appears the fully qualified domain name was ignored. Fully qualified domain names end in dot (
.), and they signify the top of the DNS tree. Also see Steven's TCP/IP Illustrated, Volume I.
How do I set a fully qualified domain name as the hostname?
A related issue is the host does not register its name with my DHCP server. I don't see an option to send the hostname in the
hostnameclt man page.
I guess the DHCP name issue is related to the FQDN issue since the machine does not need a name from a DHCP server, but the host does not realize it because the FQDN is being mishandled.
How do I instruct the machine to sends its hostname?
Below is from
hostnamectl status. Things are a little worse because the dot is being interpreted as some sort of adornment for the pretty name; and not being recognized as a FQDN.
$ hostnamectl status Static hostname: asus-f26-x64 Pretty hostname: asus-f26-x64. Icon name: computer-desktop Chassis: desktop Deployment: production Machine ID: 3d914cf11226f83093acc Boot ID: 21fb5dabfd6a0c24ba8f2 Virtualization: oracle Operating System: Fedora 26 (Workstation Edition) CPE OS Name: cpe:/o:fedoraproject:fedora:26 Kernel: Linux 4.11.9-300.fc26.x86_64 Architecture: x86-64