Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I want to use monit to monitor services on my Ubuntu VM(precise 32) but I cannot access the monit daemon via HTTP from the host (local) machine.

I have enabled the following settings in /etc/monit/monitrc:

set httpd port 2812 and
  use address localhost
  allow localhost
  allow vagrant:vagrant_pwd

and have forwarded port 2812 in the virtual machine to host machine in Vagrantfile as follows:

config.vm.forward_port 2812, 2812

I have confirmed that monit is running on the virtual machine by ssh'ing into the VM and running:

sudo /etc/init.d/monit status

and can access the Monit daemon using HTTP within the VM by running

curl -u vagrant:vagrant localhost:2812

but when I enter localhost:2812 on the host machine browser (firefox) I get no response.

Any ideas on how to make this work?

share|improve this question

1 Answer 1

This answer helped me: http://stackoverflow.com/a/5999945/262972

When I set my monitrc to the following, I was able to connect at 33.33.33.10:3737

set httpd port 3737 and
    use address 0.0.0.0
    allow admin:"password"
share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.