Re: [PATCH 0/2] dm log writes: Add support for filter bios based on its type

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

 



Gentle ping?

This feature would be pretty useful if we want to really log heavy
operations on a relatively small log devices.

Thanks,
Qu

On 2019/6/19 下午4:03, Qu Wenruo wrote:
> Current dm-log-writes will record all bios, no matter if the bios is
> METADATA (normally what we care) or is DATA (normally we cares less for
> the log-replay context).
> 
> This causes a lot of extra space required for log device. E.g write 10M,
> sync, overwrite that 10M file, this would cause over 20M for log device
> just for the data.
> 
> This patchset introduces two way to specify the dump type:
> - dump_type=%s optional option for constructor
>   The default dump_type is ALL, thus no behavior change.
> 
> - dump_type=%s message type to change type on the fly
> 
> Also to cooperate the new dump_type= option, always output the dump_type
> for STATUSTYPE_TABLE.
> 
> A common use case would be:
>  # dmsetup create log --table 0 $(blockdev --getsz $dev) log-writes $dev $log_dev
>  # mkfs.btrfs -f /dev/mapper/log
>  # dmsetup suspend log
>  # dmsetup message log 0 dump_type=METADATA|FUA|FLUSH|DISCARD|MARK
>  # dmsetup resume log
>  # mount /dev/mapper/log <mnt>
>  # <do some work load>
>  # umount <mnt>
>  # dmsetup remove log
>  # <replay>
> 
> Now the log device will not record data writes, thus hugely reduce the
> space requirement for log device, allowing more operations to be down
> before hitting the space limit.
> 
> Currently btrfs check doesn't check data checksum by default, thus even
> we have wrong data on-disk, we should be fine checking the metadata.
> 
> I'm not 100% sure if this applies to other filesystems, but as long as
> metadata writes is marked correctly, other filesystems can also benifit
> from this feature.
> 
> Qu Wenruo (2):
>   dm log writes: Allow dm-log-writes to filter bios based on types to
>     reduce log device space usage
>   dm log writes: Introduce dump_type= message type to change dump_type
>     on the fly
> 
>  drivers/md/dm-log-writes.c | 177 ++++++++++++++++++++++++++++++++++---
>  1 file changed, 167 insertions(+), 10 deletions(-)
> 

Attachment: signature.asc
Description: OpenPGP digital signature

--
dm-devel mailing list
dm-devel@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/dm-devel

[Index of Archives]     [DM Crypt]     [Fedora Desktop]     [ATA RAID]     [Fedora Marketing]     [Fedora Packaging]     [Fedora SELinux]     [Yosemite Discussion]     [KDE Users]     [Fedora Docs]

  Powered by Linux