|
Last change
on this file since 0e62558 was
c5c522c,
checked in by Edwin Eefting <edwin@datux.nl>, 9 years ago
|
|
initial commit, transferred from cleaned syn3 svn tree
|
-
Property mode set to
100755
|
|
File size:
658 bytes
|
| Line | |
|---|
| 1 | #!/bin/bash |
|---|
| 2 | |
|---|
| 3 | STAT=/tmp/areca.$$ |
|---|
| 4 | |
|---|
| 5 | #Hebben we een controller? |
|---|
| 6 | modprobe sg |
|---|
| 7 | if /usr/bin/areca-cli vsf info &> $STAT; then |
|---|
| 8 | STATTXT=`grep '^ [0-9]' $STAT` |
|---|
| 9 | #Is er EEN regel die niet op Normal eindigd? |
|---|
| 10 | if grep '^ [0-9]' $STAT | grep -v 'Normal$' >/dev/null; then |
|---|
| 11 | if grep Rebuilding $STAT >/dev/null; then |
|---|
| 12 | syn3-state 'raid-areca' CAUTION "Raid array is rebuilding: $STATTXT" |
|---|
| 13 | else |
|---|
| 14 | syn3-state 'raid-areca' ALERT "Trouble with raid array: $STATTXT" |
|---|
| 15 | fi |
|---|
| 16 | else |
|---|
| 17 | syn3-state 'raid-areca' OK "Raid array is online: $STATTXT" |
|---|
| 18 | fi |
|---|
| 19 | elif [ -e /var/lib/mon/alerts/raid-areca ]; then |
|---|
| 20 | syn3-state 'raid-areca' ALERT "Error getting raid status: $STATTXT" |
|---|
| 21 | fi |
|---|
| 22 | rm $STAT |
|---|
Note: See
TracBrowser
for help on using the repository browser.