Is it safe to suspend (to RAM or HDD) a Debian 8, upgrading to 9?

Update: I ended doing it anyway (suspend to RAM). I did it when it after all downloads as it was unpacking. Otherwise I would have to leave my laptop at the office. I suppose thing could have turned ugly if I had done it during some config operation.

  • Do not push your luck. – Rui F Ribeiro Jun 22 '17 at 18:39
  • No, it is not safe, in any understanding of safe. – Isaac Jun 23 '17 at 1:48

Dist-upgrades are fairly unstable as they are and often fail anyways.

The only time I suspended a dist-upgrade years ago, I borked the system completely and had to reinstall. Things might be better now, but I doubt it.

On the other hand, dist-upgrades often take more than a clean re-install, both for the huge downloads and the troubleshooting afterwards

| improve this answer | |
  • I have made hundreds of dist upgrades, and the only reason I am on Debian nowadays is because they work so well. Otherwise I would be on *BSD. – Rui F Ribeiro Jun 22 '17 at 18:38
  • That is not my experience with dist-upgrades, but well, I got tired of all the troubles and passed to a rolling release distro half a decade ago: my data might be outdated – Bruno9779 Jun 22 '17 at 20:46

Suspend to ram should be safer than suspend to HDD. Mostly because if a newer kernel is installed, only the old kernel will accept the hibernation image.

I think powerfail during a correctly-executed upgrade is expected to be recoverable. I don't know exactly what level of resources you need to guarantee that. Basically, you want to be able to boot, log in, and re-run the same apt command e.g. apt-get dist-upgrade.

(This is not true of rpm. rpm is expected to not handle powerfail gracefully; it requires manual intervention).

I think as Bruno9779 points out, the main reason not to rely on this is that you should be expecting something to break anyway, unless you've already upgraded a sufficiently similar system. If you're not already experienced in recovering from the powerfail, you could be dealing with two new problems at the same time. Stressful, and with the possibility that they compound each other.

The upgrade is not 100% guaranteed safe, unless you're already prepared to give up and do a fresh install. As the ever-helpful upgrade instructions say

Although Debian tries to ensure that your system stays bootable at all times, there is always a chance that you may experience problems rebooting your system after the upgrade. Known potential issues are documented in this and the next chapters of these Release Notes.

For this reason it makes sense to ensure that you will be able to recover if your system should fail to reboot or, for remotely managed systems, fail to bring up networking.

and the documentation for the recovery system it points to conclude

Repairing broken systems can be difficult, and this manual does not attempt to go into all the things that might have gone wrong or how to fix them. If you have problems, consult an expert.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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