Jump to content

strange prob regarding ssh


gbi

Recommended Posts

Hi All,

 

I have a strange prob regarding Armbian on my Banana Pi.

 

I have installed vanilla Jessie on my BaPi (1st modell with an SD, not uSD). I have also installed tvheadend, lighttpd and the kernel-nfs-server (beyond the packages already in the image). The BaPi is connected to a switch (no WiFi), and it is headless. When it starts all works as expected. But after some hours logging in via SSH stops working. The sshd itself runs, if I try to login (with pubkey auth) I can see that the connection to the sshd is successfully established, but when the shell should be started it hangs forever:

debug1: kex: server->client aes128-ctr hmac-sha2-256 none
debug1: kex: client->server aes128-ctr hmac-sha2-256 none
debug1: sending SSH2_MSG_KEX_ECDH_INIT
debug1: expecting SSH2_MSG_KEX_ECDH_REPLY
debug1: Server host key: RSA aa:bb:cc:dd:ee:ff:ee:dd:cc:bb:aa:bb:cc:dd:ee:ff
debug1: Host '192.168.x.y' is known and matches the RSA host key.
debug1: Found key in /home/gbi/.ssh/known_hosts:zz
debug1: ssh_rsa_verify: signature correct debug1: SSH2_MSG_NEWKEYS sent
debug1: expecting SSH2_MSG_NEWKEYS debug1: SSH2_MSG_NEWKEYS received
debug1: SSH2_MSG_SERVICE_REQUEST sent debug1: SSH2_MSG_SERVICE_ACCEPT received 
debug1: Authentications that can continue: publickey,password
debug1: Next authentication method: publickey
debug1: Offering RSA public key: /home/gbi/.ssh/id_rsa
debug1: Server accepts key: pkalg ssh-rsa blen 279
debug1: read PEM private key done: type RSA
debug1: Authentication succeeded (publickey). Authenticated to 192.168.x.y ([192.168.x.y]:22).
debug1: channel 0: new [client-session]
debug1: Requesting no-more-sessions@openssh.com
debug1: Entering interactive session.

After the last line it hangs forever (done on the client with ssh -v). Normally this should continue like

debug1: Sending environment.
debug1: Sending env LANG = en_US.UTF-8

 ____                               
| __ )  __ _ _ __   __ _ _ __   __ _
|  _ \ / _` | '_ \ / _` | '_ \ / _` |
| |_) | (_| | | | | (_| | | | | (_| |
|____/ \__,_|_| |_|\__,_|_| |_|\__,_|

...

 

My first idea what could cause this was that the root-FS "has been lost" in kind of a way, but I can see the filesystem thru NFS and thru Lighty (with dir indexing). Also tvheadend works as expected. Using another SD card has not helped, also changing the powersupply does not help. Also reinstalling the openssh-server package has not helped. I had Bananian on the same BaPi before (same SD), havn't had this strange prob. Have also found nothing in /var/log. Only thing I can do is to do a hard power off/on, and the game begins again for a few hours.

 

Who has an idea ?

 

Thanks in advance

Link to comment
Share on other sites

You had bananian with legacy or vanilla kernel? Strange ...  I would go first with kernel upgrade, but if you need today, you will need to build it yourself. Our upgrade should happen once this month.

Link to comment
Share on other sites

Hi,

yesterday I saw the recommendations for SD cards, so I thought to try a Samsung which is in my portfolio. No luck :-(. The kernel on my BaPi is exactly the one which is in the vanilla Jessie image, have not touched it in any way. It looks like sshd is unable to spawn or exec the loginshell.

As soon as you update the kernel I'll try it. A real bizarre prob

Link to comment
Share on other sites

Hi all and especially Igor,

 

meanwhile I have deinstalled openssh-server and installed dropbear. And guess what, dropbear seems to work as expected.

debug1: Authentication succeeded (password).
Authenticated to 192.168.x.y ([192.168.x.y]:22).
debug1: channel 0: new [client-session]
debug1: Entering interactive session.
debug1: Sending environment.
debug1: Sending env LANG = en_US

But the nice, colored Armbian splashscreen is now missing. What must be done to get it also with Dropbear ?

 

Thanks in advance

 

Link to comment
Share on other sites

Hi,

 

seems I'm talking to myself :).

 

Another workaround for this prob I found in another thread, is setting "UsePAM no" in /etc/ssh/sshd_config

 

Logging in is also significantly faster with this setting. Looks there is something broken in PAM, not in SSHD

 

Good hunting

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

Terms of Use - Privacy Policy - Guidelines