Does anybody know why are we redirecting stderr to /dev/null when using
kexec load/unload commands? This sounds wrong to me. In case of error I
have no idea what went wrong.
Systemctl already puts all the information in journal. So if we are worried
that user will be bombarded with error messages, that should not be a concern.
So do not redirect stderr to /dev/null.
Signed-off-by: Vivek Goyal <vgoyal(a)redhat.com>
---
kdumpctl | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/kdumpctl b/kdumpctl
index 70d30fa..bb98225 100755
--- a/kdumpctl
+++ b/kdumpctl
@@ -435,7 +435,7 @@ load_kdump()
$KEXEC $KEXEC_ARGS $standard_kexec_args \
--command-line="$KDUMP_COMMANDLINE" \
- --initrd=$TARGET_INITRD $kdump_kernel 2>/dev/null
+ --initrd=$TARGET_INITRD $kdump_kernel
if [ $? == 0 ]; then
echo "kexec: loaded kdump kernel"
return 0
@@ -826,7 +826,7 @@ stop_fadump()
stop_kdump()
{
- $KEXEC -p -u 2>/dev/null
+ $KEXEC -p -u
if [ $? != 0 ]; then
echo "kexec: failed to unload kdump kernel"
return 1
--
1.9.0