Bug 41315 - Block UCS 4.0 upgrade if Postgres 8.4 is installed
Block UCS 4.0 upgrade if Postgres 8.4 is installed
Status: CLOSED FIXED
Product: UCS
Classification: Unclassified
Component: PostgreSQL
UCS 3.3
Other Linux
: P5 normal (vote)
: UCS 3.3
Assigned To: Felix Botner
Stefan Gohmann
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2016-05-21 07:45 CEST by Stefan Gohmann
Modified: 2016-09-29 17:25 CEST (History)
0 users

See Also:
What kind of report is it?: Development Internal
What type of bug is this?: ---
Who will be affected by this bug?: ---
How will those affected feel about the bug?: ---
User Pain:
Enterprise Customer affected?:
School Customer affected?:
ISV affected?:
Waiting Support:
Flags outvoted (downgraded) after PO Review:
Ticket number:
Bug group (optional):
Max CVSS v3 score:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Stefan Gohmann univentionstaff 2016-05-21 07:45:35 CEST
See Bug #40690. We should block the upgrade to UCS 4.0 if one updates from UCS 3.3 and Postgres 8.4 is used.

The SDB article needs to be adjusted (http://sdb.univention.de/1292):

1. UCS 3.3 must be mentioned
2. The /var/lib/postgresql/9.1/main directory must be moved:
 [ -f /usr/sbin/univention-pkgdb-scan ] && chmod -x /usr/sbin/univention-pkgdb-scan
 service postgresql stop
 rm -rf /etc/postgresql/9.1
 apt-get install --reinstall postgresql-9.1
 pg_dropcluster 9.1 main --stop
 service postgresql start
+ test -e /var/lib/postgresql/9.1/main && mv /var/lib/postgresql/9.1/main /var/lib/postgresql/9.1/main.old
pg_upgradecluster 8.4 main
ucr commit /etc/postgresql/9.1/main/*
chown -R postgres:postgres /var/lib/postgresql/9.1
service postgresql restart
[ -f /usr/sbin/univention-pkgdb-scan ] && chmod +x /usr/sbin/univention-pkgdb-scan
Comment 1 Stefan Gohmann univentionstaff 2016-05-23 06:02:28 CEST
The following command should be added to the SDB article:

test "$(ucr get version/version)" = 3.3 && univention-install --yes univention-postgresql-9.1

Otherwise univention-postgresql-8.4 will be installed during the upgrade to UCS 4.1.
Comment 2 Felix Botner univentionstaff 2016-05-23 11:01:52 CEST
* ucs-4.0-0/base/univention-updater/script: r69461
  added check_for_postgresql84 (copied to apt.knut.univention.de)

* modified http://sdb.univention.de/1292)
Comment 3 Stefan Gohmann univentionstaff 2016-05-24 16:58:10 CEST
Code review: OK

Tests from 3.2: OK

Tests from 3.3: OK
Comment 4 Stefan Gohmann univentionstaff 2016-06-07 21:35:45 CEST
UCS 3.3 has been released:
 https://docs.software-univention.de/release-notes-3.3-0-en.html
 https://docs.software-univention.de/release-notes-3.3-0-de.html

If this error occurs again, please use "Clone This Bug".