LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 06-27-2010, 04:26 PM   #1
MrUmunhum
Member
 
Registered: May 2006
Location: Mt Umunhum, CA, USA, Earth
Distribution: Debian/ Fedora/ Ubuntu/ Raspbian
Posts: 549

Rep: Reputation: 40
xauth fails for remote client


Hi group,

No sure exactly what the problem is here? I am trying to get a X app running from a remote site on my desktop. I am using this proceedure:
  • xhost +remote host
  • xauth on local host the get 'Cookie'.
  • scp Cookie to remote host
  • xauth merge Cookie into .Xauthority
  • ssh to remote.
  • export DISPLAY=local host:0
  • xfig
xfig fails with "Error: Can't open display: local:0"

If I start another X using '-ac' ( not authinaction) and put to local:1 , all is well.

Can anyone see what is wrong???

FYI, remote is running Debian, local running Fedora 12.

Thanks for your time.

Last edited by MrUmunhum; 06-27-2010 at 04:31 PM.
 
Old 06-28-2010, 09:12 AM   #2
zordrak
Member
 
Registered: Feb 2008
Distribution: Slackware
Posts: 595

Rep: Reputation: 116Reputation: 116
On remote
Edit /etc/sshd/sshd_config
Set "X11Forwarding yes"
Restart sshd.

On local
ssh -Y user@remote
xfig
 
Old 06-29-2010, 12:06 PM   #3
MrUmunhum
Member
 
Registered: May 2006
Location: Mt Umunhum, CA, USA, Earth
Distribution: Debian/ Fedora/ Ubuntu/ Raspbian
Posts: 549

Original Poster
Rep: Reputation: 40
Nice try

Quote:
Originally Posted by zordrak View Post
On remote
Edit /etc/sshd/sshd_config
Set "X11Forwarding yes"
Restart sshd.

On local
ssh -Y user@remote
xfig
Small point, on Debian, it is " ForwardX11 yes"

Second part did not work:
Code:
Server:~# export DISPLAY=xx.xx.xx.xx:0
Server:~# gedit&
Server:~# cannot open display: 
Run 'gedit --help' to see a full list of available command line options.
[2]+  Exit 1                  gedit
Server:~# gedit display=xx.xx.xx.xx:0
cannot open display: 
Run 'gedit --help' to see a full list of available command line options.
It is a problem with authentication on the X manager. In this case, GDM.
If I use the no authentication option ( "-ac" ) on X, it works. But that is a security hole.

Thanks for the suggestion anyway.
 
Old 06-30-2010, 03:39 AM   #4
zordrak
Member
 
Registered: Feb 2008
Distribution: Slackware
Posts: 595

Rep: Reputation: 116Reputation: 116
Quote:
Originally Posted by MrUmunhum View Post
Small point, on Debian, it is " ForwardX11 yes"
How is different on Debian to anything else? It's not something that should be Debian specific; it's sshd.

Quote:
Originally Posted by MrUmunhum View Post
Second part did not work:
This is what I said:
Code:
# ssh -Y user@remote
# xfig
This is what you say you did:
Code:
# export DISPLAY=xx.xx.xx.xx:0
# gedit&
They are different and so are unlikely to produce the same result. The whole point being that ssh -Y *sets* your display and it sets it to localhost:10.0 which is necessary for X11 forwarding to work. Instead you have overwritten the DISPLAY variable with a direct connection back to the X server which obviously is not going to work.

Quote:
Originally Posted by MrUmunhum View Post
It is a problem with authentication on the X manager. In this case, GDM.
I think you may be confused. AFAIK GDM is just starting X with whatever options it has been told to, including for example whether to set -ac, it doesn't handle authentication to X.

Quote:
Originally Posted by MrUmunhum View Post
If I use the no authentication option ( "-ac" ) on X, it works. But that is a security hole.
Still, the problem seems that you are not using SSH X Forwarding, you are simply connecting with SSH and trying to connect back to X with a direct connection that has been explicitly disallowed.
 
Old 07-01-2010, 03:47 PM   #5
MrUmunhum
Member
 
Registered: May 2006
Location: Mt Umunhum, CA, USA, Earth
Distribution: Debian/ Fedora/ Ubuntu/ Raspbian
Posts: 549

Original Poster
Rep: Reputation: 40
[Solved] xauth fails for remote client

Quote:
This is what I said:
Code:

# ssh -Y user@remote
# xfig

This is what you say you did:
Code:

# export DISPLAY=xx.xx.xx.xx:0
# gedit&
Yes, you are right. Sorry.

Code:
ssh -Y root@remote
gedit&
Works correctly.

Thanks
 
  


Reply



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
swat from remote computer fails bikeman Linux - Server 2 07-28-2010 02:11 AM
ProFTPd ... FTP client fails to connect: timeout after client sends 'LIST' nutnut Linux - Software 2 01-01-2006 07:09 PM
DHCP (client) fails at startup frankwaanders Linux - Networking 1 09-22-2005 01:43 AM
Remote webmin access fails SolarBear Debian 3 03-02-2005 07:39 AM
SENDMAIL - sm-client fails digimike Linux - Newbie 4 08-09-2003 02:30 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 06:16 PM.

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