Dietpi not booting after upgrade - unable to use dietpi-backup

Having issues with your DietPi installation or found a bug? Post it here.
Post Reply
gaggio
Posts: 19
Joined: Sat Feb 13, 2016 4:04 pm

Dietpi not booting after upgrade - unable to use dietpi-backup

Post by gaggio »

Hi,
today I tried to update a working system from 6.28 to 6.35 (this version was proposed by dietpi-upgrade, even if I think it's not latest).
I executed the backup as proposed by the script, but the upgrade was not successful, terminating with a input/output error and resulting in a system unable to boot.
I therefore realised that the backup produced by dietpi-backup is not a full image that can be flashed on the SD card and restored.
Before I surrender and reconfigure a new system from scratch, is my understanding correct? There's no way to restore the backup if the system is not even booting?

Many thanks,
gaggio
User avatar
Joulinar
Posts: 4249
Joined: Sat Nov 16, 2019 12:49 am

Re: Dietpi not booting after upgrade - unable to use dietpi-backup

Post by Joulinar »

Hi,

the backup is not an image that can be flashed directly on an SD card. The backup is a file system copy. However it is possible to restore such a backup during initial boot. But your system 6.28 is quite old and it might cause trouble during restore as the current available images are newer compare to 6.28.

Where did you saved the backup on? Same SD card or an external USB stick?
Pls let us know if a solution is working. This could help others if they hit by similar situation. Your DietPi Team
gaggio
Posts: 19
Joined: Sat Feb 13, 2016 4:04 pm

Re: Dietpi not booting after upgrade - unable to use dietpi-backup

Post by gaggio »

Thanks for your reply, the backup is on an external USB hard drive.
User avatar
Joulinar
Posts: 4249
Joined: Sat Nov 16, 2019 12:49 am

Re: Dietpi not booting after upgrade - unable to use dietpi-backup

Post by Joulinar »

in theory you can try to restore the backup on a first inital run
  1. download latest image from dietpi.com
  2. flash image to a SD card, if possible use a spare card
  3. once done, reconnect the SD card to your computer
  4. open dietpi.txt
  5. add following line to the end of the file

    Code: Select all

    # Restore a DietPi-Backup on first boot: 0 => disable | 1 => interactive restore (show list of found backups) | 2 => non-interactive restore (restore first found backup)
    # - Simply attach the drive/disk/stick with contains the backup. All attached drives will be mounted temporarily and searched automatically.
    AUTO_SETUP_BACKUP_RESTORE=1
  6. connect USB disk + SD card to your device
  7. boot your device
  8. during Initial setup process, DietPi will scan all attached devices for the availability of a backup
  9. if a valid backup was found, you will be ask if you like to restore
There might be some error messages at the end. But usually after a reboot, your system should be back online (hopefully). As said, no guarantee as you system is quite old. Not sure how many package updates you have done in between.
Pls let us know if a solution is working. This could help others if they hit by similar situation. Your DietPi Team
Post Reply