environment variable "$DISPLAY"
Since installing 12.2, some things have not been functioning as expected; the warnings/errors that occur seem to indicate that an environment variable "$DISPLAY" needs to be set. For instance:
Code:
root@abitbox:~# xwininfo -id 0:0 Thanks Gary |
That is you X server display
I am not an X-pert but I know the DISPLAY environment variable should be the identifier of the X server you want to connect to.
Usually this will be ':0', unless you are running multiple X servers. I have some notes on this from running X sessions across a LAN but that machine is not accessible to me at the moment - I'll try to post some later. [EDIT] There is a very short explanation of the $DISPLAY var here. [/EDIT] |
Look at the man page for xwininfo. It wants the window ID, not the display ID
Try running xwininfo with no arguments. |
Quote:
I already did that, and it is no help here is what it produces: Code:
root@abitbox:~# xwininfo @Astrogeek: I already saw that; unfortunately, I still do not know where to find the information that the variable needs to be set to. Again, Thank you for the replies; Gary |
Are you running X? y/n
If you are not, you need to run X. If you are, then: Were you logged in as root when you stated X (from the prompt) or did you su to root? If you are in as root, then Code:
echo $DISPLAY Code:
xhost local: Code:
DISPLAY=:0.0 If none of this works, then please post the output of Code:
echo $DISPLAY |
Interesting-----On my system, running "xwininfo" with no arguments allows you to click on a window to get a dump of information.
Can you run "xwininfo -name foo"? (Replace "foo" with the name of a window as it appears in the title bar.) |
But---"xwininfo -id <id>" does not want the display ID---it wants the window ID. I'm not getting why everyone's talking about $DISPLAY.
There is a -display option, but I assume that is to be used in conjunction with -id, -name, etc. |
Quote:
|
HA! Yes, per slack'92man: let's start over...
I focused on the value of $DISPLAY as being the question, but maybe that was not the point you were asking.
Your use of xwininfo does indicate that you are not in an X session so there would be no meaningful value for $DISPLAY in that context... And pixellany is correct, in an X environment as you used it, xwininfo wants the window ID, not the server ID... So, as slack'92man said, let's start over and restate the question. First, you stated that some things are not working, and I understand xwininfo to be an example of one that is not working? If that is correct, then the obvious question based on your output posted is: Are you in an X session? ... then follow slack'92man's decision tree... |
My system is set to boot directly into init 4; KDE 3.5; loggen in as normal user.
The root Konsole was started by: "K menu--->system--->more applications--->terminal program - super user mode", rather than "su" from the user Konsole I followed the steps suggested by slack1992man; actually using two consoles - the super user console and the user console running "xhost local:" from the regular user console and then setting "DISPLAY=:0.0" from the super-user console. xwininfo now works from the super-user console. What started me into this was when I installed hplip; hp-setup defaults to a gui application that needs to be run with root privileges, but failed because it could not open a window. I ended up having to resort to the interactive setup. I've tried running a number of other things that needed root privileges but failed when the tried to open a window. Thank you all for taking the time to try and educate me Gary |
Quote:
Obviously, using "xwininfo" was a really bad example -- I wanted to keep my request for help generic and I came across "xwininfo" when an install of a perl mod failed - so I used that as an example Thanks again Gary |
You are welcome!
Quote:
|
All times are GMT -5. The time now is 10:15 AM. |