5
0
mirror of git://git.proxmox.com/git/pve-storage.git synced 2025-01-08 21:18:06 +03:00

btrfs: log executed command on failures

Having the complete command printed out makes debuging easier.

Signed-off-by: Maximiliano Sandoval <m.sandoval@proxmox.com>
This commit is contained in:
Maximiliano Sandoval 2024-07-09 13:49:18 +02:00 committed by Thomas Lamprecht
parent 6cdcf65a2c
commit 70c480b9f1

View File

@ -226,7 +226,7 @@ sub btrfs_cmd {
} else {
$func = sub { $msg .= "$_[0]\n" };
}
run_command(['btrfs', '-q', @$cmd], errmsg => 'btrfs error', outfunc => $func);
run_command(['btrfs', '-q', @$cmd], errmsg => "command 'btrfs @$cmd' failed", outfunc => $func);
return $msg;
}