]> git.pld-linux.org Git - packages/kexec-tools.git/commitdiff
- print kernel and initrd info in status action
authorElan Ruusamäe <glen@pld-linux.org>
Thu, 2 Jun 2011 18:00:09 +0000 (18:00 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    kexec.init -> 1.7

kexec.init

index 8a5b7f2b900501bf01e520129269f51d077a2af5..b8e36186f1c2fbc3480f6910f6afa61d787ca0fc 100644 (file)
@@ -86,6 +86,18 @@ status() {
        else
                show "Kexec image for kernel crash is not loaded"; fail
        fi
+
+       # convert to real file for readability
+       if [ -L "$KERNEL_IMAGE" ]; then
+               KERNEL_IMAGE=$(readlink -f "$KERNEL_IMAGE")
+       fi
+       if [ -L "$INITRD" ]; then
+               INITRD=$(readlink -f "$INITRD")
+       fi
+       INIT_COL=0 show "Configured kernel: %s" "$KERNEL_IMAGE"; echo
+       if [ -n "$INITRD" ]; then
+               INIT_COL=0 show "Configured initrd: %s" "$INITRD"; echo
+       fi
 }
 
 RETVAL=0
This page took 0.130758 seconds and 4 git commands to generate.