Skip to content

[Bug]: Massive growth of table oc_calendarchanges #59300

@ZambeiCloud

Description

@ZambeiCloud

⚠️ This issue respects the following points: ⚠️

Bug description

I recently noticed a slight but constant databasegrowth on my small AIO instance. Every day the database was a few MB bigger as the day before. On the weekend I decided to check the cause for this and noticed that the oc_calendarchanges table was around 500 MB big and was the biggest table in my instance. I narrowed the issue down to the calendar subscriptions. On my instance there were 5 subscriptions to calendars in total (4 to google calendars and 1 to the german holiday calendar). Every subscriptions created dozens of entries every few seconds and I had over 3 million entries in the table.. After I deleted all the subscriptions only 1800 entries were left in the table. To test the issue I recreated subscriptions to one of the google calendars and the holiday calendar and there were dozens of entries for the subscriptions in the table after a view seconds, so I can say for sure this is the issue.. The database also doesn't grow anymore, now that all subscriptions has been deleted.
I don't know how long the database kept growing but I would say it was since the update to 32.0.6 with the AIO Version v12.7.0.

Steps to reproduce

  1. Create a calendar subscription to a google calendar and/or holiday calendar
  2. Check the table oc_calendarchanges

Expected behavior

No database bloat when using calendar subscriptions

Nextcloud Server version

32

Operating system

Debian/Ubuntu

PHP engine version

None

Web server

Apache (supported)

Database engine version

PostgreSQL

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

Updated from a MINOR version (ex. 32.0.1 to 32.0.2)

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

List of activated Apps

Nextcloud Signing status

Nextcloud Logs

Additional info

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No fields configured for Bug.

    Projects

    Status

    Triaged

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions