[Pkg-openldap-devel] r634 - openldap/trunk-2.3/debian
Matthijs Mohlmann
active2-guest at costa.debian.org
Mon Mar 6 20:17:49 UTC 2006
Author: active2-guest
Date: 2006-03-06 20:17:46 +0000 (Mon, 06 Mar 2006)
New Revision: 634
Removed:
openldap/trunk-2.3/debian/libldap-2.2-7.README.Debian
Modified:
openldap/trunk-2.3/debian/changelog
openldap/trunk-2.3/debian/slapd.conf
openldap/trunk-2.3/debian/slapd.config
openldap/trunk-2.3/debian/slapd.install
openldap/trunk-2.3/debian/slapd.postinst
openldap/trunk-2.3/debian/slapd.postrm
openldap/trunk-2.3/debian/slapd.prerm
openldap/trunk-2.3/debian/slapd.scripts-common
openldap/trunk-2.3/debian/slapd.templates
Log:
* Added "exit 0" to the end of slapd.postrm and slapd.prerm
* Added tool-threads and sizelimit, documented them a little bit. And added
@BACKENDOPTIONS@ for bdb, hdb backend (Closes: #327808)
* hostname -d fails when no domain name is set.
* Removed parts of ldbm config.
* manual_configuration_wanted had 2 declarations in slapd.scripts-common,
renamed one to want_manual_configuration.
* Changed slapd.config to use want_manual_configuration.
* Added break_on_ldbm_to_bdb_migration_disagree function. (not yet in use)
* Removed the LDBM backend part from the template.
* Added a default DB_CONFIG to slapd.install (I think it's not needed anymore,
but for sure)
* Removed libldap-2.2-7.README.Debian, it's now libldap-2.3-0.README.Debian.
* Updated changelog.
Modified: openldap/trunk-2.3/debian/changelog
===================================================================
--- openldap/trunk-2.3/debian/changelog 2006-03-03 05:45:12 UTC (rev 633)
+++ openldap/trunk-2.3/debian/changelog 2006-03-06 20:17:46 UTC (rev 634)
@@ -28,13 +28,24 @@
* Updated French debconf translation (Closes: #320739)
* Updated Vietnamese debconf translation (Closes: #319706)
* Encode the organization to utf8 (Closes: #236097)
- * Disabled the LDBM backend.
+ * Disabled the LDBM backend. Break in preinstallation if user doesn't want
+ to migrate to BDB backend.
+ * Removed choice for LDBM backend from slapd templates. And some explanation
+ in that question about the LDBM backend.
+ * Add sizelimit and tool-threads and some documentation to slapd.conf
+ (Closes: #327808)
+ * slapd.scripts-common had two functions with the same name.
+ * Don't return a error message if hostname fails.
+ * Backup the config only once on upgrade.
+ * For new installations do not install a DB_CONFIG file but use the
+ slapd.conf as file for BDB/HDB configuration parameters. See: slapd-bdb(5)
+ * Added various "exit 0" to the installation scripts.
[ Steve Langasek ]
* debian/slapd.templates: Fix typo durin -> during; re-run
debconf-updatepo, fixing up the fuzzies (closes: #319596).
- -- Matthijs Mohlmann <matthijs at cacholong.nl> Sun, 26 Feb 2006 20:05:44 +0100
+ -- Matthijs Mohlmann <matthijs at cacholong.nl> Wed, 1 Mar 2006 00:33:24 +0100
openldap2.2 (2.2.26-4) unstable; urgency=low
Deleted: openldap/trunk-2.3/debian/libldap-2.2-7.README.Debian
===================================================================
--- openldap/trunk-2.3/debian/libldap-2.2-7.README.Debian 2006-03-03 05:45:12 UTC (rev 633)
+++ openldap/trunk-2.3/debian/libldap-2.2-7.README.Debian 2006-03-06 20:17:46 UTC (rev 634)
@@ -1,22 +0,0 @@
-Notes about Debian's libldap2 package
--------------------------------------
-
-It has been reported that using libnss-ldap can cause a failure to
-unmount /usr on system shutdown. The reason is that the nss module
-uses libldap from /usr and is used by the shell in the system
-scripts executed on shutdown/reboot.
-
-More precisely bash uses the getpwuid function to get the data of
-the current user which pulls in the nss modules which includes
-the ldap libraries if you are using that module.
-
-Possible solutions to this problem are:
-
-a) use another shell that does not utilize getpwuid for getting info
- about the current user (take dash for example).
-b) make sure that the nsswitch.conf is replaced by a version which does
- not mention ldap before the system is shut down (and have a startup
- script that installs the "full" version of that file).
-c) move the libraries to /lib (not recommended).
-
- -- Torsten Landschoff <torsten at debian.org> Mon, 30 Sep 2002 11:06:22 +0200
Modified: openldap/trunk-2.3/debian/slapd.conf
===================================================================
--- openldap/trunk-2.3/debian/slapd.conf 2006-03-03 05:45:12 UTC (rev 633)
+++ openldap/trunk-2.3/debian/slapd.conf 2006-03-06 20:17:46 UTC (rev 634)
@@ -31,6 +31,13 @@
modulepath /usr/lib/ldap
moduleload back_ at BACKEND@
+# The maximum number of entries that is returned for a search operation
+sizelimit 500
+
+# The tool-threads parameter sets the actual amount of cpu's that is used
+# for indexing.
+tool-threads 1
+
#######################################################################
# Specific Backend Directives for @BACKEND@:
# Backend specific directives apply to this backend until another
@@ -56,6 +63,8 @@
# Where the database file are physically stored for database #1
directory "/var/lib/ldap"
+ at BACKENDOPTIONS@
+
# Indexing options for database #1
index objectClass eq
Modified: openldap/trunk-2.3/debian/slapd.config
===================================================================
--- openldap/trunk-2.3/debian/slapd.config 2006-03-03 05:45:12 UTC (rev 633)
+++ openldap/trunk-2.3/debian/slapd.config 2006-03-06 20:17:46 UTC (rev 634)
@@ -11,7 +11,7 @@
# Create an initial directory on fresh install
if is_initial_configuration "$@"; then
- if ! manual_configuration_wanted; then
+ if ! want_manual_configuration; then
set_defaults_for_unseen_entries
query_initial_config
crypt_admin_pass
Modified: openldap/trunk-2.3/debian/slapd.install
===================================================================
--- openldap/trunk-2.3/debian/slapd.install 2006-03-03 05:45:12 UTC (rev 633)
+++ openldap/trunk-2.3/debian/slapd.install 2006-03-06 20:17:46 UTC (rev 634)
@@ -5,3 +5,4 @@
debian/lintian-overrides/slapd usr/share/lintian/overrides
debian/fix_ldif usr/share/slapd
debian/ldiftopasswd usr/share/slapd
+debian/DB_CONFIG usr/share/slapd
Modified: openldap/trunk-2.3/debian/slapd.postinst
===================================================================
--- openldap/trunk-2.3/debian/slapd.postinst 2006-03-03 05:45:12 UTC (rev 633)
+++ openldap/trunk-2.3/debian/slapd.postinst 2006-03-06 20:17:46 UTC (rev 634)
@@ -63,4 +63,6 @@
#DEBHELPER#
+exit 0
+
# vim: set sw=8 foldmethod=marker:
Modified: openldap/trunk-2.3/debian/slapd.postrm
===================================================================
--- openldap/trunk-2.3/debian/slapd.postrm 2006-03-03 05:45:12 UTC (rev 633)
+++ openldap/trunk-2.3/debian/slapd.postrm 2006-03-06 20:17:46 UTC (rev 634)
@@ -37,3 +37,6 @@
fi
#DEBHELPER#
+
+exit 0
+
Modified: openldap/trunk-2.3/debian/slapd.prerm
===================================================================
--- openldap/trunk-2.3/debian/slapd.prerm 2006-03-03 05:45:12 UTC (rev 633)
+++ openldap/trunk-2.3/debian/slapd.prerm 2006-03-06 20:17:46 UTC (rev 634)
@@ -60,4 +60,6 @@
#DEBHELPER#
+exit 0
+
# vim: set foldmethod=marker:
Modified: openldap/trunk-2.3/debian/slapd.scripts-common
===================================================================
--- openldap/trunk-2.3/debian/slapd.scripts-common 2006-03-03 05:45:12 UTC (rev 633)
+++ openldap/trunk-2.3/debian/slapd.scripts-common 2006-03-06 20:17:46 UTC (rev 634)
@@ -46,7 +46,6 @@
# to the more stable and better maintained BDB backend.
# Usage: configure_ldbm_to_bdb_migration
-
if [ -e "$SLAPD_CONF" ] && grep -qE \
-e '^moduleload[[:space:]]+back_ldbm' \
-e '^(database|backend)[[:space:]]+ldbm' \
@@ -59,6 +58,20 @@
fi
}
# }}}
+break_on_ldbm_to_bdb_migration_disagree() { # {{{
+ if [ -e "$SLAPD_CONF" ] && grep -qE \
+ -e '^moduleload[[:space:]]+back_ldbm' \
+ -e '^(database|backend)[[:space:]]+ldbm' \
+ "$SLAPD_CONF"; then
+ db_get slapd/migrate_ldbm_to_bdb
+ if [ "$RET" = "false" ]; then
+ db_fset slapd/migrate_ldbm_to_bdb seen false
+ return 1
+ fi
+ return 0
+ fi
+ return 0
+} # }}}
database_dumping_enabled() { # {{{
# Check if the user has enabled database dumping for the current situation.
# Return success if yes.
@@ -530,14 +543,13 @@
# Now that we created the new directory we don't need the passwords in the
# debconf database anymore. So wipe them.
wipe_admin_pass
- copy_example_DB_CONFIG /var/lib/ldap
}
# }}}
create_new_slapd_conf() { # {{{
# Creates a new slapd.conf for the suffix given
# Usage: create_new_slapd_conf <basedn> <backend>
- local basedn backend checkpoint conf_new conf_template
+ local basedn backend backendoptions checkpoint conf_new conf_template
basedn="$1"
backend="$2"
@@ -545,8 +557,9 @@
conf_template="/usr/share/slapd/slapd.conf"
# Checkpoint if using the BDB backend
- if [ "$backend" = "bdb" -o "$backend" = "hdb" ]; then
+ if [ "$backend" = "bdb" ] || [ "$backend" = "hdb" ]; then
checkpoint="checkpoint 512 30"
+ backendoptions="# For the Debian package we use 2MB as default but be sure to update this\n# value if you have plenty of RAM\ndbconfig set_cachesize 0 2097152 0\n\n# Sven Hartge reported that he had to set this value incredibly high\n# to get slapd running at all. See http:\/\/bugs.debian.org\/303057\n# for more information.\n\n# Number of objects that can be locked at the same time.\ndbconfig set_lk_max_objects 1500\n# Number of locks (both requested and granted)\ndbconfig set_lk_max_locks 1500\n# Number of lockers\ndbconfig set_lk_max_lockers 1500"
fi
conf_new=`mktemp -q ${SLAPD_CONF}.XXXXXX`
@@ -555,7 +568,8 @@
-e "s/@SUFFIX@/$basedn/g" \
-e "s/@ADMIN@/cn=admin,$basedn/g" \
-e "s/@CHECKPOINT@/$checkpoint/g" \
- -e "s/@BACKEND@/$backend/g"
+ -e "s/@BACKEND@/$backend/g" \
+ -e "s/@BACKENDOPTIONS@/$backendoptions/g"
install_new_slapd_conf "$conf_new"
echo "done." >&2
}
@@ -591,7 +605,7 @@
# Encode to utf8 and base64 encode the organization.
db_get shared/organization
- organization=`encode_base64 `encode_utf8 "$RET"``
+ organization=`encode_utf8 "$RET"`
db_get slapd/internal/adminpw
adminpass="$RET"
@@ -819,7 +833,11 @@
local conf_new
conf_new="$1"
- backup_config_once
+ # On install and remove we don't have to backup the configuration file. Only
+ # on upgrade.
+ if [ "$MODE" = "upgrade" ]; then
+ backup_config_once
+ fi
# Make sure we keep the permissions of an old slapd.conf
if [ -e "$SLAPD_CONF" ]; then
@@ -848,7 +866,7 @@
# Set up the defaults for our templates
set_defaults_for_unseen_entries() {
- DOMAIN=`hostname -d` || true
+ DOMAIN=`hostname -d 2>/dev/null` || true
if [ -z "$DOMAIN" ]; then DOMAIN='nodomain'; fi
db_fget slapd/domain seen
@@ -863,7 +881,7 @@
}
# Check if the user wants to configure slapd manually
-manual_configuration_wanted() {
+want_manual_configuration() {
db_input low slapd/no_configuration || true
db_go || true
db_get slapd/no_configuration
@@ -1060,7 +1078,7 @@
# our scripts.
# Usage: if supported_backend "backend"; then ... fi
- case "$1" in ldbm|bdb|hdb) return 0; esac
+ case "$1" in bdb|hdb) return 0; esac
return 1
}
Modified: openldap/trunk-2.3/debian/slapd.templates
===================================================================
--- openldap/trunk-2.3/debian/slapd.templates 2006-03-03 05:45:12 UTC (rev 633)
+++ openldap/trunk-2.3/debian/slapd.templates 2006-03-06 20:17:46 UTC (rev 634)
@@ -193,12 +193,12 @@
Template: slapd/backend
Type: select
-Choices: BDB, HDB, LDBM
+Choices: BDB, HDB
Default: BDB
_Description: Database backend to use:
- The BDB backend is the recommended choice of the OpenLDAP developers while
- support of the old LDBM backend is phasing out. When using the BDB backend
- make sure that you configure the underlying database for your requirements.
+ The BDB backend is the recommended choice of the OpenLDAP developers. When
+ When using the BDB backend make sure that you configure the underlying
+ database for your requirements.
Look into /usr/share/doc/slapd/README.DB_CONFIG.gz
.
HDB is the next generation of BDB which might replace it sometime in
More information about the Pkg-openldap-devel
mailing list