Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Where is this "xhost" command?



For people still having problems with ssh forwarding X11, the first thing not 
mentionend already that you should check is that if you edited 
/etc/ssh/sshd_config on the solaris server side, you need to either type 
"/etc/init.d/sshd restart" as root.  Or reboot the Solaris box.  Any edits to 
sshd_config will not be picked up until you do this.

|> Thanks for mentioning the -v flag. That shows me this on my iMac in a 
|> terminal window.
|> 
|> email@hidden's password:
|> Warning: No xauth data; using fake authentication data for X11 forwarding.

"No xauth data" is not great - this implies you may have run "xhost +" on the 
eMac or done something else to disable authentication.  Still this is orthogonal 
to the problem of getting ssh working.

|> debug1: Requesting X11 forwarding with authentication spoofing.

OK, good.  this shows the eMac end is requesting X11 so any remaining issues are 
at the Solaris/AIX end.  Unfortunately it doesn't say if the remote system 
agreed to do X11 forwarding.

|> What am I doing wrong?

As Tim Cutts pointed out, once you've logged in with ssh you don't want any more 
X11 commands.  (Well, it's actually possible to start a nested desktop with VNC 
or with Xnest, but 99% of people don't want this).  Instead you start individual 
X-based commands within the terminal windo that's logged into the remote box.

As mentioned above, the next thing you should check is that you restarted sshd 
first.  See above.

Assuming you did this and then ran ssh from the eMac aftererwards, try the 
following to verify it's working.  Again, these commands go into the window 
that's logged into the remote solaris/AIX box.  either:

1)  "echo $DISPLAY" should show something like "hostname:10.0".  The
    number may vary, but if this gives an error or a blank line then
    forwarding is not working.  If so make sure you edited sshd_config
    and restarted sshd.

2)  Try simple X11 command such as "xdpyinfo" (gives a textual
    description of some info about your mac display), "xclock"
    (simple clock), "xterm" (gives another terminal window on
    the remote box), etc.  On Solaris these particular commands
    live in /usr/openwin/bin, and there are other commands in
    /usr/dt/bin and elsewhere (in case the plain commands are
    not in your path).  Don't know about AIX.

In cases like this you should always start with some of these simple commands 
first.  and then go onto the commands you really want to run only after getting 
these running.

Hugh.

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
X11-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/x11-users/email@hidden

This email sent to email@hidden



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.