mirror of
https://git.proxmox.com/git/mirror_zfs.git
synced 2026-05-25 11:47:43 +03:00
zfs should optionally send holds
Add -h switch to zfs send command to send dataset holds. If holds are present in the stream, zfs receive will create them on the target dataset, unless the zfs receive -h option is used to skip receive of holds. Reviewed-by: Alek Pinchuk <apinchuk@datto.com> Reviewed-by: loli10K <ezomori.nozomu@gmail.com> Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Reviewed by: Paul Dagnelie <pcd@delphix.com> Signed-off-by: Paul Zuchowski <pzuchowski@datto.com> Closes #7513
This commit is contained in:
committed by
Brian Behlendorf
parent
e73ab1b38c
commit
9c5e88b1de
@@ -645,6 +645,9 @@ typedef struct sendflags {
|
||||
|
||||
/* only send received properties (ie. -b) */
|
||||
boolean_t backup;
|
||||
|
||||
/* include snapshot holds in send stream */
|
||||
boolean_t holds;
|
||||
} sendflags_t;
|
||||
|
||||
typedef boolean_t (snapfilter_cb_t)(zfs_handle_t *, void *);
|
||||
@@ -707,6 +710,12 @@ typedef struct recvflags {
|
||||
|
||||
/* do not mount file systems as they are extracted (private) */
|
||||
boolean_t nomount;
|
||||
|
||||
/* Was holds flag set in the compound header? */
|
||||
boolean_t holds;
|
||||
|
||||
/* skip receive of snapshot holds */
|
||||
boolean_t skipholds;
|
||||
} recvflags_t;
|
||||
|
||||
extern int zfs_receive(libzfs_handle_t *, const char *, nvlist_t *,
|
||||
|
||||
Reference in New Issue
Block a user