On Wed, 10 Feb 2021 at 03:38, Michele Pardini <michele.pardini@xxxxxxxxx> wrote: > > Hello, > > I need to test a storage device adjusting the % of the write workload > that can be compressed. I've learnt how to use > > buffer_compress_percentage=70 > refill_buffers > buffer_pattern > > When you set buffer_compress_percentage to a job, or to global, then > 100% of the write workload will be compressed (at 70% rate ,in this > example) . > > What I'd like to understand is if there's a way to tune the % of the > write workload that will be compressed. Ideally FIO should send 70% > writes compressible (at 10% compress rate) and 30% not compressible > (or 0% compress rate) > > I could create 7 jobs with buffer_compress_percentage and 3 jobs > without, but I need to have the 70/30 ratio in a single job/thread. You could do this with two jobs where one job was writes compressed at 10% and another job was uncompressed writes and then use flow (https://fio.readthedocs.io/en/latest/fio_doc.html#cmdoption-arg-flow ) to balance them against each other in a 7:3 ratio. You would have to modify the source code of fio if you want to do it in a single job - feel free to submit a patch if you can provide it as an option that fits well with the rest of fio! -- Sitsofe