Here is a little reproducer I'm using.
apt update DEBIAN_FRONTEND=noninteractive apt-get -y --allow-unauthenticated -o Dpkg::Options::='--force-confold' install slapd ldap-utils
debconf-set-selections -v << EOF slapd slapd/domain string example.com slapd shared/organization string example slapd slapd/password1 password secret slapd slapd/password2 password secret EOF
rm -rf /var/backups/*slapd* /var/backups/unknown*ldapdb
# note slapd pid
pidof slapd
dpkg-reconfigure -fnoninteractive -pcritical slapd
# check if slapd was restarted pidof slapd
# also, this command should work # ldapwhoami -x -D cn=admin,dc=example,dc=com -w secret dn:cn=admin,dc=example,dc=com
I'm attaching set -x outputs from all slapd maintainer scripts during the reconfigure, in each case (proposed and release)
Here is a little reproducer I'm using.
apt update FRONTEND= noninteractive apt-get -y --allow- unauthenticated -o Dpkg::Options: :='--force- confold' install slapd ldap-utils
DEBIAN_
debconf- set-selections -v << EOF
slapd slapd/domain string example.com
slapd shared/organization string example
slapd slapd/password1 password secret
slapd slapd/password2 password secret
EOF
rm -rf /var/backups/ *slapd* /var/backups/ unknown* ldapdb
# note slapd pid
pidof slapd
dpkg-reconfigure -fnoninteractive -pcritical slapd
# check if slapd was restarted
pidof slapd
# also, this command should work dc=example, dc=com -w secret dc=example, dc=com
# ldapwhoami -x -D cn=admin,
dn:cn=admin,
I'm attaching set -x outputs from all slapd maintainer scripts during the reconfigure, in each case (proposed and release)