rpms/net-snmp/devel net-snmp-5.1.2-dir-fix.patch, 1.2, 1.3 net-snmp.spec, 1.182, 1.183
Jan Šafránek
jsafrane at fedoraproject.org
Wed Jul 1 13:53:01 UTC 2009
Author: jsafrane
Update of /cvs/pkgs/rpms/net-snmp/devel
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv5407
Modified Files:
net-snmp-5.1.2-dir-fix.patch net-snmp.spec
Log Message:
move local state file from /var/net-snmp/ to /var/lib/net-snmp
net-snmp-5.1.2-dir-fix.patch:
Index: net-snmp-5.1.2-dir-fix.patch
===================================================================
RCS file: /cvs/pkgs/rpms/net-snmp/devel/net-snmp-5.1.2-dir-fix.patch,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -p -r1.2 -r1.3
--- net-snmp-5.1.2-dir-fix.patch 25 Jul 2008 11:03:32 -0000 1.2
+++ net-snmp-5.1.2-dir-fix.patch 1 Jul 2009 13:53:01 -0000 1.3
@@ -1,3 +1,5 @@
+Assume that the configuration is in /etc/snmp, instead of /usr/share/snmp
+
diff -up net-snmp-5.4.1/net-snmp-config.in.backup_patch_6 net-snmp-5.4.1/net-snmp-config.in
--- net-snmp-5.4.1/net-snmp-config.in.backup_patch_6 2007-06-30 00:18:27.000000000 +0200
+++ net-snmp-5.4.1/net-snmp-config.in 2008-07-25 12:53:19.000000000 +0200
Index: net-snmp.spec
===================================================================
RCS file: /cvs/pkgs/rpms/net-snmp/devel/net-snmp.spec,v
retrieving revision 1.182
retrieving revision 1.183
diff -u -p -r1.182 -r1.183
--- net-snmp.spec 1 Jul 2009 12:59:46 -0000 1.182
+++ net-snmp.spec 1 Jul 2009 13:53:01 -0000 1.183
@@ -203,7 +203,7 @@ MIBS="$MIBS ucd-snmp/lmsensorsMib"
%endif
--with-sys-location="Unknown" \
--with-logfile="/var/log/snmpd.log" \
- --with-persistent-directory="/var/net-snmp" \
+ --with-persistent-directory="/var/lib/net-snmp" \
--with-mib-modules="$MIBS" \
%if %{tcp_wrappers}
--with-libwrap=%{_libdir} \
@@ -278,6 +278,8 @@ install -m 644 %{SOURCE4} ${RPM_BUILD_RO
install -d ${RPM_BUILD_ROOT}%{_bindir}
install -m 755 %SOURCE5 ${RPM_BUILD_ROOT}%{_bindir}/ucd5820stat
+install -d ${RPM_BUILD_ROOT}%{_localstatedir}/lib/net-snmp
+
rm -f ${RPM_BUILD_ROOT}%{_bindir}/snmpinform
rm -f ${RPM_BUILD_ROOT}%{_bindir}/snmpcheck
rm -f ${RPM_BUILD_ROOT}%{_mandir}/man1/snmpconf.1*
@@ -328,6 +330,9 @@ dd bs=1024 count=250 if=ChangeLog of=Cha
/sbin/chkconfig --add snmpd
/sbin/chkconfig --add snmptrapd
+# move local state files from /var/net-snmp to new location when updating the package
+mv %{_localstatedir}/net-snmp/* %{_localstatedir}/lib/net-snmp/ &>/dev/null
+
%preun
if [ $1 = 0 ]; then
service snmpd stop >/dev/null 2>&1
@@ -373,6 +378,7 @@ rm -rf ${RPM_BUILD_ROOT}
%attr(0644,root,root) %{_mandir}/man5/variables*
%dir %{_datadir}/snmp
%{_datadir}/snmp/snmpconf-data
+%dir %{_localstatedir}/lib/net-snmp
%files utils
%defattr(-,root,root,-)
@@ -425,6 +431,7 @@ rm -rf ${RPM_BUILD_ROOT}
%changelog
* Wed Jul 1 2009 Jan Safranek <jsafranek at redhat.com> 5.4.2.1-13
- package cleanup, remove unnecessary patches
+- move local state file from /var/net-snmp/ to /var/lib/net-snmp
* Wed Jul 1 2009 Jan Safranek <jsafranek at redhat.com> 5.4.2.1-12
- make the default configuration less noisy, i.e. do not print "Connection from
More information about the fedora-extras-commits
mailing list