Hi,
thanks- somehow I expected something like this. And I agree the process
you suggested will be too flawky...
I will start with a fresh backup pool, emptying everything. For safety I
will keep the original btrfs-disk until the new pool has been populated
with some stuff.
Thanks!
/KNEBB
Am 08.06.25 um 03:49 schrieb backu...@kosowsky.org:
This probably won't be very easy and I don't know of any automatic way
to do it.
You could do it manually by doing something like the following:
1a. Write a program that uses zlib to compress a file and insert the
appropriate backuppc header. This isn't too hard - you can examine
similar code in the backuppc sources.
1b. Write a script to recurse through cpool, compress each file using
above routine at a given level of compression (typically 3). Check
to make sure no existing copy in cpool before moving (assuming
you already started using compression so that you have a mixed pool
and cpool now)
2. Recurse through *all* the attrib files in the pc directory and
change 'compress' to 3 for all files in the attrib file (assuming
you want to use the standard compression level)
You could write a simple Perl script to do this
3. Also, change the 'compress' entry in 'backupInfo' for each backup
4. Similarly, change the 'compress' entry in each 'backup' file at the
root of each host
5a. Change the refCont entries in each cpool/[0-9a-f][0-9a-f] directory
5b. Simioarly, change refCnt entries in each backup root for each host
You could do both of the above brute force by running
/usr/share/backuppc/bin/BackupPC_fsck -f -s
Given all the manipulations above, I would be worried that the process
is "fragile" and could destroy invaluable backups.
So unless someone knows of a well-tested, automatic way of doing this,
I'm not sure I would recommend it.
I am not sure it is wise to switch now from uncompressed to compressed
as I'm not sure what happens if you re-backup a file that previously
was stored as uncompressed. It may very well now create a new
compressed copy resulting in significant file duplication.
Christian Völker via BackupPC-users wrote at about 14:04:39 +0200 on Saturday,
June 7, 2025:
> Hi,
>
> I have a V4 pool where I had compression disabled for couple of months.
> Now I decided (after thinking twice ;)) to enable compression on the pool.
>
> Is there any chance to move the existing (non compressed) pool into the
> cpool?
>
> Or best to just wait another months until the pool-files are getting
> outdated?
>
> [Note:
> I used BTRFS with compression inside a VM. I prefer enabling it on
> filesystem level so I disabled compression for BackuppPC initially. But
> as this is a VM running on QNAP NAS with underlying ZFS it doe not make
> sense to have a CoW fs like BTRFS on top of anothe CoW fs (QNAP ZFS). So
> I decided to move the pool to ext4 instead of btrfs. But as the VM is
> using luks encryption I can not enable ZFS compression as it will not
> see any compression possibilities. So I want to enable it on BackupPC
> and possibly moving existing uncompressed pool files to compressed pool.
>
> So any ideas?
>
> Thanks!
>
> Christian
>
>
> _______________________________________________
> BackupPC-users mailing list
> BackupPC-users@lists.sourceforge.net
> List: https://lists.sourceforge.net/lists/listinfo/backuppc-users
> Wiki: https://github.com/backuppc/backuppc/wiki
> Project: https://backuppc.github.io/backuppc/
_______________________________________________
BackupPC-users mailing list
BackupPC-users@lists.sourceforge.net
List: https://lists.sourceforge.net/lists/listinfo/backuppc-users
Wiki: https://github.com/backuppc/backuppc/wiki
Project: https://backuppc.github.io/backuppc/
_______________________________________________
BackupPC-users mailing list
BackupPC-users@lists.sourceforge.net
List: https://lists.sourceforge.net/lists/listinfo/backuppc-users
Wiki: https://github.com/backuppc/backuppc/wiki
Project: https://backuppc.github.io/backuppc/