Hi all, I was on NextCloud 13.0.6. I updated to 14. All went well but I noticed lots of old errors in the logs that ultimately were being caused by having a stale version of nginx and openssl. Easiest way to fix was to move this instance to a wholly new FreeBSD jail based on the current FreeBSD. In doing so, I recreated the nginx config, moved the nextcloud install, and installed the needed packages (nginx, php, php-pgsql, etc.). If I run a script that calls phpinfo() it works fine and gives me the expected text, but NextCloud is just unable to do anything except throw a 500 error.
(and yes I saw the similarly-titled other topic, but it wasn’t of help to me)
Nextcloud version 14.0.3:
Operating system and version: newly created jail on FreeNAS/FreeBSD 11:
Apache or nginx version: nginx 1.14.0_12,2:
PHP version (eg, 7.1): php 7.3
The issue you are facing:
PHP Fatal error: Allowed memory size of 536870912 bytes exhausted (tried to allocate 12374000625787947544 bytes) in /opt/nextcloud/lib/private/Security/CSRF/CsrfToken.php on line 57
Is this the first time you’ve seen this error? (Y/N): Y
Steps to replicate it:
- I just moved my NextCloud install to a brand new FreeNAS/FreeBSD jail
- Visit https://mynextcloud.server
- This error shows up in the logs
The output of your Nextcloud log in Admin > Logging:
Can't get to it
The output of your config.php file in /path/to/nextcloud
(make sure you remove any identifiable information!):
$CONFIG = array (
'instanceid' => 'xxx',
'passwordsalt' => 'xxx',
'secret' => 'C/xxx/R9yvFvXMC',
'trusted_domains' =>
array (
0 => '192.168.1.22',
1 => 'xxx',
2 => 'xxx2',
),
'datadirectory' => '/mnt/nextcloud_files',
'overwrite.cli.url' => 'http://192.168.1.22',
'dbtype' => 'pgsql',
'version' => '14.0.3.0',
'installed' => true,
'mail_from_address' => 'daemon',
'mail_smtpmode' => 'smtp',
'mail_domain' => 'xxx',
'ldapIgnoreNamingRules' => false,
'mail_smtpauthtype' => 'LOGIN',
'mail_smtpauth' => 1,
'mail_smtphost' => 'smtp.gmail.com',
'mail_smtpport' => '465',
'mail_smtpsecure' => 'ssl',
'mail_smtpname' => 'xxx',
'mail_smtppassword' => 'xxx',
'forcessl' => true,
'forceSSLforSubdomains' => true,
'theme' => '',
'maintenance' => false,
'logfile' => '/mnt/nextcloud_files/nextcloud.log',
'loglevel' => 2,
'trashbin_retention_obligation' => 'auto',
'dbname' => 'owncloud',
'dbhost' => 'xxx',
'dbuser' => 'xxx',
'dbpassword' => 'xxx',
'htaccess.RewriteBase' => '/',
'updater.release.channel' => 'stable',
'updater.server.url' => 'https://updates.nextcloud.com/updater_server/',
'ldapProviderFactory' => '\\OCA\\User_LDAP\\LDAPProviderFactory',
The output of your Apache/nginx/system log in /var/log/____
:
2018/10/17 22:53:25 [error] 56279#101852: *1 FastCGI sent in stderr: "PHP message: PHP Fatal error: Allowed memory size of 536870912 bytes exhausted (tried to allocate 12374000625787947544 bytes) in /opt/nextcloud/lib/private/Security/CSRF/CsrfToken.php on line 57" while reading response header from upstream, client: 192.168.1.214, server: xxxx, request: "GET / HTTP/1.1", upstream: "fastcgi://127.0.0.1:9000", host: "xxxx"