diff options
author | Lorenz <12514511+RincewindsHat@users.noreply.github.com> | 2022-07-25 11:39:36 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-07-25 11:39:36 +0200 |
commit | 4ff0dfa44306c4e8a7dc46fcb1c508f7a191638b (patch) | |
tree | 4d4bcd647a832268907afda672c36bbdedecbc8a /doc | |
parent | cebb054091e9255b2e2e672b53a8aa4bd39608b4 (diff) | |
parent | 3ad5fe9d84138da1451429bfac3b9b4024393d25 (diff) | |
download | monitoring-plugins-4ff0dfa44306c4e8a7dc46fcb1c508f7a191638b.tar.gz |
Merge branch 'master' into dev/check_ssh-patches
Diffstat (limited to 'doc')
-rw-r--r-- | doc/developer-guidelines.sgml | 146 |
1 files changed, 73 insertions, 73 deletions
diff --git a/doc/developer-guidelines.sgml b/doc/developer-guidelines.sgml index 6f31f365..28674e05 100644 --- a/doc/developer-guidelines.sgml +++ b/doc/developer-guidelines.sgml | |||
@@ -13,7 +13,7 @@ | |||
13 | 13 | ||
14 | <pubdate>2013</pubdate> | 14 | <pubdate>2013</pubdate> |
15 | <title>Monitoring Plugins Development Guidelines</title> | 15 | <title>Monitoring Plugins Development Guidelines</title> |
16 | 16 | ||
17 | <revhistory> | 17 | <revhistory> |
18 | <revision> | 18 | <revision> |
19 | <revnumber>1796</revnumber> | 19 | <revnumber>1796</revnumber> |
@@ -72,14 +72,14 @@ | |||
72 | </section> | 72 | </section> |
73 | 73 | ||
74 | <section id="PlugOutput"><title>Plugin Output for Nagios</title> | 74 | <section id="PlugOutput"><title>Plugin Output for Nagios</title> |
75 | 75 | ||
76 | <para>You should always print something to STDOUT that tells if the | 76 | <para>You should always print something to STDOUT that tells if the |
77 | service is working or why it is failing. Try to keep the output short - | 77 | service is working or why it is failing. Try to keep the output short - |
78 | probably less that 80 characters. Remember that you ideally would like | 78 | probably less that 80 characters. Remember that you ideally would like |
79 | the entire output to appear in a pager message, which will get chopped | 79 | the entire output to appear in a pager message, which will get chopped |
80 | off after a certain length.</para> | 80 | off after a certain length.</para> |
81 | 81 | ||
82 | <para>As Nagios does not capture stderr output, you should only output to | 82 | <para>As Nagios does not capture stderr output, you should only output to |
83 | STDOUT and not print to STDERR.</para> | 83 | STDOUT and not print to STDERR.</para> |
84 | 84 | ||
85 | <section><title>Print only one line of text</title> | 85 | <section><title>Print only one line of text</title> |
@@ -101,7 +101,7 @@ | |||
101 | SERVICE STATUS: Information text | 101 | SERVICE STATUS: Information text |
102 | </literallayout> | 102 | </literallayout> |
103 | <para>However, note that this is not a requirement of the API, so you cannot depend on this | 103 | <para>However, note that this is not a requirement of the API, so you cannot depend on this |
104 | being an accurate reflection of the status of the service - the status should always | 104 | being an accurate reflection of the status of the service - the status should always |
105 | be determined by the return code.</para> | 105 | be determined by the return code.</para> |
106 | </section> | 106 | </section> |
107 | 107 | ||
@@ -148,7 +148,7 @@ | |||
148 | <para>Code and output should try to respect the 80x25 size of a | 148 | <para>Code and output should try to respect the 80x25 size of a |
149 | crt (remember when fixing stuff in the server room!)</para> | 149 | crt (remember when fixing stuff in the server room!)</para> |
150 | </section> | 150 | </section> |
151 | 151 | ||
152 | <section><title>Plugin Return Codes</title> | 152 | <section><title>Plugin Return Codes</title> |
153 | <para>The return codes below are based on the POSIX spec of returning | 153 | <para>The return codes below are based on the POSIX spec of returning |
154 | a positive value. Netsaint prior to v0.0.7 supported non-POSIX | 154 | a positive value. Netsaint prior to v0.0.7 supported non-POSIX |
@@ -157,11 +157,11 @@ | |||
157 | 157 | ||
158 | <para>Note: Some plugins will on occasion print on STDOUT that an error | 158 | <para>Note: Some plugins will on occasion print on STDOUT that an error |
159 | occurred and error code is 138 or 255 or some such number. These | 159 | occurred and error code is 138 or 255 or some such number. These |
160 | are usually caused by plugins using system commands and having not | 160 | are usually caused by plugins using system commands and having not |
161 | enough checks to catch unexpected output. Developers should include a | 161 | enough checks to catch unexpected output. Developers should include a |
162 | default catch-all for system command output that returns an UNKNOWN | 162 | default catch-all for system command output that returns an UNKNOWN |
163 | return code.</para> | 163 | return code.</para> |
164 | 164 | ||
165 | <table id="ReturnCodes"><title>Plugin Return Codes</title> | 165 | <table id="ReturnCodes"><title>Plugin Return Codes</title> |
166 | <tgroup cols="3"> | 166 | <tgroup cols="3"> |
167 | <thead> | 167 | <thead> |
@@ -175,20 +175,20 @@ | |||
175 | <row> | 175 | <row> |
176 | <entry align="center"><para>0</para></entry> | 176 | <entry align="center"><para>0</para></entry> |
177 | <entry valign="middle"><para>OK</para></entry> | 177 | <entry valign="middle"><para>OK</para></entry> |
178 | <entry><para>The plugin was able to check the service and it | 178 | <entry><para>The plugin was able to check the service and it |
179 | appeared to be functioning properly</para></entry> | 179 | appeared to be functioning properly</para></entry> |
180 | </row> | 180 | </row> |
181 | <row> | 181 | <row> |
182 | <entry align="center"><para>1</para></entry> | 182 | <entry align="center"><para>1</para></entry> |
183 | <entry valign="middle"><para>Warning</para></entry> | 183 | <entry valign="middle"><para>Warning</para></entry> |
184 | <entry><para>The plugin was able to check the service, but it | 184 | <entry><para>The plugin was able to check the service, but it |
185 | appeared to be above some "warning" threshold or did not appear | 185 | appeared to be above some "warning" threshold or did not appear |
186 | to be working properly</para></entry> | 186 | to be working properly</para></entry> |
187 | </row> | 187 | </row> |
188 | <row> | 188 | <row> |
189 | <entry align="center"><para>2</para></entry> | 189 | <entry align="center"><para>2</para></entry> |
190 | <entry valign="middle"><para>Critical</para></entry> | 190 | <entry valign="middle"><para>Critical</para></entry> |
191 | <entry><para>The plugin detected that either the service was not | 191 | <entry><para>The plugin detected that either the service was not |
192 | running or it was above some "critical" threshold</para></entry> | 192 | running or it was above some "critical" threshold</para></entry> |
193 | </row> | 193 | </row> |
194 | <row> | 194 | <row> |
@@ -207,7 +207,7 @@ | |||
207 | </tgroup> | 207 | </tgroup> |
208 | </table> | 208 | </table> |
209 | 209 | ||
210 | 210 | ||
211 | </section> | 211 | </section> |
212 | 212 | ||
213 | <section id="thresholdformat"><title>Threshold and ranges</title> | 213 | <section id="thresholdformat"><title>Threshold and ranges</title> |
@@ -218,7 +218,7 @@ | |||
218 | set_thresholds(thresholds *, char *, char *) function to set the thresholds. | 218 | set_thresholds(thresholds *, char *, char *) function to set the thresholds. |
219 | </para> | 219 | </para> |
220 | <para>The theory is that the plugin will do some sort of check which returns | 220 | <para>The theory is that the plugin will do some sort of check which returns |
221 | back a numerical value, or metric, which is then compared to the warning and | 221 | back a numerical value, or metric, which is then compared to the warning and |
222 | critical thresholds. Use the get_status(double, thresholds *) function to | 222 | critical thresholds. Use the get_status(double, thresholds *) function to |
223 | compare the value against the thresholds.</para> | 223 | compare the value against the thresholds.</para> |
224 | <para>This is the generalised format for ranges:</para> | 224 | <para>This is the generalised format for ranges:</para> |
@@ -226,14 +226,14 @@ | |||
226 | <literallayout> | 226 | <literallayout> |
227 | [@]start:end | 227 | [@]start:end |
228 | </literallayout> | 228 | </literallayout> |
229 | 229 | ||
230 | <para>Notes:</para> | 230 | <para>Notes:</para> |
231 | <orderedlist> | 231 | <orderedlist> |
232 | <listitem><para>start ≤ end</para> | 232 | <listitem><para>start ≤ end</para> |
233 | </listitem> | 233 | </listitem> |
234 | <listitem><para>start and ":" is not required if start=0</para> | 234 | <listitem><para>start and ":" is not required if start=0</para> |
235 | </listitem> | 235 | </listitem> |
236 | <listitem><para>if range is of format "start:" and end is not specified, | 236 | <listitem><para>if range is of format "start:" and end is not specified, |
237 | assume end is infinity</para> | 237 | assume end is infinity</para> |
238 | </listitem> | 238 | </listitem> |
239 | <listitem><para>to specify negative infinity, use "~"</para> | 239 | <listitem><para>to specify negative infinity, use "~"</para> |
@@ -245,7 +245,7 @@ | |||
245 | (inclusive of endpoints)</para> | 245 | (inclusive of endpoints)</para> |
246 | </listitem> | 246 | </listitem> |
247 | </orderedlist> | 247 | </orderedlist> |
248 | 248 | ||
249 | <para>Note: Not all plugins are coded to expect ranges in this format yet. | 249 | <para>Note: Not all plugins are coded to expect ranges in this format yet. |
250 | There will be some work in providing multiple metrics.</para> | 250 | There will be some work in providing multiple metrics.</para> |
251 | 251 | ||
@@ -344,7 +344,7 @@ | |||
344 | </listitem> | 344 | </listitem> |
345 | <listitem><para>label can contain any characters except the equals sign or single quote (')</para> | 345 | <listitem><para>label can contain any characters except the equals sign or single quote (')</para> |
346 | </listitem> | 346 | </listitem> |
347 | <listitem><para>the single quotes for the label are optional. Required if | 347 | <listitem><para>the single quotes for the label are optional. Required if |
348 | spaces are in the label</para> | 348 | spaces are in the label</para> |
349 | </listitem> | 349 | </listitem> |
350 | <listitem><para>label length is arbitrary, but ideally the first 19 characters | 350 | <listitem><para>label length is arbitrary, but ideally the first 19 characters |
@@ -353,7 +353,7 @@ | |||
353 | </listitem> | 353 | </listitem> |
354 | <listitem><para>to specify a quote character, use two single quotes</para> | 354 | <listitem><para>to specify a quote character, use two single quotes</para> |
355 | </listitem> | 355 | </listitem> |
356 | <listitem><para>warn, crit, min or max may be null (for example, if the threshold is | 356 | <listitem><para>warn, crit, min or max may be null (for example, if the threshold is |
357 | not defined or min and max do not apply). Trailing unfilled semicolons can be | 357 | not defined or min and max do not apply). Trailing unfilled semicolons can be |
358 | dropped</para> | 358 | dropped</para> |
359 | </listitem> | 359 | </listitem> |
@@ -363,12 +363,12 @@ | |||
363 | same UOM. value may be a literal "U" instead, this would indicate that the | 363 | same UOM. value may be a literal "U" instead, this would indicate that the |
364 | actual value couldn't be determined</para> | 364 | actual value couldn't be determined</para> |
365 | </listitem> | 365 | </listitem> |
366 | <listitem><para>warn and crit are in the range format (see | 366 | <listitem><para>warn and crit are in the range format (see |
367 | <xref linkend="thresholdformat">). Must be the same UOM</para> | 367 | <xref linkend="thresholdformat">). Must be the same UOM</para> |
368 | </listitem> | 368 | </listitem> |
369 | <listitem><para>UOM (unit of measurement) is one of:</para> | 369 | <listitem><para>UOM (unit of measurement) is one of:</para> |
370 | <orderedlist> | 370 | <orderedlist> |
371 | <listitem><para>no unit specified - assume a number (int or float) | 371 | <listitem><para>no unit specified - assume a number (int or float) |
372 | of things (eg, users, processes, load averages)</para> | 372 | of things (eg, users, processes, load averages)</para> |
373 | </listitem> | 373 | </listitem> |
374 | <listitem><para>s - seconds (also us, ms)</para></listitem> | 374 | <listitem><para>s - seconds (also us, ms)</para></listitem> |
@@ -385,9 +385,9 @@ | |||
385 | </section> | 385 | </section> |
386 | 386 | ||
387 | <section><title>Translations</title> | 387 | <section><title>Translations</title> |
388 | <para>If possible, use translation tools for all output to respect the user's language | 388 | <para>If possible, use translation tools for all output to respect the user's language |
389 | settings. See <xref linkend="translationsdevelopers"> for guidelines | 389 | settings. See <xref linkend="translationsdevelopers"> for guidelines |
390 | for the core plugins. | 390 | for the core plugins. |
391 | </para> | 391 | </para> |
392 | </section> | 392 | </section> |
393 | </section> | 393 | </section> |
@@ -436,7 +436,7 @@ | |||
436 | </section> | 436 | </section> |
437 | 437 | ||
438 | </section> | 438 | </section> |
439 | 439 | ||
440 | 440 | ||
441 | 441 | ||
442 | 442 | ||
@@ -447,17 +447,17 @@ | |||
447 | Perl Nagios (ePN) requires stricter use of the some of Perl's features. | 447 | Perl Nagios (ePN) requires stricter use of the some of Perl's features. |
448 | This section outlines some of the steps needed to use ePN | 448 | This section outlines some of the steps needed to use ePN |
449 | effectively.</para> | 449 | effectively.</para> |
450 | 450 | ||
451 | <orderedlist> | 451 | <orderedlist> |
452 | 452 | ||
453 | <listitem><para> Do not use BEGIN and END blocks since they will be called | 453 | <listitem><para> Do not use BEGIN and END blocks since they will be called |
454 | only once (when Nagios starts and shuts down) with Embedded Perl (ePN). In | 454 | only once (when Nagios starts and shuts down) with Embedded Perl (ePN). In |
455 | particular, do not use BEGIN blocks to initialize variables.</para> | 455 | particular, do not use BEGIN blocks to initialize variables.</para> |
456 | </listitem> | 456 | </listitem> |
457 | 457 | ||
458 | <listitem><para>To use utils.pm, you need to provide a full path to the | 458 | <listitem><para>To use utils.pm, you need to provide a full path to the |
459 | module in order for it to work.</para> | 459 | module in order for it to work.</para> |
460 | 460 | ||
461 | <literallayout> | 461 | <literallayout> |
462 | e.g. | 462 | e.g. |
463 | use lib "/usr/local/nagios/libexec"; | 463 | use lib "/usr/local/nagios/libexec"; |
@@ -467,24 +467,24 @@ | |||
467 | 467 | ||
468 | <listitem><para>Perl scripts should be called with "-w"</para> | 468 | <listitem><para>Perl scripts should be called with "-w"</para> |
469 | </listitem> | 469 | </listitem> |
470 | 470 | ||
471 | <listitem><para>All Perl plugins must compile cleanly under "use strict" - i.e. at | 471 | <listitem><para>All Perl plugins must compile cleanly under "use strict" - i.e. at |
472 | least explicitly package names as in "$main::x" or predeclare every | 472 | least explicitly package names as in "$main::x" or predeclare every |
473 | variable. </para> | 473 | variable. </para> |
474 | 474 | ||
475 | 475 | ||
476 | <para>Explicitly initialize each variable in use. Otherwise with | 476 | <para>Explicitly initialize each variable in use. Otherwise with |
477 | caching enabled, the plugin will not be recompiled each time, and | 477 | caching enabled, the plugin will not be recompiled each time, and |
478 | therefore Perl will not reinitialize all the variables. All old | 478 | therefore Perl will not reinitialize all the variables. All old |
479 | variable values will still be in effect.</para> | 479 | variable values will still be in effect.</para> |
480 | </listitem> | 480 | </listitem> |
481 | 481 | ||
482 | <listitem><para>Do not use >DATA< handles (these simply do not compile under ePN).</para> | 482 | <listitem><para>Do not use >DATA< handles (these simply do not compile under ePN).</para> |
483 | </listitem> | 483 | </listitem> |
484 | 484 | ||
485 | <listitem><para>Do not use global variables in named subroutines. This is bad practise anyway, but with ePN the | 485 | <listitem><para>Do not use global variables in named subroutines. This is bad practise anyway, but with ePN the |
486 | compiler will report an error "<global_var> will not stay shared ..". Values used by | 486 | compiler will report an error "<global_var> will not stay shared ..". Values used by |
487 | subroutines should be passed in the argument list.</para> | 487 | subroutines should be passed in the argument list.</para> |
488 | </listitem> | 488 | </listitem> |
489 | 489 | ||
490 | <listitem><para>If writing to a file (perhaps recording | 490 | <listitem><para>If writing to a file (perhaps recording |
@@ -492,8 +492,8 @@ | |||
492 | calls <emphasis role="strong">exit</emphasis>; that is caught by | 492 | calls <emphasis role="strong">exit</emphasis>; that is caught by |
493 | p1.pl, so output streams are never closed.</para> | 493 | p1.pl, so output streams are never closed.</para> |
494 | </listitem> | 494 | </listitem> |
495 | 495 | ||
496 | <listitem><para>As in <xref linkend="runtime"> all plugins need | 496 | <listitem><para>As in <xref linkend="runtime"> all plugins need |
497 | to monitor their runtime, specially if they are using network | 497 | to monitor their runtime, specially if they are using network |
498 | resources. Use of the <emphasis>alarm</emphasis> is recommended | 498 | resources. Use of the <emphasis>alarm</emphasis> is recommended |
499 | noting that some Perl modules (eg LWP) manage timers, so that an alarm | 499 | noting that some Perl modules (eg LWP) manage timers, so that an alarm |
@@ -507,9 +507,9 @@ | |||
507 | and then "exit $ERRORS{'OK'}" rather than "exit 0" | 507 | and then "exit $ERRORS{'OK'}" rather than "exit 0" |
508 | </para> | 508 | </para> |
509 | </listitem> | 509 | </listitem> |
510 | 510 | ||
511 | </orderedlist> | 511 | </orderedlist> |
512 | 512 | ||
513 | </section> | 513 | </section> |
514 | 514 | ||
515 | <section id="runtime"><title>Runtime Timeouts</title> | 515 | <section id="runtime"><title>Runtime Timeouts</title> |
@@ -524,14 +524,14 @@ | |||
524 | df could lock up like that. Plus, it should just be more error | 524 | df could lock up like that. Plus, it should just be more error |
525 | resistant to be able to time out rather than consume | 525 | resistant to be able to time out rather than consume |
526 | resources.</para> | 526 | resources.</para> |
527 | 527 | ||
528 | <section><title>Use DEFAULT_SOCKET_TIMEOUT</title> | 528 | <section><title>Use DEFAULT_SOCKET_TIMEOUT</title> |
529 | 529 | ||
530 | <para>All network plugins should use DEFAULT_SOCKET_TIMEOUT to timeout</para> | 530 | <para>All network plugins should use DEFAULT_SOCKET_TIMEOUT to timeout</para> |
531 | 531 | ||
532 | </section> | 532 | </section> |
533 | 533 | ||
534 | 534 | ||
535 | <section><title>Add alarms to network plugins</title> | 535 | <section><title>Add alarms to network plugins</title> |
536 | 536 | ||
537 | <para>If you write a plugin which communicates with another | 537 | <para>If you write a plugin which communicates with another |
@@ -543,16 +543,16 @@ | |||
543 | 543 | ||
544 | </section> | 544 | </section> |
545 | 545 | ||
546 | 546 | ||
547 | 547 | ||
548 | </section> | 548 | </section> |
549 | 549 | ||
550 | <section id="PlugOptions"><title>Plugin Options</title> | 550 | <section id="PlugOptions"><title>Plugin Options</title> |
551 | 551 | ||
552 | <para>A well written plugin should have --help as a way to get | 552 | <para>A well written plugin should have --help as a way to get |
553 | verbose help. Code and output should try to respect the 80x25 size of a | 553 | verbose help. Code and output should try to respect the 80x25 size of a |
554 | crt (remember when fixing stuff in the server room!)</para> | 554 | crt (remember when fixing stuff in the server room!)</para> |
555 | 555 | ||
556 | <section><title>Option Processing</title> | 556 | <section><title>Option Processing</title> |
557 | 557 | ||
558 | <para>For plugins written in C, we recommend the C standard | 558 | <para>For plugins written in C, we recommend the C standard |
@@ -585,11 +585,11 @@ | |||
585 | -p port or password (--port or --passwd/--password)monitors operational | 585 | -p port or password (--port or --passwd/--password)monitors operational |
586 | -u url or username (--url or --username) | 586 | -u url or username (--url or --username) |
587 | </literallayout> | 587 | </literallayout> |
588 | 588 | ||
589 | <para>Look at check_pgsql and check_procs to see how I currently | 589 | <para>Look at check_pgsql and check_procs to see how I currently |
590 | think this can work. Standard options are:</para> | 590 | think this can work. Standard options are:</para> |
591 | 591 | ||
592 | 592 | ||
593 | <para>The option -V or --version should be present in all | 593 | <para>The option -V or --version should be present in all |
594 | plugins. For C plugins it should result in a call to print_revision, a | 594 | plugins. For C plugins it should result in a call to print_revision, a |
595 | function in utils.c which takes two character arguments, the | 595 | function in utils.c which takes two character arguments, the |
@@ -603,7 +603,7 @@ | |||
603 | 603 | ||
604 | <para>The option -h or --help should be present in all plugins. | 604 | <para>The option -h or --help should be present in all plugins. |
605 | In C plugins, it should result in a call to print_help (or | 605 | In C plugins, it should result in a call to print_help (or |
606 | equivalent). The function print_help should call print_revision, | 606 | equivalent). The function print_help should call print_revision, |
607 | then print_usage, then should provide detailed | 607 | then print_usage, then should provide detailed |
608 | help. Help text should fit on an 80-character width display, but | 608 | help. Help text should fit on an 80-character width display, but |
609 | may run as many lines as needed.</para> | 609 | may run as many lines as needed.</para> |
@@ -666,7 +666,7 @@ | |||
666 | 666 | ||
667 | <para>As always, comments are welcome - making this consistent | 667 | <para>As always, comments are welcome - making this consistent |
668 | without a host of long options was quite a hassle, and I would | 668 | without a host of long options was quite a hassle, and I would |
669 | suspect that there are flaws in this strategy. | 669 | suspect that there are flaws in this strategy. |
670 | </para> | 670 | </para> |
671 | </section> | 671 | </section> |
672 | </section> | 672 | </section> |
@@ -678,7 +678,7 @@ create and update test cases where possible. | |||
678 | </para> | 678 | </para> |
679 | 679 | ||
680 | <para> | 680 | <para> |
681 | To run a test, from the top level directory, run "make test". This will run | 681 | To run a test, from the top level directory, run "make test". This will run |
682 | all the current tests and report an overall success rate. | 682 | all the current tests and report an overall success rate. |
683 | </para> | 683 | </para> |
684 | 684 | ||
@@ -697,7 +697,7 @@ This runs the test in a summary format. | |||
697 | </para> | 697 | </para> |
698 | 698 | ||
699 | <para> | 699 | <para> |
700 | For a good and amusing tutorial on using Test::More, see this | 700 | For a good and amusing tutorial on using Test::More, see this |
701 | <ulink url="http://search.cpan.org/dist/Test-Simple/lib/Test/Tutorial.pod"> | 701 | <ulink url="http://search.cpan.org/dist/Test-Simple/lib/Test/Tutorial.pod"> |
702 | link</ulink> | 702 | link</ulink> |
703 | </para> | 703 | </para> |
@@ -706,16 +706,16 @@ link</ulink> | |||
706 | 706 | ||
707 | <section><title>Testing the C library functions</title> | 707 | <section><title>Testing the C library functions</title> |
708 | <para> | 708 | <para> |
709 | We use <ulink url="http://jc.ngo.org.uk/trac-bin/trac.cgi/wiki/LibTap">the libtap library</ulink>, which gives | 709 | We use <ulink url="http://jc.ngo.org.uk/trac-bin/trac.cgi/wiki/LibTap">the libtap library</ulink>, which gives |
710 | perl's TAP | 710 | perl's TAP |
711 | (Test Anything Protocol) output. This is used by the FreeBSD team for their regression testing. | 711 | (Test Anything Protocol) output. This is used by the FreeBSD team for their regression testing. |
712 | </para> | 712 | </para> |
713 | 713 | ||
714 | <para> | 714 | <para> |
715 | To run tests using the libtap library, download the latest tar ball and extract. | 715 | To run tests using the libtap library, download the latest tar ball and extract. |
716 | There is a problem with tap-1.01 where | 716 | There is a problem with tap-1.01 where |
717 | <ulink url="http://jc.ngo.org.uk/trac-bin/trac.cgi/ticket/25">pthread support doesn't appear to work</ulink> | 717 | <ulink url="http://jc.ngo.org.uk/trac-bin/trac.cgi/ticket/25">pthread support doesn't appear to work</ulink> |
718 | properly on non-FreeBSD systems. Install with 'CPPFLAGS="-UHAVE_LIBPTHREAD" ./configure && make && make check && make install'. | 718 | properly on non-FreeBSD systems. Install with 'CPPFLAGS="-UHAVE_LIBPTHREAD" ./configure && make && make check && make install'. |
719 | </para> | 719 | </para> |
720 | 720 | ||
721 | <para> | 721 | <para> |
@@ -729,8 +729,8 @@ setup the tests. Run "make test" to run all the tests. | |||
729 | <para>See <ulink url="http://www.gnu.org/prep/standards_toc.html">GNU | 729 | <para>See <ulink url="http://www.gnu.org/prep/standards_toc.html">GNU |
730 | Coding standards</ulink> for general guidelines.</para> | 730 | Coding standards</ulink> for general guidelines.</para> |
731 | <section><title>C coding</title> | 731 | <section><title>C coding</title> |
732 | 732 | ||
733 | <para>Variables should be declared at the beginning of code blocks and | 733 | <para>Variables should be declared at the beginning of code blocks and |
734 | not inline because of portability with older compilers.</para> | 734 | not inline because of portability with older compilers.</para> |
735 | 735 | ||
736 | <para>You should use /* */ for comments and not // as some compilers | 736 | <para>You should use /* */ for comments and not // as some compilers |
@@ -745,8 +745,8 @@ setup the tests. Run "make test" to run all the tests. | |||
745 | <para>If you have copied a routine from another source, make sure the licence | 745 | <para>If you have copied a routine from another source, make sure the licence |
746 | from your source allows this. Add a comment referencing the ACKNOWLEDGEMENTS | 746 | from your source allows this. Add a comment referencing the ACKNOWLEDGEMENTS |
747 | file, where you can put more detail about the source.</para> | 747 | file, where you can put more detail about the source.</para> |
748 | <para>For contributed code, do not add any named credits in the source code | 748 | <para>For contributed code, do not add any named credits in the source code |
749 | - contributors should be added into the THANKS.in file instead. | 749 | - contributors should be added into the THANKS.in file instead. |
750 | </para> | 750 | </para> |
751 | </section> | 751 | </section> |
752 | 752 | ||
@@ -809,11 +809,11 @@ setup the tests. Run "make test" to run all the tests. | |||
809 | 809 | ||
810 | 810 | ||
811 | <section id="Contributedplugins"><title>Contributed plugins</title> | 811 | <section id="Contributedplugins"><title>Contributed plugins</title> |
812 | <para>Plugins that have been contributed to the project and | 812 | <para>Plugins that have been contributed to the project and |
813 | distributed with the Monitoring Plugins files are held in the contrib/ directory and are not installed | 813 | distributed with the Monitoring Plugins files are held in the contrib/ directory and are not installed |
814 | by default. These plugins are not officially supported by the team. | 814 | by default. These plugins are not officially supported by the team. |
815 | The current policy is that these plugins should be owned and maintained by the original | 815 | The current policy is that these plugins should be owned and maintained by the original |
816 | contributor, preferably hosted on <ulink url="http://monitoringexchange.org">Monitoring Exchange</ulink>. | 816 | contributor, preferably hosted on <ulink url="https://exchange.icinga.com/">Icinga Exchange</ulink>. |
817 | </para> | 817 | </para> |
818 | <para>If patches or bugs are raised to an contributed plugin, we will start communications with the | 818 | <para>If patches or bugs are raised to an contributed plugin, we will start communications with the |
819 | original contributor, but seek to remove the plugin from our distribution. | 819 | original contributor, but seek to remove the plugin from our distribution. |
@@ -824,11 +824,11 @@ setup the tests. Run "make test" to run all the tests. | |||
824 | 824 | ||
825 | <section id="Newplugins"><title>New plugins</title> | 825 | <section id="Newplugins"><title>New plugins</title> |
826 | <para>If you would like others to use your plugins, please add it to | 826 | <para>If you would like others to use your plugins, please add it to |
827 | the official 3rd party plugin repository, | 827 | the official 3rd party plugin repository, |
828 | <ulink url="http://monitoringexchange.org">Monitoring Exchange</ulink>. | 828 | <ulink url="https://exchange.icinga.com/">Icinga Exchange</ulink>. |
829 | </para> | 829 | </para> |
830 | 830 | ||
831 | <para>We are not accepting requests for inclusion of plugins into | 831 | <para>We are not accepting requests for inclusion of plugins into |
832 | our distribution at the moment, but when we do, these are the minimum | 832 | our distribution at the moment, but when we do, these are the minimum |
833 | requirements: | 833 | requirements: |
834 | </para> | 834 | </para> |
@@ -843,9 +843,9 @@ setup the tests. Run "make test" to run all the tests. | |||
843 | --timeout, --warning, --critical)</para> | 843 | --timeout, --warning, --critical)</para> |
844 | </listitem> | 844 | </listitem> |
845 | <listitem> | 845 | <listitem> |
846 | <para>It is determined to be not redundant (for instance, we would not | 846 | <para>It is determined to be not redundant (for instance, we would not |
847 | add a new version of check_disk just because someone had provide | 847 | add a new version of check_disk just because someone had provide |
848 | a plugin that had perf checking - we would incorporate the features | 848 | a plugin that had perf checking - we would incorporate the features |
849 | into an exisiting plugin)</para> | 849 | into an exisiting plugin)</para> |
850 | </listitem> | 850 | </listitem> |
851 | <listitem> | 851 | <listitem> |
@@ -857,7 +857,7 @@ setup the tests. Run "make test" to run all the tests. | |||
857 | utils (perl or c or sh) rather than using its own</para> | 857 | utils (perl or c or sh) rather than using its own</para> |
858 | </listitem> | 858 | </listitem> |
859 | <listitem> | 859 | <listitem> |
860 | <para>Includes patches to configure.in if required (via the EXTRAS list if | 860 | <para>Includes patches to configure.in if required (via the EXTRAS list if |
861 | it will only work on some platforms)</para> | 861 | it will only work on some platforms)</para> |
862 | </listitem> | 862 | </listitem> |
863 | <listitem> | 863 | <listitem> |
@@ -870,5 +870,5 @@ utils (perl or c or sh) rather than using its own</para> | |||
870 | 870 | ||
871 | </section> | 871 | </section> |
872 | </article> | 872 | </article> |
873 | 873 | ||
874 | </book> | 874 | </book> |