1832964 Members
2673 Online
110048 Solutions
New Discussion

setting up ssh

 
SOLVED
Go to solution
Gary L. Paveza, Jr.
Trusted Contributor

setting up ssh

I'm setting up ssh and I'm not able to login to my server using it. Can anyone help decipher what the problem is from the attached log?

14 REPLIES 14
Sridhar Bhaskarla
Honored Contributor

Re: setting up ssh

Hi Gary,

//debug2: channel 0: sent ext data 1
debug1: channel 0: read<=0 rfd 13 len 0debug1: Received SIGCHLD.
//

This is suspecious but there isn't much I could digest from the log. Can you post your 'ssh -vvv your_server' output? from the client side?

-Sri
You may be disappointed if you fail, but you are doomed if you don't try
Ravi_8
Honored Contributor

Re: setting up ssh

Hi,

you are building the ssh .depot is available which is easier to install and configure itself

http://www.software.hp.com/cgi-bin/swdepot_parser.cgi/cgi/displayProductInfo.pl?productNumber=T1471AA
never give up
Steven E. Protter
Exalted Contributor

Re: setting up ssh

have you used solid depot files and followed Chris's cook book? Attaching.

You can replace the X stuff with cat >> commands.

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
Gary L. Paveza, Jr.
Trusted Contributor

Re: setting up ssh

This is what I get from the client side (it's a ReflectionX connection):


================================================================================
xterm (kappa via ssh)
Connecting kappa via OPENSSH
Wednesday, February 25, 2004 9:48:56
--------------------------------------------------------------------------------
OpenSSH_3.0.2p1, SSH protocols 1.5/2.0, OpenSSL 0x0090601f

09:48:56 debug1: Seeding random number generator
09:48:56 debug1: Rhosts Authentication disabled, originating port will not be trusted.
09:48:56 debug1: restore_uid
09:48:56 debug3: getuid() - warning stubbed function
09:48:56 debug3: setuid() - warning stubbed function
09:48:56 debug3: getgid() - warning stubbed function
09:48:56 debug3: setgid() - warning stubbed function
09:48:56 debug3: setgroups() - warning stubbed function
09:48:56 debug3: main():sshdll.display - 127.0.0.1:0.0
09:48:56 debug3: geteuid() - warning stubbed function
09:48:56 debug3: getuid() - warning stubbed function
09:48:56 debug1: ssh_connect: getuid 0 geteuid 0 anon 1
09:48:56 debug1: Connecting to kappa [172.22.134.9] port 22.
09:48:56 debug3: geteuid() - warning stubbed function
09:48:56 debug3: getgroups() - warning stubbed function
09:48:56 debug3: setgroups() - warning stubbed function
09:48:56 debug3: getgid() - warning stubbed function
09:48:56 debug3: setgid() - warning stubbed function
09:48:56 debug3: geteuid() - warning stubbed function
09:48:56 debug3: setuid() - warning stubbed function
09:48:56 debug3: setegid() - warning stubbed function
09:48:56 debug3: seteuid() - warning stubbed function
09:48:56 debug1: restore_uid
09:48:56 debug3: getuid() - warning stubbed function
09:48:56 debug3: setuid() - warning stubbed function
09:48:56 debug3: getgid() - warning stubbed function
09:48:56 debug3: setgid() - warning stubbed function
09:48:56 debug3: setgroups() - warning stubbed function
09:48:56 debug3: geteuid() - warning stubbed function
09:48:56 debug3: getgroups() - warning stubbed function
09:48:56 debug3: setgroups() - warning stubbed function
09:48:56 debug3: getgid() - warning stubbed function
09:48:56 debug3: setgid() - warning stubbed function
09:48:56 debug3: geteuid() - warning stubbed function
09:48:56 debug3: setuid() - warning stubbed function
09:48:56 debug3: setegid() - warning stubbed function
09:48:56 debug3: seteuid() - warning stubbed function
09:48:56 debug1: restore_uid
09:48:56 debug3: getuid() - warning stubbed function
09:48:56 debug3: setuid() - warning stubbed function
09:48:56 debug3: getgid() - warning stubbed function
09:48:56 debug3: setgid() - warning stubbed function
09:48:56 debug3: setgroups() - warning stubbed function
09:48:56 debug1: Connection established.
09:48:56 debug3: setgid() - warning stubbed function
09:48:56 debug3: setuid() - warning stubbed function
09:48:56 debug1: identity file C:\Documents and Settings\gpaveza\My Documents\Reflection\.ssh\identity type -1
09:48:56 debug3: Not a RSA1 key file C:\Documents and Settings\gpaveza\My Documents\Reflection\.ssh\id_rsa.
09:48:56 debug2: key_type_from_name: unknown key type '-----BEGIN'
09:48:56 debug3: key_read: no key found
09:48:56 debug2: key_type_from_name: unknown key type 'Proc-Type:'
09:48:56 debug3: key_read: no key found
09:48:56 debug2: key_type_from_name: unknown key type 'DEK-Info:'
09:48:56 debug3: key_read: no key found
09:48:56 debug3: key_read: no space
09:48:56 debug3: key_read: no space
09:48:56 debug3: key_read: no space
09:48:56 debug3: key_read: no space
09:48:56 debug3: key_read: no space
09:48:56 debug3: key_read: no space
09:48:56 debug3: key_read: no space
09:48:56 debug3: key_read: no space
09:48:57 debug3: key_read: no space
09:48:57 debug3: key_read: no space
09:48:57 debug3: key_read: no space
09:48:57 debug3: key_read: no space
09:48:57 debug3: key_read: no space
09:48:57 debug2: key_type_from_name: unknown key type '-----END'
09:48:57 debug3: key_read: no key found
09:48:57 debug1: identity file C:\Documents and Settings\gpaveza\My Documents\Reflection\.ssh\id_rsa type 1
09:48:57 debug1: identity file C:\Documents and Settings\gpaveza\My Documents\Reflection\.ssh\id_dsa type -1
09:48:57 debug1: Remote protocol version 2.0, remote software version OpenSSH_3.1p1
09:48:57 debug1: match: OpenSSH_3.1p1 pat ^OpenSSH
Enabling compatibility mode for protocol 2.0
09:48:57 debug1: Local version string SSH-2.0-OpenSSH_3.0.2p1
09:48:57 debug3: fcntl() - warning stubbed function
09:48:57 debug1: SSH2_MSG_KEXINIT sent
09:48:57 debug1: SSH2_MSG_KEXINIT received
09:48:57 debug2: kex_parse_kexinit: diffie-hellman-group-exchange-sha1,diffie-hellman-group1-sha1
09:48:57 debug2: kex_parse_kexinit: ssh-rsa,ssh-dss
09:48:57 debug2: kex_parse_kexinit: aes128-cbc,3des-cbc,blowfish-cbc,cast128-cbc,arcfour,aes192-cbc,aes256-cbc,rijndael128-cbc,rijndael192-cbc,rijndael256-cbc,rijndael-cbc@lysator.liu.se
09:48:57 debug2: kex_parse_kexinit: aes128-cbc,3des-cbc,blowfish-cbc,cast128-cbc,arcfour,aes192-cbc,aes256-cbc,rijndael128-cbc,rijndael192-cbc,rijndael256-cbc,rijndael-cbc@lysator.liu.se
09:48:57 debug2: kex_parse_kexinit: hmac-md5,hmac-sha1,hmac-ripemd160,hmac-ripemd160@openssh.com,hmac-sha1-96,hmac-md5-96
09:48:57 debug2: kex_parse_kexinit: hmac-md5,hmac-sha1,hmac-ripemd160,hmac-ripemd160@openssh.com,hmac-sha1-96,hmac-md5-96
09:48:57 debug2: kex_parse_kexinit: none
09:48:57 debug2: kex_parse_kexinit: none
09:48:57 debug2: kex_parse_kexinit:
09:48:57 debug2: kex_parse_kexinit:
09:48:57 debug2: kex_parse_kexinit: first_kex_follows 0
09:48:57 debug2: kex_parse_kexinit: reserved 0
09:48:57 debug2: kex_parse_kexinit: diffie-hellman-group-exchange-sha1,diffie-hellman-group1-sha1
09:48:57 debug2: kex_parse_kexinit: ssh-rsa,ssh-dss
09:48:57 debug2: kex_parse_kexinit: aes128-cbc,3des-cbc,blowfish-cbc,cast128-cbc,arcfour,aes192-cbc,aes256-cbc
09:48:57 debug2: kex_parse_kexinit: aes128-cbc,3des-cbc,blowfish-cbc,cast128-cbc,arcfour,aes192-cbc,aes256-cbc
09:48:57 debug2: kex_parse_kexinit: hmac-md5,hmac-sha1,hmac-ripemd160,hmac-ripemd160@openssh.com,hmac-sha1-96,hmac-md5-96
09:48:57 debug2: kex_parse_kexinit: hmac-md5,hmac-sha1,hmac-ripemd160,hmac-ripemd160@openssh.com,hmac-sha1-96,hmac-md5-96
09:48:57 debug2: kex_parse_kexinit: none,zlib
09:48:57 debug2: kex_parse_kexinit: none,zlib
09:48:57 debug2: kex_parse_kexinit:
09:48:57 debug2: kex_parse_kexinit:
09:48:57 debug2: kex_parse_kexinit: first_kex_follows 0
09:48:57 debug2: kex_parse_kexinit: reserved 0
09:48:57 debug2: mac_init: found hmac-md5
09:48:57 debug1: kex: server->client aes128-cbc hmac-md5 none
09:48:57 debug2: mac_init: found hmac-md5
09:48:57 debug1: kex: client->server aes128-cbc hmac-md5 none
09:48:57 debug1: SSH2_MSG_KEX_DH_GEX_REQUEST sent
09:48:57 debug1: expecting SSH2_MSG_KEX_DH_GEX_GROUP
09:48:57 debug1: dh_gen_key: priv key bits set: 133/256
09:48:57 debug1: bits set: 1575/3191
09:48:57 debug1: SSH2_MSG_KEX_DH_GEX_INIT sent
09:48:57 debug1: expecting SSH2_MSG_KEX_DH_GEX_REPLY
09:48:57 debug3: check_host_in_hostfile: filename C:\Documents and Settings\gpaveza\My Documents\Reflection\.ssh\known_hosts
09:48:57 debug3: check_host_in_hostfile: match line 1
09:48:57 debug3: check_host_in_hostfile: filename C:\Documents and Settings\gpaveza\My Documents\Reflection\.ssh\known_hosts
09:48:57 debug3: check_host_in_hostfile: match line 1
09:48:57 debug1: Host 'kappa' is known and matches the RSA host key.
09:48:57 debug1: Found key in C:\Documents and Settings\gpaveza\My Documents\Reflection\.ssh\known_hosts:1
09:48:57 debug1: bits set: 1590/3191
09:48:57 debug1: ssh_rsa_verify: signature correct
09:48:57 debug1: kex_derive_keys
09:48:57 debug1: newkeys: mode 1
09:48:57 debug1: SSH2_MSG_NEWKEYS sent
09:48:57 debug1: waiting for SSH2_MSG_NEWKEYS
09:48:57 debug1: newkeys: mode 0
09:48:57 debug1: SSH2_MSG_NEWKEYS received
09:48:57 debug1: done: ssh_kex2.
09:48:57 debug1: send SSH2_MSG_SERVICE_REQUEST
09:48:57 debug1: service_accept: ssh-userauth
09:48:57 debug1: got SSH2_MSG_SERVICE_ACCEPT
09:48:57 debug1: authentications that can continue: external-keyx,gssapi,publickey,password,keyboard-interactive
09:48:57 debug3: start over, passed a different list external-keyx,gssapi,publickey,password,keyboard-interactive
09:48:57 debug3: preferred publickey,keyboard-interactive,password
09:48:57 debug3: authmethod_lookup publickey
09:48:57 debug3: remaining preferred: keyboard-interactive,password
09:48:57 debug3: authmethod_is_enabled publickey
09:48:57 debug1: next auth method to try is publickey
09:48:57 debug1: try privkey: C:\Documents and Settings\gpaveza\My Documents\Reflection\.ssh\identity
09:48:57 debug3: no such identity: C:\Documents and Settings\gpaveza\My Documents\Reflection\.ssh\identity
09:48:57 debug1: try pubkey: C:\Documents and Settings\gpaveza\My Documents\Reflection\.ssh\id_rsa
09:48:57 debug3: send_pubkey_test
09:48:57 debug2: we sent a publickey packet, wait for reply
09:48:57 debug1: input_userauth_pk_ok: pkalg ssh-rsa blen 149 lastkey 87f348 hint 1
09:48:57 debug2: input_userauth_pk_ok: fp 4e:30:6c:a0:68:9f:1c:39:97:ad:ba:12:e3:77:32:da
09:48:57 debug3: sign_and_send_pubkey
09:48:57 debug1: PEM_read_PrivateKey failed
09:48:57 debug1: read PEM private key done: type
09:49:02 debug1: read PEM private key done: type RSA
09:49:02 debug1: ssh-userauth2 successful: method publickey
09:49:02 debug3: ssh_session2(): sshdll.display = 127.0.0.1:0.0
09:49:02 debug3: fcntl() - warning stubbed function
09:49:02 debug1: fd 344 setting O_NONBLOCK
09:49:02 debug3: fcntl() - warning stubbed function
09:49:02 debug3: fcntl() - warning stubbed function
09:49:02 debug1: fd 352 setting O_NONBLOCK
09:49:02 debug3: fcntl() - warning stubbed function
09:49:02 debug3: fcntl() - warning stubbed function
09:49:02 debug1: fd 364 setting O_NONBLOCK
09:49:02 debug3: fcntl() - warning stubbed function
09:49:02 debug1: channel 0: new [client-session]
09:49:02 debug3: ssh_session2_open: channel_new: 0
09:49:03 debug1: send channel open 0
09:49:03 debug1: Entering interactive session.
09:49:03 debug2: callback start
09:49:03 debug1: ssh_session2_setup: id 0
09:49:04 debug1: Requesting X11 forwarding with authentication spoofing.
09:49:05 debug1: Sending command: (/usr/bin/X11/xterm -back black -fore white -fn 6x13 -sb -ls -name "xterm (kappa via ssh)" )
09:49:05 debug2: callback done
09:49:06 debug1: channel 0: open confirm rwindow 0 rmax 32768
09:49:07 debug2: channel 0: rcvd adjust 131072
09:49:08 debug2: channel 0: rcvd ext data 32
09:49:09 debug2: channel 0: rcvd ext data 38
09:49:09 debug2: channel 0: rcvd ext data 54
09:49:10 debug2: channel 0: rcvd ext data 211
09:49:11 debug2: channel 0: rcvd ext data 7
09:49:12 debug2: channel 0: rcvd ext data 66
09:49:13 debug1: channel 0: rcvd eof
09:49:13 debug1: channel 0: output open -> drain
09:49:14 debug1: client_input_channel_req: channel 0 rtype exit-status reply 0
09:49:15 debug1: channel 0: rcvd close
09:49:16 debug1: channel 0: input open -> closed
09:49:17 debug1: channel 0: close_read
channel 0: chan_shutdown_read: close() failed for fd-1: No such file or directory
09:49:18 debug3: channel 0: will not send data after close
09:49:19 debug1: channel 0: obuf empty
09:49:20 debug1: channel 0: output drain -> closed
09:49:21 debug1: channel 0: close_write
channel 0: chan_shutdown_write: close() failed for fd-1: No such file or directory
09:49:22 debug2: channel 0: active efd: 364 len 408 type write
09:49:23 debug2: channel 0: written 0 to efd 364
09:49:24 debug2: channel 0: closing write-efd 364
09:49:25 debug2: channel 0: active efd: -1 len 408 type write
James A. Donovan
Honored Contributor

Re: setting up ssh

It appears that you are being authenticated via your RSA2 key and allowed to login, but that login is almost immediately disconnected.

What does your sshd_config file look like?
From the client, can you run "ssh -vvv server" and post the results?

Also, you are using a pretty outdated version of sshd, you might want to think about upgrading.
Remember, wherever you go, there you are...
Robert Binkhorst
Trusted Contributor

Re: setting up ssh

Hi,

On the server, in your sshd_config file, what is the value of X11Forwarding? Your client is trying to start an Xterm, it should be set to Yes:
X11Forwarding yes

Robert

linux: the choice of a GNU generation
James A. Donovan
Honored Contributor

Re: setting up ssh

You are definitely getting logged in, but the connection is closing when after the xterm command is sent.


09:49:05 debug1: Sending command: (/usr/bin/X11/xterm -back black -fore white -fn 6x13 -sb -ls -name "xterm (kappa via ssh)" )
09:49:05 debug2: callback done
09:49:06 debug1: channel 0: open confirm rwindow 0 rmax 32768
09:49:07 debug2: channel 0: rcvd adjust 131072
09:49:08 debug2: channel 0: rcvd ext data 32
09:49:09 debug2: channel 0: rcvd ext data 38
09:49:09 debug2: channel 0: rcvd ext data 54
09:49:10 debug2: channel 0: rcvd ext data 211
09:49:11 debug2: channel 0: rcvd ext data 7
09:49:12 debug2: channel 0: rcvd ext data 66
09:49:13 debug1: channel 0: rcvd eof
09:49:13 debug1: channel 0: output open -> drain
09:49:14 debug1: client_input_channel_req: channel 0 rtype exit-status reply 0
09:49:15 debug1: channel 0: rcvd close
09:49:16 debug1: channel 0: input open -> closed
09:49:17 debug1: channel 0: close_read
channel 0: chan_shutdown_read: close() failed for fd-1: No such file or directory
09:49:18 debug3: channel 0: will not send data after close
09:49:19 debug1: channel 0: obuf empty
09:49:20 debug1: channel 0: output drain -> closed
09:49:21 debug1: channel 0: close_write
channel 0: chan_shutdown_write: close() failed for fd-1: No such file or directory


You may want to check the settings on your SSH client. Try downloading another client, like putty, to test your connection.

http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html
Remember, wherever you go, there you are...
Sridhar Bhaskarla
Honored Contributor

Re: setting up ssh

Hi,

How about any other command than "xterm"?. Try "ll /etc/passwd" and see if it works. If so, then it has to do with X11 forwarding.

-Sri
You may be disappointed if you fail, but you are doomed if you don't try
Gary L. Paveza, Jr.
Trusted Contributor

Re: setting up ssh

I've upgraded my version of ssh as recommended in a prior posting. And enabled X11 port forwarding. It appears to be getting farther, but still no window after login.

I'm using a Reflection client (not from a UX workstation, so I can't issue the ssh manually).

Geoff Wild
Honored Contributor
Solution

Re: setting up ssh

To hellp eliminate whether or not the issue is ssh or Reflections, download and install Putty:

http://www.chiark.greenend.org.uk/~sgtatham/putty/

PuTTY is a free implementation of Telnet and SSH for Win32 and Unix platforms, along with an xterm terminal emulator.

Then, from your Windows box, use Putty to ssh to your server....

If that works, then Reflections is the issue...

Rgds...Geoff
Proverbs 3:5,6 Trust in the Lord with all your heart and lean not on your own understanding; in all your ways acknowledge him, and he will make all your paths straight.
Bill Hassell
Honored Contributor

Re: setting up ssh

Rather than use Reflection/X, start the Reflection for Unix client (part of Reflection/X suite). Personally, I finf that using Xwindows for terminals is a total waste of network bandwidth. If you are going to run applications with lots of graphics like en engineering design program, Xwindows makes a lot of sense, but to run an xterm? You'll reduce your network bandwidth as much as 50:1 by using the straight telnet client and eliminate *all* the huge issues asociated with getting Xwindows working. And of course, you won't be loading down your remote server by running xterm processes on it.

To do this, just click on the Reflection for UNIX client in your WRQ folder, click on the Connection menu item and select OPENSSH for your connection. Then click on OK, then press Enter to get a prompt for the system or IP address of the system you want. Now you'll have mouse-scalable fonts (just drag the window bigger or smaller) and a wide range of immediate color customizations.

Another very nice feature is the ability to save an autologin. Just use the Macro recorder to capture a login (the password is not stored) and once saved as the Login macro, save the .r1w file under a new name and now, you can create a shorcut to the .r1w file and everything except the password will be automatic.


Bill Hassell, sysadmin
Robert Binkhorst
Trusted Contributor

Re: setting up ssh

Is there any way you can try to get an xterm on a screen somewhere without using reflection? That way you can establish if it is a reflection problem. Anyway, it may be time to use that support contract for Reflection that you pay a lot of money for.
linux: the choice of a GNU generation
Gary L. Paveza, Jr.
Trusted Contributor

Re: setting up ssh

I've downloaded putty and have it working. I've also used Reflection for Unix and managed to get it working. hpterm works fine. It's just xterm that I've having difficulty with. At this point, I'm happy. However, I know once I turn off telnet that some of the developers are going to want to use xterm and that I'll be fighting this one then.

Thanks for all the help.
Gary L. Paveza, Jr.
Trusted Contributor

Re: setting up ssh

Closing thread.