mirror of
https://github.com/psy0rz/zfs_autobackup.git
synced 2025-06-09 01:52:07 +03:00
Short options for send so as to support older zfs versions
This commit is contained in:
parent
60840a4213
commit
8b600c9e9c
@ -575,13 +575,14 @@ class ZfsDataset:
|
|||||||
|
|
||||||
# all kind of performance options:
|
# all kind of performance options:
|
||||||
if 'large_blocks' in features and "-L" in self.zfs_node.supported_send_options:
|
if 'large_blocks' in features and "-L" in self.zfs_node.supported_send_options:
|
||||||
cmd.append("--large-block") # large block support (only if recordsize>128k which is seldomly used)
|
# large block support (only if recordsize>128k which is seldomly used)
|
||||||
|
cmd.append("-L") # --large-block
|
||||||
|
|
||||||
if write_embedded and 'embedded_data' in features and "-e" in self.zfs_node.supported_send_options:
|
if write_embedded and 'embedded_data' in features and "-e" in self.zfs_node.supported_send_options:
|
||||||
cmd.append("--embed") # WRITE_EMBEDDED, more compact stream
|
cmd.append("-e") # --embed; WRITE_EMBEDDED, more compact stream
|
||||||
|
|
||||||
if zfs_compressed and "-c" in self.zfs_node.supported_send_options:
|
if zfs_compressed and "-c" in self.zfs_node.supported_send_options:
|
||||||
cmd.append("--compressed") # use compressed WRITE records
|
cmd.append("-c") # --compressed; use compressed WRITE records
|
||||||
|
|
||||||
# raw? (send over encrypted data in its original encrypted form without decrypting)
|
# raw? (send over encrypted data in its original encrypted form without decrypting)
|
||||||
if raw:
|
if raw:
|
||||||
@ -589,8 +590,8 @@ class ZfsDataset:
|
|||||||
|
|
||||||
# progress output
|
# progress output
|
||||||
if show_progress:
|
if show_progress:
|
||||||
cmd.append("--verbose")
|
cmd.append("-v") # --verbose
|
||||||
cmd.append("--parsable")
|
cmd.append("-P") # --parsable
|
||||||
|
|
||||||
# resume a previous send? (don't need more parameters in that case)
|
# resume a previous send? (don't need more parameters in that case)
|
||||||
if resume_token:
|
if resume_token:
|
||||||
@ -599,7 +600,7 @@ class ZfsDataset:
|
|||||||
else:
|
else:
|
||||||
# send properties
|
# send properties
|
||||||
if send_properties:
|
if send_properties:
|
||||||
cmd.append("--props")
|
cmd.append("-p") # --props
|
||||||
|
|
||||||
# incremental?
|
# incremental?
|
||||||
if prev_snapshot:
|
if prev_snapshot:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user