Skip to content
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

[Bug]: "mariadb"'s binary logs are created in huge amounts so that the free space of the server machine fills up. #33063

Closed
5 of 8 tasks
piiskop opened this issue Jun 29, 2022 · 4 comments
Labels
0. Needs triage Pending check for reproducibility or if it fits our roadmap bug

Comments

@piiskop
Copy link

piiskop commented Jun 29, 2022

⚠️ This issue respects the following points: ⚠️

  • This is a bug, not a question or a configuration/webserver/proxy issue.
  • This issue is not already reported on Github (I've searched it).
  • Nextcloud Server is up to date. See Maintenance and Release Schedule for supported versions.
  • I agree to follow Nextcloud's Code of Conduct.

Bug description

Every like five days, i need to do RESET MASTER to mariadb as it creates binary log files up to 63 GB in size filling up the free space on the server machine. Unless resetting the master, the whole server machine becomes useless. i opened one of the binary logs and saw there repeatedly records like

#Q> UPDATE oc_authtoken SET password = 'bKYY5NLt9TdihYNXIpsrhWagWvtarYnhB0f++F3/OFgEZ2RRwGaPOaQLPhiFonpBcYvAr1yxEqIllOhPn3FCEncqtZYUMgCNNBjopRb401SGahNfHlzZsrca8W8e34XWJdb4fFv39msGe6GPfEMzw66R0uTbaDAEg4xXkzuGgBZ+Q+lqpGR0Gg85mZht3kccN1t3N7GrsEQ46xvmaWTJJERd2dfbbZIAFYNCt4lohlWHWj01EOKe+Ulhg6ZFr5SdkSdr7p/gyYGzIkMVvvanXi0fcpyvyi/MunawQRKOjLbDmQAw5U530JoK0C3eST4wMyh5qfvoqG+8+L1IMLRFEQ==' WHERE id = 13813
#220629 15:33:57 server id 1 end_log_pos 902 CRC32 0xc61f3e82 Table_map: nextcloud.oc_authtoken mapped to number 3463

at 902

#220629 15:33:57 server id 1 end_log_pos 10136 CRC32 0x5bc0894d Update_rows: table id 3463 flags: STMT_END_F

Such records accompanied with a binary part will be written several times per second.

Steps to reproduce

  1. Have nextcloud running!
  2. Check mariadb's binary log files!
  3. See that nextcloud grows the size and number of mariadb's binary log files!

Expected behavior

i expect that nextcloud doesn't fill up the free space of my server machine because of some authentication activities that have nothing to do with the purpose of the usage of nextcloud.

Installation method

Manual installation

Operating system

Debian/Ubuntu

PHP engine version

PHP 7.4

Web server

Nginx

Database engine version

MariaDB

Is this bug present after an update or on a fresh install?

Fresh Nextcloud Server install

Are you using the Nextcloud Server Encryption module?

Encryption is Disabled

What user-backends are you using?

  • Default user-backend (database)
  • LDAP/ Active Directory
  • SSO - SAML
  • Other

Configuration report

kalmer@test:~$ sudo -u www-data php occ config:list system
[sudo] password for kalmer: 
Could not open input file: occ
kalmer@test:~$ php occ config:list system
Could not open input file: occ
kalmer@test:~$ ./occ config:list system
-bash: ./occ: No such file or directory

List of activated Apps

kalmer@test:~$ sudo -u www-data php occ app:list
Could not open input file: occ
kalmer@test:~$ php occ app:list
Could not open input file: occ
kalmer@test:~$ ./occ app:list
-bash: ./occ: No such file or directory

Nextcloud Signing status

No errors have been found.

Nextcloud Logs

No response

Additional info

No response

@piiskop piiskop added 0. Needs triage Pending check for reproducibility or if it fits our roadmap bug labels Jun 29, 2022
@solracsf
Copy link
Member

https://mariadb.com/kb/en/replication-and-binary-log-system-variables/#expire_logs_days

@CarlSchwan
Copy link
Member

as pointed out by @solracsf this seems to be a configuration issue in mariadb :)

@piiskop
Copy link
Author

piiskop commented Jul 4, 2022

Do you want me to tweak mariadb and let nextcloud constantly doing something under the hood? Removing the symptoms won't remove the disease as the cause still exists. As far as i understand, nextcloud is the root of the issue as it constantly messes with authentication tokens. Is that really necessary? My nextcloud database is also huge in comparison to other databases. Isn't it time to optimize nextcloud's performance because as i see it, too much is going on that uses up both the processing power as well as the storage space and yet, the system itself is slow. Let's start by explaining why in our holy green world nextcloud causes the current trouble for mariadb at all!

@not-implemented
Copy link

see #33485

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
0. Needs triage Pending check for reproducibility or if it fits our roadmap bug
Projects
None yet
Development

No branches or pull requests

4 participants