fio:tldr:3173d
fio: Test sequential reads.
$ sudo fio --filename=${filename} --direct=1 --rw=read --bs=4k --ioengine=libaio --iodepth=256 --runtime=120 --numjobs=4 --time_based --group_reporting --name=${job_name} --eta-newline=1 --readonly
try on your machine
This command is using the "fio" tool with elevated privileges (using "sudo").
Here is the breakdown of the command with explanations for each option:
--filename=${filename}
: Specifies the filename or device to be used for the I/O operations.${filename}
is a placeholder that should be replaced with the actual filename or device.--direct=1
: Enables direct I/O, bypassing the kernel page cache.--rw=read
: Sets the I/O access pattern to "read", indicating that the command will perform read operations.--bs=4k
: Specifies the block size of I/O operations, where 4k represents 4 kilobytes.--ioengine=libaio
: Selects the I/O engine to be used, in this case, "libaio" (asynchronous I/O).--iodepth=256
: Sets the I/O depth, which determines the number of outstanding I/O operations at a given time.--runtime=120
: Specifies the duration of the benchmark in seconds, in this case, 120 seconds (2 minutes).--numjobs=4
: Specifies the number of parallel jobs or threads to be used for I/O operations, in this case, 4 jobs.--time_based
: Tells fio to use a time-based workload rather than a per-request-based workload.--group_reporting
: Enables grouping of output reports for multiple threads or jobs.--name=${job_name}
: Specifies a name for the job or workload.${job_name}
is a placeholder that should be replaced with the desired name.--eta-newline=1
: Outputs estimated time of arrival on a new line.--readonly
: Specifies that the I/O operations should be read-only, meaning no writes will be performed.
Overall, this command will run the "fio" tool with the provided parameters to perform a read-only benchmark on the specified file or device for a duration of 2 minutes, using 4 parallel jobs and 256 I/O depth.
This explanation was created by an AI. In most cases those are correct. But please always be careful and
never run a command you are not sure if it is safe.