From f4b934e1eb15bf5192ec5e9f241444eb5732f8f9 Mon Sep 17 00:00:00 2001 From: mulhern Date: Wed, 3 Jan 2024 23:47:47 -0500 Subject: [PATCH 1/2] Run thin_check in loud mode stratisd does not need to suppress output via -q option to thin_check because the cmd module captures stderr and stdout streams and only reads them if the command returns an error. Signed-off-by: mulhern --- src/engine/strat_engine/cmd.rs | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/src/engine/strat_engine/cmd.rs b/src/engine/strat_engine/cmd.rs index 5a5e6241ae..91f8df7c2a 100644 --- a/src/engine/strat_engine/cmd.rs +++ b/src/engine/strat_engine/cmd.rs @@ -342,11 +342,7 @@ pub fn set_uuid(devnode: &Path, uuid: FilesystemUuid) -> StratisResult<()> { /// Call thin_check on a thinpool pub fn thin_check(devnode: &Path) -> StratisResult<()> { - execute_cmd( - Command::new(get_executable(THIN_CHECK).as_os_str()) - .arg("-q") - .arg(devnode), - ) + execute_cmd(Command::new(get_executable(THIN_CHECK).as_os_str()).arg(devnode)) } /// Call thin_repair on a thinpool From c0b10d28977dac9ae86e6202d51403b88f1611a7 Mon Sep 17 00:00:00 2001 From: mulhern Date: Wed, 3 Jan 2024 23:52:52 -0500 Subject: [PATCH 2/2] Do not pass -q option to xfs.mkfs stratisd captures stdout and stderr and will only report the output on a failure of the command. No need to make xfs.mkfs quiet via a command-line option. Signed-off-by: mulhern --- src/engine/strat_engine/cmd.rs | 1 - 1 file changed, 1 deletion(-) diff --git a/src/engine/strat_engine/cmd.rs b/src/engine/strat_engine/cmd.rs index 91f8df7c2a..68ed6fa7fe 100644 --- a/src/engine/strat_engine/cmd.rs +++ b/src/engine/strat_engine/cmd.rs @@ -299,7 +299,6 @@ pub fn create_fs(devnode: &Path, uuid: Option) -> StratisResult<()> let mut command = Command::new(get_executable(MKFS_XFS).as_os_str()); command.arg("-f"); - command.arg("-q"); command.arg(devnode); if let Some(uuid) = uuid {