Make this Nagios compatible

Abierto
#63 5 comentarios 0 reacciones 0 asignados Ver en GitHub

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
5/5
Tiempo estimado
Más de una semana
Aptitud para principiantes
25/100
Tipo de issue
Nueva funcionalidad
Claridad
Necesita aclaración
Estado de actividad
Estancado
Stack tecnológico
powershell

Línea de trabajo

Comienza con el script de PowerShell existente y la documentación enlazada de la Nagios plugin API. Define cómo se asignan las comprobaciones a OK, WARNING, CRITICAL y UNKNOWN, incluidos los parámetros include/exclude propuestos y los escenarios de los controladores de dominio. Se considera terminado cuando el script devuelve una salida y códigos de salida compatibles con Nagios, con un comportamiento WARNING y CRITICAL configurable.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

enhancement

Hello

I think this is a great script. Really thorough checking.

That being said, I think it should be Nagios compatible (or even fork it, although sync issues might occur). The script should be ran from a domain controller.

You can read the entire documentation here: https://assets.nagios.com/downloads/nagioscore/docs/nagioscore/3/en/pluginapi.html but the TL;DR is that your last line should be:

Write-Host "Whatever you want Nagios to display as text"
exit $variableholdingexitcode # 0 for OK, 1 for WARNING, 2 for CRITICAL and 3 for UNKNOWN

$variableholdingexitcode should be:

0 - OK
1 - WARNING
2 - CRITICAL
3 - UNKNOWN

OK is obviously that all checks have gone fine.

I think WARNING and CRITICAL should be defined by you and/or the user. You can, for example, decide that if there are six domain controllers and two cannot be reached, it is a WARNING status but if it cannot reach four, it should be a CRITICAL.

Not being able to resolve DNS against DCs should be a CRITICAL automatically with no WARNING state possible.

etc, etc....

And the user should also be able to -IncludeAsWarnings and pass a string array with checks he wants to be warnings if they fail or -ExcludeAsWarnings with again a string array with check he wants to ignore if they fail

Same with -IncludeAsCritical and -ExcludeAsCritical

Also -CompletelyInclude and -CompletelyExclude

UNKNOWN is mainly if the script fails for some reason out of your control....Running it on a 2003 DC if it isnt supported, should return a UNKNOWN for example.

I hope this gives you some ideas and Im sure plently more with input with even better ideas.

Thanks!

Lenguaje dominante
PowerShell
Estrellas
654
Forks
77
Métricas de merge de PR
Sin PR fusionados en 30 d

Preparar el entorno

Este proyecto no incluye contenedor de desarrollo, Dockerfile ni guía de contribución, así que la configuración corre por tu cuenta: empieza por su README y consulta nuestra guía para la primera contribución para los pasos generales.

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de EvotecIT/Testimo

Todos los issues de EvotecIT/Testimo

Issues similares

Más issues de Observability & SRE

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.