Giter Club home page Giter Club logo

Comments (16)

gvenka008c avatar gvenka008c commented on August 22, 2024

@jjethwa I was able to pull from git repo. Closing it. Thanks.

from icinga2.

jjethwa avatar jjethwa commented on August 22, 2024

Hi @gvenka008c

Sorry for the late response. Sounds like you have it working though :) The easiest way is to use a volume for /etc/icinga2 (also the database would be good for persistence) then pull the configs down on the container host. Then use docker exec to reload the config

sudo docker exec icinga2 service icinga2 reload

from icinga2.

gvenka008c avatar gvenka008c commented on August 22, 2024

@jjethwa Thanks. We wanted to keep all our config in github. So we can clone the repo inside the container.

After i cloned the repo, I am seeing the as below

Service Status: UNKNOWN
CHECK_​NRPE: Error receiving data from daemon.

I was able to run the below command inside docker and get the desired output.

check_nrpe -H hostname -c command -n

Not sure why Icinga Web is throwing error. Also under System > Monitoring Health it is showing as Backend icinga2 is not running. Any thoughts?

from icinga2.

jjethwa avatar jjethwa commented on August 22, 2024

Hi @gvenka008c

Check the logs under /var/log/icinga2 That should tell you why Icinga2 failed to start. Maybe a bad configuration?

from icinga2.

gvenka008c avatar gvenka008c commented on August 22, 2024

@jjethwa I didn't see any issues in the log

#/var/log/icinga2/icinga2.log
[2016-04-12 14:14:06 +0000] information/ConfigCompiler: Compiling config file: /var/lib/icinga2/modified-attributes.conf
[2016-04-12 14:14:06 +0000] information/IdoMysqlConnection: MySQL IDO instance id: 1 (schema version: '1.14.0')
[2016-04-12 14:14:07 +0000] information/IdoMysqlConnection: Finished reconnecting to MySQL IDO database in 0.669704 second(s).

from icinga2.

gvenka008c avatar gvenka008c commented on August 22, 2024

@jjethwa I killed the running container and started a new one. And now all the alerts are back up and running without issues..

How can i get rid of the alerts that is showing on web for docker-icinga2?

from icinga2.

jjethwa avatar jjethwa commented on August 22, 2024

Hi @gvenka008c

If you're using Icinga Web 2 that is on the same container as Icinga2 then the alerts should automatically clear if their checks pass. Are you using a separate container for Icinga2 and Icinga Web 2 (or Icinga Classic UI)?

from icinga2.

gvenka008c avatar gvenka008c commented on August 22, 2024

@jjethwa No. I am using a single container for both icinga2 and icinga web2.

from icinga2.

jjethwa avatar jjethwa commented on August 22, 2024

Hi @gvenka008c

That's strange. Just to confirm, after starting a new container to load up config changes, you are still seeing alerts in Icinga Web 2 (or Classic UI) for checks that have passed in Icinga2 (as confirmed in the icinga2.log) ?

from icinga2.

gvenka008c avatar gvenka008c commented on August 22, 2024

screen shot 2016-04-12 at 5 08 00 pm

from icinga2.

jjethwa avatar jjethwa commented on August 22, 2024

@gvenka008c

Thanks, the screenshot helped. The swap check will always fail since it's a container. I left that check in there by default so new users could see that checks were working properly (SSH and Swap tests should be critical and the rest should be OK). Not sure what the random checks are, but I assume those statuses are OK? :)

from icinga2.

gvenka008c avatar gvenka008c commented on August 22, 2024

@jjethwa Thanks. Is there a way i can restart nrpe and icinga within container? For Ex: I wanted to pull the monitors from my git repo and when we add new alerts we need to reload icinga. Also if for any reason if we need to restart any services, only way is to restart the container? Thoughts.

from icinga2.

jjethwa avatar jjethwa commented on August 22, 2024

Hi @gvenka008c

Use docker exec:

sudo docker exec icinga2 service icinga2 reload

from icinga2.

gvenka008c avatar gvenka008c commented on August 22, 2024

@jjethwa

$ sudo docker exec icinga2 service icinga2 reload
exec: "service": executable file not found in $PATH

from icinga2.

jjethwa avatar jjethwa commented on August 22, 2024

Hi @gvenka008c

That's weird. It works on my containers. You're using the jordan/icinga2 image from Docker Hub?

from icinga2.

jjethwa avatar jjethwa commented on August 22, 2024
# sudo docker ps | grep icinga2
624739f4425d        jordan/icinga2:latest        "/opt/run"               2 weeks ago         Up 2 weeks          443/tcp, 0.0.0.0:80->80/tcp, 5665/tcp   icinga2
# sudo docker exec icinga2 service icinga2 status
icinga2 is running.
# sudo docker exec icinga2 service icinga2 reload
checking Icinga2 configuration.
icinga2 is running.
Reloading icinga2 monitoring daemon: icinga2.

from icinga2.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.