[Why] when test fio with write mode, an error is reported: fio: /dev/sda appears mounted, and 'allow_mounted_write' isn't set. [How] add allow_mounted_write when write mode
Signed-off-by: Wei Jihui weijihuiall@163.com --- setup/fio-setup-basic | 6 ++++++ 1 file changed, 6 insertions(+)
diff --git a/setup/fio-setup-basic b/setup/fio-setup-basic index 58ebeb80..f90963aa 100755 --- a/setup/fio-setup-basic +++ b/setup/fio-setup-basic @@ -116,6 +116,12 @@ $create_task ioscheduler=$ioscheduler" fi
+if [[ "$rw" =~ "write" ]]; then + create_task="\ +$create_task +allow_mounted_write=1" +fi + if parse_bool -q "$time_based"; then create_task=" $create_task
On Thu, Nov 05, 2020 at 01:13:14PM +0800, Wei Jihui wrote:
[Why] when test fio with write mode, an error is reported: fio: /dev/sda appears mounted, and 'allow_mounted_write' isn't set. [How] add allow_mounted_write when write mode
Signed-off-by: Wei Jihui weijihuiall@163.com
setup/fio-setup-basic | 6 ++++++ 1 file changed, 6 insertions(+)
diff --git a/setup/fio-setup-basic b/setup/fio-setup-basic index 58ebeb80..f90963aa 100755 --- a/setup/fio-setup-basic +++ b/setup/fio-setup-basic @@ -116,6 +116,12 @@ $create_task ioscheduler=$ioscheduler" fi
+if [[ "$rw" =~ "write" ]]; then
- create_task="\
+$create_task +allow_mounted_write=1"
It's a short line no need change a line.
Thanks, Xueliang
+fi
if parse_bool -q "$time_based"; then create_task=" $create_task -- 2.23.0