Bug 44650 - Memberserver upgrade to 4.2 failed during post-installation script of slapd
Memberserver upgrade to 4.2 failed during post-installation script of slapd
Status: CLOSED FIXED
Product: UCS
Classification: Unclassified
Component: Update - Release updates
UCS 4.2
Other Linux
: P5 normal (vote)
: UCS 4.2-0-errata
Assigned To: Felix Botner
Philipp Hahn
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2017-05-22 16:20 CEST by Tobias Birkefeld
Modified: 2017-06-07 15:22 CEST (History)
2 users (show)

See Also:
What kind of report is it?: Bug Report
What type of bug is this?: 7: Crash: Bug causes crash or data loss
Who will be affected by this bug?: 2: Will only affect a few installed domains
How will those affected feel about the bug?: 5: Blocking further progress on the daily work
User Pain: 0.400
Enterprise Customer affected?:
School Customer affected?: Yes
ISV affected?:
Waiting Support:
Flags outvoted (downgraded) after PO Review:
Ticket number: 2017050921000234
Bug group (optional):
Max CVSS v3 score:


Attachments
updater.log (3.20 MB, text/x-log)
2017-05-22 16:20 CEST, Tobias Birkefeld
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Tobias Birkefeld univentionstaff 2017-05-22 16:20:53 CEST
Created attachment 8868 [details]
updater.log

Following error occurred during upgrade:

slapd (2.4.42+dfsg-2.A~4.2.0.201703081826) wird eingerichtet ...
  Backing up /etc/ldap/slapd.d in /var/backups/slapd-2.4.42+dfsg-2.219.201612021613... done.
  Moving old database directories to /var/backups:
  - directory dc=unassigned-domain... done.
  Loading from /var/backups/slapd-2.4.42+dfsg-2.219.201612021613: 
  - directory dc=unassigned-domain... failed.

Loading the database from the LDIF dump failed with the following
error while running slapadd:
    /var/backups/slapd-2.4.42+dfsg-2.219.201612021613/dc=unassigned-domain.ldif: No such file or directory
dpkg: Fehler beim Bearbeiten des Paketes slapd (--configure):
 Unterprozess installiertes post-installation-Skript gab den Fehlerwert 1 zurück


Overview of the system environment:
UCS Master - 4.2-0 errata15
Installed: adconnector=11.0 self-service=2.0 ucsschool=4.2 v1 webweaver=2.0.0-4

UCS Backup - 4.2-0 errata15
Installed: ucsschool=4.2 v1

UCS Member - 4.1-4 errata0 (wrong version number because of failed upgrade)
Installed: nagios=3.4

All three server were installed/configured out of the appliance KVM image (UCS-KVM-Demo-Image.qcow2 respectively UCS-VMware-ESX-Demo-Image.ova). All servers have set "repository/online/unmaintained=yes".

Upgrade of UCS Master and Backup without any problems.
This bug happened in customer environment and also in my internal test environment. So there is a debugging system available here:
Master: 10.200.34.90 (snapshot before UCS upgrade: 4.1-4 errate406)
Backup: 10.200.34.91
Member: 10.200.34.92


I found out a suitable workaround:
touch /var/backups/slapd-2.4.42+dfsg-2.219.201612021613/dc=unassigned-domain.ldif && apt-get install -f
Comment 1 Michel Smidt 2017-05-23 14:56:43 CEST
(In reply to Tobias Birkefeld from comment #0)
> I found out a suitable workaround:
> touch
> /var/backups/slapd-2.4.42+dfsg-2.219.201612021613/dc=unassigned-domain.ldif
> && apt-get install -f

Same problem here. Real bad issue.
Workaround worked.
Comment 2 Tobias Birkefeld univentionstaff 2017-05-23 16:09:04 CEST
(In reply to Tobias Birkefeld from comment #0)
> I found out a suitable workaround:
> touch
> /var/backups/slapd-2.4.42+dfsg-2.219.201612021613/dc=unassigned-domain.ldif
> && apt-get install -f

No idea if the workaround generate side-effects -> workaround without engagement.
Comment 4 Felix Botner univentionstaff 2017-05-24 13:17:38 CEST
Added a check to the preup to abort the update on member servers if slapd is installed.

univention-updater r79638
univention-updater.yaml

updated preup on apt.knut.univention.de and updates-test
Comment 5 Philipp Hahn univentionstaff 2017-06-02 17:02:23 CEST
OK: r79638
OK: ucr set version/version=4.1 version/patchlevel=4 repository/online/server='http://apt.knut.univention.de/';univention-upgrade --ignoressh --ignoreterm
OK: ucr set update42/ignore_slapd_on_member=yes
OK: dpkg -P slapd;univention-upgrade --ignoressh --ignoreterm

OK: errata-announce -V --only univention-updater.yaml
OK: univention-updater.yaml

QA: ls -l test_mirror/ftp/4.2/maintained/4.2-0/all/preup.sh* mirror/testing/4.2/maintained/4.2-0/all/preup.sh* mirror/ftp/4.2/maintained/4.2-0/all/preup.sh*
OK: ucr set version/version=4.1 version/patchlevel=4 repository/online/server='http://univention-repository.knut.univention.de/';univention-upgrade --ignoressh --ignoreterm
OK: sudo update_mirror.sh ftp/4.2/maintained/4.2-0/all/
OK: ucr set version/version=4.1 version/patchlevel=4 repository/online/server='http://updates.software-univention.de/';univention-upgrade --ignoressh --ignoreterm
Comment 6 Janek Walkenhorst univentionstaff 2017-06-07 15:22:38 CEST
<http://errata.software-univention.de/ucs/4.2/28.html>