How can I backup my umbrel node?

Since all disks will fail at some point in the future, I wonder what is the recommended backup procedure for an umbrel node.

Would you recommend to commit and save the docker images to an external harddisk, or would you rather create a filesystem snapshot of the umbrel filesystem (provided there is some leftover storage in the volume group) and make a (i.e. borg) backup of the read-only mounted snapshot?

It would be nice not to interrupt the running umbrel node during backup, and to have an easy procedure to restore all the data (blockchain, lightning channels, and all other data) on a freshly setup umbrel node.

Hi @raphae1

We have an app solution for this in the works!
But for the moment my recommended solution is running

sudo ~/umbrel/scripts/stop && tar -cvzf umbrel_backup.tar.gz ~/umbrel/

after SSHing into your Umbrel
then exit

scp umbrel@umbrel.local:/home/umbrel/umbrel/umbrel_backup.tar.gz /local/path/

To export it to another device (/local/path/ will be different for you)

1 Like

Thanks a lot.
I am now doing

DATE=`date '+%Y%m%d%H%M%S'`

${MOUNTPOINT}/scripts/stop \
       &&  /bin/sync -f ${MOUNTPOINT}/  \
       &&  /sbin/lvcreate --size 10g --snapshot --name umbrelsnap /dev/ubuntu-vg/umbrel \
       && ${MOUNTPOINT}/scripts/start \
       &&  /bin/mount -r /dev/ubuntu-vg/umbrelsnap /media/umbrelsnap  \
       && echo umbrelsnap successfully mounted
/usr/bin/borg create -x --compression lz4 -s --exclude=/media/umbrelsnap/app-data/bitcoin/data/bitcoin/blocks \
                                             --exclude=/media/umbrelsnap/app-data/bitcoin/data/bitcoin/chainstate \
                                             --exclude=/media/umbrelsnap/app-data/bitcoin/data/bitcoin/indexes \
                                        ${BACKUP_ROOT}::auto_${DATE} /media/umbrelsnap

/bin/umount /media/umbrelsnap
/sbin/lvremove -f /dev/ubuntu-vg/umbrelsnap  && echo umbrelsnap removed

Which will only cause a very short downtime of umbrel (esp LND), because it only has to create a LVM snapshot and restarts immediately again. After the restart, I mount the snapshot and back it up (which takes less than minute without the blockchain, but could last a lot longer otherwise).