Changeset 265
- Timestamp:
- Jun 26, 2018, 6:54:14 PM (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/nagios-velvice/velvice.cgi
r264 r265 15 15 use strict; 16 16 use warnings; 17 use version; our $VERSION = version->declare('0.7. 2');17 use version; our $VERSION = version->declare('0.7.3'); 18 18 19 19 use CGI; … … 304 304 velvice.cgi - nagios velvice alert panel 305 305 306 =head1 USAGE 307 308 velvice.cgi 309 velvice.cgi?check=XXX 310 306 311 307 312 =head1 DESCRIPTION 308 313 309 314 Nagios VELVICE is an acronym for "Nagios leVEL serVICE status". 310 Homepage: http://servforge.legi.grenoble-inp.fr/projects/soft-trokata/wiki/SoftWare/NagiosVelvice 311 312 =head1 AUTHORS 313 314 Written by Gabriel Moreau - Grenoble - France 315 316 The Nagios web page is sometimes very graphically charged 317 and does not necessarily contain the information you need at a glance. 318 For example, it is quite complicated to restart controls on multiple hosts in one click. 319 320 For example, a server that is down should take only one line and not one per service... 321 Similarly, a service that has been down for 5 minutes or since yesterday 322 has more weight than a service that has fallen for 15 days. 323 324 With Velvice Panel, a broken down server takes only one line. 325 Services that have been falling for a long time gradually lose their color and become pastel colors. 326 327 With Velvice Panel, it is possible through a single click 328 to redo a check of all services that are in the CRITICAL state. 329 Similarly, it is possible to restart a check on all SSH services in breakdowns ... 330 In order not to clog the Nagios server, checks are shifted by 2 seconds in time. 331 332 There is also a link to the web page of the main Nagios server. 333 For each computer, you have a direct link to its dedicated web page on this server. 334 335 336 =head1 CONFIGURATION FILE SPECIFICATION 337 338 The configuration file must be F</etc/nagios3/velvice.yml>. 339 This is not a required file. 340 The file is in YAML format because this is a human-readable text file style. 341 Other formats could have been Plain XML, RDF, JSON... but they are much less readable. 342 343 You can find in the software nagios-velvice an example of configuration: 344 L<velvice.sample.yml|http://servforge.legi.grenoble-inp.fr/pub/soft-trokata/nagios-velvice/velvice.sample.yml>. 345 This one is in fact the master reference specification! 346 347 The main keys C<nagios-server> and C<color-downtime> have good default values. 348 No secondary key is required... 349 350 With key C<host-mapping>, 351 it's good to map C<localhost> to the real name of the computer (hostname). 352 353 The only important key is C<remote-action>. 354 You can affiliate as many subkeys as you want. 355 Let's take an example: 356 357 remote-action: 358 oom-killer: 359 regex: ^OOM Killer 360 title: OOM Killer 361 command: tssh -c 'sudo rm /var/lib/nagios3/nagios_oom_killer.log' %m 362 command-one: ssh %m 'sudo rm /var/lib/nagios3/nagios_oom_killer.log' 363 depend: ^SSH 364 status: ALL 365 style: bold 366 367 C<oom-killer> is just a key for your remote action. 368 The regex is used to find which service has a problem... 369 The title is use in the result web page (not mandatory - otherwise, it will be C<Action: oom-killer>). 370 The C<command> is just written on this web page. 371 You have the responsibility to copy / cut it on a terminal. 372 For security reasons, the nagios server does not have the right to launch the command on the remote host. 373 The wildcard C<%m> is replaced by the list of the host (separated by the space). 374 Sometime, the command could be different if there is only one computer (just SSH and no parallel SSH). 375 If your command is based on SSH, 376 you can have an SSH action only if the remote SSH is running. 377 So you can make the remote action depend on the SSH service through a regular expression of your choice. 378 379 The last two keys. 380 The C<status> key is for CRITICAL or WARNING (or ALL). 381 The key C<style> is there to mark in bold the service in error on the web page. 382 383 =head1 SEE ALSO 384 385 yamllint(1), ysh(1), YAML, Nagios::StatusLog, Color::Calc 386 387 In Debian GNU/Linux distribution, packages for C<yamllint> and C<ysh> are: 388 389 =over 390 391 =item * C<yamllint> - Linter for YAML files (Python) 392 393 =item * C<libyaml-shell-perl> - YAML test shell (Perl) 394 395 =back 396 397 398 Own project ressources: 399 400 =over 401 402 =item * L<Web site|http://servforge.legi.grenoble-inp.fr/projects/soft-trokata/wiki/SoftWare/NagiosVelvice> 403 404 =item * L<Online Manual|http://servforge.legi.grenoble-inp.fr/pub/soft-trokata/nagios-velvice/velvice.html> 405 406 =item * L<SVN repository|http://servforge.legi.grenoble-inp.fr/svn/soft-trokata/trunk/nagios-velvice> 407 408 =back 409 410 411 =head1 VERSION 412 413 $Id: klask 397 2018-02-28 18:53:47Z g7moreau $ 414 415 416 =head1 AUTHOR 417 418 Written by Gabriel Moreau <Gabriel.Moreau(A)univ-grenoble-alpes.fr>, LEGI UMR 5519, CNRS, Grenoble - France 315 419 316 420 … … 319 423 Licence GNU GPL version 2 or later and Perl equivalent 320 424 321 Copyright (C) 2014-2018 Gabriel Moreau <Gabriel.Moreau(A)univ-grenoble-alpes.fr>.425 Copyright (C) 2014-2018, LEGI UMR 5519 / CNRS UGA G-INP, Grenoble, France
Note: See TracChangeset
for help on using the changeset viewer.