aboutsummaryrefslogtreecommitdiff
path: root/sysutils/linux-megacli2/files/407.status-mfi-raid.in
diff options
context:
space:
mode:
authorBoris Samorodov <bsam@FreeBSD.org>2007-12-27 00:15:48 +0000
committerBoris Samorodov <bsam@FreeBSD.org>2007-12-27 00:15:48 +0000
commitc519e1827c684e4adc8179dd3ae7996ae4b21a47 (patch)
tree914af0a4d202a3504a7d438c0d36da5d1d221a43 /sysutils/linux-megacli2/files/407.status-mfi-raid.in
parentbe3e6334f2fbd66fbe2131a28e3f2e4532ba9d90 (diff)
Main changes:
- The periodic script should print a banner, like all other periodic script - Don't sort the PD heading output, it breaks with certain numbering Minor nits: - Fix spelling - pet portlint(1) - Use awk(1) to alleviate the need for additional wc(1) - remove non-portable -z flag to cmp(1) PR: 118416 Submitted by: Ulrich Spoerlein <uspoerlein at gmail.com> Reviewed by: maintainer timeout (3 weeks)
Notes
Notes: svn path=/head/; revision=204594
Diffstat (limited to 'sysutils/linux-megacli2/files/407.status-mfi-raid.in')
-rw-r--r--sysutils/linux-megacli2/files/407.status-mfi-raid.in6
1 files changed, 4 insertions, 2 deletions
diff --git a/sysutils/linux-megacli2/files/407.status-mfi-raid.in b/sysutils/linux-megacli2/files/407.status-mfi-raid.in
index 609709797071..54c58a9cb35f 100644
--- a/sysutils/linux-megacli2/files/407.status-mfi-raid.in
+++ b/sysutils/linux-megacli2/files/407.status-mfi-raid.in
@@ -22,6 +22,8 @@ logdir=${logdir:-/var/log}
case "$daily_status_mfi_raid_enable" in
[Yy][Ee][Ss])
+ echo
+ echo 'Checking status of MFI RAID controllers:'
;;
*)
exit 0
@@ -58,12 +60,12 @@ for ctrl in `jot ${ADPCOUNT} ${ADPMINIDX} ${ADPMAXIDX}`; do
# Print summary information.
echo "------------------------------------------------------------------------"
echo "Physical Drive Information:"
+ echo "ENC SLO DEV SEQ MEC OEC PFC LPF STATE"
${megacli} -PDList -a${ctrl} | \
awk '
BEGIN {
E=-1; S=-1; D=-1; s=-1; mec=-1; oec=-1; pfc=-1; lpfeqn=-1;
state="";
- printf "ENC SLO DEV SEQ MEC OEC PFC LPF STATE\n";
}
/^Enclosure Number:/ { E=$3; }
/^Slot Number:/ { S=$3; }
@@ -199,7 +201,7 @@ for ctrl in `jot ${ADPCOUNT} ${ADPMINIDX} ${ADPMAXIDX}`; do
# Now show the differences or the entire log.
case "$daily_status_mfi_raid_persist_logs" in
[Yy][Ee][Ss])
- cmp -zs ${ctrl_log}.yesterday ${ctrl_log}.today
+ cmp -s ${ctrl_log}.yesterday ${ctrl_log}.today
raid_rc=$?
if test $raid_rc -ne 0; then
diff -u ${ctrl_log}.yesterday ${ctrl_log}.today | \