HTTP server could not start if no network interface available

Issue #537 resolved
Benoit Le Texier
created an issue

I have a strange behavior using 5.19.0 version of monit on a Linux isolated equipment: the HTTP interface is not available if only the loopback interface is available.

Using the same binary and configuration file and adding an interface (here eth0), the socket is correctly created on the loopback interface (as shown in netstat.log).

I have tested using a previous version of monit (5.18.0) and the problem was not present.

Comments (7)

  1. Patrick Oberdorfer

    I can confirm this bug, if interfaces are down monit httpd wont start even when listening on 0.0.0.0 which should be possible by recent kernels. Why is the use of AI_ADDRCONFIG in monit? Any benefits from using this non default flag? If there are non can this be removed? I think a lot of startup problems are related to this.

    This also affects 5.20.0

  2. Tildeslash repo owner

    Thanks for bringing this to our attention. Removed usage of AI_ADDRCONFIG with this checkin dcc28e7ffaed. Could you guys be so kind and checkout Monit from Git and test and let us know if this solves the problem you have?

  3. Rahul De

    Hi,

    When will be an stable release be available having this fix? We are planning to deploy onto production soon and were hoping we don't have to compile from source for this bug.

    Thanks!

  4. Log in to comment