When does the synchronisation start?

I have entered all the data in the backend. Verify database connection says OK.
But the user data from Nextcloud is not synchronised into the external database (Nextcloud always wins selected).

Is there a trigger for the synchronisation?

If I’m understanding the question right, you’ve created a user account in Nextcloud, then hooked up the ‘user_sql’ integration, and you want your user info to be moved into that database now.

Based on what I’ve seen of the user auth backend integrations like this, I think you’ll need to create a new user account now that the integration is hooked up. If you want it to have the same name, you’ll need to delete your account and re-create it.

As far as I’m aware, there isn’t a mechanism for moving “Nextcloud-native” accounts into the backend, and if an account name exists in both databases, Nextcloud’s own will take priority.
If it helps any, the new user migration feature in NC24 might make it much simpler to move your settings to the new account than it used to be.

The problem is a bit more complex: The problem is that I want to maintain a larger number of users both in a WordPress instance and in Nextcloud. In order to keep the data consistent, I want to maintain it in a database separate from both systems, which is then synchronised with both WordPress and Nextcloud. This process does not have to run continuously, but could also be triggered by the admin as needed.
I understand the description of the app ‘User and Group SQL Backends’ to mean that it could solve the problem for Nextcloud. However, I cannot find a way to trigger the synchronisation.

Hmm, I don’t see much documentation around, so I’ll refer to the readme file. If anyone around here knows better, please do correct me. :smile:

There are definitely some things that sync. From the looks of the Options table, that includes name, email, and quota. There’s also a cache you can clear, but I don’t think that applies to synced items.
If I’m reading the descriptions of the way the users table should be laid out right, the ‘user backend’ is one service provided by this plugin, while sync for the listed 3 things are separate, optional services. I don’t see anything about configuring sync for the user backend, so I think that’s more or less live (apart from caching), as opposed to synced.

I think you set this up, have someone try signing in, and if their account doesn’t already exist in the Nextcloud database, then it authenticates them against the password in the backend database. It optionally syncs name, email and quota from there to Nextcloud, but since there’s nothing here about scheduling, that sync might be triggered by login as well. Might be synced rather than retrieved live to cut down on unnecessary latency.