axboe / fio

Flexible I/O Tester

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

`fio: io_u error on file /tmp/mounts3/1-job-30-write.0.0: Bad file descriptor: write offset=0, buflen=131072`

bas-kirill opened this issue · comments

Please acknowledge the following before creating a ticket

Description of the bug:
I installed mount-s3 and mounted it as /tmp/mounts3 using command mount-s3 kirill.bas /tmp/mounts3.

Also wrote config for benchmark:

[global]
direct=1
ioengine=libaio
iodepth=16
bs=128k

[1-job-30-write]
name=1-job-30-write
numjobs=1
directory=/tmp/mounts3
rw=rw
rwmixwrite=30
rwmixread=70
size=1m

After execution fio ./mounts3.fio > report.txt got an error:

fio: io_u error on file /tmp/mounts3/1-job-30-write.0.0: Bad file descriptor: write offset=0, buflen=131072
fio: io_u error on file /tmp/mounts3/1-job-30-write.0.0: Bad file descriptor: write offset=131072, buflen=131072

Environment: ubuntu/images/hvm-ssd/ubuntu-jammy-22.04-arm64-server-20240207.1

fio version: fio-3.28

Reproduction steps

  1. Install mount-s3:
sudo apt update -y
sudo apt install fio -y
wget -P /home/ubuntu https://s3.amazonaws.com/mountpoint-s3-release/latest/arm64/mount-s3.deb
sudo apt-get install /home/ubuntu/mount-s3.deb -y
  1. Create mount directory: mkdir /tmp/mounts3

  2. mount-s3 <bucket-name> /tmp/mount3 --allow-delete

  3. Create fio configuration:

cat <<EOF > /home/ubuntu/mounts3.fio
[global]
direct=1
ioengine=libaio
iodepth=16
bs=128k

[1-job-30-write]
name=1-job-30-write
numjobs=1
directory=/tmp/mounts3
rw=rw
rwmixwrite=30
rwmixread=70
size=1m
  1. Start benchmark: fio /home/ubuntu/mounts3.fio > report.txt

Expected Result: got report in .txt

Actual Result: error: fio: io_u error on file /tmp/mounts3/1-job-30-write.0.0: Bad file descriptor: write offset=0, buflen=131072

This works fine for me on a regular file system. So I suspect this is not fio issue. Try running with --debug=io,file to get more insight into what fio is doing and where the failure is happening.

root@localhost:~/fio-dev/1732# cat > mounts3.fio
[global]
direct=1
ioengine=libaio
iodepth=16
bs=128k

[1-job-30-write]
name=1-job-30-write
numjobs=1
directory=/tmp/mounts3
rw=rw
rwmixwrite=30
rwmixread=70
size=1m
root@localhost:~/fio-dev/1732# mkdir /tmp/mounts3
root@localhost:~/fio-dev/1732# fio mounts3.fio
1-job-30-write: (g=0): rw=rw, bs=(R) 128KiB-128KiB, (W) 128KiB-128KiB, (T) 128KiB-128KiB, ioengine=libaio, iodepth=16
fio-3.36-43-g8b31
Starting 1 process
1-job-30-write: Laying out IO file (1 file / 1MiB)

1-job-30-write: (groupid=0, jobs=1): err= 0: pid=275152: Thu Mar 14 17:38:11 2024
  read: IOPS=3000, BW=375MiB/s (393MB/s)(768KiB/2msec)
    slat (usec): min=24, max=297, avg=98.13, stdev=99.61
    clat (usec): min=314, max=1584, avg=942.27, stdev=611.66
     lat (usec): min=376, max=1882, avg=1040.40, stdev=680.01
    clat percentiles (usec):
     |  1.00th=[  314],  5.00th=[  314], 10.00th=[  314], 20.00th=[  412],
     | 30.00th=[  412], 40.00th=[  437], 50.00th=[  437], 60.00th=[ 1418],
     | 70.00th=[ 1500], 80.00th=[ 1500], 90.00th=[ 1582], 95.00th=[ 1582],
     | 99.00th=[ 1582], 99.50th=[ 1582], 99.90th=[ 1582], 99.95th=[ 1582],
     | 99.99th=[ 1582]
  write: IOPS=1000, BW=125MiB/s (131MB/s)(256KiB/2msec); 0 zone resets
    slat (usec): min=32, max=925, avg=479.28, stdev=631.25
    clat (usec): min=376, max=486, avg=431.67, stdev=77.46
     lat (usec): min=409, max=1412, avg=910.96, stdev=708.70
    clat percentiles (usec):
     |  1.00th=[  379],  5.00th=[  379], 10.00th=[  379], 20.00th=[  379],
     | 30.00th=[  379], 40.00th=[  379], 50.00th=[  379], 60.00th=[  486],
     | 70.00th=[  486], 80.00th=[  486], 90.00th=[  486], 95.00th=[  486],
     | 99.00th=[  486], 99.50th=[  486], 99.90th=[  486], 99.95th=[  486],
     | 99.99th=[  486]
  lat (usec)   : 500=62.50%
  lat (msec)   : 2=37.50%
  cpu          : usr=0.00%, sys=200.00%, ctx=4, majf=0, minf=12
  IO depths    : 1=12.5%, 2=25.0%, 4=50.0%, 8=12.5%, 16=0.0%, 32=0.0%, >=64=0.0%
     submit    : 0=0.0%, 4=100.0%, 8=0.0%, 16=0.0%, 32=0.0%, 64=0.0%, >=64=0.0%
     complete  : 0=0.0%, 4=0.0%, 8=100.0%, 16=0.0%, 32=0.0%, 64=0.0%, >=64=0.0%
     issued rwts: total=6,2,0,0 short=0,0,0,0 dropped=0,0,0,0
     latency   : target=0, window=0, percentile=100.00%, depth=16

Run status group 0 (all jobs):
   READ: bw=375MiB/s (393MB/s), 375MiB/s-375MiB/s (393MB/s-393MB/s), io=768KiB (786kB), run=2-2msec
  WRITE: bw=125MiB/s (131MB/s), 125MiB/s-125MiB/s (131MB/s-131MB/s), io=256KiB (262kB), run=2-2msec

Disk stats (read/write):
  sda: ios=0/0, sectors=0/0, merge=0/0, ticks=0/0, in_queue=0, util=0.00%

Closing due to lack of response from reporter.