Missing index oc_mounts

Support intro

Sorry to hear you’re facing problems. :slightly_frowning_face:

The community help forum (help.nextcloud.com) is for home and non-enterprise users. Support is provided by other community members on a best effort / “as available” basis. All of those responding are volunteering their time to help you.

If you’re using Nextcloud in a business/critical setting, paid and SLA-based support services can be accessed via portal.nextcloud.com where Nextcloud engineers can help ensure your business keeps running smoothly.

Getting help

In order to help you as efficiently (and quickly!) as possible, please fill in as much of the below requested information as you can.

Before clicking submit: Please check if your query is already addressed via the following resources:

(Utilizing these existing resources is typically faster. It also helps reduce the load on our generous volunteers while elevating the signal to noise ratio of the forums otherwise arising from the same queries being posted repeatedly).

Some or all of the below information will be requested if it isn’t supplied; for fastest response please provide as much as you can. :heart:

The Basics

  • Nextcloud Server version: nextcloud 26 hub summer (35.0.0), nextcloud AIO 14.4.1
  • Operating system and version: Debian 13
  • Web server and version: Apache (in nextcloud-release/aio-apache container)
  • Reverse proxy and version: don't know (Caddy in apache container ?)
  • PHP version:don't know
  • Is this the first time you’ve seen this error?: yes
  • When did this problem seem to first start?:last week
  • Installation method:aio
  • Are you using CloudfIare, mod_security, or similar? :I guess no

Summary of the issue you are facing:

Un message d’avertissement reste affiché sur la page "Vue d’ensemble des paramètres de configuration/
A warning message remains displayed on Overview in administration settings:

Performance 1 échoue

Tables scanning sequentially

Information ·pg.tables_without_index_use

Échoue

Some tables have many sequential scans and no index scans, suggesting a missing index.

1 table(s) have > 1M sequential scans without any index scans.

- oc_mounts

Add appropriate indexes to the affected tables (pg_stat_user_tables shows the full scan statistics).

Valeur

1

Steps to replicate it (hint: details matter!):

  1. open admin settings

  2. select overview

Log entries

No log in nextcloud.log but these ones on overview page :



Buffer cache hit ratio
Avertissement ·
pg.cache_hit_ratio
Passe

Valeur
    99.97

Dead tuples in user tables
Avertissement ·
pg.dead_tuples
Passe

Valeur
    1 198

Long-running queries
Avertissement ·
pg.long_running_queries
Passe

Valeur
    0

Replication
Replication lag
Alerte ·
pg.replication_lag
Passe

Valeur
    0

Connections
Connection saturation
Alerte ·
pg.connection_saturation
Passe

Valeur
    0.04


Have you already tried to run occ db:add-missing-indices to add missing indices?

Thank you, j-ed

I tried :

  • sudo -u www-data occ db:add-missing-indices
  • sudo occ db:add-missing-indices

No result, except : occ command not found

Since you’re using AIO, this should help:

https://github.com/nextcloud/all-in-one#how-to-run-occ-commands

Thanks !.. I’ll remember that.

I tried :

sudo docker exec --user www-data -it nextcloud-aio-nextcloud php occ db:add-missing-indices

Is it correct ?.. But it doesn’t change anything.

Yes, that’s correct. And as far as I know, the command doesn’t produce any output.

Unfortunately, if the command didn’t solve the problem, I’m afraid I can’t tell you exactly how to fix it either.

There are two things worth mentioning, though:

  1. You’re running version 35.0.0, which had a few bugs related to both the database check and the database itself. I’d recommend updating to version 35.0.2. If that doesn’t help, try searching for the error message online. Several forum threads and GitHub issues discuss similar problems.

  2. AIO normally only upgrades to the next major version of Nextcloud once everything it ships with is working properly. I’d therefore recommend resisting the temptation to click the link explaining how to upgrade directly to the latest Nextcloud version, and let AIO handle the upgrades as intended. This should help you avoid problems like this in the future.

OK… Thanks anyway bb77.

But, actually, I can’t update to 35.0.2… I’ve left another message about this ( Update nexcloud 35.0.2 failed )… And it wasn’t out of weakness (in regard to the temptation! :wink: ) but because the AIO interface prompted me to do so.