Pulling disk status from a disk array, I get "ready" and "online" as status for OK. Trying to trap this with an IF statement in bash, that will act if the value is something else than "ready" and "online".
The code snippet below works for trapping "OK" but I'd like to reverse it, so it traps if $diskstatus is NOT ready or online.
#!/bin/bash
diskstatus="online"
if [[ $diskstatus = online ]] || [[ $diskstatus = ready ]]; then echo "OK: $diskstatus"; fi
Have now tried nearly everything with brackets, quotes and whatnot but not getting any of it to work.