Giter Club home page Giter Club logo

check_mandatory_services's Introduction

check_mandatory_services

Powershell script to check/change the status of services. For use with Icinga/NSClient++.

Show on Icinga Exchange.

What does this script do?

At first run, this Powershell script creates a snapshot of all running services in form of a .json file.

Every run after that it will check the currently running services against the snapshot and start services to change back to running.

Return codes

  • Returns 0 if every service from the list could be started or all needed services were already running.
  • Returns 2 if an error occured while starting a stopped service.

Logging

Every change and tried change in service state will be logged with a timestamp in a file called mansvc.log.

To Do

  • Add support for stopped services
  • Add exception messages to log
  • Add pretty logo to make README look cool :)

Usage (Standalone)

WIP

Usage (with Icinga2 (Nagios) & NSClient++)

  1. Download the script and move it into you're NSClient++ scripts folder
  2. Add a check definition into you're nsclient.cfg
  3. Restart the NSClient++ Service using services.msc
  4. Create a new service config on the Icinga2 Master
  5. Add the service to your host config
  6. Reload Icinga2 Service using service icinga2 reload

About

Made with โ™ฅ by aaronlyy

check_mandatory_services's People

Contributors

aaronlyy avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar

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.