[pve-devel] Fix #2124: Add support for zstd

Alwin Antreich a.antreich at proxmox.com
Fri Jun 14 15:37:29 CEST 2019


This patch series adds in general the possibility to use a de-compressor for
compression formats that are not supported natively by the extracting command
(eg. tar).

The extension of the code in this series is focused mainly on the addition of
the zstandard compression algorithm.

Thanks for any comment or suggestion in advance.


Some more thoughts/ideas on the whole backup/restore code:
  * merge compression & format detection to one common place (eg. pve-storage)
  * extend the extract_from_archive and use it as a general extraction method
    (eg. for tar_archive_read_firstfile; QemuServer.pm)
  * maybe unify extraction via sysopen (see LXC/Create.pm)
    or archive path to compressor (see Storage.pm) (which would be better?)

What's your take on these ideas?

Alwin Antreich (6):
  Fix #2124: Add support for zstd
  Remove dup code from extract_vzdump_config_vma
  decompress: use hash instead of if statement

 PVE/Storage.pm        | 169 ++++++++++++++++++++++++++++++--------------------
 PVE/Storage/Plugin.pm |   2 +-
 2 files changed, 103 insertions(+), 68 deletions(-)

  Fix #2124: restore: support external de-compressor

   src/PVE/LXC/Create.pm | 31 +++++++++++++++++++++----------
    1 file changed, 21 insertions(+), 10 deletions(-)

  Fix #2124: Add support for zstd

   PVE/VZDump.pm                            | 8 +++++---
    www/manager6/form/CompressionSelector.js | 3 ++-
     2 files changed, 7 insertions(+), 4 deletions(-)

  Fix #2124: restore: add zstd de-compression

   PVE/QemuServer.pm | 8 ++++++++
    1 file changed, 8 insertions(+)

-- 
2.11.0





More information about the pve-devel mailing list