Project

General

Profile

Bug #115

Hostname definition

Added by ouaille_aime_scier 6 months ago. Updated about 2 months ago.

Status:
Done
Priority:
Normal
Assignee:
Target version:
Start date:
09/29/2019
Due date:
% Done:

100%


Description

If the hostname defined in the rc.conf file includes a dot (ie : ouaille.ghostbsd), the hostname rc-service does not set this hostname. Users should be prevented from defining their hostname with a dot (on the other hand, dash is valid : ouaille-ghostbsd).
I already had the case under Linux and some distributions are forbidding during installation to set a hostname with a dot.

History

#1 Updated by ericbsd 6 months ago

From FreeBSD, documentation dots are supported, for a single maybe it doesn't get set up properly but it is getting a ping.

ping freenas.local
PING freenas.local (192.168.2.##): 56 data bytes
64 bytes from 192.168.2.##: icmp_seq=0 ttl=64 time=0.226 ms
64 bytes from 192.168.2.##: icmp_seq=1 ttl=64 time=0.147 ms
64 bytes from 192.168.2.##: icmp_seq=2 ttl=64 time=0.357 ms
64 bytes from 192.168.2.##: icmp_seq=3 ttl=64 time=0.180 ms
64 bytes from 192.168.2.##: icmp_seq=4 ttl=64 time=0.187 ms
^C
--- freenas.local ping statistics ---
5 packets transmitted, 5 packets received, 0.0% packet loss
round-trip min/avg/max/stddev = 0.147/0.219/0.357/0.073 ms

Also, vanilla FreeBSD let use setup hostname with dots, so I plan to keep it that way.

#2 Updated by ouaille_aime_scier 6 months ago

Hello ericbsd,

There is no problem pinging a host defined with a dot, but this type of hostname does not appear as expected on the console or terminal prompt (console prompt just mentions the user name).

#3 Updated by ericbsd 6 months ago

It is working as expected if you have a dot it will take the first part before the dot it is not bug and issue, I will not strip the part that makes the installer work the way I use it. Also, it is for the user to choose how they will set their hostname. One I can do is to make the default name-machine_name for default example but I will not remove the capability of using the dots.

#4 Updated by ouaille_aime_scier 6 months ago

ericbsd wrote:

... One I can do is to make the default name-machine_name for default example but I will not remove the capability of using the dots.

Ok ericbsd this is a good idea that gives to the user freedom to set a custom host name.

#5 Updated by ericbsd about 2 months ago

  • Status changed from New to In Progress
  • Assignee set to ericbsd
  • Target version set to GhostBSD 20.02

#6 Updated by ericbsd about 2 months ago

  • Status changed from In Progress to Done
  • % Done changed from 0 to 100

#7 Updated by ouaille_aime_scier about 2 months ago

Thanks for your commit ericbsd !

Also available in: Atom PDF