Repository navigation
Description
⚠️ This issue respects the following points: ⚠️
- This is not a troubleshooting question, general support matter, or webserver/proxy problem, but likely a bug (if unsure, ask the Community Help Forum).
- This issue is not already reported on Github OR solved at the Community Help Forum (I've searched!).
- I'm using a maintained major version of Nextcloud Server and tested against the latest patch level. (Supported major versions and current patch levels).
- I agree to follow Nextcloud's Code of Conduct.
- I've tried my best to provide clear reproduction steps that someone unfamiliar with this bug could use to reproduce it.
Bug description
Description
Nextcloud displays an “On-disk temp tables” warning:
A large share of temporary tables are being created on disk instead of in memory.
The check is marked as failed, initially reporting 45.46%, and recommends increasing tmp_table_size and max_heap_table_size.
However, both settings are already configured to 64 MB, and MariaDB confirms that these values are active.
Configuration verification
SELECT
@@GLOBAL.tmp_table_size AS tmp_global,
@@GLOBAL.max_heap_table_size AS heap_global,
@@SESSION.tmp_table_size AS tmp_session,
@@SESSION.max_heap_table_size AS heap_session;Result:
tmp_global : 67108864
heap_global : 67108864
tmp_session : 67108864
heap_session : 67108864
MariaDB counters
A subsequent status check returned:
Created_tmp_disk_tables : 1021
Created_tmp_tables : 2369
Uptime : 163965 seconds
This represents approximately 43.10% of temporary tables being created on disk over 45 hours and 33 minutes of uptime.
Observed impact
Nextcloud works normally, with no noticeable slowdowns. The warning is the only observed issue.
Question / suggested improvement
Should this check consider the number of temporary tables created, the measurement period, and the effective configuration values before recommending an increase?
It would be helpful for the warning to explain that disk-based temporary tables may still occur with these settings, and that a high percentage alone does not necessarily indicate a performance problem.
Steps to reproduce
Go to index.php/settings/admin/overview
Expected behavior
No warning
Nextcloud Server version
35
Operating system
None
PHP engine version
None
Web server
None
Database engine version
None
Is this bug present after an update or on a fresh install?
None
Are you using the Nextcloud Server Encryption module?
None
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
Labels
Type
Projects
- StatusShow more project fieldsConfirmed
Activity
Lawkss commentedon Oct 23, 2026
Same problem.
I even set this to 128M and it still shows the same error after 24/48hrs of being cleared. Looks like it is always triggered at 57-58M or something.
matthiasdanner commentedon Oct 24, 2026
I have two observations on this to share:
So I think the check alone on the ratio is not enough, maybe there should be a threshold in absolute size of on disk tables when the check starts to trigger a warning.
REggleston27 commentedon Oct 24, 2026
Same here on MariaDB 10.11.18 (Debian 12): tmp_table_size and max_heap_table_size both 64M (confirmed in config and SHOW GLOBAL VARIABLES), Created_tmp_disk_tables still ~49% of Created_tmp_tables. Nextcloud runs fine. Presumably temp tables with TEXT/BLOB columns, which go to disk regardless of size limits, so no setting can clear this check.
nycoagung commentedon Oct 25, 2026
Same here, and I captured the queries, which confirms the TEXT/BLOB explanation above.
Setup: Nextcloud 35.0.2, serverinfo 7.0.0, MariaDB 11.8.9.
tmp_table_sizeandmax_heap_table_sizeare both 64M, and the check shows 54% (934 of 1,844 temp tables on disk).With
long_query_time = 0andlog_slow_filterlimited to on-disk temp tables or full joins, pluslog_slow_verbosity = 'query_plan,explain', the slow log records each matching query with its temp-table counts and sizes. Two sources turned up, neither related to size:Calendar reminder background job. The query joining
oc_calendar_reminderswithoc_calendarobjects/oc_calendarshas aGROUP BYthat includesco.calendardata(a BLOB):An 8 KB temp table went to disk with a 64 MB limit.
The admin Overview page itself. The core setup checks for missing columns, indices and primary keys and for bigint conversions each run Doctrine schema introspection over
information_schema. In every run, theinformation_schema.COLUMNSquery creates 5 temp tables, 3 of them on disk, about 5 MB in total. That table has threelongtextcolumns (COLUMN_DEFAULT,COLUMN_TYPE,GENERATION_EXPRESSION). One Overview load therefore adds 40 temp tables, 12 of them on disk (30%). That's the self-influence @matthiasdanner noticed: reloading Overview pulls the ratio towards about 30%.So for these temp tables, no value of
tmp_table_sizeormax_heap_table_sizechanges anything, and the recommendation can't be acted on. Possible fixes: skip the rule, or make it a notice, once both settings are at or above the recommended value. Or use an absolute threshold, as suggested above. This also answers #1134: a larger recommended value wouldn't help these temp tables either.salmart-dev commentedon Oct 27, 2026
Hello @S1RIUS1,
thank you for reporting the issue. I think the check may be reporting too eagerly and lacks a check for the current value being equal or greater than the recommended one. Also, as already reported, BLOB and TEXT columns always hit the disk so the check needs adjustments.
pikk-poket commentedon Nov 2, 2026
Same here, confirming @Lawkss’s observation with two months of data.
Nextcloud: 35.0.2 — serverinfo: 7.0.0 — MariaDB: 11.8.9
My instance runs with tmp_table_size = 128M and max_heap_table_size = 128M, and the check still fails. The config snippet offered by the check suggests:
[mysqld]
tmp_table_size = 64M
Applying it would halve the current value. The snippet does not take the running configuration into account.
Beyond the suggestion itself, I don’t think this check can pass on MariaDB at all. MariaDB always materialises a temporary table on disk when it contains a TEXT or BLOB column, regardless of the configured memory, because the in-memory engine cannot handle variable-length columns — MySQL 8 solved this by moving to the TempTable engine. Nextcloud’s schema uses such columns extensively (oc_filecache.path, properties, Talk messages), so a large share of temp tables will always spill to disk on MariaDB.
@Lawkss and I both run 128M and both still see the warning, which supports the idea that the ratio is not driven by the configured size at all.
Over the past two months the ratio on my instance has stayed between 50% and 65%, with no correlation to actual performance: the slow query log has been empty for weeks and database latency sits around 1.3 ms.
Suggestion: skip or downgrade this check on MariaDB, and never suggest a value lower than the one currently configured.