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
[user@ip-10-60-109-73]# cat MINDBLOWN | |
HELLO | |
WORLD | |
[user@ip-10-60-109-73]# grep -v HELLO MINDBLOWN | |
WORLD | |
[user@ip-10-60-109-73]# grep -v HELLO MINDBLOWN > MINDBLOWN | |
[user@ip-10-60-109-73]# cat MINDBLOWN | |
[user@ip-10-60-109-73]# |
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/bash | |
/usr/bin/monit start appsrv1 | |
/usr/bin/monit stop aws-dns-healthcheck |
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
check host appsrv1 with address 127.0.0.1 | |
start program = "/sbin/start myapp" | |
stop program = "/sbin/stop myapp" | |
alert [email protected] on {timeout,connection} | |
if failed port 9009 protocol HTTP | |
request / | |
with timeout 3 seconds | |
then restart | |
if 10 restarts within 10 cycles then timeout | |
if 10 restarts within 10 cycles then exec "/usr/bin/monit start aws-dns-healthcheck" |
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
check host appsrv1 with address 127.0.0.1 | |
start program = "/sbin/start myapp" | |
stop program = "/sbin/stop myapp" | |
alert [email protected] on {timeout,connection} | |
if failed port 9009 protocol HTTP | |
request / | |
with timeout 3 seconds | |
then restart | |
if 10 restarts within 10 cycles then timeout |