Guest User

Untitled

a guest
Jun 25th, 2018
118
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.17 KB | None | 0 0
  1. if [[ $(ping -c5 SERVER1 | grep -q "5 packets transmitted, 5 received") -eq 0 ]]
  2. then
  3. echo "Server1 is up."
  4. else
  5. echo "Server is NOT up, look for another server."
  6. fi
Add Comment
Please, Sign In to add comment