I am currently trying to make an autonomous drone using the Robot Operating System (ROS). To do this, I have installed Raspbian Lite (Jessie) on a Rasperry Pi 3 and am currently using ROS Kinetic on it. I decided to go with Openbox Window Manager and installed a terminal onto it for convenience. I can just call sudo startx to open up a window manager in another terminal. Since there is no desktop environment, I have also installed tmux for convenience. I am running the xserver on a particular pane and conduct my ROS work on other panes.

Now when I try to run commands that call on a GUI application from my first terminal virtual device (Ctrl + Alt + F1), I get the error:

QxcbConnection: Could not connect to display

After a recommendation from this question, I decided to install xhost on my terminal emulator (which is running on my window manager on my second terminal virtual device, that can be accessed by Ctrl + Alt + F2). After invoking xhost + in the same emulator, I get this:

access control disabled, clients can connect from any host

After which I invoke xhost which returns with:

access control disabled, clients can connect from any host

Therefore, in my first virtual terminal device, I have set the environmental variable to 5 different values which have been listed below, and tried to run the program which calls on the $DISPLAY, but I get the same QxcbConnection: Could not connect to display error.


The last one was actually from the linked question. To my understanding, I am doing exactly what is listed out in this man page. What am I doing wrong?


I have also tried ssh'ing into the window manager with ssh root@raspberrypi (which is what I infer the user@hostname to be from the prompt in my terminal emulator inside my window manager). However, this asks me for a password, which I do not know and cannot access. This is the topic for this question.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.