Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

I have a local machine A, and a server B.

from A, I got:

#ps -ef
root      3161  3160  0 09:07 tty1     00:03:04 /usr/bin/Xorg :0 -nr -verbose -auth /var/run/gdm/auth-for-gdm-dJExDH/database vt1

#netstat -nltu
tcp        0      0 0.0.0.0:6000                0.0.0.0:*                   LISTEN      - 

#xhost +
access control disabled, clients can connect from any host

A's ip address is 10.99.54.148

From B, I trid:

#export DISPLAY=10.99.54.148:0.0
#xclock
Xlib: connection to "10.99.54.148:0.0" refused by server
Xlib: No protocol specified

Error: Can't open display: 10.99.54.148:0

I have another desktop C, if I change the DISPLAY to C's IP address, xclock will work. Any suggestion on what to check in A?

share|improve this question

migrated from serverfault.com Jan 13 '12 at 7:42

This question came from our site for professional system and network administrators.

    
Are you using SSH to connect to both? If so, make sure you use the -Y switch to enable trusted X forwarding. –  Herman Torjussen Jan 13 '12 at 13:00
    
no, I'm not using SSH, thanks –  valpa Jan 16 '12 at 0:41

1 Answer 1

Looks as if xclock tries to connect to the x-server using a tcp connection while the x server is not listening to tcp.

In ubuntu that can be changed by:

sudo gedit /etc/gdm/gdm.schemas

find:

<schema>
<key>security/DisallowTCP</key>
<signature>b</signature>
<default>true</default>
</schema>

change from true to false:

<schema>
<key>security/DisallowTCP</key>
<signature>b</signature>
<default>false</default>
</schema>

and then restart gdm.

share|improve this answer
    
#netstat -nltu tcp 0 0 0.0.0.0:6000 0.0.0.0:* LISTEN - X server already listen on 6000 –  valpa Jan 16 '12 at 0:42
    
firewall that does rejects instead of drops? –  Folkert van Heusden Jan 17 '12 at 0:53

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.