[ovirt-users] engine-setup failed because of postgres 9.4
I'm on a RHEL 7, trying to install a ovirt 3.6.0.3. The database used is on a remote server, using a postgres 9.4. The backup of the previous database fails with : 2015-12-10 12:04:13 DEBUG otopi.**FILTERED**_engine_setup.engine_common.database database.backup:661 db backup res {'result': [{'stderr': 'pg_dump: server version: 9.4.5; pg_dump version: 9.2.14\npg_dump: aborting because of server version mismatch\n', 'rc': 1}], 'stdout': ''} But the good pg_dump is in the path: ~# type pg_dump pg_dump is /usr/pgsql-9.4/bin/pg_dump Although in the log file: 2015-12-10 12:40:19 DEBUG otopi.context context.dumpEnvironment:510 ENV COMMAND/pg_dump=str:'/bin/pg_dump' Why ? How can I enforce the use of the latest pg_dump without rewrinting the '/bin/pg_dump' which is owned by the official postgres package ? ___ Users mailing list Users@ovirt.org http://lists.ovirt.org/mailman/listinfo/users
Re: [ovirt-users] engine-setup failed because of postgres 9.4
> Le 10 déc. 2015 à 13:51, Yedidyah Bar Davida écrit : > > engine-setup > --otopi-environment='SYSTEM/commandPath=str:/usr/pgsql-9.4/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin' I got better results with --otopi-environment="COMMAND/pg_dump=str:'/usr/pgsql-9.4/bin/pg_dump'" But anyway: ~$ ls -l /bin/pg_dump lrwxrwxrwx 1 root root 31 Dec 10 13:13 /bin/pg_dump -> /etc/alternatives/pgsql-pg_dump So it should not be needed to specify it at command line. Once the latest version of postgres is installed : ~# alternatives --list | grep pg_dump pgsql-pg_dump auto/usr/pgsql-9.4/bin/pg_dump I don't know why my first try failed. This time I installed pg-9.4 before and everything was fine. ___ Users mailing list Users@ovirt.org http://lists.ovirt.org/mailman/listinfo/users
Re: [ovirt-users] engine-setup failed because of postgres 9.4
On Thu, Dec 10, 2015 at 1:43 PM, Fabrice Bacchellawrote: > I'm on a RHEL 7, trying to install a ovirt 3.6.0.3. > > The database used is on a remote server, using a postgres 9.4. > > The backup of the previous database fails with : > 2015-12-10 12:04:13 DEBUG > otopi.**FILTERED**_engine_setup.engine_common.database database.backup:661 > db backup res {'result': [{'stderr': 'pg_dump: server version: 9.4.5; > pg_dump version: 9.2.14\npg_dump: aborting because of server version > mismatch\n', 'rc': 1}], 'stdout': ''} > > But the good pg_dump is in the path: > > ~# type pg_dump > pg_dump is /usr/pgsql-9.4/bin/pg_dump > > Although in the log file: > > 2015-12-10 12:40:19 DEBUG otopi.context context.dumpEnvironment:510 ENV > COMMAND/pg_dump=str:'/bin/pg_dump' > > Why ? How can I enforce the use of the latest pg_dump without rewrinting the > '/bin/pg_dump' which is owned by the official postgres package ? otopi ignores the PATH in env. It defaults to: /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin You can change that by something like: cat << __EOF__ > /etc/ovirt-engine-setup.conf.d/99-my-path.conf [environment:default] SYSTEM/commandPath=str:/usr/pgsql-9.4/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin __EOF__ Or just pass on the command line: engine-setup --otopi-environment='SYSTEM/commandPath=str:/usr/pgsql-9.4/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin' grep for commandPath in the log file to see that it worked. Never tried this myself, though. You might face problems also with pg libraries, including making psycopg2 use your own libs. Please report about success/failure/problems. Thanks. Good luck, -- Didi ___ Users mailing list Users@ovirt.org http://lists.ovirt.org/mailman/listinfo/users