qt.qpa.xcb: could not connect to display :0
-
wrote on 27 Oct 2020, 16:28 last edited by
-
Hi and welcome to devnet,
Start your application with the QT_DEBUG_PLUGINS environment variable set to 1. That will give you more information about what is going wrong.
If you have a recent version of Qt, I would guess you are missing libxinerama.
[edit: added missing words SGaist]
-
wrote on 27 Oct 2020, 17:53 last edited by
-
wrote on 27 Oct 2020, 18:32 last edited by
-
Now you have to start your application to see the debug output.
-
wrote on 27 Oct 2020, 18:43 last edited by
So now I should try this command again? export LIBGL_ALWAYS_INDIRECT=; export DISPLAY=:0; ~/build/QtSLiM
Also I can only post once every 600 seconds
I am also doing thin on a windows 10 computer using ubuntu
-
So now I should try this command again? export LIBGL_ALWAYS_INDIRECT=; export DISPLAY=:0; ~/build/QtSLiM
Also I can only post once every 600 seconds
I am also doing thin on a windows 10 computer using ubuntu
wrote on 27 Oct 2020, 18:47 last edited by@SSJCarti said in qt.qpa.xcb: could not connect to display :0:
So now I should try this command again? export LIBGL_ALWAYS_INDIRECT=; export DISPLAY=:0; ~/build/QtSLiM
Yes.
-
Hi, I've been trying to set up QtSLiM and it isn't working.
I enter export LIBGL_ALWAYS_INDIRECT=; export DISPLAY=:0; ~/build/QtSLiM
and then this is the result
Any help would be greatly appreciated
wrote on 27 Oct 2020, 18:52 last edited by@SSJCarti said in qt.qpa.xcb: could not connect to display :0:
QtSLiM
It would be great you had provided a link to such application
and then this is the result
Please paste the output as text, not an screenshot so it's easier to copy/reply to such output
export DISPLAY=:0
If you export such variable, it's likely you want some X server to be available.
Which seems not the case by looking at your outputcould not connect to display :0
-
wrote on 27 Oct 2020, 19:27 last edited by
This is the link to the instructions for running the QtSlim, you have to go to section 2.4.5
http://benhaller.com/slim/SLiM_Manual.pdf
After running that this is what popped upadduser@DESKTOP-991BCVH:~$ export LIBGL_ALWAYS_INDIRECT=; export DISPLAY=:0; ~/build/QtSLiM
QFactoryLoader::QFactoryLoader() checking directory path "/usr/lib/x86_64-linux-gnu/qt5/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() looking at "/usr/lib/x86_64-linux-gnu/qt5/plugins/platforms/libqeglfs.so"
Found metadata in lib /usr/lib/x86_64-linux-gnu/qt5/plugins/platforms/libqeglfs.so, metadata=
{
"IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3",
"MetaData": {
"Keys": [
"eglfs"
]
},
"archreq": 0,
"className": "QEglFSIntegrationPlugin",
"debug": false,
"version": 330752
}Got keys from plugin meta data ("eglfs")
QFactoryLoader::QFactoryLoader() looking at "/usr/lib/x86_64-linux-gnu/qt5/plugins/platforms/libqlinuxfb.so"
Found metadata in lib /usr/lib/x86_64-linux-gnu/qt5/plugins/platforms/libqlinuxfb.so, metadata=
{
"IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3",
"MetaData": {
"Keys": [
"linuxfb"
]
},
"archreq": 0,
"className": "QLinuxFbIntegrationPlugin",
"debug": false,
"version": 330752
}Got keys from plugin meta data ("linuxfb")
QFactoryLoader::QFactoryLoader() looking at "/usr/lib/x86_64-linux-gnu/qt5/plugins/platforms/libqminimal.so"
Found metadata in lib /usr/lib/x86_64-linux-gnu/qt5/plugins/platforms/libqminimal.so, metadata=
{
"IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3",
"MetaData": {
"Keys": [
"minimal"
]
},
"archreq": 0,
"className": "QMinimalIntegrationPlugin",
"debug": false,
"version": 330752
}Got keys from plugin meta data ("minimal")
QFactoryLoader::QFactoryLoader() looking at "/usr/lib/x86_64-linux-gnu/qt5/plugins/platforms/libqminimalegl.so"
Found metadata in lib /usr/lib/x86_64-linux-gnu/qt5/plugins/platforms/libqminimalegl.so, metadata={
"IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3",
"MetaData": {
"Keys": [
"minimalegl"
]
},
"archreq": 0,
"className": "QMinimalEglIntegrationPlugin",
"debug": false,
"version": 330752
}Got keys from plugin meta data ("minimalegl")
QFactoryLoader::QFactoryLoader() looking at "/usr/lib/x86_64-linux-gnu/qt5/plugins/platforms/libqoffscreen.so"
Found metadata in lib /usr/lib/x86_64-linux-gnu/qt5/plugins/platforms/libqoffscreen.so, metadata=
{
"IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3",
"MetaData": {
"Keys": [
"offscreen"
]
},
"archreq": 0,
"className": "QOffscreenIntegrationPlugin",
"debug": false,
"version": 330752
}Got keys from plugin meta data ("offscreen")
QFactoryLoader::QFactoryLoader() looking at "/usr/lib/x86_64-linux-gnu/qt5/plugins/platforms/libqvnc.so"
Found metadata in lib /usr/lib/x86_64-linux-gnu/qt5/plugins/platforms/libqvnc.so, metadata=
{
"IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3",
"MetaData": {
"Keys": [
"vnc"
]
},
"archreq": 0,
"className": "QVncIntegrationPlugin",
"debug": false,
"version": 330752
}Got keys from plugin meta data ("vnc")
QFactoryLoader::QFactoryLoader() looking at "/usr/lib/x86_64-linux-gnu/qt5/plugins/platforms/libqxcb.so"
Found metadata in lib /usr/lib/x86_64-linux-gnu/qt5/plugins/platforms/libqxcb.so, metadata=
{
"IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3",
"MetaData": {
"Keys": [
"xcb"
]
},
"archreq": 0,
"className": "QXcbIntegrationPlugin",
"debug": false,
"version": 330752
}Got keys from plugin meta data ("xcb")
QFactoryLoader::QFactoryLoader() checking directory path "/home/adduser/build/platforms" ...
loaded library "/usr/lib/x86_64-linux-gnu/qt5/plugins/platforms/libqxcb.so"
qt.qpa.xcb: could not connect to display :0
qt.qpa.plugin: Could not load the Qt platform plugin "xcb" in "" even though it was found.
This application failed to start because no Qt platform plugin could be initialized. Reinstalling the application may fix this problem.Available platform plugins are: eglfs, linuxfb, minimal, minimalegl, offscreen, vnc, xcb.
Aborted
-
This is the link to the instructions for running the QtSlim, you have to go to section 2.4.5
http://benhaller.com/slim/SLiM_Manual.pdf
After running that this is what popped upadduser@DESKTOP-991BCVH:~$ export LIBGL_ALWAYS_INDIRECT=; export DISPLAY=:0; ~/build/QtSLiM
QFactoryLoader::QFactoryLoader() checking directory path "/usr/lib/x86_64-linux-gnu/qt5/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() looking at "/usr/lib/x86_64-linux-gnu/qt5/plugins/platforms/libqeglfs.so"
Found metadata in lib /usr/lib/x86_64-linux-gnu/qt5/plugins/platforms/libqeglfs.so, metadata=
{
"IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3",
"MetaData": {
"Keys": [
"eglfs"
]
},
"archreq": 0,
"className": "QEglFSIntegrationPlugin",
"debug": false,
"version": 330752
}Got keys from plugin meta data ("eglfs")
QFactoryLoader::QFactoryLoader() looking at "/usr/lib/x86_64-linux-gnu/qt5/plugins/platforms/libqlinuxfb.so"
Found metadata in lib /usr/lib/x86_64-linux-gnu/qt5/plugins/platforms/libqlinuxfb.so, metadata=
{
"IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3",
"MetaData": {
"Keys": [
"linuxfb"
]
},
"archreq": 0,
"className": "QLinuxFbIntegrationPlugin",
"debug": false,
"version": 330752
}Got keys from plugin meta data ("linuxfb")
QFactoryLoader::QFactoryLoader() looking at "/usr/lib/x86_64-linux-gnu/qt5/plugins/platforms/libqminimal.so"
Found metadata in lib /usr/lib/x86_64-linux-gnu/qt5/plugins/platforms/libqminimal.so, metadata=
{
"IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3",
"MetaData": {
"Keys": [
"minimal"
]
},
"archreq": 0,
"className": "QMinimalIntegrationPlugin",
"debug": false,
"version": 330752
}Got keys from plugin meta data ("minimal")
QFactoryLoader::QFactoryLoader() looking at "/usr/lib/x86_64-linux-gnu/qt5/plugins/platforms/libqminimalegl.so"
Found metadata in lib /usr/lib/x86_64-linux-gnu/qt5/plugins/platforms/libqminimalegl.so, metadata={
"IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3",
"MetaData": {
"Keys": [
"minimalegl"
]
},
"archreq": 0,
"className": "QMinimalEglIntegrationPlugin",
"debug": false,
"version": 330752
}Got keys from plugin meta data ("minimalegl")
QFactoryLoader::QFactoryLoader() looking at "/usr/lib/x86_64-linux-gnu/qt5/plugins/platforms/libqoffscreen.so"
Found metadata in lib /usr/lib/x86_64-linux-gnu/qt5/plugins/platforms/libqoffscreen.so, metadata=
{
"IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3",
"MetaData": {
"Keys": [
"offscreen"
]
},
"archreq": 0,
"className": "QOffscreenIntegrationPlugin",
"debug": false,
"version": 330752
}Got keys from plugin meta data ("offscreen")
QFactoryLoader::QFactoryLoader() looking at "/usr/lib/x86_64-linux-gnu/qt5/plugins/platforms/libqvnc.so"
Found metadata in lib /usr/lib/x86_64-linux-gnu/qt5/plugins/platforms/libqvnc.so, metadata=
{
"IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3",
"MetaData": {
"Keys": [
"vnc"
]
},
"archreq": 0,
"className": "QVncIntegrationPlugin",
"debug": false,
"version": 330752
}Got keys from plugin meta data ("vnc")
QFactoryLoader::QFactoryLoader() looking at "/usr/lib/x86_64-linux-gnu/qt5/plugins/platforms/libqxcb.so"
Found metadata in lib /usr/lib/x86_64-linux-gnu/qt5/plugins/platforms/libqxcb.so, metadata=
{
"IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3",
"MetaData": {
"Keys": [
"xcb"
]
},
"archreq": 0,
"className": "QXcbIntegrationPlugin",
"debug": false,
"version": 330752
}Got keys from plugin meta data ("xcb")
QFactoryLoader::QFactoryLoader() checking directory path "/home/adduser/build/platforms" ...
loaded library "/usr/lib/x86_64-linux-gnu/qt5/plugins/platforms/libqxcb.so"
qt.qpa.xcb: could not connect to display :0
qt.qpa.plugin: Could not load the Qt platform plugin "xcb" in "" even though it was found.
This application failed to start because no Qt platform plugin could be initialized. Reinstalling the application may fix this problem.Available platform plugins are: eglfs, linuxfb, minimal, minimalegl, offscreen, vnc, xcb.
Aborted
wrote on 27 Oct 2020, 19:32 last edited by@SSJCarti said in qt.qpa.xcb: could not connect to display :0:
qt.qpa.xcb: could not connect to display :0
it seems you haven't looked at my previous post. You may need an X server running
-
wrote on 27 Oct 2020, 19:40 last edited by
I have a VcXsrv running. Also known as XLaunch
-
wrote on 27 Oct 2020, 21:43 last edited by
@SSJCarti said in qt.qpa.xcb: could not connect to display :0:
I have a VcXsrv running
According to this site:
VcXsrv makes it possible to run Linux GUI programs installed with WSL, the Windows Subsystem for Linux. In bash for Windows, setting the DISPLAY environment variable allows WSL programs to use the Windows GUI. For instance, if VcXsrv is configured to use display number zero, the command DISPLAY=:0 etr would run the game Extreme Tux Racer
Given that you're running VcXsrv, you may need to double check its configuration and what display it's exporting/providing to the Linux side of the Windows WSL (sorry but I don't have experience with Windows WSL to help more).
You may also want to check the videos here about VcXsrv & Win10 Linux Subsystems
-
wrote on 27 Oct 2020, 22:03 last edited by
thank you. Is there anyone else with potential ideas?
-
wrote on 28 Oct 2020, 13:43 last edited by
loaded library "/usr/lib/x86_64-linux-gnu/qt5/plugins/platforms/libqxcb.so" qt.qpa.xcb: could not connect to display :0 qt.qpa.plugin: Could not load the Qt platform plugin "xcb" in "" even though it was found.
I know little about, less than you or @Pablo-J-Rogina . But it does seem to me that whatever he is trying to ask/tell you about an X server --- either not running or somehow not found? --- is what is causing the problem here, given that it has said
loaded library "/usr/lib/x86_64-linux-gnu/qt5/plugins/platforms/libqxcb.so"
Could not load the Qt platform plugin "xcb" in "" even though it was found.?
There are many Google hits for
Could not load the Qt platform plugin "xcb"
, and we usually find that is an absent library likelibxcb-xinerama.so.0
. But here I am thinking you should Google forcould not load the qt platform plugin "xcb" in "" even though it was found.
The "even though it was found" being key. There are a bunch of hits on that, things likeXDG_RUNTIME_DIR
not giving you a good X environment. If I understood any of this :) that is what I would look through. -
loaded library "/usr/lib/x86_64-linux-gnu/qt5/plugins/platforms/libqxcb.so" qt.qpa.xcb: could not connect to display :0 qt.qpa.plugin: Could not load the Qt platform plugin "xcb" in "" even though it was found.
I know little about, less than you or @Pablo-J-Rogina . But it does seem to me that whatever he is trying to ask/tell you about an X server --- either not running or somehow not found? --- is what is causing the problem here, given that it has said
loaded library "/usr/lib/x86_64-linux-gnu/qt5/plugins/platforms/libqxcb.so"
Could not load the Qt platform plugin "xcb" in "" even though it was found.?
There are many Google hits for
Could not load the Qt platform plugin "xcb"
, and we usually find that is an absent library likelibxcb-xinerama.so.0
. But here I am thinking you should Google forcould not load the qt platform plugin "xcb" in "" even though it was found.
The "even though it was found" being key. There are a bunch of hits on that, things likeXDG_RUNTIME_DIR
not giving you a good X environment. If I understood any of this :) that is what I would look through. -
wrote on 28 Oct 2020, 14:21 last edited by JonB
@SSJCarti
One thing: It seems to me there is a related discussion going on in https://forum.qt.io/topic/120349/run-qt-gui-application-inside-docker. I assume that Poster is not yourself too. At least, that seems to get the same message as you do:loaded library "/home/user/app/platforms/libqxcb.so"
qt.qpa.xcb: could not connect to display
qt.qpa.plugin: Could not load the Qt platform plugin "xcb" in "" even though it was found.So maybe worth a look?
EDIT @Pablo-J-Rogina has said below this would not be helpful to you, so don't! :)
-
@SSJCarti
One thing: It seems to me there is a related discussion going on in https://forum.qt.io/topic/120349/run-qt-gui-application-inside-docker. I assume that Poster is not yourself too. At least, that seems to get the same message as you do:loaded library "/home/user/app/platforms/libqxcb.so"
qt.qpa.xcb: could not connect to display
qt.qpa.plugin: Could not load the Qt platform plugin "xcb" in "" even though it was found.So maybe worth a look?
EDIT @Pablo-J-Rogina has said below this would not be helpful to you, so don't! :)
wrote on 28 Oct 2020, 14:31 last edited by@JonB said in qt.qpa.xcb: could not connect to display :0:
So maybe worth a look?
I don't think the goals/environments are the same... I'd say it will mislead OP here
-
@JonB said in qt.qpa.xcb: could not connect to display :0:
So maybe worth a look?
I don't think the goals/environments are the same... I'd say it will mislead OP here
wrote on 28 Oct 2020, 15:41 last edited by@Pablo-J-Rogina so is my Xlaunch a xserver?
1/26