Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Unable to open GUI applications after connecting with NM
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Desktop Environments
View previous topic :: View next topic  
Author Message
simernes
n00b
n00b


Joined: 08 Mar 2020
Posts: 10

PostPosted: Wed Mar 11, 2020 8:59 pm    Post subject: Unable to open GUI applications after connecting with NM Reply with quote

Whenever I reboot and after I connect to a wireless network with NetworkManager I am unable to open any GUI applications in KDE after. I just see the loading icon for the app and then nothing.

Trying to start Dolphin in a terminal I get the output:

No protocol specified
qt.qpa.xcb: could not connect to display :0
qt.qpa.xcb: Could not load the Qt platform plugin "xcb" in "" even though it was found.

Furthermore I've noticed that when I start the terminal the prompt says myname@localhost, but then when I start tmux it changes to myname@livecd, so perhaps that is misconfigured somehow. I'm not sure if it is related, but this post https://bbs.archlinux.org/viewtopic.php?id=163324 mentions things related to hostname during a very similar problem to mine.

Another problem I have with the GUI in general is that I can't get a tty with ctrl+alt+f2.. I just see a brief and very colorful flash flow across the screen, and then it's all black. Don't know if it's related.

edit: I also noticed that I have to manually connect with the nm indicator applet in KDE, although the wifi password is saved, and I just have to click on "connect" for it to actually establish a connection with the wifi network, even though I checked for it to connect automatically with priority 1.


Last edited by simernes on Fri Mar 13, 2020 7:09 pm; edited 1 time in total
Back to top
View user's profile Send private message
crocket
Guru
Guru


Joined: 29 Apr 2017
Posts: 418

PostPosted: Wed Mar 11, 2020 10:26 pm    Post subject: Reply with quote

Did you enable xcb in qtgui?
Back to top
View user's profile Send private message
Hu
Moderator
Moderator


Joined: 06 Mar 2007
Posts: 15603

PostPosted: Thu Mar 12, 2020 12:59 am    Post subject: Re: Unable to open GUI applications after connecting with NM Reply with quote

simernes wrote:
Another problem I have with the GUI in general is that I can't get a tty with ctrl+alt+f2.. I just see a brief and very colorful flash flow across the screen, and then it's all black. Don't know if it's related.
This is probably not related to your network problem. Please open a separate thread for that, and provide details about your graphics environment. Are you using X11 or Wayland? What graphics card and driver are you using? What kind of black do you get: powersave black or backlight-enabled all black pixels?
Back to top
View user's profile Send private message
simernes
n00b
n00b


Joined: 08 Mar 2020
Posts: 10

PostPosted: Fri Mar 13, 2020 6:40 pm    Post subject: Reply with quote

crocket wrote:
Did you enable xcb in qtgui?


I don't think I did honestly, it's my first time installing Gentoo so I'm climbing a bit of a steep learning curve at the moment. I didn't even have qtgui installed, and now I've installed it with emerge. I can't see it as a USE flag here https://packages.gentoo.org/packages/dev-qt/qtgui should it be there?
Back to top
View user's profile Send private message
crocket
Guru
Guru


Joined: 29 Apr 2017
Posts: 418

PostPosted: Fri Mar 13, 2020 9:15 pm    Post subject: Reply with quote

Execute

> sudo emerge -q gentoolkit
> equery u qtgui
Back to top
View user's profile Send private message
Hu
Moderator
Moderator


Joined: 06 Mar 2007
Posts: 15603

PostPosted: Sat Mar 14, 2020 12:29 am    Post subject: Reply with quote

The original symptoms sound like your hostname is being changed. Don't do that. Tell your network management tool not to change your hostname, and instead statically configure your hostname correctly. Renaming the system is known to break X applications.
Back to top
View user's profile Send private message
simernes
n00b
n00b


Joined: 08 Mar 2020
Posts: 10

PostPosted: Sat Mar 14, 2020 1:01 pm    Post subject: Reply with quote

Hu wrote:
The original symptoms sound like your hostname is being changed. Don't do that. Tell your network management tool not to change your hostname, and instead statically configure your hostname correctly. Renaming the system is known to break X applications.


The hostname thing seems to have stopped now (I've rebooted many times), and stays as localhost which is what I specified it to be. I had to chroot back in after installing KDE because I forgot to install Konsole, so maybe somehow that was the reason the hostname was acting up.
Back to top
View user's profile Send private message
simernes
n00b
n00b


Joined: 08 Mar 2020
Posts: 10

PostPosted: Sat Mar 14, 2020 1:06 pm    Post subject: Reply with quote

crocket wrote:
Execute

> sudo emerge -q gentoolkit
> equery u qtgui


There is a + for both U and I on xcb in the output of equery u qtgui. xcb has red color. For the record the same is true for wayland.
Back to top
View user's profile Send private message
crocket
Guru
Guru


Joined: 29 Apr 2017
Posts: 418

PostPosted: Sun Mar 15, 2020 6:34 am    Post subject: Reply with quote

Collect logs from networkmanager, /var/log/Xorg.0.log, and GUI applications.

Try searching the internet with `qt.qpa.xcb: could not connect to display` or `qt.qpa.xcb: Could not load the Qt platform plugin "xcb" in "" even though it was found.`
Back to top
View user's profile Send private message
coderanger
Tux's lil' helper
Tux's lil' helper


Joined: 19 Sep 2018
Posts: 138

PostPosted: Sun Mar 15, 2020 8:33 am    Post subject: Reply with quote

This is how I tell nm to ignore hostname received via dhcp
Code:
$ cat /etc/NetworkManager/NetworkManager.conf
[main]
plugins=keyfile
hostname-mode=none

[keyfile]
hostname=ibm
Back to top
View user's profile Send private message
simernes
n00b
n00b


Joined: 08 Mar 2020
Posts: 10

PostPosted: Sun Mar 15, 2020 8:51 am    Post subject: Reply with quote

coderanger wrote:
This is how I tell nm to ignore hostname received via dhcp
Code:
$ cat /etc/NetworkManager/NetworkManager.conf
[main]
plugins=keyfile
hostname-mode=none

[keyfile]
hostname=ibm


Hey, man. That did the trick! Although for the record I set hostname=localhost instead of ibm. Right before reading your message, I noticed that in uname -a my hostname changed from localhost to localhost.localdomain after connecting with NetworkManager, so I guess as someone else pointed out here that messing with the hostname breaks X!
Back to top
View user's profile Send private message
crocket
Guru
Guru


Joined: 29 Apr 2017
Posts: 418

PostPosted: Sun Mar 15, 2020 11:14 am    Post subject: Reply with quote

It seems both X and NetworkManager were bitches to you.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Desktop Environments 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