package slapd 2.4.21-0ubuntu5.1 failed to install/upgrade: subprocess installed post-installation script returned error exit status 143

Bug #611526 reported by Arjan
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
openldap (Ubuntu)
Expired
Medium
Unassigned

Bug Description

just did an apt-get update && apt-get update, and found my
Setting up slapd (2.4.21-0ubuntu5.1) ...
  Backing up /etc/ldap/slapd.d in /var/backups/slapd-2.4.21-0ubuntu5
hanging.

finllay i dit a killall slapd, en it got finished.

ubuntu 10.04 TL 64 bits

ProblemType: Package
DistroRelease: Ubuntu 10.04
Package: slapd 2.4.21-0ubuntu5.1
ProcVersionSignature: Ubuntu 2.6.32-24.38-generic 2.6.32.15+drm33.5
Uname: Linux 2.6.32-24-generic x86_64
NonfreeKernelModules: nvidia
Architecture: amd64
Date: Fri Jul 30 03:21:38 2010
ErrorMessage: subprocess installed post-installation script returned error exit status 143
SourcePackage: openldap
Title: package slapd 2.4.21-0ubuntu5.1 failed to install/upgrade: subprocess installed post-installation script returned error exit status 143

Revision history for this message
Arjan (iafilius) wrote :
Revision history for this message
Mathias Gug (mathiaz) wrote :

Could you check the content of /var/log/syslog and /var/log/daemon for messages related to slapd? Could you attach them to this bug?

Is slapd running now that the upgrade has finished?

Changed in openldap (Ubuntu):
importance: Undecided → Medium
status: New → Incomplete
Revision history for this message
Arjan (iafilius) wrote :

as requested some additional syslog:

arfi@arfi-laptop:/var/log$ grep -i slap syslog
Jul 30 03:01:53 arfi-laptop kernel: [10611.956583] type=1505 audit(1280451713.728:25): operation="profile_replace" pid=8306 name="/usr/sbin/slapd"
Jul 30 03:01:53 arfi-laptop slapd[8328]: @(#) $OpenLDAP: slapd 2.4.21 (Jul 28 2010 11:13:04) $#012#011buildd@crested:/build/buildd/openldap-2.4.21/debian/build/servers/slapd
Jul 30 03:01:54 arfi-laptop slapd[8328]: hdb_db_open: warning - no DB_CONFIG file found in directory /var/lib/ldap/access_log: (2).#012Expect poor performance for suffix "cn=accesslog".
Jul 30 03:01:54 arfi-laptop slapd[8328]: slapd starting
Jul 30 03:21:38 arfi-laptop slapd[8328]: daemon: shutdown requested and initiated.
Jul 30 03:21:38 arfi-laptop slapd[8328]: slapd shutdown: waiting for 0 operations/tasks to finish
Jul 30 03:21:38 arfi-laptop slapd[8328]: slapd stopped.
Jul 30 05:57:51 arfi-laptop kernel: [21151.348938] type=1505 audit(1280462271.549:26): operation="profile_replace" pid=9756 name="/usr/sbin/slapd"
Jul 30 05:57:51 arfi-laptop slapd[9778]: @(#) $OpenLDAP: slapd 2.4.21 (Jul 28 2010 11:13:04) $#012#011buildd@crested:/build/buildd/openldap-2.4.21/debian/build/servers/slapd
Jul 30 05:57:51 arfi-laptop slapd[9778]: hdb_db_open: warning - no DB_CONFIG file found in directory /var/lib/ldap/access_log: (2).#012Expect poor performance for suffix "cn=accesslog".
Jul 30 05:57:51 arfi-laptop slapd[9778]: slapd starting

additional note.

when i do an "apt-get upgrade" again, i get::
$ sudo apt-get upgrade
Reading package lists... Done
Building dependency tree
Reading state information... Done
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
1 not fully installed or removed.
After this operation, 0B of additional disk space will be used.
Do you want to continue [Y/n]? y
Setting up slapd (2.4.21-0ubuntu5.1) ...
  Backing up /etc/ldap/slapd.d in /var/backups/slapd-2.4.21-0ubuntu5... done.
Starting OpenLDAP: slapd

and it just keeps sitting/hanging there.

a ^C to interrupt doesn't work.

and also a manual:

$ sudo /etc/init.d/slapd start
Starting OpenLDAP: slapd

"hangs."

i'm not sure what changed, didn't do realy much with ldap, but i'm pretty sure it just started without problems

for some reason it looks just it won't start as daemon anymore.

how the proces is running:
 ps aux|grep slap
root 10073 0.0 0.0 4092 668 pts/3 S+ 06:11 0:00 /bin/sh /etc/init.d/slapd start
openldap 10075 0.1 11.0 2815744 437664 pts/3 Sl+ 06:11 0:00 /usr/sbin/slapd -h ldap:/// ldapi:/// -g openldap -u openldap -F /etc/ldap/slapd.d -d 256
arfi 10084 0.0 0.0 7620 916 pts/2 S+ 06:13 0:00 grep --color=auto slap

hope this might some light

regards,

Arjan Filius

Revision history for this message
Adam Sommer (asommer) wrote : Re: [Bug 611526] Re: package slapd 2.4.21-0ubuntu5.1 failed to install/upgrade: subprocess installed post-installation script returned error exit status 143

On Fri, Jul 30, 2010 at 12:15 AM, Arjan <email address hidden> wrote:

> as requested some additional syslog:
>
> arfi@arfi-laptop:/var/log$ grep -i slap syslog
> Jul 30 03:01:53 arfi-laptop kernel: [10611.956583] type=1505
> audit(1280451713.728:25): operation="profile_replace" pid=8306
> name="/usr/sbin/slapd"
> Jul 30 03:01:53 arfi-laptop slapd[8328]: @(#) $OpenLDAP: slapd 2.4.21 (Jul
> 28 2010 11:13:04) $#012#011buildd@crested
> :/build/buildd/openldap-2.4.21/debian/build/servers/slapd
> Jul 30 03:01:54 arfi-laptop slapd[8328]: hdb_db_open: warning - no
> DB_CONFIG file found in directory /var/lib/ldap/access_log: (2).#012Expect
> poor performance for suffix "cn=accesslog".
> Jul 30 03:01:54 arfi-laptop slapd[8328]: slapd starting
> Jul 30 03:21:38 arfi-laptop slapd[8328]: daemon: shutdown requested and
> initiated.
> Jul 30 03:21:38 arfi-laptop slapd[8328]: slapd shutdown: waiting for 0
> operations/tasks to finish
> Jul 30 03:21:38 arfi-laptop slapd[8328]: slapd stopped.
> Jul 30 05:57:51 arfi-laptop kernel: [21151.348938] type=1505
> audit(1280462271.549:26): operation="profile_replace" pid=9756
> name="/usr/sbin/slapd"
> Jul 30 05:57:51 arfi-laptop slapd[9778]: @(#) $OpenLDAP: slapd 2.4.21 (Jul
> 28 2010 11:13:04) $#012#011buildd@crested
> :/build/buildd/openldap-2.4.21/debian/build/servers/slapd
> Jul 30 05:57:51 arfi-laptop slapd[9778]: hdb_db_open: warning - no
> DB_CONFIG file found in directory /var/lib/ldap/access_log: (2).#012Expect
> poor performance for suffix "cn=accesslog".
> Jul 30 05:57:51 arfi-laptop slapd[9778]: slapd starting
>
>
>

Arjan, can you copy your /var/lib/ldap/DB_CONFIG to the
/var/lib/ldap/access_log directory? Also, make sure that the directory
exists, but I think it should or you'd have a different error.

Anyway, try:

  sudo cp /var/lib/ldap/DB_CONFIG /var/lib/ldap/access_log
  sudo /etc/init.d/slapd start

Thanks

--
Party On,
Adam

Revision history for this message
Mathias Gug (mathiaz) wrote : Re: [Bug 611526] Re: package slapd 2.4.21-0ubuntu5.1 failed to install/upgrade: subprocess installed post-installation script returned error exit status 143

Excerpts from Arjan's message of Fri Jul 30 04:15:11 UTC 2010:
>
> how the proces is running:
> ps aux|grep slap
> root 10073 0.0 0.0 4092 668 pts/3 S+ 06:11 0:00 /bin/sh /etc/init.d/slapd start
> openldap 10075 0.1 11.0 2815744 437664 pts/3 Sl+ 06:11 0:00 /usr/sbin/slapd -h ldap:/// ldapi:/// -g openldap -u openldap -F /etc/ldap/slapd.d -d 256

It seems that slapd is running with the debugging option set (-d 256) in
which case slapd won't fork in the background.

From the slapd manpage:

 -d debug-level

 Turn on debugging as defined by debug-level. If this option is
 specified, even with a zero argument, slapd will not fork or
 disassociate from the invoking terminal.

Could you try to not start slapd with debugging set?

--
Mathias Gug
Ubuntu Developer http://www.ubuntu.com

Revision history for this message
Arjan (iafilius) wrote :
Download full text (3.7 KiB)

Hi,

first of all, just started my laptop, again which runs the ldap, and noticed no hanging ldap startup, but also no running process.
tried by hand, bu no hangs, just an error (as below).

as requested, copied the DB_CONFIG file, i've seen this DB_CONFIG message
before, but for my purpose it didn;t matter much

now after coping (DB_CONFIG) i get:

root@arfi-laptop:/etc/init.d# /etc/init.d/slapd start
Starting OpenLDAP: slapd - failed:
@(#) $OpenLDAP: slapd 2.4.21 (Jul 28 2010 11:13:04) $
 buildd@crested:/build/buildd/openldap-2.4.21/debian/build/servers/slapd
daemon: bind(10) failed errno=2 (No such file or directory)
slapd stopped.
connections_destroy: nothing to destroy.
root@arfi-laptop:/etc/init.d#

my /var/log/syslog says:
Jul 30 18:35:42 arfi-laptop slapd[3860]: @(#) $OpenLDAP: slapd 2.4.21 (Jul 28 2010 11:13:04) $#012#011buildd@crested:/build/buildd/openldap-2.4.21/debian/build/servers/slapd
Jul 30 18:35:42 arfi-laptop rsyslogd: Could not open dynamic file '/tmp/allmessages' - discarding message
Jul 30 18:35:42 arfi-laptop slapd[3860]: daemon: bind(10) failed errno=2 (No such file or directory)
Jul 30 18:35:42 arfi-laptop slapd[3860]: slapd stopped.
Jul 30 18:35:42 arfi-laptop slapd[3860]: connections_destroy: nothing to destroy.

another tip, to disable debugging by emty-ing the SLAPD_OPTIONS= in /etc/default.slapd, results in a little other message:
root@arfi-laptop:/etc/init.d# /etc/init.d/slapd start
Starting OpenLDAP: slapd - failed.
The operation failed but no output was produced. For hints on what went
wrong please refer to the system's logfiles (e.g. /var/log/syslog) or
try running the daemon in Debug mode like via "slapd -d 16383" (warning:
this will create copious output).

Below, you can find the command line options used by this script to
run slapd. Do not forget to specify those options if you
want to look to debugging output:
  slapd -h 'ldap:/// ldapi:///' -g openldap -u openldap -F /etc/ldap/slapd.d
root@arfi-laptop:/etc/init.d#

now, debugging again but then manually:
root@arfi-laptop:/etc/init.d# slapd -h 'ldap:/// ldapi:///' -g openldap -u openldap -F /etc/ldap/slapd.d -d 16383
@(#) $OpenLDAP: slapd 2.4.21 (Jul 28 2010 11:13:04) $
 buildd@crested:/build/buildd/openldap-2.4.21/debian/build/servers/slapd
ldap_pvt_gethostbyname_a: host=arfi-laptop, r=0
daemon_init: ldap:/// ldapi:///
daemon_init: listen on ldap:///
daemon_init: listen on ldapi:///
daemon_init: 2 listeners to open...
ldap_url_parse_ext(ldap:///)
daemon: listener initialized ldap:///
ldap_url_parse_ext(ldapi:///)
daemon: bind(9) failed errno=2 (No such file or directory)
slap_open_listener: failed on ldapi:///
slapd stopped.
connections_destroy: nothing to destroy.
root@arfi-laptop:/etc/init.d#

so it looks like it will complain about the ldapi:///

after removing the ldapi:/// it just seems starting fine
root@arfi-laptop:/etc/init.d# slapd -h 'ldap:///' -g openldap -u openldap -F /etc/ldap/slapd.d
root@arfi-laptop:/etc/init.d# ps aux|grep slapd
openldap 3912 4.7 10.9 2751228 435380 ? Ssl 18:44 0:00 slapd -h ldap:/// -g openldap -u openldap -F /etc/ldap/slapd.d
root 3918 0.0 0.0 7620 932 pts/0 S+ 18:44 0:00 gre...

Read more...

Revision history for this message
Arjan (iafilius) wrote :

hi, additional note, the /var/run/slapd/ directory doesn't exists, but creating one manual seems not to change anything.

Revision history for this message
Mathias Gug (mathiaz) wrote :

Excerpts from Arjan's message of Fri Jul 30 17:18:26 UTC 2010:
> hi, additional note, the /var/run/slapd/ directory doesn't exists, but
> creating one manual seems not to change anything.
>

What's the error message when /var/run/slapd/ was created? Is there any
messages in /var/log/kern.log?

Was slapd running *before* the upgrade was started?

What changes were made to /etc/default/slapd?

--
Mathias Gug
Ubuntu Developer http://www.ubuntu.com

Revision history for this message
Launchpad Janitor (janitor) wrote :

[Expired for openldap (Ubuntu) because there has been no activity for 60 days.]

Changed in openldap (Ubuntu):
status: Incomplete → Expired
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.