Commit 9ee30b87 authored by Jim Harris's avatar Jim Harris Committed by Ben Walker
Browse files

fio_plugin: enforce thread=1



The SPDK fio plugin only supports jobs as threads, not separate
processes.  So log an error and bail if --thread=1 is not
specified.

Signed-off-by: default avatarJim Harris <james.r.harris@intel.com>
Change-Id: I318f924e0b7fbb76f11427a447dd7c5fc0ebc221
parent b512e01a
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -39,7 +39,8 @@ To select NVMe devices, you simply pass an identifier as the filename in the for
Remember that NVMe namespaces start at 1, not 0! Also, the notation uses '.' throughout,
not ':'. For example - 0000.04.00.0/1.

Currently the fio_plugin is limited to a single thread, so only one job is supported.
Currently the SPDK fio plugin is limited to a single thread, so only one job is supported.
fio jobs must also specify thread=1 when using the SPDK fio plugin.

When testing random workloads, it is recommended to set norandommap=1.  fio's random map
processing consumes extra CPU cycles which will degrade performance over time with
+5 −0
Original line number Diff line number Diff line
@@ -179,6 +179,11 @@ static int spdk_fio_setup(struct thread_data *td)
	struct spdk_fio_thread *fio_thread;
	struct spdk_env_opts opts;

	if (!td->o.use_thread) {
		log_err("spdk: must set thread=1 when using spdk plugin\n");
		return 1;
	}

	fio_thread = calloc(1, sizeof(*fio_thread));
	assert(fio_thread != NULL);