Hi selfhosting community! At the moment I have my services set up with nix. They store their data on a btrfs subvolume which I can easily snapshot.

For backup I configured btrbk to send the snapshots to a target pc. However I feel uneasy not knowing if the backups succeeded or not. Right now I would need to check manually on the target machine every so often.

How are you guys handling this problem? Custom scripts for btrfs send/receive? Is there a function in btrbk I overlooked where I can verify the state and get notified of problems?

I was looking into ntfy-sh, which looks optimal, but how can I know if the send/receive was successful?

  • TehNomad@piefed.social
    link
    fedilink
    English
    arrow-up
    5
    ·
    14 days ago

    I use the “||” operator in bash scripts to send a curl command to ntfy if the backup fails. But the healthchecks option is a little bit more robust since you wouldn’t get a notification if your system crashed and ntfy dies too. I believe you can also do this with Uptime Kuma if you want to go self-hosted on a remote server.

    • skilltheamps@feddit.org
      link
      fedilink
      English
      arrow-up
      1
      ·
      13 days ago

      btrbk ... && curl https://uptime.my.domain/api/push/... is exactly what I do in a systemd service with nightly timer. Uptime Kuma sends a matrix message (via a bot account on matrix.org) if it doesn’t get a success notification in 25h. I have two servers in different locations that do mutual backups and mutual uptime kuma monitoring. Should both servers go down at the same time, there’s also some basic and free healthcheck from my dynamic-ipv6 provider https://ipv64.net/, so I also get an email if any of the two uptime kumas cannot be reached anymore.