Quantcast
Channel: Alex Schroeder: oddmuse
Viewing all articles
Browse latest Browse all 16

Monit and Oddmuse 6

$
0
0

I noticed that my Monit setup for Oddmuse 6 isn’t working.

check process oddmuse6 with pidfile /home/alex/oddmuse6/pid
    start program = "/home/alex/bin/oddmuse6" as uid alex gid alex
    restart program = "/home/alex/bin/oddmuse6" as uid alex gid alex
    stop program = "/bin/kill `cat /home/alex/oddmuse6/pid`" as uid alex gid alex
    if failed host next.oddmuse.org port 443 protocol https
      and request "/view/Monit" for 5 cycles then restart
    if totalmem > 1500 MB for 5 cycles then restart
    if 6 restarts within 15 cycles then timeout

monit status oddmuse6 gives me:

FAILED to [next.oddmuse.org]:443/view/Monit type TCP/IP using SSL/TLS protocol HTTP

Everything seems to be working, however. Finally I decided to try curl and look at the headers.

$ curl -I https://next.oddmuse.org:443/view/Monit
HTTP/1.1 405 Method Not Allowed

Then I realized: this is HEAD vs. GET requests!

Confirmation in the Apache log. There’s the 405 status code again.

next.oddmuse.org:443 178.209.50.237 - - [22/Oct/2018:09:36:52 +0200] "HEAD /view/Monit HTTP/1.1" 405 4561 "-" "Monit/5.20.0"

Clearly, I need to start working on caching and handling HEAD requests in Oddmuse 6!

Tags:


Viewing all articles
Browse latest Browse all 16

Trending Articles