LinuxQuestions.org
Latest LQ Deal: Complete CCNA, CCNP & Red Hat Certification Training Bundle
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 02-23-2006, 03:52 AM   #1
merchtemeagle
Member
 
Registered: Oct 2004
Location: Belgium
Distribution: Slackware 13.37
Posts: 512

Rep: Reputation: 31
Xlib: connection to ":0.0" refused


When trying to run an installation program as root, I get:

Code:
ik@box:/mnt/cdrom# su -c ./installUnix
VisualWorks(R) 7.3 Nov 24 2004
Xlib: connection to ":0.0" refused by
server Xlib: No protocol specified

Xlib: connection to ":0.0" refused by server
Xlib: No protocol specified

VisualWorks(R) 7.3 Nov 24 2004
Fatal error: Unable to connect to X11 server
This used to work both no longer does after a power failure.
Anyone knows why this might be the case?

And what is the proper use of xauth to, when I log in as regular user, make sure root can use the display. I use KDE 3.4.2 and log in with KDM.

Last edited by merchtemeagle; 03-03-2006 at 11:52 AM.
 
Old 02-23-2006, 04:19 AM   #2
tizzef
Member
 
Registered: Jan 2005
Location: Nice, France
Distribution: Ubuntu,RHES, Mandriva, RHAS, AIX 4.3.3, 5.2 & 5.3, Debian,Solaris8/10
Posts: 119

Rep: Reputation: 20
try to append an <xhost +> to enable X connexion to localhost.
 
Old 02-23-2006, 06:59 AM   #3
alienDog
Member
 
Registered: Apr 2004
Location: Europe
Distribution: Debian, Slackware
Posts: 505

Rep: Reputation: 46
Hmm, I think it's actually:

Code:
xhost +localhost
xhost + will just enable access control.
 
Old 02-23-2006, 07:57 AM   #4
merchtemeagle
Member
 
Registered: Oct 2004
Location: Belgium
Distribution: Slackware 13.37
Posts: 512

Original Poster
Rep: Reputation: 31
Yes, but that will give access to everyone. I've read somewhere xauth is a better way to do this, but can't find very good resources on it.

Last edited by merchtemeagle; 03-03-2006 at 11:53 AM.
 
Old 03-03-2006, 11:55 AM   #5
merchtemeagle
Member
 
Registered: Oct 2004
Location: Belgium
Distribution: Slackware 13.37
Posts: 512

Original Poster
Rep: Reputation: 31
Anyone with some xauth experience?
 
Old 03-03-2006, 07:21 PM   #6
devnull13
LQ Newbie
 
Registered: Mar 2006
Posts: 2

Rep: Reputation: 0
I think the following will work:

As you, type the following:

xauth list | grep localhost

You should get a line (listline) with 3 fields. The first field (field1) contains localhost, the second field contains the string "magic cookie", and the last field is random.

As root, type the following:

# export XAUTHORITY=$HOME/.xauthority

# xauth add <listline> # where <listline> is the output from above.

# export DISPLAY=<field1> # see above for contents

Good luck!!
 
Old 03-04-2006, 05:27 AM   #7
merchtemeagle
Member
 
Registered: Oct 2004
Location: Belgium
Distribution: Slackware 13.37
Posts: 512

Original Poster
Rep: Reputation: 31
# xauth list
192.168.2.5:0 MIT-MAGIC-COOKIE-1 9f876287f2e1c2538c729e001675156a
diane/unix:0 MIT-MAGIC-COOKIE-1 9f876287f2e1c2538c729e001675156a

Is the first one for remote connections?
 
Old 03-04-2006, 11:13 PM   #8
devnull13
LQ Newbie
 
Registered: Mar 2006
Posts: 2

Rep: Reputation: 0
Easier way to do it.

While looking up other things, I found this.

Look for the remote-x-apps mini-howto. It may also be in /usr/doc on your machine. (The site won't let me post URLS, since I'm a newbie. ) It has a script to do exactly what you want.

And as another poster stated, the program "sux" (included with Debian) is an improved version of the script.

devnull13
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Xlib: connection to ":0.0" refused by server Xlib: No protocol specified eyalkz Linux - Newbie 11 04-22-2015 10:17 AM
XERROR: 'Xlib: connection to ":0.0" refused by server' tsiMental Debian 11 02-16-2007 08:30 PM
Xlib: connection to ":0.0" refused by server Xlib: No protocol specified eyalkz Programming 1 03-02-2004 09:22 AM
Wine not working. Xlib: connection to ":0.0" refused by server Xerop Linux - General 1 02-18-2004 10:37 PM
What is "Xlib: connection to ":0.0" refused by server " rack201 Linux - Software 1 02-04-2004 08:49 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 05:17 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration