I SSH'ed into a machine and used -X to turn on X forwarding. Then tried to start a simple xterm. I got the message
xterm Xt error: Can't open display: %s xterm: DISPLAY is not set
I know the SSHd forwarding is turned on but this made no sense. So I used the ever so helpful -vvv debuging feature built in to OpenSSH. So you ssh like the following command.
ssh -Xvvv username@hostname
This procedes to tell me in the last few lines
debug1: Remote: No xauth program; cannot forward with spoofing.". The above the line "debug2: x11_get_proto: /usr/bin/X11/xauth list :0.0 2>/dev/null
This shows it looking for xauth in /usr/bin/X11/xauth. It's not there so I make a symbolic link it there (restart sshd), login again and still no go. My xauth lives in /usr/bin/xauth. Then I tried using configuration setting "xauthlocation /usr/bin/xauth" in the sshd_config file and restarting sshd. That did not work either. So I do decide to see where sshd thinks xauth lives. I check this with the strings command.
strings sshd | grep xauth
That gave me the following:
So I make a symbolic link from /usr/bin/xauth to /usr/X11R6/bin/xauth and it worked perfectly. The one thing I do need to say is that this SSH version was compiled by someone and was not part of a distro. So it seems it had it's own default places it looked for things.