I am trying to set up a new manual installation of Nextcloud, to see if it’s faster than the snap one.
I want the data directory to be an rclone remote on Google Drive.
If I try to set this up while setting Nextcloud up for the first time, I get an error message on the web UI that the data dir permissions are wrong and need to change to 0770. I can’t do that as rclone remotes can’t be set permissions.
If I set up a normal data directory on the server on setup, and then try to change it afterwards, it’s a complicated process and I get the following error message, even though the DB connection worked fine until right before the attempt to move the data dir:
An unhandled exception has been thrown:
Doctrine\DBAL\DBALException: Failed to connect to the database: An exception occurred in driver: SQLSTATE[HY000] [2002] No such file or directory in /var/www/nextcloud/lib/private/DB/Connection.php:67
Could anyone suggest a way out of this?
If there is a way to prevent Nextcloud for complaining about the data dir permissions, that would probably be the best way forward.