Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
login hostname@unknown_domain systemd
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
transsib
l33t
l33t


Joined: 26 Jul 2003
Posts: 889

PostPosted: Mon May 18, 2020 2:10 pm    Post subject: login hostname@unknown_domain systemd Reply with quote

I recently set up a new system for a friend. She wanted systemd.
My own Gentoo gets started by OpenRC. I am new to systemd.
Everything seems to be just fine with the exception of the login
which does not show the domain "localhost". I need to set up a
gui login manager later but before I do that I need to correct this deficit.

I just don´t know how. I followed the wiki for systemd, having enabled
systemd-resolved.service.

Would any of you point me into the right direction, please.
Back to top
View user's profile Send private message
dr_wulsen
Tux's lil' helper
Tux's lil' helper


Joined: 21 Aug 2013
Posts: 134
Location: Austria

PostPosted: Mon May 18, 2020 8:06 pm    Post subject: Reply with quote

sure enough, there's the gentoo-systemd article, which introduces you to hostnamectl
_________________
There's no stupid questions, only stupid answers.
Back to top
View user's profile Send private message
transsib
l33t
l33t


Joined: 26 Jul 2003
Posts: 889

PostPosted: Tue May 19, 2020 11:54 am    Post subject: Reply with quote

Quote:
Hostname

To set the hostname, create/edit /etc/hostname and simply provide the desired hostname.

When booted using systemd, a tool called hostnamectl exists for editing /etc/hostname and /etc/machine-info. To change the hostname, run:
root #hostnamectl set-hostname <HOSTNAME>

Refer to man hostnamectl for more options.




Surely there is and that´s what I´ve followed but may be I should have hostnamectl set-hostname <hostname>.localhost instead of only <hostname> ?
Or is /etc/machine-info the right place?
Back to top
View user's profile Send private message
dr_wulsen
Tux's lil' helper
Tux's lil' helper


Joined: 21 Aug 2013
Posts: 134
Location: Austria

PostPosted: Tue May 19, 2020 12:07 pm    Post subject: Reply with quote

The FQDN (fully qualified domain name) consists of two parts: *your hostname and *the domain name returned by the resolver.
So the easiest way is to add/modify your FQDN to /etc/hosts
127.0.0.1 localbox. lan localbox localhost

should do the trick for IPv4.
Sure enogh, you should edit the IPv6 line to read the same names, if you are using IPv6.
_________________
There's no stupid questions, only stupid answers.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum