Gentoo Archives: gentoo-commits

From: Michael Orlitzky <mjo@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: net-analyzer/nagios-core/
Date: Sat, 31 Aug 2019 21:35:45
Message-Id: 1567287295.7e81910df1947a9b7968fffe52655438b1adbdc4.mjo@gentoo
1 commit: 7e81910df1947a9b7968fffe52655438b1adbdc4
2 Author: Michael Orlitzky <mjo <AT> gentoo <DOT> org>
3 AuthorDate: Sat Aug 31 20:23:00 2019 +0000
4 Commit: Michael Orlitzky <mjo <AT> gentoo <DOT> org>
5 CommitDate: Sat Aug 31 21:34:55 2019 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=7e81910d
7
8 net-analyzer/nagios-core: move localstatedir to /var/lib/nagios.
9
10 For whatever reason, the local state directory for nagios was
11 historically set to /var/nagios. The FHS (v3) states that local
12 application state should live under /var/lib instead, so this revision
13 sets it to /var/lib/nagios.
14
15 This could potentially be annoying to upgraders but is probably non-
16 fatal. The state directory holds logs and service status information
17 that can be regenerated if necessary. Doing so could lead to "extra"
18 service notifications, though. To mitigate this, a warning is emitted
19 telling upgraders how to migrate the state information if they choose
20 to do so.
21
22 Package-Manager: Portage-2.3.69, Repoman-2.3.16
23 Signed-off-by: Michael Orlitzky <mjo <AT> gentoo.org>
24
25 ...s-core-4.4.5-r1.ebuild => nagios-core-4.4.5-r2.ebuild} | 15 ++++++++++++++-
26 1 file changed, 14 insertions(+), 1 deletion(-)
27
28 diff --git a/net-analyzer/nagios-core/nagios-core-4.4.5-r1.ebuild b/net-analyzer/nagios-core/nagios-core-4.4.5-r2.ebuild
29 similarity index 91%
30 rename from net-analyzer/nagios-core/nagios-core-4.4.5-r1.ebuild
31 rename to net-analyzer/nagios-core/nagios-core-4.4.5-r2.ebuild
32 index fdfccca6aab..2fab4595e65 100644
33 --- a/net-analyzer/nagios-core/nagios-core-4.4.5-r1.ebuild
34 +++ b/net-analyzer/nagios-core/nagios-core-4.4.5-r2.ebuild
35 @@ -96,7 +96,7 @@ src_configure() {
36 econf ${myconf} \
37 --prefix=/usr \
38 --bindir=/usr/sbin \
39 - --localstatedir=/var/nagios \
40 + --localstatedir=/var/lib/nagios \
41 --sysconfdir=/etc/nagios \
42 --libexecdir=/usr/$(get_libdir)/nagios/plugins \
43 --with-cgibindir=/usr/$(get_libdir)/nagios/cgi-bin \
44 @@ -210,4 +210,17 @@ pkg_postinst() {
45 elog "filesystem. You can fix this by adding nagios into"
46 elog "the group wheel, but this is not recomended."
47 elog
48 +
49 + if [ -n "${REPLACING_VERSIONS}" ]; then
50 + ewarn "The local state directory for nagios has changed in v4.4.5,"
51 + ewarn "from ${EROOT}var/nagios to ${EROOT}var/lib/nagios. If you"
52 + ewarn "wish to migrate your state to the new location, first stop"
53 + ewarn "nagios and then run"
54 + ewarn ""
55 + ewarn " diff --recursive --brief ${EROOT}var/nagios ${EROOT}var/lib/nagios"
56 + ewarn ""
57 + ewarn "to identify any files that should be moved to the new"
58 + ewarn "location. They can simply be moved with \"mv\" before"
59 + ewarn "restarting nagios."
60 + fi
61 }