Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

This is what happens:

ssh pureluck@10.1.1.231
password: something
Connection closed

Any idea why this happens?

Update:

Here's what happens when I do ssh -vvv

name@server% ssh -vvv admin@10.1.1.231
OpenSSH_5.5p1, OpenSSL 0.9.8l 5 Nov 2009
debug1: Reading configuration data /opt/ssh/etc/ssh_config
debug1: /opt/ssh/etc/ssh_config line 27: Deprecated option "RhostsAuthentication"
debug2: ssh_connect: needpriv 0
debug1: Connecting to 10.1.1.231 [10.1.1.231] port 22.
debug1: Connection established.
debug1: could not open key file '/opt/ssh/etc/ssh_host_key': Permission denied
debug1: could not open key file '/opt/ssh/etc/ssh_host_dsa_key': Permission denied
debug1: could not open key file '/opt/ssh/etc/ssh_host_rsa_key': Permission denied
debug1: identity file /home/name/.ssh/identity type -1
debug1: identity file /home/name/.ssh/identity-cert type -1
debug1: identity file /home/name/.ssh/id_rsa type -1
debug1: identity file /home/name/.ssh/id_rsa-cert type -1
debug1: identity file /home/name/.ssh/id_dsa type -1
debug1: identity file /home/name/.ssh/id_dsa-cert type -1
debug1: Remote protocol version 2.0, remote software version dropbear_0.52
debug1: no match: dropbear_0.52
debug1: Enabling compatibility mode for protocol 2.0
debug1: Local version string SSH-2.0-OpenSSH_5.5
debug2: fd 5 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-cert-v00@openssh.com,ssh-dss-cert-v00@openssh.com,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-group1-sha1
debug2: kex_parse_kexinit: ssh-rsa
debug2: kex_parse_kexinit: aes128-ctr,3des-ctr,aes256-ctr,aes128-cbc,3des-cbc,aes256-cbc,twofish256-cbc,twofish-cbc,twofish128-cbc,blowfish-cbc
debug2: kex_parse_kexinit: aes128-ctr,3des-ctr,aes256-ctr,aes128-cbc,3des-cbc,aes256-cbc,twofish256-cbc,twofish-cbc,twofish128-cbc,blowfish-cbc
debug2: kex_parse_kexinit: hmac-sha1-96,hmac-sha1,hmac-md5
debug2: kex_parse_kexinit: hmac-sha1-96,hmac-sha1,hmac-md5
debug2: kex_parse_kexinit: none
debug2: kex_parse_kexinit: none
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
debug2: dh_gen_key: priv key bits set: 125/256
debug2: bits set: 529/1024
debug1: sending SSH2_MSG_KEXDH_INIT
debug1: expecting SSH2_MSG_KEXDH_REPLY
debug3: check_host_in_hostfile: host 10.1.1.231 filename /home/name/.ssh/known_hosts2
debug3: check_host_in_hostfile: host 10.1.1.231 filename /home/name/.ssh/known_hosts2
debug3: check_host_in_hostfile: host 10.1.1.231 filename /opt/ssh/etc/ssh_known_hosts2
debug3: check_host_in_hostfile: host 10.1.1.231 filename /opt/ssh/etc/ssh_known_hosts2
debug3: check_host_in_hostfile: host 10.1.1.231 filename /home/name/.ssh/known_hosts
debug3: check_host_in_hostfile: host 10.1.1.231 filename /home/name/.ssh/known_hosts
debug3: check_host_in_hostfile: match line 18
debug1: Host '10.1.1.231' is known and matches the RSA host key.
debug1: Found key in /home/name/.ssh/known_hosts:18
debug2: bits set: 507/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: Roaming not allowed by server
debug1: SSH2_MSG_SERVICE_REQUEST sent
debug2: service_accept: ssh-userauth
debug1: SSH2_MSG_SERVICE_ACCEPT received
debug2: key: /home/name/.ssh/identity (0)
debug2: key: /home/name/.ssh/id_rsa (0)
debug2: key: /home/name/.ssh/id_dsa (0)
debug1: Authentications that can continue: publickey,password
debug3: start over, passed a different list publickey,password
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: /home/name/.ssh/identity
debug3: no such identity: /home/name/.ssh/identity
debug1: Trying private key: /home/name/.ssh/id_rsa
debug3: no such identity: /home/name/.ssh/id_rsa
debug1: Trying private key: /home/name/.ssh/id_dsa
debug3: no such identity: /home/name/.ssh/id_dsa
debug2: we did not send a packet, disable method
debug3: authmethod_lookup password
debug3: remaining preferred: ,password
debug3: authmethod_is_enabled password
debug1: Next authentication method: password
admin@10.1.1.231's password: 
debug3: packet_send2: adding 64 (len 58 padlen 6 extra_pad 64)
debug2: we sent a password packet, wait for reply
Connection closed by 10.1.1.231
share|improve this question
add comment

3 Answers

Run ssh -vvv during your connection for extended logging of what is going on. My instinct that you have something like /bin/true for a shell so it drops you out by default.

share|improve this answer
    
I did that, and the same thing happens. The connection closes after I input the password –  purepureluck Mar 2 '12 at 0:19
    
@purepureluck The -vvv is for debugging... it is not expected to change the outcome. Try ssh [user@host, etc...] /bin/bash to get yourself a terminal and see if forcing the shell doesn't help. If not, look at Chris' suggestion about full filesystems and the like. –  Jeff Ferland Mar 2 '12 at 6:52
add comment

Your shell can't start for some reason. Most likely culprits are full file systems (like /var/log) or something wrong with the actual shell's executable (or it's configuration file).

If you have some sort of IPMI can you pull up the console and see if there's any relevant data? Situations like this are the selling point for out of band management systems like iLO/DRAC/ILOM.

share|improve this answer
add comment

A permission issue would be my first guess...

debug1: Connection established. debug1: could not open key file '/opt/ssh/etc/ssh_host_key': Permission denied debug1: could not open key file '/opt/ssh/etc/ssh_host_dsa_key': Permission denied debug1: could not open key file '/opt/ssh/etc/ssh_host_rsa_key': Permission denied

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.