2

When starting monit my logs show that

[CET Oct 31 19:43:34] info     : Starting Monit 5.16 daemon
[CET Oct 31 19:43:34] error    : monit: monit httpd not started since no connect allowed
[CET Oct 31 19:43:34] info     : 'srv.home' Monit 5.16 started

despite having

set httpd port 2812

in /etc/monit/monitrc.

Is there anything else needed to have the httpd server enabled when monit is started via systemd?

Note: A previous answer pointed to an extra and, which is not my case (the andwas there, but an an introduction for following configuration lines, of which I believe I need none for an open, unauthenticated access. I also tried to add and use address 10.10.10.254 to the line above expecting that this is the address the httpd monitor would bind to, unfortunately with the same effect)

WoJ
  • 3,365
  • 8
  • 46
  • 75

2 Answers2

3

It seems you have to specify at least one between the allow and credentials directives.

In my case I solved the issue simply adding the ALLOW directive

SET HTTPD PORT 2812
  USE ADDRESS 127.0.0.1
  ALLOW 127.0.0.1

See the relevant code from monit sources.

  • Thanks Davide. I have forgotten about the question but thi s is an opportunity to review the subject. – WoJ Mar 09 '18 at 09:21
0

The monit http server is not responding until monit is fully started. It you specified an "start delay", the http server will not respond until that delay.
set daemon 120 # check services at 2-minute intervals # with start delay 240 # optional: delay the first check by 4-minutes but also responses from http server

DevOps
  • 720
  • 3
  • 15