Experiencing slow webpage loading on Nextcloud 18 behind nginx

Hello,

I’ve installed nextcloud 18.0 behind nginx reverse proxy,
The problem is the web interface is very slow (loading each page take around ~20s).

We test a lot of different configurations (on nginx). Unfortunately, these configuration changes were insignificants on webpage loadings.

Anybody experience similar problems?

Thanks for the help.
Rémi.

This is my nextcloud configuration:

    <?php
    $CONFIG = array (
      'instanceid' => ***
      'passwordsalt' => ***
      'secret' => ***
      'trusted_domains' =>
      array (
        0 => ***
        1 => ***
        2 => ***
        3 => ***
      ),
      'datadirectory' => ***
      'dbtype' => 'mysql',
      'version' => '18.0.0.10',
      'overwrite.cli.url' => ***
      'dbname' => ***
      'dbhost' => ***
      'dbport' => '',
      'dbtableprefix' => 'oc_',
      'mysql.utf8mb4' => true,
      'dbuser' => ***
      'dbpassword' => ***
      'installed' => true,
      'theme' => '',
      'loglevel' => 2,
      'maintenance' => true,
      'default_language' => 'fr',
      'default_locale' => 'fr_FR',
      'defaultapp' => 'files',
      'allow_user_to_change_display_name' => true,
      'mail_domain' => ***
      'mail_from_address' => 'nextcloud',
      'mail_smtphost' => '127.0.0.1',
      'mail_smtpport' => '25',
      'ldapIgnoreNamingRules' => false,
      'ldapProviderFactory' => 'OCA\\User_LDAP\\LDAPProviderFactory',
      'skeletondirectory' => '',
      'mail_smtpmode' => 'smtp',
      'mail_sendmailmode' => 'smtp',
      'filelocking.enabled' => false,
      'trusted_proxies' =>
      array (
        0 => ***
      ),
      'updater.secret' => ***
    );

Nginx config (server and proxy) ? Distance from server? Good HDD (if you’re caching) ?

Otherwise you have no cache configured in your nextcloud config. Are you using opcache at least?

I’d blame your mysql server without any further information. Have you checked the logs for slow queries?