Help answer threads with 0 replies.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 06-30-2006, 12:14 AM   #1
LQ Newbie
Registered: Sep 2002
Location: Mumbai, INDIA.
Distribution: Debian GNU/Linux 2.6.11 - coLinux 0.6.3
Posts: 8

Rep: Reputation: 0
X Server error after installing KDE+Vncserver

Few days back I configured my coLinux 0.6.3 (Debian Linux 3.1 Kernel 2.6.11) system for using KDE by installing KDE, vncserver on Linux and TightVnc on WinXP SP2.

Now I can use KDE 3.3.2 desktop from WinXP using TightVNC viewer. But this recent installation has affected the X Server in a way that it refuses access to any other client like dpkg-reconfigure, xterm, xlsfonts, etc.

I get following error(s) while trying to execute-

root@coLinux:/etc# dpkg-reconfigure xserver-xfree86
Xlib: connection to "" refused by server
Xlib: Client is not authorized to connect to Server
dpkg-reconfigure: cannot connect to X server
root@coLinux:/etc# xterm
Xlib: connection to "" refused by server
Xlib: Client is not authorized to connect to Server
Warning: This program is an suid-root program or is being run by the root user. The full text of the error or warning message cannot be safely formatted in this environment. You may get a more descriptive message by running the program as a non-root user or by removing the suid bit on the executable. xterm Xt error: Can't open display: %s
root@coLinux:/etc# xlsfonts RET
Xlib: connection to "" refused by server
Xlib: Client is not authorized to connect to Server
xlsfonts: unable to open display ''

Even when trying to install new packages, dpkg-preconfigure gives the same "cannot connect to X server" error.

My configuration:
For coLinux, eth0 is set to
In /etc/bash.bashrc, I am exporting DISPLAY as-
export DISPLAY=

I am using kdm as x-window manager.
I have following setup in /etc/kde3/kdm/

#:0 local@tty1 /usr/X11R6/bin/X -nolisten tcp
#:1 local@tty2 reserve /usr/X11R6/bin/X -nolisten tcp :1
#:2 local@tty3 reserve /usr/X11R6/bin/X -nolisten tcp :2
#:3 local@tty4 reserve /usr/X11R6/bin/X -nolisten tcp :3
#:4 local@tty5 reserve /usr/X11R6/bin/X -nolisten tcp :4
:0 local /usr/bin/Xvnc :0 -geometry 1016x704 -depth 32 -desktop vt7

* #any host can get a login window
* CHOOSER BROADCAST #any indirect host can get a chooser

Before KDE installation, dpkg and other programs were working correctly. What have I done wrong?

Please advise.

Thanks & Regards,
Old 06-30-2006, 06:39 PM   #2
Registered: Mar 2005
Location: Kansas City
Distribution: Ubuntu 7.10
Posts: 47

Rep: Reputation: 15
It is because by default root does not have access to X. If you want ALL users to be able to launch graphical applications from a command line you can disable X access controls. As a normal user type "xhost +" to disable it. You can type "xhost -" to enable it again but that means that you cannot launch applications as root from the shell. You can also simply add root to the access list although I am unsure of the syntax for that.

*note: those are plus/minus signs in the xhost commands - see "man xhost" for more information.


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 Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
VNCSERVER Causes KDE Daemon to Crash anseK Mandriva 6 01-02-2006 09:49 PM
Robust vncserver startup file (rc.vncserver) arobinson74 Slackware 4 05-14-2005 06:33 AM
VNCSERVER Error message alirezan1 Linux - Newbie 4 12-22-2004 03:01 PM
vncserver error loading shared lib. WeBoat Linux - Software 2 06-22-2004 09:19 AM
Error when installing KDE 3.1 kgsum Linux - Software 2 02-27-2003 12:49 PM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 08:30 PM.

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