On Sep 30, 2014 6:47 PM, "Jens Axboe" <axboe@xxxxxxxxx> wrote: > > On 2014-09-30 02:57, Andrey Kuzmin wrote: >> >> The same thing could be done by partitioning the SSD in the operating >> system with the desired partition size, and then running a time-based >> fio job against the partition. >> >> Basically, fio options offset/size should yield the same net result, >> but I'm always unsure on what is the actual effect of mixing size and >> time_based in a single job, and whether fio will wrap around the >> specified size to the specified offset if the job is time-based. HOWTO >> could have used some clarification on size/time_based interaction. > > > The HOWTO currently states: > > time_based If set, fio will run for the duration of the runtime > specified even if the file(s) are completely read > or written. It will simply loop over the same workload > as many times as the runtime allows. > > Especially the last sentence should make it clear, that it will simply run the specified workload over and over until the time has passed. I'd welcome changes to make that clearer, if it doesn't get the point across. > A potentially confusing point is the size and io_size options which are specified as follows (quoting from https://github.com/axboe/fio/blob/master/HOWTO) size=int The total size of file io for this job. Fio will run until this many bytes has been transferred, unless runtime is limited by other options (such as 'runtime', for instance). Unless specific nrfiles and filesize options are given, fio will divide this size between the available files specified by the job. If not set, fio will use the full size of the given files or devices. If the files do not exist, size must be given. It is also possible to give size as a percentage between 1 and 100. If size=20% is given, fio will use 20% of the full size of the given files or devices. io_limit=int Normally fio operates within the region set by 'size', which means that the 'size' option sets both the region and size of IO to be performed. Sometimes that is not what you want. With this option, it is possible to define just the amount of IO that fio should do. For instance, if 'size' is set to 20G and 'io_limit' is set to 5G, fio will perform IO within the first 20G but exit when 5G have been done. Although, under 'size' description above, runtime exception is properly made, I - may be it's just individual ;) - didn't get it clear at first, and had to spend some time on checking with the code what it does when time_based/runtime is mixed with size and io_size options. I believe it might be worth an extra sentence saying that time_based and io_size are mutually exclusive and, for time_based jobs, (offset/?)size just specify the file/device range to be utilized, with sequential I/O wrapping around as/if necessitated by runtime/size. YMMW. Regards, Andrey > -- > Jens Axboe > -- To unsubscribe from this list: send the line "unsubscribe fio" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html