-
Simon Michnowicz authoredSimon Michnowicz authored
check_lustre_health.nhc 383 B
#!/bin/bash
function check_lustre_health() {
# lustre health check file is different on different versions
HEALTH_FILE="/proc/fs/lustre/health_check"
if [ ! -f $HEALTH_FILE ]; then
HEALTH_FILE="/sys/fs/lustre/health_check"
fi
health_check=`cat $HEALTH_FILE`
if [ $health_check != "healthy" ]
then
die 1 " $FUNCNAME Lustre Health check failed $health_check"
return 1
fi
}