Just upgraded to v6 and realized this no longer works:
pihole -a -t /tmp/pihole-backup.tar.gz
Is there a way to automate the backups in this version? Would like to run this from cron.
Just upgraded to v6 and realized this no longer works:
pihole -a -t /tmp/pihole-backup.tar.gz
Is there a way to automate the backups in this version? Would like to run this from cron.
This was replaced by pihole-FTL --teleporter.
Run pihole-FTL -h to see the new options help.
Thanks a lot for this information very useful!
I don't see anything about this change in the release (i search "backup" word, change option for pihole command, etc). I will check about this binary command that i didn't know yet.
I'm using ChronoSync on a Mac to automate the backups over an SSH connection to the pihole, so I've pointed ChronoSync at /tmp/backups on the pihole and created two scripts for pre- and post-sync:
pre-sync:
#!/usr/bin/env zsh
ssh pihole '(mkdir /tmp/backups 2> /dev/null || true) && cd /tmp/backups && sudo pihole-FTL --teleporter'
post_sync:
#!/usr/bin/env zsh
ssh pihole 'cd /tmp/backups && sudo rm pi-hole_pihole_teleporter_*.zip'
When Chronosync kicks off a pihole backup, it creates a folder to contain the backup, then generates it; after the backup has synced to my Mac, it removes the backup on the pihole.
Of course, this only works if the pi user is set up for passwordless sudo, which appears to be the default setup. (I assume there have already been discussions about the risks of that, so I won't kick them off here
)