Reputation: 381
I'm using the following monit code to alert if the specified page isn't answering with http 200 status code:
check host gateway with address 127.0.0.1
if failed
port 7778
protocol http
request "/mypage/"
status = 200
then alert
Anyway, on monit 5.20 (default on my debian 9) I'm getting: FAILED to [127.0.0.1]:7778/mypage/ type TCP/IP protocol HTTP, why?
Editing: it seems related to the status getting back, which is 301, but still haven't figured out the reason.
Upvotes: 0
Views: 512
Reputation: 381
At the end I couldn't find the reason, but upgrading to latest monit version (5.26) the issue disappeared.
Upvotes: 0