Summary: OpenSSH and XWindows

From: Jay Morgan <jhmnospam_at_jaymorgan.us>
Date: Tue Feb 01 2011 - 15:17:06 EST
I found my own solution.  Thanks to a number of folks who responded.  I 
hadn't seen a console message that was popping up when logging in, and a 
google search of that error provided the solution.  It's apparently a 
bug, with a workaround in how ssh handles a system with only IPv4 
addresses.

The console error I was getting was: "error: Failed to allocate 
internet-domain X11 display socket."

Upon doing a little google-ing, I found a couple of sites  that describe 
the problem and workarounds.
http://groups.google.com/group/mailing.unix.openssh-dev/browse_thread/thread/8bc4833f84f05ce3
http://dbaspot.com/forums/solaris/397531-s10-sshd-x-forwarding-problem.html

Basically, the workaround I selected was to bring up an IPv6 loopback 
interface, and all new ssh sessions create X11 sockets correctly.

Jay

On 1/31/11 3:28 PM, Jay Morgan wrote:
> All,
>
> We had to migrate from Solaris 10 built-in SSH to OpenSSH (5.6p1) due to
> a requirement for "jailing" functionality found in OpenSSH (I hear
> rumors this will be coming to built-in SSH - crossing fingers).  Now
> that we're on it, I'm having issues with establishing XWindows sessions
> with the servers with OpenSSH on them.  FWIW, the client I'm coming from
> is running MacOS X 10.6.6, running OpenSSH 5.2p1
>
> When I run xterm, I get "xterm Xt error: Can't open display:"  It works
> fine to other Solaris hosts (running built-in Solaris SSH), and to linux
> hosts.
>
> doing "ssh -Yvvv root@server", I get the following debug output:
>
> OpenSSH_5.2p1, OpenSSL 0.9.8l 5 Nov 2009
> debug1: Reading configuration data /etc/ssh_config
> debug2: ssh_connect: needpriv 0
> debug1: Connecting to server [10.11.12.13] port 22.
> debug1: Connection established.
> debug1: identity file /Users/username/.ssh/identity type -1
> debug1: identity file /Users/username/.ssh/id_rsa type -1
> debug1: identity file /Users/username/.ssh/id_dsa type -1
> debug1: Remote protocol version 2.0, remote software version OpenSSH_5.6
> debug1: match: OpenSSH_5.6 pat OpenSSH*
> debug1: Enabling compatibility mode for protocol 2.0
> debug1: Local version string SSH-2.0-OpenSSH_5.2
> debug2: fd 3 setting O_NONBLOCK
> debug1: SSH2_MSG_KEXINIT sent
> debug1: SSH2_MSG_KEXINIT received
> debug2: kex_parse_kexinit:
> diffie-hellman-group-exchange-sha256,diffie-hellman-group-exchange-sha1,diffie-hellman-group14-sha1,diffie-hellman-group1-sha1
> debug2: kex_parse_kexinit: ssh-rsa,ssh-dss
> debug2: kex_parse_kexinit:
> aes128-ctr,aes192-ctr,aes256-ctr,arcfour256,arcfour128,aes128-cbc,3des-cbc,blowfish-cbc,cast128-cbc,aes192-cbc,aes256-cbc,arcfour,rijndael-cbc@lysator.liu.se
> debug2: kex_parse_kexinit:
> aes128-ctr,aes192-ctr,aes256-ctr,arcfour256,arcfour128,aes128-cbc,3des-cbc,blowfish-cbc,cast128-cbc,aes192-cbc,aes256-cbc,arcfour,rijndael-cbc@lysator.liu.se
> debug2: kex_parse_kexinit:
> hmac-md5,hmac-sha1,umac-64@openssh.com,hmac-ripemd160,hmac-ripemd160@openssh.com,hmac-sha1-96,hmac-md5-96
> debug2: kex_parse_kexinit:
> hmac-md5,hmac-sha1,umac-64@openssh.com,hmac-ripemd160,hmac-ripemd160@openssh.com,hmac-sha1-96,hmac-md5-96
> debug2: kex_parse_kexinit: none,zlib@openssh.com,zlib
> debug2: kex_parse_kexinit: none,zlib@openssh.com,zlib
> debug2: kex_parse_kexinit:
> debug2: kex_parse_kexinit:
> debug2: kex_parse_kexinit: first_kex_follows 0
> debug2: kex_parse_kexinit: reserved 0
> debug2: kex_parse_kexinit:
> diffie-hellman-group-exchange-sha256,diffie-hellman-group-exchange-sha1,diffie-hellman-group14-sha1,diffie-hellman-group1-sha1
> debug2: kex_parse_kexinit: ssh-rsa,ssh-dss
> debug2: kex_parse_kexinit:
> aes128-ctr,aes192-ctr,aes256-ctr,arcfour256,arcfour128,aes128-cbc,3des-cbc,blowfish-cbc,cast128-cbc,aes192-cbc,aes256-cbc,arcfour,rijndael-cbc@lysator.liu.se
> debug2: kex_parse_kexinit:
> aes128-ctr,aes192-ctr,aes256-ctr,arcfour256,arcfour128,aes128-cbc,3des-cbc,blowfish-cbc,cast128-cbc,aes192-cbc,aes256-cbc,arcfour,rijndael-cbc@lysator.liu.se
> debug2: kex_parse_kexinit:
> hmac-md5,hmac-sha1,umac-64@openssh.com,hmac-ripemd160,hmac-ripemd160@openssh.com,hmac-sha1-96,hmac-md5-96
> debug2: kex_parse_kexinit:
> hmac-md5,hmac-sha1,umac-64@openssh.com,hmac-ripemd160,hmac-ripemd160@openssh.com,hmac-sha1-96,hmac-md5-96
> debug2: kex_parse_kexinit: none,zlib@openssh.com
> debug2: kex_parse_kexinit: none,zlib@openssh.com
> debug2: kex_parse_kexinit:
> debug2: kex_parse_kexinit:
> debug2: kex_parse_kexinit: first_kex_follows 0
> debug2: kex_parse_kexinit: reserved 0
> debug2: mac_setup: found hmac-md5
> debug1: kex: server->client aes128-ctr hmac-md5 none
> debug2: mac_setup: found hmac-md5
> debug1: kex: client->server aes128-ctr hmac-md5 none
> debug1: SSH2_MSG_KEX_DH_GEX_REQUEST(1024<1024<8192) sent
> debug1: expecting SSH2_MSG_KEX_DH_GEX_GROUP
> debug2: dh_gen_key: priv key bits set: 130/256
> debug2: bits set: 514/1024
> debug1: SSH2_MSG_KEX_DH_GEX_INIT sent
> debug1: expecting SSH2_MSG_KEX_DH_GEX_REPLY
> debug3: check_host_in_hostfile: filename /Users/username/.ssh/known_hosts
> debug3: check_host_in_hostfile: match line 25
> debug3: check_host_in_hostfile: filename /Users/username/.ssh/known_hosts
> debug3: check_host_in_hostfile: match line 25
> debug1: Host 'server' is known and matches the RSA host key.
> debug1: Found key in /Users/username/.ssh/known_hosts:25
> debug2: bits set: 532/1024
> debug1: ssh_rsa_verify: signature correct
> debug2: kex_derive_keys
> debug2: set_newkeys: mode 1
> debug1: SSH2_MSG_NEWKEYS sent
> debug1: expecting SSH2_MSG_NEWKEYS
> debug2: set_newkeys: mode 0
> debug1: SSH2_MSG_NEWKEYS received
> debug1: SSH2_MSG_SERVICE_REQUEST sent
> debug2: service_accept: ssh-userauth
> debug1: SSH2_MSG_SERVICE_ACCEPT received
> debug2: key: /Users/username/.ssh/identity (0x0)
> debug2: key: /Users/username/.ssh/id_rsa (0x0)
> debug2: key: /Users/username/.ssh/id_dsa (0x0)
> debug1: Authentications that can continue:
> publickey,password,keyboard-interactive
> debug3: start over, passed a different list
> publickey,password,keyboard-interactive
> debug3: preferred publickey,keyboard-interactive,password
> debug3: authmethod_lookup publickey
> debug3: remaining preferred: keyboard-interactive,password
> debug3: authmethod_is_enabled publickey
> debug1: Next authentication method: publickey
> debug1: Trying private key: /Users/username/.ssh/identity
> debug3: no such identity: /Users/username/.ssh/identity
> debug1: Trying private key: /Users/username/.ssh/id_rsa
> debug3: no such identity: /Users/username/.ssh/id_rsa
> debug1: Trying private key: /Users/username/.ssh/id_dsa
> debug3: no such identity: /Users/username/.ssh/id_dsa
> debug2: we did not send a packet, disable method
> debug3: authmethod_lookup keyboard-interactive
> debug3: remaining preferred: password
> debug3: authmethod_is_enabled keyboard-interactive
> debug1: Next authentication method: keyboard-interactive
> debug2: userauth_kbdint
> debug2: we sent a keyboard-interactive packet, wait for reply
> debug2: input_userauth_info_req
> debug2: input_userauth_info_req: num_prompts 1
> Password:
> debug3: packet_send2: adding 32 (len 23 padlen 9 extra_pad 64)
> debug2: input_userauth_info_req
> debug2: input_userauth_info_req: num_prompts 0
> debug3: packet_send2: adding 48 (len 10 padlen 6 extra_pad 64)
> debug1: Authentication succeeded (keyboard-interactive).
> debug1: channel 0: new [client-session]
> debug3: ssh_session2_open: channel_new: 0
> debug2: channel 0: send open
> debug1: Requesting no-more-sessions@openssh.com
> debug1: Entering interactive session.
> debug2: callback start
> debug2: x11_get_proto: /usr/X11R6/bin/xauth  list
> /tmp/launch-hBpNWN/org.x:0 2>/dev/null
> Warning: No xauth data; using fake authentication data for X11 forwarding.
> debug1: Requesting X11 forwarding with authentication spoofing.
> debug2: channel 0: request x11-req confirm 0
> debug1: Requesting authentication agent forwarding.
> debug2: channel 0: request auth-agent-req@openssh.com confirm 0
> debug2: client_session2_setup: id 0
> debug2: channel 0: request pty-req confirm 1
> debug2: channel 0: request shell confirm 1
> debug2: fd 3 setting TCP_NODELAY
> debug2: callback done
> debug2: channel 0: open confirm rwindow 0 rmax 32768
> debug2: channel_input_status_confirm: type 99 id 0
> debug2: PTY allocation request accepted on channel 0
> debug2: channel 0: rcvd adjust 2097152
> debug2: channel_input_status_confirm: type 99 id 0
> debug2: shell request accepted on channel 0
> Last login: Mon Jan 31 20:17:43 2011 from 172.29.74.241
> Sun Microsystems Inc.   SunOS 5.10      Generic January 2005
>
> Anyone have any recommendations on how to debug further?
>
> Thanks,
>
> Jay
>

-- 
Jay Morgan
jhmnospam@jaymorgan.us
_______________________________________________
sunmanagers mailing list
sunmanagers@sunmanagers.org
http://www.sunmanagers.org/mailman/listinfo/sunmanagers
Received on Tue Feb 1 15:17:30 2011

This archive was generated by hypermail 2.1.8 : Thu Mar 03 2016 - 06:44:17 EST