[ovirt-users] 4.2 upgrade question

Yedidyah Bar David didi at redhat.com
Mon Mar 12 12:33:47 UTC 2018


On Mon, Mar 12, 2018 at 1:37 PM, KSNull Zero <ksnull01 at gmail.com> wrote:
> Hello!
> Currently we run 4.1.9 and try to upgrade to the latest 4.2 release.
> Our DB server is on separate machine and run PostgreSQL 9.2.23.
>
> During upgrade the following error occurs:
> [WARNING] This release requires PostgreSQL server 9.5.9 but the engine
> database is currently hosted on PostgreSQL server 9.2.23
> [ ERROR ] Please upgrade the PostgreSQL instance that serves the engine
> database to 9.5.9 and retry.
>
> Ok, so we need to upgrade PostgreSQL.
> The question is - do we need to have exact 9.5.9 version of PostgreSQL ?

'9.5.9' is not hard-coded, but is the version shipped by SCL [1].

The CentOS 7 engine build pulls that in and uses it, for both client (always)
and server (if configured to).

This is the only combination that's tested and known to work. To use this
on your remote PG machine, add there SCL repos and use them. You will need
to upgrade your database to the new version, similarly to what engine-setup
does if it's a local db. I do not think we have docs for this, see e.g. [2].

If you want to use some other (non-SCL) build of PG also on the client,
I think it should not be too hard to make everything work, as this is
what we do in the fedora build, but I didn't try this myself, nor know
about anyone that did. It's probably enough to remove the file:

/etc/ovirt-engine-setup.env.d/10-setup-scl-postgres-95.env

If you go this way, note that you'll have to repeat removing it per
each upgrade. Alternatively, you can add your own file there, with
a later number, clearing the variables set in this file, e.g.:

# cat << __EOF__ > /etc/ovirt-engine-setup.env.d/99-unset-postgresql.env
unset RHPOSTGRESQL95BASE
unset RHPOSTGRESQL95DATA
unset sclenv
unset POSTGRESQLENV
__EOF__

And also install the postgresql client/libraries/etc matching what you
have on your server.

[1] https://www.softwarecollections.org/en/scls/rhscl/rh-postgresql95/
[2] https://bugzilla.redhat.com/show_bug.cgi?id=1498351#c12

> Because if we upgrade PostgreSQL to the latest available 9.5.12 the same
> error occurs saying that client and server version mismatched and upgrade
> terminates.
> Thank you.

Best regards,
-- 
Didi


More information about the Users mailing list