Re: How to get Fedora 35 to use DNS name as hostname?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




> Am 25.01.2022 um 18:46 schrieb Thomas Cameron <thomas.cameron@xxxxxxxxxxxxxxx>:
> 
> I just did a fresh kickstart of F35 Server. I didn't do anything to set the hostname during installation. 
> 
> At first boot, I could see that the hostname was set to the reverse DNS-provided hostname "hostxxx.tc.camerontech.com" - this is normal and expected. 
> 
> When I log in via ssh or on the KVM console, the hostname is hostxxx.tc.camerontech.com UNITL I REBOOT. 
> 
> Once I reboot, the hostname is set up "fedora" with no FQDN. I am assuming it's somehow being set because of the lines in /etc/profile where the hostname is set, but I'm not sure. 
> 

Disabling systemd-resolved might not be the best idea. That makes you a good candidate for surprise follow-up problems elsewhere. 

I’m wondering, if something is wrong with your DHCP / DNS service.

systemd-resolved „knows“ there kind of hostnames:

If you don’t touch the hostname during installation, you get a „transient hostname“ with fallback „fedora“, if the system get’s no hostname from DHCP, or a similar service. The transient hostname is evaluated at each boot time. If your DHCP service provides a hostname, it is used. Otherwise - just as a fallback - fedora is used.

As soon as you define a „static hostname“, that hostname is fixed and will not be changed in the future (unless you change it explicitly), regardless what your DHCP server might deliver. If I remember correctly, the static hostname is synchronised with the classic /etc/hostname. Or maybe, it is a one-time action. 

And that is exactly the way, F35 works. I just tested the setup. (Usually I go the other path and define a static hostname in the installation process and the DHCP server picks that hostname and creates an DNS entry). 

(For details see https://www.freedesktop.org/software/systemd/man/hostnamectl.html) 


Best
Peter

_______________________________________________
users mailing list -- users@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe send an email to users-leave@xxxxxxxxxxxxxxxxxxxxxxx
Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: https://lists.fedoraproject.org/archives/list/users@xxxxxxxxxxxxxxxxxxxxxxx
Do not reply to spam on the list, report it: https://pagure.io/fedora-infrastructure



[Index of Archives]     [Older Fedora Users]     [Fedora Announce]     [Fedora Package Announce]     [EPEL Announce]     [EPEL Devel]     [Fedora Magazine]     [Fedora Summer Coding]     [Fedora Laptop]     [Fedora Cloud]     [Fedora Advisory Board]     [Fedora Education]     [Fedora Security]     [Fedora Scitech]     [Fedora Robotics]     [Fedora Infrastructure]     [Fedora Websites]     [Anaconda Devel]     [Fedora Devel Java]     [Fedora Desktop]     [Fedora Fonts]     [Fedora Marketing]     [Fedora Management Tools]     [Fedora Mentors]     [Fedora Package Review]     [Fedora R Devel]     [Fedora PHP Devel]     [Kickstart]     [Fedora Music]     [Fedora Packaging]     [Fedora SELinux]     [Fedora Legal]     [Fedora Kernel]     [Fedora OCaml]     [Coolkey]     [Virtualization Tools]     [ET Management Tools]     [Yum Users]     [Yosemite News]     [Gnome Users]     [KDE Users]     [Fedora Art]     [Fedora Docs]     [Fedora Sparc]     [Libvirt Users]     [Fedora ARM]

  Powered by Linux