Re: xhost: cannot connect to X server
On Wed, Mar 18, 2009 at 23:52:00 +0100, Dieder Vervoort wrote:
> Florian Kulzer wrote:
>>>> On Sat, Mar 14, 2009 at 23:22:32 +0100, Dieder Vervoort wrote:
>>>>
>>>>> I can' t make xhost to work.
[...]
>> The first thing to check is if X really was started without "-nolisten
>> tcp":
>>
>> $ ps -ef | grep "[/]bin/X "
>> root 9482 9480 0 22:49 tty7 00:00:01 /usr/bin/X -br :0 vt7 -auth /var/run/xauth/A:0-qdt4bc
[...]
> I booted from Lenny-KDE 3.5 from a USB-key
>
> Did some tests again, here are the results,
>
> dieder@panda:~$ xhost +
> access control disabled, clients can connect from any host
> dieder@panda:~$ export DISPLAY=127.0.0.1:0
> dieder@panda:~$ xclock
> Error: Can't open display: 127.0.0.1:0
>
> dieder@panda:~$ ps -ef | grep "[/]bin/X "
> root 3588 3585 1 21:50 tty7 00:00:45 /usr/bin/X -br -nolisten tcp :0 vt7 -auth /var/run/xauth/A:0-4dB4fg
> # -nolisten ! > check config files:
OK, we have to figure out where the "-nolisten tcp" comes from.
> dieder@panda:~$ cat /etc/X11/xinit/xserverrc
> #!/bin/sh
>
> # $Id: xserverrc 189 2005-06-11 00:04:27Z branden $
>
> exec /usr/bin/X11/X
AFAIK, it is not even necessary to remove the "-nolisten tcp" here if
you are starting Xorg via [xkg]dm.
> dieder@panda:~$ cat /etc/kde3/kdm/kdmrc|grep ServerArgsLocal
> ServerArgsLocal=
Hmm, on my system that is enough to make Xorg listen to port 6000 (after
I restart kdm). However, looking at /etc/init.d/kdm I get the impression
that in some cases you also have to edit /var/run/kdm/kdmrc to remove
ServerArgsLocal.
If that does not help then I would like to see the output of
pstree -aAc | grep -B2 -A2 '[X]org'
--
Regards, | http://users.icfo.es/Florian.Kulzer
Florian |
Reply to: