finkelg
asked on
Xlib: connection refused
I boot may X as a user.
When I need root permition I su to root.
for some resone I cant run any X application as root (DISPLAY env is fine :0 )
The message I get is:
Xlib: connection to ":0.0" refused by server
Xlib: Client is not authorized to connect to Server
Only if as a user i do xhost + (to disable authentications) can i run X based programs as root
Where should I lok for an answer ?
P.S (almost all may packages are updates of RH 6.1 or mandrake)
When I need root permition I su to root.
for some resone I cant run any X application as root (DISPLAY env is fine :0 )
The message I get is:
Xlib: connection to ":0.0" refused by server
Xlib: Client is not authorized to connect to Server
Only if as a user i do xhost + (to disable authentications) can i run X based programs as root
Where should I lok for an answer ?
P.S (almost all may packages are updates of RH 6.1 or mandrake)
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
so, what's the question now?
ASKER
None just wanted you to know
ASKER
The better answer I found was that I have an .Xauthorty file in my home dir which uses a MAGIC-KEY ... with a code for each display I want to protect (Usally :0 ).
If I whant others(root too) to connect to that display they too need the .Xauthorty file with that code so here what you do:
Run xauth list, copy the code, su to the user you what to give excess, xauth add . <the code you copy> ,
Now that user can X client to my X server but others cant
See also Xauth menuals