Find the answer to your Linux question:
Page 1 of 2 1 2 LastLast
Results 1 to 10 of 13
So I've had this weird problem with SSH for months. After countless Google searches I've yet to find anybody with a similar problem. I am a CS major and I ...
  1. #1
    Just Joined!
    Join Date
    Dec 2008
    Posts
    8

    SSH Problem: Can connect through PuTTy (Win XP) but NOT Linux

    So I've had this weird problem with SSH for months. After countless Google searches I've yet to find anybody with a similar problem. I am a CS major and I need to be able to connect to my school account easily through Linux (ssh / sftp).

    Maybe one out of hundred tries it will successfully connect to the SSH servers I attempt (school or my personal website, so that proves at least that I'm not typing the wrong things in the terminal), but every other time it locks up after I type my password (correctly). I type the following to connect via the Linux terminal:

    ssh -v uname@schoolserver.edu

    Then I type in my password. It authenticates, and then locks up. Even the terminal locks up. Even ctrl-C/L doesn't work. I have to close the terminal.

    The weird thing is that I can reboot into Windows XP Pro SP3, launch PuTTy, insert my information, and connect instantly, every time.

    I've included a verbose log of me trying to connect.
    Code:
    josh@josh-desktop:~$ ssh -vv uname@schoolserver.edu
    OpenSSH_5.1p1 Debian-3ubuntu1, OpenSSL 0.9.8g 19 Oct 2007
    debug1: Reading configuration data /etc/ssh/ssh_config
    debug1: Applying options for *
    debug2: ssh_connect: needpriv 0
    debug1: Connecting to schoolserver.edu [152.30.5.5] port 22.
    debug1: Connection established.
    debug1: identity file /home/josh/.ssh/identity type -1
    debug1: identity file /home/josh/.ssh/id_rsa type -1
    debug1: identity file /home/josh/.ssh/id_dsa type -1
    debug1: Remote protocol version 2.0, remote software version OpenSSH_4.3p2 Debian-8ubuntu1.5
    debug1: match: OpenSSH_4.3p2 Debian-8ubuntu1.5 pat OpenSSH*
    debug1: Enabling compatibility mode for protocol 2.0
    debug1: Local version string SSH-2.0-OpenSSH_5.1p1 Debian-3ubuntu1
    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-cbc,3des-cbc,blowfish-cbc,cast128-cbc,arcfour128,arcfour256,arcfour,aes192-cbc,aes256-cbc,rijndael-cbc@lysator.liu.se,aes128-ctr,aes192-ctr,aes256-ctr
    debug2: kex_parse_kexinit: aes128-cbc,3des-cbc,blowfish-cbc,cast128-cbc,arcfour128,arcfour256,arcfour,aes192-cbc,aes256-cbc,rijndael-cbc@lysator.liu.se,aes128-ctr,aes192-ctr,aes256-ctr
    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-sha1,diffie-hellman-group14-sha1,diffie-hellman-group1-sha1
    debug2: kex_parse_kexinit: ssh-rsa,ssh-dss
    debug2: kex_parse_kexinit: aes128-cbc,3des-cbc,blowfish-cbc,cast128-cbc,arcfour128,arcfour256,arcfour,aes192-cbc,aes256-cbc,rijndael-cbc@lysator.liu.se,aes128-ctr,aes192-ctr,aes256-ctr
    debug2: kex_parse_kexinit: aes128-cbc,3des-cbc,blowfish-cbc,cast128-cbc,arcfour128,arcfour256,arcfour,aes192-cbc,aes256-cbc,rijndael-cbc@lysator.liu.se,aes128-ctr,aes192-ctr,aes256-ctr
    debug2: kex_parse_kexinit: hmac-md5,hmac-sha1,hmac-ripemd160,hmac-ripemd160@openssh.com,hmac-sha1-96,hmac-md5-96
    debug2: kex_parse_kexinit: hmac-md5,hmac-sha1,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-cbc hmac-md5 none
    debug2: mac_setup: found hmac-md5
    debug1: kex: client->server aes128-cbc 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: 127/256
    debug2: bits set: 507/1024
    debug1: SSH2_MSG_KEX_DH_GEX_INIT sent
    debug1: expecting SSH2_MSG_KEX_DH_GEX_REPLY
    debug1: Host 'schoolserver.edu' is known and matches the RSA host key.
    debug1: Found key in /home/josh/.ssh/known_hosts:1
    debug2: bits set: 495/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: /home/josh/.ssh/identity ((nil))
    debug2: key: /home/josh/.ssh/id_rsa ((nil))
    debug2: key: /home/josh/.ssh/id_dsa ((nil))
    debug1: Authentications that can continue: publickey,password
    debug1: Next authentication method: publickey
    debug1: Trying private key: /home/josh/.ssh/identity
    debug1: Trying private key: /home/josh/.ssh/id_rsa
    debug1: Trying private key: /home/josh/.ssh/id_dsa
    debug2: we did not send a packet, disable method
    debug1: Next authentication method: password
    uname@schoolserver.edu's password: 
    debug2: we sent a password packet, wait for reply
    debug1: Authentication succeeded (password).
    debug1: channel 0: new [client-session]
    debug2: channel 0: send open
    debug1: Requesting no-more-sessions@openssh.com
    debug1: Entering interactive session.
    debug2: callback start
    debug2: client_session2_setup: id 0
    debug2: channel 0: request pty-req confirm 1
    debug1: Sending environment.
    debug1: Sending env LANG = en_US.UTF-8
    debug2: channel 0: request env confirm 0
    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

  2. #2
    Linux User dxqcanada's Avatar
    Join Date
    Sep 2006
    Location
    Canada
    Posts
    259
    What happens if you run the connection from the consoles ?

    Have you tried PuTTY on Linux ?



    Men occasionally stumble over the truth,
    but most of them pick themselves up
    and hurry off as if nothing had happened.

    Winston Churchill


    ... then the Unix-Gods created "man" ...

  3. #3
    Just Joined!
    Join Date
    Dec 2008
    Posts
    8
    What do you mean from the consoles? I do most of my work through the terminal/command line. Is that what you mean?

    And no, I've thought about trying PuTTY on Linux, but I still want to diagnose why it my naitve SSH client isn't working. But I'll try it out now just to see if the issue lies with my distro (Ubuntu 8.10) as a whole or just the client.

  4. #4
    drl
    drl is offline
    Linux Engineer drl's Avatar
    Join Date
    Apr 2006
    Location
    Saint Paul, MN, USA / CentOS, Debian, Solaris, SuSE
    Posts
    1,117
    Hi.
    Quote Originally Posted by josh_ncsu View Post
    ... I still want to diagnose why it my naitve SSH client isn't working. But I'll try it out now just to see if the issue lies with my distro (Ubuntu 8.10) as a whole or just the client.
    I think dxqcanada is trying to determine the problem with a differential diagnosis. It helps to have as much information as possible (within reason), so knowing how PuTTY works from Linux may help narrow the real problem.

    It s said that many software practitioners find insight in:
    Code:
    Title: Medical Detectives, The
    Author: Berton Roueche
    Date: 1991
    Publisher: Plume
    ISBN: 0452265886
    Pages: 400
    Categories: debugging, hardware, software, solution, creativity
    Best wishes ... cheers, drl
    Welcome - get the most out of the forum by reading forum basics and guidelines: click here.
    90% of questions can be answered by using man pages, Quick Search, Advanced Search, Google search, Wikipedia.
    We look forward to helping you with the challenge of the other 10%.
    ( Mn, 2.6.n, AMD-64 3000+, ASUS A8V Deluxe, 1 GB, SATA + IDE, Matrox G400 AGP )

  5. #5
    Just Joined!
    Join Date
    Dec 2008
    Posts
    8
    Okay I tried PuTTY on Linux and it connected right away to the 2 SSH servers I tried. I then tried to connect via ssh through the terminal and it's still a no-go.

    PuTTy must have a setting enabled or something that is not enabled on my distro. Any idea where I can start to diagnose why?

    P.S. When I launch putty via the command like "putty &" I get the following:
    Gtk-WARNING **: Failed to load module "libgail.so": libgail.so: cannot open shared object file: No such file or directory

    Gtk-WARNING **: Failed to load module "libatk-bridge.so": libatk-bridge.so: cannot open shared object file: No such file or directory

    It still loads and runs, but that's annoying to me. Any idea why? I Google'd the errors last night and they aren't uncommon but I didn't find a fix.

  6. #6
    Linux User dxqcanada's Avatar
    Join Date
    Sep 2006
    Location
    Canada
    Posts
    259
    Quote Originally Posted by josh_ncsu View Post
    What do you mean from the consoles?
    I do not mean an XWindows terminal (xterm, konsole, gnome-terminal) ... I mean from the real console ... CTL+ALT+F1 (F2, F3 ...)

    It could be that the XWindows Terminal is the problem.



    Men occasionally stumble over the truth,
    but most of them pick themselves up
    and hurry off as if nothing had happened.

    Winston Churchill


    ... then the Unix-Gods created "man" ...

  7. #7
    Just Joined!
    Join Date
    Dec 2008
    Posts
    8
    Ah, I completely forgot about that. Anyway, I just did and the same thing happened. The console even froze up. I had to go to another console and killall ssh to unfreeze it.

  8. #8
    Linux User dxqcanada's Avatar
    Join Date
    Sep 2006
    Location
    Canada
    Posts
    259
    Hmm, odd.

    I use that version of OpenSSH ... and have not encountered such a problem.



    Men occasionally stumble over the truth,
    but most of them pick themselves up
    and hurry off as if nothing had happened.

    Winston Churchill


    ... then the Unix-Gods created "man" ...

  9. #9
    Linux User dxqcanada's Avatar
    Join Date
    Sep 2006
    Location
    Canada
    Posts
    259
    Here is an experiment ...

    Start an SSH server on your PC.
    Then start an SSH connection to itself.

    See if you encounter the problem.

    I am wondering if this bug is caused by connecting to an older OpenSSH daemon ?



    Men occasionally stumble over the truth,
    but most of them pick themselves up
    and hurry off as if nothing had happened.

    Winston Churchill


    ... then the Unix-Gods created "man" ...

  10. #10
    Just Joined!
    Join Date
    Dec 2008
    Posts
    8
    Okay, I set up my server and was able to ssh localhost and connect instantly. So I guess that isn't the problem.

Page 1 of 2 1 2 LastLast

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
...