Need assistance with quota display for LDAP users

Nextcloud version: 28.0.4
Operating system and version (eg, Ubuntu 20.04): Docker Nextcloud Image on Ubuntu 22.04
Apache or nginx version (eg, Apache 2.4.25): Docker Nextcloud Image
PHP version (eg, 7.4): Docker Nextcloud Image

The issue you are facing:
For all my ~200 Users that sign in with LDAP, I am facing quota display problems. A quota of 1TB is displayed, while a quota of 500MB is enforced.

  • my default quota as per user settings is 500MB:
  • I have checked and validated in the database that the quota setting for all my users is set to “default”:
    SELECT * FROM preferences where preferences.appid = 'files' and preferences.configkey = 'quota';
  • A quota of 500MB is enforced - filling an account with 490 MB and then uploading a 10MB file leads to “insufficient space” errors.
  • The visual bar in the files app is based on a 500MB quota. It turns red and almost full when 490MB are in the account.
  • This issue does not appear for local users, only for LDAP users.
  • In my LDAP sync settings, the fields for “Default Quota” and “Quota Field” are empty.

    A few months ago I was syncing this from LDAP, and I may have had a default of 1TB set here (so that’s where the number may come from).

Is this the first time you’ve seen this error? (Y/N): N
It’s been like this for months and multiple nextcloud versions. Users have used multiple browsers, computers, Nextcloud has been restarted and upgraded many times. I will not believe that this is a caching issue :slight_smile:

Does anyone have an idea how to further troubleshoot this?

I can’t find any “cached” quota in the LDAP modules’ config:

mysql> SELECT DISTINCT preferences.configkey FROM preferences where preferences.appid = 'user_ldap';
| configkey                 |
| cached-group-memberships- |
| displayName               |
| firstLoginAccomplished    |
| foundDeleted              |
| homePath                  |
| isDeleted                 |
| lastAvatarChecksum        |
| lastProfileChecksum       |
| uid                       |

LDAP Quota in the DB is empty too.

mysql> SELECT * FROM appconfig where appid = 'user_ldap' and configkey = 'ldap_quota_def';
| appid     | configkey      | configvalue | type | lazy |
| user_ldap | ldap_quota_def |             |    2 |    0 |

Thanks for any hint!