I just tried a couple of thing that seem to work. 1. Put the "export XAUTHORITY=~paul/.Xauthority in your .bashrc file. When you su to another user the XAUTHORITY environment variable still exists! Works fine.
2. Did you ever notice what happens when you su to another user with the USER enviroment variable? It does not change unless you su a second time! Therefore you could put in the root's .bashrc -- "export XAUTHORITY=$USER/.Xauthority" Both of these worked for me. It would also appear to me to be more secure than the xhost methold mentioned by others. Also I have run across programs that do not like the "xhost +localhost" methold. On Mon, 2 Jun 1997, Paul McDermott wrote: > thanks jens, is there a way so i don't have to type the command all the time? > thanks again. > Paul > > > On Mon, 2 Jun 1997, Jens B. Jorgensen wrote: > > > Paul McDermott wrote: > > > > > > Hi folks, I just installed X version 3.2 on my system this past few > > > weeks. I am having problems do things as su. ie for the first error > > > message is one that I receive whenever I try to run an X program as su. > > > This error message is when I was trying to use xclock. I have check > > > xclocks permissions, ownership both seem to be in order. Ownership is > > > root.root and the Permissions are 755. This error happens when I try to > > > run all x programs. > > > > > > Xlib: connection to ":0.0" refused by server > > > Xlib: Client is not authorized to connect to Server > > > open display failed > > > InitXWindows failed, exiting > > > > > > This error is when I try to run emacs as su. > > > > > > Xlib: connection to ":0.0" refused by server > > > Xlib: Client is not authorized to connect to Server > > > emacs: Cannot connect to X server :0.0. > > > Check the DISPLAY environment variable or use `-d'. > > > Also use the `xhost' program to verify that it is set to permit > > > connections from your machine. > > > > > > I cam run things as user paul and if I login as root. If you have any > > > suggestions or need any more information please email me. > > > Paul > > > > > > > If you log in as paul and then su to root, then after you su type > > > > export XAUTHORITY=~paul/.Xauthority > > > > -- > > Jens B. Jorgensen > > [EMAIL PROTECTED] > > > > > -- > TO UNSUBSCRIBE FROM THIS MAILING LIST: e-mail the word "unsubscribe" to > [EMAIL PROTECTED] . > Trouble? e-mail to [EMAIL PROTECTED] . > > ---------------- http://www.sound.net/~wpmills/ ----------------- : W. Paul Mills : Bill, I was there several years ago. : : Topeka, Kansas, U.S.A. : Why would I want to go back tomorrow? : : [EMAIL PROTECTED] : Where were you! : : [EMAIL PROTECTED] : ---------------------------------------- : : [EMAIL PROTECTED] : Linux: Tomorrow's operating system, : : [EMAIL PROTECTED] : here, today. : : [EMAIL PROTECTED] : ---------------------------------------- : : compuserve 70023,1750 : #define MY_TRUE_LOVE computer : -------------- http://homepage.midusa.net/~wpmills/ ------------- -- TO UNSUBSCRIBE FROM THIS MAILING LIST: e-mail the word "unsubscribe" to [EMAIL PROTECTED] . Trouble? e-mail to [EMAIL PROTECTED] .