nextcloud / nextcloud/fulltextsearch
fulltextsearch:live causes high database CPU
Nobody has claimed this yet.
- Dominant language
- PHP
- Stars
- 234
- Forks
- 64
- Avg merge
- 6h 18m
- Merged PRs (30d)
- 10
Description
I've been trying to track down the source of a recent change in my performance patterns where my Mariadb instance is sitting there with one of my cores pegged at 100% pretty much constantly. I was in the middle of tracking it when something occurred with my Nextcloud that caused my fulltextsearch:live job to crap out. Suddenly that performance dropped back to a more normal level and everything was fine.
Started fulltextsearch:live... 100% CPU core pegged. Stop it... back to normal. I can recreate this consistently.
This seems new since I upgraded to 17... didn't seem to happen with earlier versions. I am not seeing any unusual activity on Elastisearch.
This is a very low-utilization implementation with maybe 45 users and perhaps 200 documents changed/created per hour. As a result I'd expect MUCH lower utilization than this, and the fact that the indexer seems to be sitting there cranking against my DB's CPU constantly when there's literally nothing happening (ran it interactively to test and saw nothing going on but the CPU high on the DB).
Any thoughts or things I might look at?
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the fulltextsearch:live entry point and reproduce the report while monitoring MariaDB CPU; compare behavior before and after the Nextcloud 17 upgrade. Check whether Elasticsearch shows activity during the idle period and identify what database work continues when no documents are changing. Done means the idle live job no longer keeps a database core saturated, with a regression test or confirmed reproduction details.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- elasticsearch, mariadb, php
- Domain
- backend, databases, search
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100