-
-
Notifications
You must be signed in to change notification settings - Fork 4.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Probably unnecessary MariaDB global configuration change requirement #29911
Comments
Committed here, sadly without further explanation or a PR: nextcloud/documentation@c32114a The additional text at the top of the page was committed here, pulled in from ownCloud docs in 2016: nextcloud/documentation#56 For the transaction isolation there is a setup warning implemented, but I've never seen or heard of this being triggered: https://github.com/nextcloud/server/blob/19d0708/apps/settings/lib/Controller/CheckSetupController.php#L523-L535 What I can say is that both settings have other defaults and I run a Nextcloud instance for several years + we (DietPi) offer a fully configured Nextcloud setup with MariaDB for years without touching any of the two settings, and at least we didn't get any issue reports that could be narrowed down to these missing, and never faced someone with this warning. So indeed Nextcloud seems to handle this internally. But not sure about the binary logging format. @nickvergessen @MorrisJobke |
You can set the binlog format to mixed. Then MariaDB can decide which type to use. |
As mentioned above: don't not force admin to globally change default db server settings if not required as it may interfere with other applications using other databases on same server. NC should configure only own sessions and not require global sql server changes. |
I suppose this is a non issue for the binlog as the default value in MariaDB changed to mixed anyways (cf. https://mariadb.com/kb/en/replication-and-binary-log-system-variables/#binlog_format). |
The transaction isolation level seems to be set on a per session basis (cf.
|
So, the docs should be updated. |
SQL server admin is allowed to set whatever they like for server globally and NC should not assume that SQL server has required setting. SQL server may be shared between many apps with different requirements. NC should setup only own sessions if required (and not done already). |
Even setting the session variable for the biglog format requires super privileges which you don't want the nextcloud user to have in production. |
Seems super is required only for https://mariadb.com/kb/en/binary-log-formats/ ...but should be verified by devs if required. |
Please look at the output of my PR, then you'll see that it is not allowed: https://drone.nextcloud.com/nextcloud/server/22239/11/5 |
Just checked in MariaDB/Debian 11:
so you're right - special privileges are required and nextcloud user problably should not have such privileges for security reasons. |
How to use GitHub
Is your feature request related to a problem? Please describe.
According to
https://docs.nextcloud.com/server/stable/admin_manual/configuration_database/linux_database_configuration.html#configuring-a-mysql-or-mariadb-database
Nextcloud requires non default MariaDB settings
Accoring to
https://help.nextcloud.com/t/transaction-isolation-level-of-nextcloud-database/88858/4
Nextcloud already sets transaction_isolation for its sessions.
Accroding to
https://mariadb.com/kb/en/binary-log-formats/#configuring-the-binary-log-format
binary log format may be configured per session too but I didn't find such solution in Nextcloud source.
Describe the solution you'd like
Please verify and consider removing MariaDB global configuration change requirement for transaction_isolation and binlog_format if not absolutely required (Nextcloud should configure own sessions only); don't not force admin to globally change default db server settings if not required as it may interfere with other applications using other databases on same server.
The text was updated successfully, but these errors were encountered: