From: Axel Burri <axel@tty0.ch>
To: linux-btrfs@vger.kernel.org
Subject: btrfs receive error recovery
Date: Sat, 09 May 2015 13:52:08 +0200 [thread overview]
Message-ID: <554DF4E8.2010601@tty0.ch> (raw)
Hi btrfs team
I'm the developer of "btrbk" [1], which uses btrfs send/receive to
create backups. In case of errors, "btrfs receive" leaves the partially
received subvolume behind, causing some trouble for subsequent
incremental backups. As I can see in the wiki, "Delete partially
received subvolumes on error" is on the TODO list. Until then, what
would be the best way to check if the received subvolume needs to be
deleted?
As "btrfs receive" does always return an exit value of "1" on errors, I
cannot rely on this (e.g. if a file with the received name already
exists, I also get an exit code=1, but then I do NOT want to delete
anything).
Also, "btrfs subvolume show <partially-received-subvol>" does not
complain either.
Do you have any hints on how I can check for this? (and no, parsing
stderr messages is not an option)
Thanks in advance,
- Axel
[1] https://www.digint.ch/btrbk/
https://github.com/digint/btrbk
next reply other threads:[~2015-05-09 11:58 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-05-09 11:52 Axel Burri [this message]
2015-05-10 3:11 ` btrfs receive error recovery Duncan
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=554DF4E8.2010601@tty0.ch \
--to=axel@tty0.ch \
--cc=linux-btrfs@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.