I have recently installed Fedora 30 on a new laptop. When I had set it up, my hostname, as seen in the command prompt, was set to simply 'fedora'. At some point during the last month of usage the hostname changed to 'Galaxy-Note9'. I have no idea precisely how this happened, although this is the model of my phone, so I guess something weird went on when I plugged my phone in at some point. I researched how to change the name of my computer to fix this issue. Everything I found pertained to changing the hostname, so I did this using the
hostnamectl command and reset it to 'fedora'. This change persisted reboot and successfully changed the name in the prompt and as returned by the
hostname command, so I considered the matter solved.
However, today I have been SSHing into my raspberry pi, and I noticed that the second time I accessed it, it said that the last login was from a device named 'galaxy-note9.home'. Indeed, I checked the devices on my network with
nmap -sP 192.168.1.* and the IP address of my laptop was listed under the name 'Galaxy-Note9.home'. My hostname is still set to 'fedora'.
How can I fully change the name of my system so this won't crop up again here or anywhere else in future? And can anybody explain why the name changed in the first place?