Skip to content

Commit 8a6977e

Browse files
committed
rrd: apply patch for nagios
Change-Id: I58d14ff73e43149b15f05f269877e48f97c7feb3
1 parent a5aeaa7 commit 8a6977e

5 files changed

Lines changed: 16 additions & 10 deletions

File tree

omd/packages/nagios/patches/README

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -51,11 +51,3 @@ Index of patches
5151
Adding triggered downtime for child hosts causes a SIGSEGV on
5252
restart/reload
5353
http://sourceforge.net/p/nagios/nagioscore/ci/76310176f3ec9a37b0b4161dddbbea69b6fa6a73/
54-
55-
0011:
56-
Prevent creation of invalid RRD files when the RRD filename exceeds the
57-
filesystem PC_NAME_MAX limit. rrd_create.c appends "XXXXXX" to the filename
58-
for a temp file, so the filename plus 6 bytes must fit within PC_NAME_MAX.
59-
If the limit would be exceeded, data2rrd logs a warning and returns early
60-
instead of letting the RRD backend fail silently or corrupt state.
61-

omd/packages/nagios/patches/0011-prevent-creation-invalid-rrd-files.dif renamed to omd/packages/pnp4nagios/patches/0001-prevent-creation-invalid-rrd-files.dif

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
--- pnp4nagios-0.6.26/share/pnp/process_perfdata.pl
2-
+++ /tmp/process_perfdata.pl
1+
--- a/scripts/process_perfdata.pl.in
2+
+++ b/scripts/process_perfdata.pl.in
33
@@ -409,6 +409,36 @@
44
my @rrd_state = ();
55
my $rrd_storage_type;

omd/packages/pnp4nagios/patches/BUILD

Whitespace-only changes.
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
Index of patches
2+
3+
0001:
4+
Prevent creation of invalid RRD files when the RRD filename exceeds the
5+
filesystem PC_NAME_MAX limit. rrd_create.c appends "XXXXXX" to the filename
6+
for a temp file, so the filename plus 6 bytes must fit within PC_NAME_MAX.
7+
If the limit would be exceeded, data2rrd logs a warning and returns early
8+
instead of letting the RRD backend fail silently or corrupt state.
9+

omd/packages/pnp4nagios/pnp4nagios_http.bzl

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,11 @@ def pnp4nagios_workspace():
1010
name = "pnp4nagios",
1111
build_file = "@omd_packages//omd/packages/pnp4nagios:BUILD.pnp4nagios.bazel",
1212
strip_prefix = "pnp4nagios-" + version_str,
13+
patches = [
14+
"//omd/packages/pnp4nagios/patches:0001-prevent-creation-invalid-rrd-files.dif",
15+
],
16+
patch_args = ["-p1"],
17+
patch_tool = "patch",
1318
urls = [
1419
UPSTREAM_MIRROR_URL + filename,
1520
"https://sourceforge.net/projects/pnp4nagios/files/PNP-0.6/" + filename,

0 commit comments

Comments
 (0)