SD card backup via DD to file in Linux Mint cannot be properly restored

  • Hello.


    My offline backup method for OMV is done by shutting down the RPi, removing the SD card, doing a full DD (all partitions) to an image file (in a Linux Mint installation).


    When trying to restore, by doing DD again from the image file to a new SD card, I can never get the system to boot properly, it complains of an issue in one of the partitions.


    If I do the same exact DD command but directly from an SD card to a new SD card (same size, brand, etc), I can properly boot from the new SD card.


    Any reason why the dd to image and image to new SD card would not work?


    Thanks in advance for any help.

  • You're right, sorry about that.


    Initial backup from SD card to file done with command:
    sudo dd if=/dev/mmcblk0 of=path_and_image_filename.img


    Restore from initial backup to new SD card (same size/brand/etc):
    sudo dd if=path_and_image_filename.img of=/dev/mmcblk0


    No errors occur during the execution of any of the above commands and I always unmount the SD cards before removing it from the card reader.


    This is how far the boot process goes when booting RPi2 from new SD card (restored from image, as per above command):

    • Offizieller Beitrag

    Was the sd card mounted when you performed either or both dd commands? Linux mint typically automounts the cards and that could cause issues especially when writing the card. You don't want to eject the card just unmount all of the partitions before the dd command.
    umount /dev/mmcblk0p1
    umount /dev/mmcblk0p2
    When done reading/writing, you shouldn't have to unmount the cards.


    I would add block size to make it faster:


    dd if=/dev/mmcblk0 of=path_name.dd bs=1M
    dd if=pat_name.dd of=/dev/mmcblk0 bs=1M

    omv 7.0-32 sandworm | 64 bit | 6.5 proxmox kernel

    plugins :: omvextrasorg 7.0 | kvm 7.0.9 | compose 7.0.9 | cputemp 7.0 | mergerfs 7.0.3


    omv-extras.org plugins source code and issue tracker - github


    Please try ctrl-shift-R and read this before posting a question.

    Please put your OMV system details in your signature.
    Please don't PM for support... Too many PMs!

Jetzt mitmachen!

Sie haben noch kein Benutzerkonto auf unserer Seite? Registrieren Sie sich kostenlos und nehmen Sie an unserer Community teil!