I follow the Migrate the files and the database instructions to migrate from NCP (running on a Odroid XU4 with Armbian Busllseye 23.8.1) to AIO on a Intel laptop.
At step 3.iii of the Migrate instructions on the XU4:
in 127.0.0.1 nextcloud_db
Creating schema in new database
In Connection.php line 140:
Failed to connect to the database: An exception occurred in the driver: could not find driver
Could anybody please advice me what could be wrong?
Thank you!
The error message indicates that it’s not possible to connect to the database.
Just check pg’s client connection parameter (is it tcp, named pipe, shared memory,…)
I’d try to establish a connection by means of a native pg client program.
Thank you for supporting me.
Tried to enable the pdo_pgsql support by sudo apt install php-pgsql
which finished without error.
Then uncommenting in php.ini
;extension=pdo_pgsql
When I try to run the db converstion i get:
PHP Warning: PHP Startup: Unable to load dynamic library 'pdo_pgsql'
(tried: /usr/lib/php/20210902/pdo_pgsql (/usr/lib/php/20210902/pdo_pgsql:
cannot open shared object file: No such file or directory),
/usr/lib/php/20210902/pdo_pgsql.so (/usr/lib/php/20210902/pdo_pgsql.so:
cannot open shared object file: No such file or directory)) in Unknown on line 0
Any Idea how to enable pdo_pgsql in Arbian 23.8.1 Bullseye?
# sudo apt install php-pgsql
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
The following additional packages will be installed:
php8.2-common php8.2-pgsql
The following NEW packages will be installed:
php-pgsql php8.2-common php8.2-pgsql
installed php8.2, whereas ncp is using 8.1
root@nextcloudpi:~# php --ini
Cannot load Zend OPcache - it was already loaded
PHP Warning: PHP Startup: Unable to load dynamic library 'pdo_pgsql' (tried: /usr/lib/php/20210902/pdo_pgsql (/usr/lib/php/20210902/pdo_pgsql: cannot open shared object file: No such file or directory), /usr/lib/php/20210902/pdo_pgsql.so (/usr/lib/php/20210902/pdo_pgsql.so: cannot open shared object file: No such file or directory)) in Unknown on line 0
Configuration File (php.ini) Path: /etc/php/8.1/cli
Loaded Configuration File: /etc/php/8.1/cli/php.ini
Scan for additional .ini files in: /etc/php/8.1/cli/conf.d
Additional .ini files parsed: /etc/php/8.1/cli/conf.d/10-mysqlnd.ini,
/etc/php/8.1/cli/conf.d/10-opcac
....
I broke my whole Nextcloudpi installation with my experiments and finally had to restore a backup.
Tried again, but this time installed the correct pdo_pgsql version with apt-get install php8.1-pgsql
Then the database export works.
Thx for guiding me in the right direction.