RE: [PATCH] btrfs: allow defrag compress to override NOCOMPRESS attribute

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> -----Original Message-----
> From: linux-btrfs-owner@xxxxxxxxxxxxxxx [mailto:linux-btrfs-
> owner@xxxxxxxxxxxxxxx] On Behalf Of Anand Jain
> Sent: Saturday, 15 July 2017 2:53 PM
> To: David Sterba <dsterba@xxxxxxxx>; linux-btrfs@xxxxxxxxxxxxxxx
> Subject: Re: [PATCH] btrfs: allow defrag compress to override NOCOMPRESS
> attribute
> 
> 
> On 07/13/2017 09:18 PM, David Sterba wrote:
> > Currently, the BTRFS_INODE_NOCOMPRESS will prevent any compression
> on
> > a given file, except when the mount is force-compress. As users have
> > reported on IRC, this will also prevent compression when requested by
> > defrag (btrfs fi defrag -c file).
> >
> > The nocompress flag is set automatically by filesystem when the ratios
> > are bad and the user would have to manually drop the bit in order to
> > make defrag -c work. This is not good from the usability perspective.
> >
> > This patch will raise priority for the defrag -c over nocompress, ie.
> > any file with NOCOMPRESS bit set will get defragmented. The bit will
> > remain untouched.
> >
> > Alternate option was to also drop the nocompress bit and keep the
> > decision logic as is, but I think this is not the right solution.
> 
> 
> Now the compression set through property will act same as '-o compress-
> force'. Before this patch is was like '-o compress'.
> I am ok to fix that patch with a new patch.

While we are at it, would it be possible to add an option to remove compression? Ie. btrfs fi defrag -c none file
Currently this doesn't seem to exist.

Thanks,
Paul.
��.n��������+%������w��{.n�����{����n�r������&��z�ޗ�zf���h���~����������_��+v���)ߣ�


[Index of Archives]     [Linux Filesystem Development]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux