Lines Matching +full:up +full:- +full:samples
15 nonmed: Show SMART non-medium errors (SAS).
27 smart_test: Show SMART self-test results summary.
28 test_type: Show SMART self-test type (short, long... ).
29 test_status: Show SMART self-test status.
30 test_progress: Show SMART self-test percentage done.
31 test_ended: Show when the last SMART self-test ended (if supported).
36 # If you set $samples to a directory containing smartctl output text files,
39 # $samples is set, and additional 'file' column is added to the zpool output
41 samples=
46 # is chosen quasi-sequentially (based off our PID). This allows us to return
53 num_files=$(find "$dir" -maxdepth 1 -type f | wc -l)
56 find "$dir" -type f -printf '%f\n' | while read -r file ; do
67 if [ "$1" = "-h" ] ; then
68 echo "$helpstr" | grep "$script:" | tr -s '\t' | cut -f 2-
72 # Sometimes, UPATH ends up /dev/(null).
75 if [ ! -b "$VDEV_UPATH" ]; then
81 if [ -b "$somepath" ] && PATH="/usr/sbin:$PATH" command -v smartctl > /dev/null || [ -n "$samples" ] ; then
82 if [ -n "$samples" ] ; then
85 file=$(get_filename_from_dir "$samples")
87 raw_out=$(cat "$samples/$file")
89 raw_out=$(sudo smartctl -a "$somepath")
107 /Non-medium error count/{print "nonmed="$4}
114 /SMART Health Status:/{printf "health="; for(i=4;i<=NF-1;i++){printf "%s_", $i}; printf "%s\n", $i}
115 /number of hours powered up/{print "hours_on="$7; hours_on=int($7)}
132 /SMART overall-health self-assessment test result:/{print "health="$6}
139 /SMART overall-health self-assessment test result:/{print "health="$6}
140 /Power On Hours:/{gsub("[^0-9]","",$4); print "hours_on="$4}
147 # SMART self-test info
148 /Self-test execution status:/{progress=tolower($4)} # SAS
149 /SMART Self-test log/{test_seen=1} # SAS
150 /SMART Extended Self-test Log/{test_seen=1} # SATA
164 hours=int($(NF-4))
166 hours=int($(NF-1))
169 progress=(100-int($(NF-2)))"%"
171 # When we int()-ify "hours", it converts stuff like "NOW" and "-" into
185 total_hours_ago=(hours_on-hours)
199 type=$(echo "$out" | grep '^type=' | cut -d '=' -f 2)
204 if [ -z "$type" ]; then
237 with_vals=$(echo "$out" | grep -E "$scripts")
238 if [ -n "$with_vals" ]; then
241 grep -v -E "$(echo "$with_vals" |
242 awk -F "=" '{print $1}')" | awk '{print $0"="}')
247 if [ -n "$without_vals" ]; then