Losing ssh connection during apt upgrade

Bo Berglund bo.berglund at gmail.com
Sun Jan 31 17:16:24 UTC 2021


On Sun, 31 Jan 2021 17:08:38 +0100, Bo Berglund <bo.berglund at gmail.com> wrote:

>>On Sat, 30 Jan 2021 at 23:28, Bo Berglund <bo.berglund at gmail.com> wrote:
>>> ...
>>> So now I always make sure that the console screensaver is *disabled permanently*
>>> on my headless server ubuntu boxes.
>>
>>Are you saying that the screensaver blanked an ssh terminal?  That
>>seems unlikely to me, if not actually impossible.
>>
>>Perhaps you were updating using a directly connected display, not via ssh.
>>
>
>Yes, you might be correct here!
>It was a couple of years ago so I don't remember exactly. It could have been a
>monitor and keyboard directly connected in this case.

Since I saw several comments here on my screensaver issue I now went back and
found some notes I wrote at the time.
Turns out I had connected the physical keyboard/monitor because I was afraid
that the ssh connection would fail during the upgrade.
This was based on a warning message about ssh when first starting the
dist-upgrade via ssh.

Here goes what I wrote at the time:
----------------------------------------------------------------------
I did this:
- Connected monitor and USB keyboard to physical system.
- Booted up and logged on via kbd/monitor <== Notice method I chose since
PuTTU/SSH might fail...
- Started the do-release-upgrade process
- Answered a few questions and then it began its work
- After a while (10 minutes?) the screen went blank <== Physical monitor
- Nothing more seemed to happen so:
- Connected via PuTTY and found the login working!
- Message said Ubuntu 18.04.2 LTS and restart required
- So executed sudo reboot
- Now the system crashes with a PANIC message: ...not syncing: VFS: unable to
mount root fs on unknown-block(0.0)
- At this point it is possible to reboot and use the GRUB menu Advanced function
and then select the previous kernel
- Now the boot continues until done and a logon prompt is shown. My credentials
work.
- On the prompt it looks like all user files are intact on the disk including
the OpenVPN, Subversion and Apache files
- Subversion is in /var/lib/svn/
- OpenVPN is located in /etc/openvpn/
- Apache is in /var/www/html/

In the end I figured out that the cause of the blank screen with no feedback is
that some kind of "screen saver" had kicked in!
In actual fact the upgrade was still running, but invisible!

I still don't know if the blackout happened in Ubuntu or in the upgrader itself,
but it is pretty scary.

Anyway I re-ran the upgrade from an ssh prompt (using PuTTY) and with the
firewall disabled, which made it complete (took a very long time).
----------------------------------------------------------------------

So this confirms the suspicion by Colin Law that I referred to a *physical
monitor* screensaver....


-- 
Bo Berglund
Developer in Sweden





More information about the ubuntu-users mailing list