Sharing files between threads
Author: xldrxCreated Jul 28, 2018Updated Apr 27, 2026
Labelsenhancement
I am trying to share files between threads with no success. The following fio file works perfectly:
[global]
filename_format=data-$jobnum-$filenum.bin
filesize=256m
nrfiles=1
directory=${DEVICE}
rw=randread
time_based=1
runtime=30s
[sync-d1-s64]
bssplit=4k/1
ioengine=sync
direct=0
group_reporting=1
stonewall
numjobs=4
thread=1However, when I change the filename_format=data-$jobnum-$filenum.bin to filename_format=data-$filenum.bin (removing $jobnum to share the files), I get the following error from all but one thread:
sync-d1-s64: you need to specify size=
fio: pid=0, err=22/file:filesetup.c:961, func=total_file_size, error=Invalid argumentI also added the size=256m just in case, but the job still fails with the following error:
sync-d1-s64: No I/O performed by sync, perhaps try --debug=io option for details?debug=all suggests that the error is this:
file 6655 get_next_file: nr_open=0, nr_done=0, nr_files=0
io 6655 io_u 0x7f0a7c001ac0, setting file failed
io 6655 get_io_u failed
sync-d1-s64: No I/O performed by sync, perhaps try --debug=io option for details?I have tried this on fio v3.8, v3.7, v2.99, and v3.1 (centos yum). As well as different filesystems.
Any thoughts on what I am missing?
Source: axboe/fio