Skip to content

Loading…

Support for pbzip2 #85

Merged
merged 1 commit into from

2 participants

@justino

Adds support for using pbzip2 (http://compression.ca/pbzip2/)
pbzip2 has roughly the same commandline interface as bzip2 and pigz, and works perfectly out of the box.

pbzip2 is not usually installed by default and might need to be installed prior to usage.

I'm aware that the new development version of Holland has support for the pbzip2 as an alias to bzip2. I figured this would tide over until v1.1 is released.

@justino justino New Compression Mechanism: pbzip2
Adds support for using pbzip2 (http://compression.ca/pbzip2/)
pbzip2 has roughly the same commandline interface as bzip2 and pigz, and works perfectly out of the box.

pbzip2 is not usually installed by default and might need to be installed prior to usage.
bb7e58a
@justino

I think the only thing left to modify is the docs: https://github.com/holland-backup/holland-backup.github.com/blob/master/provider_configs/compression.html
If you accept this patch, I'll also patch up the aforementioned file.

@abg abg merged commit 88fb0b6 into holland-backup:master
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Jul 9, 2012
  1. @justino

    New Compression Mechanism: pbzip2

    justino committed
    Adds support for using pbzip2 (http://compression.ca/pbzip2/)
    pbzip2 has roughly the same commandline interface as bzip2 and pigz, and works perfectly out of the box.
    
    pbzip2 is not usually installed by default and might need to be installed prior to usage.
View
4 config/backupsets/examples/mysql-lvm.conf
@@ -52,9 +52,9 @@ estimated-size-factor = 1.0
## Compression Settings
[compression]
-## compress method: gzip, bzip2, lzop, or xz
+## compress method: gzip, bzip2, pbzip2, lzop, or xz
## Which compression method to use, which can be either gzip, bzip2, or lzop.
-## Note that lzop is not often installed by default on many Linux
+## Note that pbzip2 and lzop are not often installed by default on many Linux
## distributions and may need to be installed separately.
method = gzip
View
4 config/backupsets/examples/mysqldump.conf
@@ -92,9 +92,9 @@ additional-options = ""
## Compression Settings
[compression]
-## compress method: gzip, bzip2, lzop, or xz
+## compress method: gzip, bzip2, pbzip2, lzop, or xz
## Which compression method to use, which can be either gzip, bzip2, or lzop.
-## Note that lzop is not often installed by default on many Linux
+## Note that pbzip2 and lzop are not often installed by default on many Linux
## distributions and may need to be installed separately.
method = gzip
View
2 config/providers/mysqldump.conf
@@ -83,7 +83,7 @@ additional-options = ""
## Compression Settings
[compression]
-## compress method: gzip, bzip2 or lzop
+## compress method: gzip, bzip2, pbzip2, or lzop
## Which compression method to use, which can be either gzip, bzip2, or lzop.
## Note that lzop is not often installed by default on many Linux
## distributions and may need to be installed separately.
View
2 config/providers/sqlite.conf
@@ -12,7 +12,7 @@ binary = /usr/bin/sqlite3
## Compression Settings
[compression]
-## Compress method: gzip, bzip2 or lzop
+## Compress method: gzip, bzip2, pbzip2, or lzop
## Which compression method to use, which can be either gzip, bzip2, or lzop.
## Note that lzop is not often installed by default on many Linux
## distributions and may need to be installed separately.
View
2 plugins/holland.backup.mysql_lvm/holland/backup/mysql_lvm/plugin/raw/plugin.py
@@ -49,7 +49,7 @@
pre-args = string(default=None)
[compression]
-method = option('none', 'gzip', 'pigz', 'bzip2', 'lzop', default='gzip')
+method = option('none', 'gzip', 'pigz', 'bzip2', 'pbzip2', 'lzop', default='gzip')
level = integer(min=0, max=9, default=1)
[mysql:client]
View
2 plugins/holland.backup.mysqldump/README
@@ -6,7 +6,7 @@ skipped by simply not passing them to the --database flags.
Inline-compression of mysqldump output is supported and the default. By
default mechanism uses gzip -1 ("--fast") for fast but reasonable compression.
-bzip2, lzop and lzma (vi xz-utils) are also supported.
+bzip2, pbzip2, lzop and lzma (vi xz-utils) are also supported.
For more information please consult the holland manual or visit the holland
wiki at http://hollandbackup.org.
View
2 plugins/holland.backup.mysqldump/holland/backup/mysqldump/plugin.py
@@ -56,7 +56,7 @@
estimate-method = string(default='plugin')
[compression]
-method = option('none', 'gzip', 'pigz', 'bzip2', 'lzma', 'lzop', default='gzip')
+method = option('none', 'gzip', 'pigz', 'bzip2', 'pbzip2', 'lzma', 'lzop', default='gzip')
inline = boolean(default=yes)
level = integer(min=0, max=9, default=1)
View
2 plugins/holland.backup.mysqlhotcopy/holland/backup/mysqlhotcopy.py
@@ -64,7 +64,7 @@
# Only applicable to certain archive types
# (e.g. zip only supports 'zlib' internal compression)
[compression]
-method = option('none','gzip','pigz','bzip2','lzma','lzop',default='gzip')
+method = option('none','gzip','pigz','bzip2','pbzip2','lzma','lzop',default='gzip')
inline = boolean(default=false)
level = integer(default=1,min=0,max=9)
bin-path = string(default=None)
View
2 plugins/holland.backup.pgdump/holland/backup/pgdump/interface.py
@@ -34,7 +34,7 @@
additional-options = string(default=None)
[compression]
-method = option('gzip', 'bzip2', 'lzop', 'lzma', 'pigz', 'none', default='gzip')
+method = option('gzip', 'bzip2', 'pbzip2', 'lzop', 'lzma', 'pigz', 'none', default='gzip')
level = integer(min=0, default=1)
[pgauth]
View
2 plugins/holland.backup.sqlite/holland/backup/sqlite.py
@@ -15,7 +15,7 @@
binary = string(default=/usr/bin/sqlite3)
[compression]
-method = option('none', 'gzip', 'pigz', 'bzip2', 'lzop', default='gzip')
+method = option('none', 'gzip', 'pigz', 'bzip2', 'pbzip2', 'lzop', default='gzip')
inline = boolean(default=yes)
level = integer(min=0, max=9, default=1)
""".splitlines()
View
2 plugins/holland.backup.xtrabackup/holland/backup/xtrabackup/plugin.py
@@ -31,7 +31,7 @@
pre-command = string(default=None)
[compression]
-method = option('none', 'gzip', 'pigz', 'bzip2', 'lzma', 'lzop', default='gzip')
+method = option('none', 'gzip', 'pigz', 'bzip2', 'pbzip2', 'lzma', 'lzop', default='gzip')
inline = boolean(default=yes)
level = integer(min=0, max=9, default=1)
View
5 plugins/holland.lib.common/holland/lib/compression.py
@@ -10,6 +10,7 @@
'gzip' : ('gzip', '.gz'),
'pigz' : ('pigz', '.gz'),
'bzip2' : ('bzip2', '.bz2'),
+ 'pbzip2': ('pzip2', '.bz2'),
'lzop' : ('lzop', '.lzo'),
'lzma' : ('xz', '.xz'),
}
@@ -143,7 +144,7 @@ def stream_info(path, method=None, level=None):
Arguments:
path -- Path to file to compress/decompress
- method -- Compression method (i.e. 'gzip', 'bzip2', 'lzop')
+ method -- Compression method (i.e. 'gzip', 'bzip2', 'pbzip2', 'lzop')
level -- Compression level (0-9)
"""
if not method or level == 0:
@@ -168,7 +169,7 @@ def open_stream(path, mode, method=None, level=None, inline=True):
Arguments:
mode -- File access mode (i.e. 'r' or 'w')
- method -- Compression method (i.e. 'gzip', 'bzip2', 'lzop')
+ method -- Compression method (i.e. 'gzip', 'bzip2', 'pbzip2', 'lzop')
level -- Compression level
inline -- Boolean whether to compress inline, or after the file is written.
"""
View
2 test_config/backupsets/traditional.conf
@@ -47,7 +47,7 @@ backup-size-factor = 1.0
## Compression settings
[compression]
-## compress method: gzip, bzip2 or lzop
+## compress method: gzip, bzip2, pbzip2, or lzop
method = gzip
## where to compress data as it's output
## or compress a file at the end
View
2 test_config/providers/mysqldump.conf
@@ -41,7 +41,7 @@ backup-size-factor = 1.0
# Compression settings
[compression]
-# compress method: gzip, bzip2 or lzop
+# compress method: gzip, bzip2, pbzip2, or lzop
method = gzip
# where to compress data as it's output
# or compress a file at the end
View
7 test_suite/tests/providers/mysqldump/all_databases/config/providers/mysqldump.conf
@@ -83,9 +83,10 @@ additional-options = ""
## Compression Settings
[compression]
-## compress method: gzip, bzip2 or lzop
-## Which compression method to use, which can be either gzip, bzip2, or lzop.
-## Note that lzop is not often installed by default on many Linux
+## compress method: gzip, bzip2, pbzip2, or lzop
+## Which compression method to use, which can be either gzip, bzip2, pbzip2, or
+## lzop.
+## Note that pbzip2 and lzop are not often installed by default on many Linux
## distributions and may need to be installed separately.
method = gzip
View
2 test_suite/tests/providers/mysqldump/all_databases/config/providers/sqlite.conf
@@ -5,7 +5,7 @@ binary = /usr/bin/sqlite3
## Compression settings
[compression]
-## compress method: gzip, bzip2 or lzop
+## compress method: gzip, bzip2, pbzip2, or lzop
method = gzip
## where to compress data as it's output
## or compress a file at the end
Something went wrong with that request. Please try again.