Created
October 20, 2017 20:17
-
-
Save mfeit-internet2/24ad3bb83a6dd3fdef87fb9469f92a4a to your computer and use it in GitHub Desktop.
Ping pScheduler and produce a netstat on failure.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh -e | |
# | |
# Ping pScheduler every so often and grab a netstat when it fails, | |
# placing a copy in /tmp/netstat. | |
# | |
while pscheduler ping --quiet localhost > /dev/null | |
do | |
sleep 10 | |
done | |
netstat -na | egrep -e '^tcp' | tee /tmp/netstat | |
exit 0 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment