Re: [Nagios-devel] Host Urgency Patch
Posted: Wed May 04, 2011 1:33 pm
This is a multi-part message in MIME format.
--------------030605080708060607060600
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
On 05/04/2011 02:18 PM, Jochen Bern wrote:
> On 05/04/2011 01:17 PM, Ton Voon wrote:
>> Hi Jochen,
>> Is it possible if you can create a test case for this? Hit the status.=
cgi
>> with this sortoption and then check that the hosts are ordered appropr=
iately?
>> There are some examples of tests in t/ that do similar tricks.
> Does a "nagios -v" do the nagios_user:nagios_group set[ug]id() stuff
> before starting the check? Because I work under a mode-750 /root while
> t/etc/nagios.cfg specifies nagios:nagios ...
Apparently it does; moving stuff over to ~nagios fixed "make test-perl"
at least. ("make test-tap" is lacking an appropriate configuration, but
it's operating outside the t/ subdir you referred me to, anyway.)
Additional t/ stuff in the attached tarfile (it's all *new* files, not
much sense in providing a "diff", is there?
, a verbose run gives:
> [nagios@nagios t]$ prove -v 611cgistatus-hosturgencies.t
> 611cgistatus-hosturgencies....1..3
> ok 1 - List of hosts sorted by ascending name
> ok 2 - List of hosts sorted by ascending status
> ok 3 - List of hosts sorted by descending urgency
> ok
> All tests successful.
> Files=3D1, Tests=3D3, 0 wallclock secs ( 0.06 cusr + 0.01 csys =3D 0=
.07 CPU)
Kind regards,
J. Bern
--=20
Jochen Bern, Systemingenieur --- LINworks GmbH
Postfach 100121, 64201 Darmstadt | Robert-Koch-Str. 9, 64331 Weiterstadt
PGP (1024D/4096g) FP =3D D18B 41B1 16C0 11BA 7F8C DCF7 E1D5 FAF4 444E 1C2=
7
Tel. +49 6151 9067-231, Zentr. -0, Fax -299 - Amtsg. Darmstadt HRB 85202
Unternehmenssitz Weiterstadt, Gesch=E4ftsf=FChrer Metin Dogan, Oliver Mic=
hel
--------------030605080708060607060600
Content-Type: application/x-compressed-tar;
name="nagios-3.2.3-HostUrgency-tests.tgz"
Content-Transfer-Encoding: base64
Content-Disposition: attachment; filename="nagios-3.2.3-HostUrgency-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y6xCTwAkj3jjCjeQCWAqf6mqF
8Lz78GnQ67SvxIfh9ZW4aw8/OBQDxm8hk5nDD/6kZTlQljNamcBXdUE74YBHGaYKT4Cozke6
hLEnEz4hjKexCOZyCkcg3GzF8Q37vblcwAlIB/57qUOiFuC3mK1M4MlwNEvm4Qgha1EoiqeH
FtFDM5NaMXL3/RfwWoAXQc6AW8FnuD6ZSSS+BpQWceQbhB7ewW73dUamsM0SoUCaqjTgl0AY
ADk5jh/Vft19vkwaizlJQ5lMcRTCduHHXjpXUUIftHSZarmYBZ4BevcmKG1Cep4ypgjMgui7
DABJiFwRMXS8cMAsSRZnh4fL5bI+X6FQ1L14bmlXgxMyEM0sTkOAUIGP5td7sL2KR4Lzpm/9
lsYQEwNulVSXmMLrmQmgRMPur8ODQfdm0Bv2PnbFh+7VnSMHxwhArERpCEEU6RJKOYb7GOZL
1IREfU4OjIoMBI2PhIUKFyKAN6xDAKQfGAjSV0BTlMt5zMGCIy6S/yOiZc5EA8IlWC3HyKkn
h9PRsNr9NGG1ip5dXAFSLUf25QgftRpWu7o35xA4icGwPewOxO0dGpLnUAfZQ6mH33Py55iB
fUCElmoMZwTwOT2RHptIiooOjdKPAYgCS/FMAoRIw5VK4CAF9gizNDQVZWqEClc+e0S+nU5j
SALkUjANIIxnsNfoNpf64bXHAnp4MCiOJRolj6MFh3YjpkqrWWHCtu+HH7o3Q7BcZJrvB+3L
7hpdkR86Dp8IVFKyvph2omVF1UrhVZQEVrlhW+Roj8ElWWUyS4wK0AAIP6fFNYAbTliCV0AM
QKPmQZLgLvxVWjNiVRPZtdAxaiysACUml9Z3boDMSEntyTIoyKIBhiWtQVCB8v+0kMb6wbyh
U24grj8TvQQNjETXEoYr8XYs/bcCDLTEk6zol8+oiTQCCUck0J5QugsnazWPHxEN/KhFhRx1
1Zv
...[email truncated]...
This post was automatically imported from historical nagios-devel mailing list archives
Original poster: [email protected]
--------------030605080708060607060600
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
On 05/04/2011 02:18 PM, Jochen Bern wrote:
> On 05/04/2011 01:17 PM, Ton Voon wrote:
>> Hi Jochen,
>> Is it possible if you can create a test case for this? Hit the status.=
cgi
>> with this sortoption and then check that the hosts are ordered appropr=
iately?
>> There are some examples of tests in t/ that do similar tricks.
> Does a "nagios -v" do the nagios_user:nagios_group set[ug]id() stuff
> before starting the check? Because I work under a mode-750 /root while
> t/etc/nagios.cfg specifies nagios:nagios ...
Apparently it does; moving stuff over to ~nagios fixed "make test-perl"
at least. ("make test-tap" is lacking an appropriate configuration, but
it's operating outside the t/ subdir you referred me to, anyway.)
Additional t/ stuff in the attached tarfile (it's all *new* files, not
much sense in providing a "diff", is there?
> [nagios@nagios t]$ prove -v 611cgistatus-hosturgencies.t
> 611cgistatus-hosturgencies....1..3
> ok 1 - List of hosts sorted by ascending name
> ok 2 - List of hosts sorted by ascending status
> ok 3 - List of hosts sorted by descending urgency
> ok
> All tests successful.
> Files=3D1, Tests=3D3, 0 wallclock secs ( 0.06 cusr + 0.01 csys =3D 0=
.07 CPU)
Kind regards,
J. Bern
--=20
Jochen Bern, Systemingenieur --- LINworks GmbH
Postfach 100121, 64201 Darmstadt | Robert-Koch-Str. 9, 64331 Weiterstadt
PGP (1024D/4096g) FP =3D D18B 41B1 16C0 11BA 7F8C DCF7 E1D5 FAF4 444E 1C2=
7
Tel. +49 6151 9067-231, Zentr. -0, Fax -299 - Amtsg. Darmstadt HRB 85202
Unternehmenssitz Weiterstadt, Gesch=E4ftsf=FChrer Metin Dogan, Oliver Mic=
hel
--------------030605080708060607060600
Content-Type: application/x-compressed-tar;
name="nagios-3.2.3-HostUrgency-tests.tgz"
Content-Transfer-Encoding: base64
Content-Disposition: attachment; filename="nagios-3.2.3-HostUrgency-tests.tgz"
H4sIAABiwU0AA+w8a3Mix7X+Gn5Fr+SK0BZCoJVkRzauYhHSEusVQGvvJ9LMNDDRMIO7Z8SS
X5/z6J4HAkm+u8n1vRUlZUsz3T3n/W4nh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3GzF8Q37vblcwAlIB/57qUOiFuC3mK1M4MlwNEvm4Qgha1EoiqeH
FtFDM5NaMXL3/RfwWoAXQc6AW8FnuD6ZSSS+BpQWceQbhB7ewW73dUamsM0SoUCaqjTgl0AY
ADk5jh/Vft19vkwaizlJQ5lMcRTCduHHXjpXUUIftHSZarmYBZ4BevcmKG1Cep4ypgjMgui7
DABJiFwRMXS8cMAsSRZnh4fL5bI+X6FQ1L14bmlXgxMyEM0sTkOAUIGP5td7sL2KR4Lzpm/9
lsYQEwNulVSXmMLrmQmgRMPur8ODQfdm0Bv2PnbFh+7VnSMHxwhArERpCEEU6RJKOYb7GOZL
1IREfU4OjIoMBI2PhIUKFyKAN6xDAKQfGAjSV0BTlMt5zMGCIy6S/yOiZc5EA8IlWC3HyKkn
h9PRsNr9NGG1ip5dXAFSLUf25QgftRpWu7o35xA4icGwPewOxO0dGpLnUAfZQ6mH33Py55iB
fUCElmoMZwTwOT2RHptIiooOjdKPAYgCS/FMAoRIw5VK4CAF9gizNDQVZWqEClc+e0S+nU5j
SALkUjANIIxnsNfoNpf64bXHAnp4MCiOJRolj6MFh3YjpkqrWWHCtu+HH7o3Q7BcZJrvB+3L
7hpdkR86Dp8IVFKyvph2omVF1UrhVZQEVrlhW+Roj8ElWWUyS4wK0AAIP6fFNYAbTliCV0AM
QKPmQZLgLvxVWjNiVRPZtdAxaiysACUml9Z3boDMSEntyTIoyKIBhiWtQVCB8v+0kMb6wbyh
U24grj8TvQQNjETXEoYr8XYs/bcCDLTEk6zol8+oiTQCCUck0J5QugsnazWPHxEN/KhFhRx1
1Zv
...[email truncated]...
This post was automatically imported from historical nagios-devel mailing list archives
Original poster: [email protected]