Boot boot problems Debian / lunix

In case your debian-linux system does not boot properly or crashes during boot and you can boot in recovery mode, the steps below could be a quick solution to restore your system. This performs an update and also restores your system.

1: apt-get update
2: dpkg --configure -a
3: apt-get dist-upgrade
4: apt-get -f install
5: exit