Debian This forum is for the discussion of Debian Linux.
|
| Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
 |
GNU/Linux Basic Guide
This 255-page guide will provide you with the keys to understand the philosophy of free software, teach you how to use and handle it, and give you the tools required to move easily in the world of GNU/Linux. Many users and administrators will be taking their first steps with this GNU/Linux Basic guide and it will show you how to approach and solve the problems you encounter.
Click Here to receive this Complete Guide absolutely free. |
|
 |
04-02-2005, 09:41 PM
|
#1
|
|
Member
Registered: Jan 2005
Location: Norway
Distribution: Ubuntu Hoary / Debian Sarge
Posts: 62
Rep:
|
XERROR: 'Xlib: connection to ":0.0" refused by server'
After I installed/converted to Debian Sarge. I get the following error message whenever I try to start a GUI-program from a Konsole in KDE. I am running a 2.6.8-2-686-smp kernel.
Quote:
Xlib: connection to ":0.0" refused by server
Xlib: No protocol specified
|
Does anyone know how to fix this error?
|
|
|
|
04-02-2005, 09:53 PM
|
#2
|
|
Guru
Registered: Nov 2003
Location: N. E. England
Distribution: Fedora, CentOS, Debian
Posts: 16,298
Rep:
|
Are you trying to do this as the user who started the X session? If you are trying to do this as root or a user who didn't start the X session, then you need to do "xhost +localhost" before using "su" to switch to root or another user.
|
|
|
|
04-03-2005, 04:44 AM
|
#3
|
|
Member
Registered: Jan 2005
Location: Norway
Distribution: Ubuntu Hoary / Debian Sarge
Posts: 62
Original Poster
Rep:
|
Tried it:
Quote:
user@linuxpc:~$ xhost +localhost
localhost being added to access control list
user@linuxpc:~$ su
Password:
linuxpc:/home/user# kedit
Xlib: connection to ":0.0" refused by server
Xlib: No protocol specified
kedit: cannot connect to X server :0.0
linuxpc:/home/user#
|
Need this to edit configfiles as root (in an easy way).
If I pop up a terminal an type kedit as user, then kedit starts fine...
|
|
|
|
04-03-2005, 08:48 AM
|
#4
|
|
LQ Newbie
Registered: Aug 2004
Location: The Derby
Distribution: Squeeze AMD64
Posts: 15
Rep:
|
See if this helps, from the mepislover forums.
http://www.mepislovers.org/modules/n...=3083&forum=11
To fix the xhost error you see sometimes when you try to run a program as root from a terminal:
edit your /etc/kde3/kdm/Xservers file
On the line that says:
:0 local@tty1 /usr/X11R6/bin/X -nolisten tcp
Change it to:
:0 local@tty1 /usr/X11R6/bin/X -ac -nolisten tcp
Got this info from http://www.mepis.org/node/view/4535 which Carlos provided the link for.
|
|
|
|
04-03-2005, 09:06 AM
|
#5
|
|
LQ Newbie
Registered: Aug 2004
Location: The Derby
Distribution: Squeeze AMD64
Posts: 15
Rep:
|
"Need this to edit configfiles as root (in an easy way)"
You could also right click desktop choose the run command and enter "kdesu kedit" then enter root password. Just another option I thought maybe of interest or help good luck
norb
|
|
|
|
04-03-2005, 10:18 AM
|
#6
|
|
Senior Member
Registered: Jul 2003
Location: Panama
Distribution: Debian Sid
Posts: 1,013
Rep:
|
With your favorite editor, open /etc/profile
Example: # nano /etc/profile
and add this line:
export XAUTHORITY=/home/your_user_name/.Xauthority
inserting the username you're using in this box, obviously.
save/exit
logout/login
Last edited by macondo; 04-03-2005 at 10:24 AM.
|
|
|
|
04-03-2005, 10:47 AM
|
#7
|
|
Guru
Registered: Nov 2003
Location: N. E. England
Distribution: Fedora, CentOS, Debian
Posts: 16,298
Rep:
|
You can edit config files with a console only editor like nano/pico, emacs, vi/vim etc. You don't realy need to start a gui text editor, but if you are not familiar with the others then the "kdesu" command suggested above is ok to use.
|
|
|
|
04-03-2005, 06:27 PM
|
#8
|
|
Member
Registered: Feb 2003
Location: Jersey shore,north
Distribution: Siduction the only way to do Debian Sid!
Posts: 500
Rep:
|
Use "sux" instead of "su"
|
|
|
|
04-05-2005, 09:50 PM
|
#9
|
|
Member
Registered: Jan 2005
Location: Norway
Distribution: Ubuntu Hoary / Debian Sarge
Posts: 62
Original Poster
Rep:
|
Quote:
Originally posted by macondo
With your favorite editor, open /etc/profile
Example: # nano /etc/profile
and add this line:
export XAUTHORITY=/home/your_user_name/.Xauthority
inserting the username you're using in this box, obviously.
save/exit
logout/login
|
the file /root/.Xauthority does not exist... Does that matter?
|
|
|
|
04-05-2005, 10:14 PM
|
#10
|
|
Member
Registered: Jan 2005
Location: Norway
Distribution: Ubuntu Hoary / Debian Sarge
Posts: 62
Original Poster
Rep:
|
Quote:
Originally posted by Norb
See if this helps, from the mepislover forums.
http://www.mepislovers.org/modules/n...=3083&forum=11
To fix the xhost error you see sometimes when you try to run a program as root from a terminal:
edit your /etc/kde3/kdm/Xservers file
On the line that says:
:0 local@tty1 /usr/X11R6/bin/X -nolisten tcp
Change it to:
:0 local@tty1 /usr/X11R6/bin/X -ac -nolisten tcp
Got this info from http://www.mepis.org/node/view/4535 which Carlos provided the link for.
|
Tnx nurb!!! Works now, needed to reboot after I'd done this.
btw: "sux" didn't work in my Konsole...
|
|
|
|
04-08-2005, 07:25 AM
|
#11
|
|
LQ Newbie
Registered: Aug 2004
Location: The Derby
Distribution: Squeeze AMD64
Posts: 15
Rep:
|
Your Welcome
Norb
|
|
|
|
02-16-2007, 07:30 PM
|
#12
|
|
LQ Newbie
Registered: Feb 2007
Posts: 5
Rep:
|
I don't have /etc/kde3/kdm/Xservers.
Code:
# cd /etc/kde3/kdm
# ls
backgroundrc kdmrc kdmrc.dpkg-dist Xaccess Xreset Xsession Xsetup Xstartup Xwilling
#
|
|
|
|
| Thread Tools |
Search this Thread |
|
|
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
All times are GMT -5. The time now is 10:38 AM.
|
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|