Nextcloud works except LARGE federated shares. cURL 500 errors in log

Working config looks like:

  'instanceid' => 'foobarwhatsit',
  'passwordsalt' => 'nope',
  'secret' => 'also nope',
  'trusted_domains' =>
  array (
    0 => 'my.domain',
  ),
  'datadirectory' => '/var/www/nextcloud/data',
  'dbtype' => 'pgsql',
  'version' => '30.0.2.2',
  'overwrite.cli.url' => 'https://my.domain',
  'dbname' => 'nextcloud',
  'dbhost' => '/var/run/postgresql',
  'dbport' => '',
  'dbtableprefix' => 'oc_',
  'dbuser' => 'admin',
  'dbpassword' => 'password',
  'installed' => true,
  'maintenance' => false,
  'maintenance_window_start' => 1,
  'memcache.locking' => '\\OC\\Memcache\\Redis',
  'memcache.distributed' => '\\OC\\Memcache\\Redis',
  'memcache.local' => '\\OC\\Memcache\\Redis',
  'redis' =>
  array (
    'host' => '/run/redis/redis-server.sock',
    'port' => 0,
    'timeout' => 0.0,
  ),
  'default_phone_region' => 'GB',
  'mail_smtpmode' => 'sendmail',
  'mail_sendmailmode' => 'smtp',
  'mail_from_address' => 'nextcloud',
  'mail_domain' => 'my.domain',
  'memories.db.triggers.fcu' => true,
  'memories.exiftool' => '/var/www/nextcloud/apps/memories/bin-ext/exiftool-aarch64-glibc',
  'memories.vod.path' => '/var/www/nextcloud/apps/memories/bin-ext/go-vod-aarch64',
  'memories.vod.ffmpeg' => '/usr/bin/ffmpeg',
  'memories.vod.ffprobe' => '/usr/bin/ffprobe',
  'preview_concurrency_all' => 2,
  'preview_concurrency_new' => 1,
  'app_install_overwrite' =>
  array (
    0 => 'maps',
  ),
  'memories.gis_type' => 2,
  'trashbin_retention_obligation' => 'disabled',
  'versions_retention_obligation' => 'disabled',
  'loglevel' => 2,
  'forbidden_filename_characters' =>
  array (
    0 => '\\',
    1 => '/',
  ),
  'forbidden_filename_extensions' =>
  array (
    0 => '.filepart',
    1 => '.part',
  ),
  'bulkupload.enabled' => false,
  'memories.viewer.high_res_cond_default' => 'always',
  'defaultapp' => '',

I also needed to alter the nginx config recommended on the nextcloud page:

    fastcgi_read_timeout 600;
    fastcgi_send_timeout 600;
    fastcgi_connect_timeout 600;

And this seemed prudent:

   include mime.types;
    types {
            application/javascript mjs;
            #    text/javascript js mjs; - already in mime.types
            #   application/wasm wasm; - already in mime.types
    }

I removed “setup” from the line

rewrite ^/(?!index|setup|remote|public|cron|core\/ajax\/update|status|ocs\/v[12]|updater\/.+|ocs-provider\/.+|.+\/richdocumentscode(_arm64)?\/proxy) /index.php$request_uri;

as its wrong anyway, the setup script has a different name now. A note in the docs to remove it after installation might be a good idea, too.

What documentation are you looking at where you are seeing setup in that line of the suggested Nginx configuration?

hm. docs.nextcloud.com - but I can’t find it now. Bizarre.

The rest looks the same.

Similar to Can't open / sync big files on external storage (webdav) · Issue #30282 · nextcloud/server · GitHub