Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
change of hostname by dhcp and kde broken [SOLVED]
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
sergdev
n00b
n00b


Joined: 03 Jun 2018
Posts: 11

PostPosted: Wed Mar 04, 2020 3:43 pm    Post subject: change of hostname by dhcp and kde broken [SOLVED] Reply with quote

Hey guys!
I am seeing strange thing: in a short time after signin my prompt in the terminal changes to the pc-19, something like:
pc-19 ~#
it's happening only today, when I moved to another appartments, another internet provider and I restarted pc after a week with no restarts...
And one of symptoms: my kde stops working.... new gui programs impossible to start


Last edited by sergdev on Wed Mar 04, 2020 8:11 pm; edited 1 time in total
Back to top
View user's profile Send private message
krinn
Watchman
Watchman


Joined: 02 May 2003
Posts: 7367

PostPosted: Wed Mar 04, 2020 5:09 pm    Post subject: Reply with quote

it's more probably that after few time your dhcp provide an ip and an hostname, why it's "pc-19", no idea
Back to top
View user's profile Send private message
etnull
Apprentice
Apprentice


Joined: 26 Mar 2019
Posts: 285

PostPosted: Wed Mar 04, 2020 5:11 pm    Post subject: Reply with quote

I would call my botnet pc1, pc2, pc3 etc. as well.
Back to top
View user's profile Send private message
krinn
Watchman
Watchman


Joined: 02 May 2003
Posts: 7367

PostPosted: Wed Mar 04, 2020 5:12 pm    Post subject: Reply with quote

etnull wrote:
I would call my botnet pc1, pc2, pc3 etc. as well.

But would you help user to see he has been hack by doing something he could easy see?
Back to top
View user's profile Send private message
Ant P.
Watchman
Watchman


Joined: 18 Apr 2009
Posts: 6333

PostPosted: Wed Mar 04, 2020 6:01 pm    Post subject: Reply with quote

krinn wrote:
it's more probably that after few time your dhcp provide an ip and an hostname, why it's "pc-19", no idea

That also explains why KDE broke. It's a common problem with that desktop. Surprised they still refuse to fix it.
Back to top
View user's profile Send private message
sergdev
n00b
n00b


Joined: 03 Jun 2018
Posts: 11

PostPosted: Wed Mar 04, 2020 6:07 pm    Post subject: Reply with quote

Ant P. wrote:
krinn wrote:
it's more probably that after few time your dhcp provide an ip and an hostname, why it's "pc-19", no idea

That also explains why KDE broke. It's a common problem with that desktop. Surprised they still refuse to fix it.

Oh, how do I prevent this problem ?
Back to top
View user's profile Send private message
Ant P.
Watchman
Watchman


Joined: 18 Apr 2009
Posts: 6333

PostPosted: Wed Mar 04, 2020 6:40 pm    Post subject: Reply with quote

The usual way to fix it is by putting whatever you configured your hostname as in /etc/hosts:
Code:
127.0.0.1       localhost
::1             localhost

127.0.0.2       <hostname>

There's also sys-auth/nss-myhostname, but I haven't tried that.

If you can configure the dhcp client to not change the hostname, that would work too.
Back to top
View user's profile Send private message
sergdev
n00b
n00b


Joined: 03 Jun 2018
Posts: 11

PostPosted: Wed Mar 04, 2020 7:08 pm    Post subject: Reply with quote

Ant P. wrote:
The usual way to fix it is by putting whatever you configured your hostname as in /etc/hosts:
Code:
127.0.0.1       localhost
::1             localhost

127.0.0.2       <hostname>

There's also sys-auth/nss-myhostname, but I haven't tried that.

If you can configure the dhcp client to not change the hostname, that would work too.

Thank you so much! I've tried one of these ideas before you wrote (forced localhost name for my pc for interface but it still was buggy)
Then I changed my hostname to be the same as my provider configured it for me and now everything works.
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