monit-general
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Monit unable to bind to public ip on EC2 instance


From: Martin Pala
Subject: Re: Monit unable to bind to public ip on EC2 instance
Date: Mon, 14 Jul 2014 14:06:51 +0200

Hi,

you can omit the "use address" option completely - Monit will then listen on any interface. The "address" option is usually used only if you want to bind Monit to loopback interface and make it inaccessible via public network.


Regards,
Martin



On 14 Jul 2014, at 12:47, Daniel Smedegaard Buus <address@hidden> wrote:

Hi :)

I'm trying to set up monit + mmonit on an EC2 cluster spanning three regions.

If my monitrc attempts to bind to the public ip of my instance, e.g.,

   set eventqueue basedir /var/monit/ slots 10000
   set mmonit https://monit:address@hidden:44443/collector
   set httpd port 2812 and use address <Public IP of instance>
      SSL enable
       pemfile /lib/mydomain/ssl/mmonit.mydomain.com.pem
      allowselfcertification
       allow mmonit.mydomain.com
      allow admin:password

- then monit will start, but it will fail to start the listener on port 28 with,

   [UTC Jul 14 10:33:43] error    : monit: Cannot bind -- Cannot
assign requested address
   [UTC Jul 14 10:33:43] error    : http server: Could not create a
server socket at port 2812 -- Cannot assign requested address
   [UTC Jul 14 10:33:43] error    : monit HTTP server not available

Trying to bind to the registered DNS A record for the instance doesn't
work either;
   set httpd port 2812 and use address <DNS A record for instance>

Binding to either localhost, the EC2 private DNS
(ec2-....-compute.internal) or the private ip of the instance will
start the listener correctly, but then M/Monit won't be able to
control the instance (at least not across regions) unless I manually
override the network settings for the host.

Is there no way to do this? Don't necessarily need to bind to
something different, but if the monit service could at least be
configured to provide M/Monit with different settings for this, it'd
be very nice :)

TIA,
Daniel

--
To unsubscribe:
https://lists.nongnu.org/mailman/listinfo/monit-general


reply via email to

[Prev in Thread] Current Thread [Next in Thread]