Starting from Ubuntu 18.04, changing /etc/hostname can no longer change the hostname, so it can only be changed by the command:
$ sudo hostnamectl set-hostname linuxconfig
Starting from Ubuntu 18.04, changing /etc/hostname can no longer change the hostname, so it can only be changed by the command:
$ sudo hostnamectl set-hostname linuxconfig