1755004 Members
3350 Online
108828 Solutions
New Discussion юеВ

XServer Error Message

 
Andrew Kaplan
Super Advisor

XServer Error Message

We have a Fedora Core 3 system that connects to a remote Red Hat 8.0 system in the following manner: The user runs the xhost + command on the Fedora system and then telnets to the remote 8.0 server via an xterm connection. Once there, the user in the past was able to run emacs and have the emacs application gui appear on the Fedora system's desktop. Recently this has not been the case. The following error message appears instead: cannnot connect to xserver 0.0 Try -d or DISPLAY. Has anyone seen this and know how to troubleshoot it? Thanks.
A Journey In The Quest Of Knowledge
11 REPLIES 11
Dave Falloon
Trusted Contributor

Re: XServer Error Message

You are probably running Xserver with the --no-listen tcp

You can check the options that X is running with this command:

ps -jxww
or
ps -auxww

If you see x running with the no-listen tcp it's probably set during startup. Check the X startup scripts, I'm not 100% sure but I think they are in /etc/X11/. Recursive grep will find it

grep -ri no-listen /etc/X11/

There is a security concern with opening X to tcp connections. You may want to just ssh instead of telnet and turn on the X forwarding options like so:

ssh -X user@rh8.0machine
then export your DISPLAY env var.

--Dave


--Dave
Clothes make the man, Naked people have little to no effect on society
Ian Vaughan
Honored Contributor

Re: XServer Error Message

Ht,
try "echo $DISPLAY" at a command line. If it doesn't come back with anything then it isn't set. have a look in the .profile or .bash_profile for the user and see if someone has commented it out.

Should be like
DISPLAY=$( who -mu | cut -d"(" -f1 | tr ")" ":" )0.0 ; export DISPLAY

HTH
Ian
Hope that helps - please click "Thumbs up" for Kudos if it does
## ---------------------------------------------------------------------------##
Which is the only cheese that is made backwards?
Edam!
Tweets: @2techie4me
Andrew Kaplan
Super Advisor

Re: XServer Error Message

Hi guys -- I tried the various reconfigurations that were suggested, and unfortunately none worked. Anyone have any other ideas? Thanks.
A Journey In The Quest Of Knowledge
Mobeen_1
Esteemed Contributor

Re: XServer Error Message

Andrew,
Looks like the display is missing, try the following

$ set DISPLAY :0.0
$ export DISPLAY

regards
Mobeen
Andrew Kaplan
Super Advisor

Re: XServer Error Message

Hi there --

There is no export command on the remote RH 8 server. Is it an rpm that can be downloaded?
A Journey In The Quest Of Knowledge
Ian Vaughan
Honored Contributor

Re: XServer Error Message

Hi,
The export command is a built-in part of your shell environment. If you are on fc3 it is most probably the BASH shell. It will be there somewhere - trust us.
Anyhoo - that doesn't solve your real problem...
I take it that the xserver is ok on the FC3 machine and that X apps run ok e.g. xclock or whatever.
Try explicitly setting your display variable on the RH8 box as DISPLAY=:0.0 ; export DISPLAY - is that any better, can you get other xapps to work ovwer the connection, can you narrow it down to an emacs config prob.
HTH
Ian
Hope that helps - please click "Thumbs up" for Kudos if it does
## ---------------------------------------------------------------------------##
Which is the only cheese that is made backwards?
Edam!
Tweets: @2techie4me
Bejoy C Alias
Respected Contributor

Re: XServer Error Message

This may be because of any firewall rules you had configured. Try iptables -F on the fedora machine and then try to run the emacs on the rh 8.0 machine .
Be Always Joy ......
Rashard Kelly_1
New Member

Re: XServer Error Message

Hi I ran into the same problem. The way you get around this is by
1.)) editing this file

/etc/X11/gdm/gdm.conf <<-----

and changing the disallow tcp parameter to false.

# Note: Anytime we find a -query or -indirect on the command line we do
# not add a "-nolisten tcp", as then the query just wouldn't work, so
# this setting only affects truly local sessions.
DisallowTCP=false


2)) Logout of x. ctrl+alt+backspace

3)) Log into a root shell

switch to init3 and then to init5 by running

init 3 init 5

your graphical greeter should pop back up once you change back to init 5.

when you change to init 3 you will not get a promt. when the last service reads ok after issuing the init 3 command type in init 5 and upon pressing enter you will get the graphical greeter login.


log log into the window manager of your choice

open a terminal to ssh to your server
ssh -X
export DISPLAY=
&


this worked for me I hope I did not leave a step out.

Jan Sladky
Trusted Contributor

Re: XServer Error Message

Hi Andrew,

seems like DISPLAYMANGER has forbiden to listen on port 6000

just do following

on remote export DISPLAY=IP:0.0 where 0.0 means first display first monitor

and change gdm.conf on local

/etc/X11/gdm/gdm.conf

to

DisallowTCP=false

rgds Jan

GSM, Intelligent Networks, UNIX