From cf9f4a2bece35725391560d65074feaa774b3599 Mon Sep 17 00:00:00 2001 From: Jan Šafránek Date: Oct 13 2008 11:30:59 +0000 Subject: - add SLAPD_SHUTDOWN_TIMEOUT to /etc/sysconfig/ldap, allowing admins to set non-default slapd shutdown timeout - add checkpoint to default slapd.conf file Resolves: #458679 --- diff --git a/ldap.init b/ldap.init index 42aa12a..289852d 100644 --- a/ldap.init +++ b/ldap.init @@ -30,6 +30,7 @@ SLAPD_LDAP="yes" SLAPD_LDAPI="no" SLAPD_LDAPS="no" +SLAPD_SHUTDOWN_TIMEOUT=3 # OPTIONS, SLAPD_OPTIONS and KTB5_KTNAME are not defined # Source an auxiliary options file if we have one @@ -188,7 +189,7 @@ function stop() { # Stop daemons. prog=`basename ${slapd}` echo -n $"Stopping $prog: " - killproc -p $pidfile ${slapd} + killproc -p $pidfile -d $SLAPD_SHUTDOWN_TIMEOUT ${slapd} RETVAL=$? [ $RETVAL -eq 0 ] && rm -f $lockfile /var/run/slapd.args echo diff --git a/ldap.sysconfig b/ldap.sysconfig index 4e45769..7b11b83 100644 --- a/ldap.sysconfig +++ b/ldap.sysconfig @@ -18,3 +18,6 @@ # Run slapd with -h "... ldaps:/// ..." # yes/no, default: no #SLAPD_LDAPS=no + +# Maximum allowed time to wait for slapd shutdown on 'service ldap stop' (in seconds) +#SLAPD_SHUTDOWN_TIMEOUT=3 diff --git a/openldap-2.4.6-config.patch b/openldap-2.4.6-config.patch index e4fd1ef..7c987a3 100644 --- a/openldap-2.4.6-config.patch +++ b/openldap-2.4.6-config.patch @@ -77,6 +77,7 @@ diff -up openldap-2.4.6/servers/slapd/slapd.conf.old openldap-2.4.6/servers/slap database bdb suffix "dc=my-domain,dc=com" ++checkpoint 1024 15 rootdn "cn=Manager,dc=my-domain,dc=com" # Cleartext passwords, especially for the rootdn, should -# be avoid. See slappasswd(8) and slapd.conf(5) for details. diff --git a/openldap.spec b/openldap.spec index d351411..c457376 100644 --- a/openldap.spec +++ b/openldap.spec @@ -8,7 +8,7 @@ Summary: The configuration files, libraries, and documentation for OpenLDAP Name: openldap Version: %{version} -Release: 1%{?dist} +Release: 2%{?dist} License: OpenLDAP Group: System Environment/Daemons Source0: ftp://ftp.OpenLDAP.org/pub/OpenLDAP/openldap-release/openldap-%{version}.tgz @@ -606,6 +606,11 @@ fi %attr(0644,root,root) %{evolution_connector_libdir}/*.a %changelog +* Mon Oct 13 2008 Jan Safranek 2.4.10-2 +- add SLAPD_SHUTDOWN_TIMEOUT to /etc/sysconfig/ldap, allowing admins + to set non-default slapd shutdown timeout +- add checkpoint to default slapd.conf file (#458679) + * Mon Jul 21 2008 Jan Safranek 2.4.10-1 - bump to ver. 2.4.10 to fix #455357 and #455073 - use new upgrade scripts from rawhide