-
$DISPLAY question
Greeting again !
I want to use xconsoleto (keep an eye on logs.
but when starting the apps. from a shell,
keeps telling me :
dah@home:/# xconsole
Error: Can't open display:
I got the same result for a bunch of other X
apps. ?!?
How can I resolv this problem ?
Thanks
-
This could be the result of one of two (or possibly both) things.
Firstly, you need to have an environment variable called DISPLAY set to tell the X programs where to draw themselves. This should be set when you are first logged in, but often when you su to root this is not set in the root shell. This is normally set to ":0.0" which means the first display on the local machine. You can double check what the value should be by echoing the value of $DISPLAY before you su to root.
However, when you have done this, it is possible that you will get an error about the connection being refused by the server. In order to fix this, you must run the xhost command to grant access permissions to your display. This must be done before you su to root. It should be possible to run something like "xhost localhost" which will allow access to any program running on your local machine, but I couldn't seem to get this work. You can also do "xhost +" which basically completely disables any sort of access control.
WARNING, doing xhost + is a security risk if your computer is connected to any sort of a network because it basically allows open access to your machine.
-
Follow up on the problem with $DISPLAY
When doing a "su -"
and trying to start any apps. in a shell, error cannot connect to display.
but when executing the apps. from under the original user account
everything seems to work fine ...
but I have problem with video4linux, camserv seems to not
work properly :-S
please help
-
For some security reasons X only allows one connection at a time. You can either do: kdesu appname to run it as root or create a workaround with:
ln -s /home/your_username/.Xauthority /root/.Xauthority
Sorry, not a clue about camserv. Any error messages on that one?
-
$DISPLAY problem
no error from camserv, even if I start the process using
a 'usual' account. (not admin / root) and nothing
comes up onthe webpage...
Similar Threads
-
Replies: 5
Last Post: 07-09-2005, 04:40 PM
-
By maestrobwh1 in forum General Support
Replies: 3
Last Post: 09-19-2004, 12:58 AM
-
By illcuban in forum General Support
Replies: 2
Last Post: 12-21-2003, 07:14 PM
-
By mark1221 in forum Hdd Install / Debian / Apt
Replies: 2
Last Post: 11-01-2003, 10:32 PM
-
By jclochesy in forum Hardware & Booting
Replies: 6
Last Post: 08-25-2003, 11:04 AM
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
![15.6](/store/img/g/Hb4AAOSwWahmfbAj/s-l225/15-6-Lenovo-ThinkPad-Laptop-PC-Intel-i5-16GB-RAM-5.jpg)
15.6" Lenovo ThinkPad Laptop PC: Intel i5 16GB RAM 512 SSD Windows 11 Webcam
$216.59
![Lenovo ThinkPad Laptop PC Computer 15.6](/store/img/g/DLkAAOSwMapmfYli/s-l225/Lenovo-ThinkPad-Laptop-PC-Computer-15-6-Core-i5-8G.jpg)
Lenovo ThinkPad Laptop PC Computer 15.6" Core i5 8GB RAM 256GB SSD Windows 11
$188.57
![15.6](/store/img/g/aFMAAOSwS4dmT5XL/s-l225/15-6-Lenovo-ThinkPad-Laptop-PC-Intel-i5-16GB-RAM-5.jpg)
15.6" Lenovo ThinkPad Laptop PC: Intel i5 16GB RAM 512 SSD Windows 10 Webcam
$229.99
![Lenovo ThinkPad T560 15.6](/store/img/g/LTUAAOSwfvhmfa21/s-l225/Lenovo-ThinkPad-T560-15-6-FHD-Laptop-PC-Intel-i7-8.jpg)
Lenovo ThinkPad T560 15.6" FHD Laptop PC Intel i7 8GB Ram 256GB SSD Fingerprint
$117.00
![Lenovo ThinkPad 15.6](/store/img/g/tPUAAOSwYr5mg4nj/s-l225/Lenovo-ThinkPad-15-6-Core-i5-Laptop-PC-Computer-Wi.jpg)
Lenovo ThinkPad 15.6" Core i5 Laptop PC Computer Windows 10 16GB RAM 256GB SSD
$209.99
![Lenovo Ideapad 1 14](/store/img/g/l2oAAOSw3UplMDZC/s-l225/Lenovo-Ideapad-1-14-Laptop-Celeron-N4020-with-4GB-.jpg)
Lenovo Ideapad 1 14" Laptop - Celeron N4020 with 4GB Memory - Intel UHD Graph...
$149.99
![Lenovo ThinkPad Laptop PC 15](/store/img/g/ZC4AAOSw7mJmhN6w/s-l225/Lenovo-ThinkPad-Laptop-PC-15-FHD-Core-i5-16GB-RAM-.jpg)
Lenovo ThinkPad Laptop PC 15" FHD Core i5 16GB RAM 256GB SSD Windows 10 Pro HDMI
$239.99
![Lenovo ThinkPad T540P 15.6](/store/img/g/OVgAAOSwMgBmfcp-/s-l225/Lenovo-ThinkPad-T540P-15-6-FHD-Laptop-PC-Intel-i5-.jpg)
Lenovo ThinkPad T540P 15.6" FHD Laptop PC Intel i5 8GB Ram 256GB SSD Fingerprint
$118.00
![~OVERSTOCK~ 15.6 Lenovo ThinkPad Laptop: Intel i5 16GB RAM 1TB SSD Windows 10 picture](/store/img/g/zQoAAOSwZ71mfc0x/s-l225/-OVERSTOCK-15-6-Lenovo-ThinkPad-Laptop-Intel-i5-16.jpg)
~OVERSTOCK~ 15.6 Lenovo ThinkPad Laptop: Intel i5 16GB RAM 1TB SSD Windows 10
$309.95
![Lenovo ThinkPad T470 14](/store/img/g/EiAAAOSwhKpj5Csy/s-l225/Lenovo-ThinkPad-T470-14-FHD-Core-i7-7600U-2-80GHz-.jpg)
Lenovo ThinkPad T470 14" FHD Core i7-7600U 2.80GHz Webcam Backlit HDMI USB-C
$295.00