SSH Has stopped working. Logs out Immediately,

Absolutely love Yunohost… I’ve been able to muddle through most issues and problem so far with a lot of reading, and I’ve learned a bunch… But this one got me stumped and looking for a little guidance.

The server happily runs in another room, headless. I’ve always done 99% of all installs/updates via the admin panel. SSH was installed before Yunohost – and actually, that’s how YH was installed unto the server. It has always worked flawlessly.

So – I’ve been using YH for a little over a month or so.

About 2 days ago I was considering adding an external HD for some storage – and went to check something via SSH. The server logs in, gives me a Debian title screen, says “No Mail.” and immediately closes the session. Tried several times, from various computers and IP addresses. Then I tried to log in via console. (Had to add a keyboard and a monitor.) Same deal. Logs in, gives me he YH title screen, and I am assuming gives me the same message and logs out – and clears the screen. Everything works great on the web – So I tried Shell In a Box, Installed … And am getting the same results.

The error via SSH:

"Debian GNU/Linux 9
password:
Linux {server name} 4.9.0-9-amd64 #1 SMP Debian 4.9.168-1+deb9u5 (2019-08-11) x86_64

The programs included with the Debian GNU/Linux system are free software;
the exact distribution terms for each program are described in the
individual files in /usr/share/doc/*/copyright.

Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent
permitted by applicable law.
No mail.
Last login: Mon Aug 26 17:56:42 2019 from 127.0.0.1"

Powered by YunoHost 3.6.4.6 (stable).

Tell me what logs to attach and I will. Just can’t figure this one out, and can’t get to the system to
to make any changes at the console level.

Advise?

Maybe that’s the clue – I didn’t log in from 127.0.0.1 – I logged in from 192.168.1.xxx

Can you explain if you’re logging in as root, admin, or as another user ?

  • root login should be entirely disabled except from the local network
  • admin login should be preferred if you want to do adminstration tasks (you can become root using sudo -i
  • logging in as another user is disabled by default with the behavior your describe, but can be enabled following this documentation https://yunohost.org/#/ssh

I’m logging in as my main (and only) admin account that I created when I created the server. Has always worked.

OK… Actually worked as root… And then "yunohost user ssh allow " added my main SU account again. Strange. It just started doing that. Maybe it took a while for Yunohost to update the SSH settings. Anyway – I’m back in. Thanks for the advice. Glad I had the problem – Now i’m connected to the user group and on matrix. It’s bad to have problems – but great to learn how to fix them! Thanks again!

1 Like

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.