Nextcloud Internal Server Error cant acces nextcloud

Support intro

Sorry to hear you’re facing problems :slightly_frowning_face:

help.nextcloud.com is for home/non-enterprise users. If you’re running a business, paid support can be accessed via portal.nextcloud.com where we can ensure your business keeps running smoothly.

In order to help you as quickly as possible, before clicking Create Topic please provide as much of the below as you can. Feel free to use a pastebin service for logs, otherwise either indent short log examples with four spaces:

example

Or for longer, use three backticks above and below the code snippet:

longer
example
here

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:

I get a internal server error when trying to acces nextcloud, not sure what happend.

Nextcloud version : 19.0.5.2
Operating system and version:Ubuntu Linux 20.04
Apache or nginx version (eg, Apache 2.4.25): nginx
PHP version (eg, 7.4): 7.4

The issue you are facing:

Internal Server Error

The server was unable to complete your request.

If this happens again, please send the technical details below to the server administrator.

Technical details

  • Remote Address: 192.168.1.5
  • Request ID: uBEZFjgAdlua2QUYQTqo

Is this the first time you’ve seen this error? (Y/N): yes

The output of your Nextcloud log in ** path=var/www/nextcloud/data)**:

{"reqId":"ppR9r7GtutFKo2MICGJp","level":2,"time":"2020-06-24T17:06:15+00:00","remoteAddr":"192.168.1.5","user":"--","app":"no app in context","method":"GET","url":"/","message":"Could not detect any host in https:///data/htaccesstest.txt","userAgent":"Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/76.0.3809.71 Safari/537.36","version":""}
{"reqId":"ppR9r7GtutFKo2MICGJp","level":2,"time":"2020-06-24T17:06:15+00:00","remoteAddr":"192.168.1.5","user":"--","app":"no app in context","method":"GET","url":"/","message":"Could not detect any host in http:///data/htaccesstest.txt","userAgent":"Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/76.0.3809.71 Safari/537.36","version":""}
{"reqId":"ppR9r7GtutFKo2MICGJp","level":3,"time":"2020-06-24T17:06:15+00:00","remoteAddr":"192.168.1.5","user":"--","app":"jsresourceloader","method":"GET","url":"/","message":"Could not find resource js/setup.js to load","userAgent":"Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/76.0.3809.71 Safari/537.36","version":""}
{"reqId":"ppR9r7GtutFKo2MICGJp","level":3,"time":"2020-06-24T17:06:15+00:00","remoteAddr":"192.168.1.5","user":"--","app":"PHP","method":"GET","url":"/","message":"chmod(): No such file or directory at /var/www/nextcloud/lib/private/Log/File.php#86","userAgent":"Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/76.0.3809.71 Safari/537.36","version":""}
{"reqId":"Vv2Wci6b6e9ztwMXhA0a","level":3,"time":"2020-06-24T17:06:15+00:00","remoteAddr":"192.168.1.5","user":"--","app":"PHP","method":"GET","url":"/","message":"session_start(): A session had already been started - ignoring at /var/www/nextcloud/lib/private/Session/Internal.php#209","userAgent":"Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/76.0.3809.71 Safari/537.36","version":""}
{"reqId":"Vv2Wci6b6e9ztwMXhA0a","level":2,"time":"2020-06-24T17:06:15+00:00","remoteAddr":"192.168.1.5","user":"--","app":"no app in context","method":"GET","url":"/","message":"Could not detect any host in https:///data/htaccesstest.txt","userAgent":"Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/76.0.3809.71 Safari/537.36","version":""}
{"reqId":"Vv2Wci6b6e9ztwMXhA0a","level":2,"time":"2020-06-24T17:06:15+00:00","remoteAddr":"192.168.1.5","user":"--","app":"no app in context","method":"GET","url":"/","message":"Could not detect any host in http:///data/htaccesstest.txt","userAgent":"Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/76.0.3809.71 Safari/537.36","version":""}
{"reqId":"Vv2Wci6b6e9ztwMXhA0a","level":3,"time":"2020-06-24T17:06:15+00:00","remoteAddr":"192.168.1.5","user":"--","app":"jsresourceloader","method":"GET","url":"/","message":"Could not find resource js/setup.js to load","userAgent":"Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/76.0.3809.71 Safari/537.36","version":""}
{"reqId":"09XQX9iUy9dKW8LhSWvg","level":3,"time":"2020-06-24T17:07:08+00:00","remoteAddr":"192.168.1.5","user":"--","app":"PHP","method":"GET","url":"/","message":"session_start(): A session had already been started - ignoring at /var/www/nextcloud/lib/private/Session/Internal.php#209","userAgent":"Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/76.0.3809.71 Safari/537.36","version":""}
{"reqId":"09XQX9iUy9dKW8LhSWvg","level":2,"time":"2020-06-24T17:07:08+00:00","remoteAddr":"192.168.1.5","user":"--","app":"no app in context","method":"GET","url":"/","message":"Could not detect any host in https:///data/htaccesstest.txt","userAgent":"Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/76.0.3809.71 Safari/537.36","version":""}
{"reqId":"09XQX9iUy9dKW8LhSWvg","level":2,"time":"2020-06-24T17:07:08+00:00","remoteAddr":"192.168.1.5","user":"--","app":"no app in context","method":"GET","url":"/","message":"Could not detect any host in http:///data/htaccesstest.txt","userAgent":"Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/76.0.3809.71 Safari/537.36","version":""}
{"reqId":"09XQX9iUy9dKW8LhSWvg","level":3,"time":"2020-06-24T17:07:08+00:00","remoteAddr":"192.168.1.5","user":"--","app":"jsresourceloader","method":"GET","url":"/","message":"Could not find resource js/setup.js to load","userAgent":"Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/76.0.3809.71 Safari/537.36","version":""}

The output of your config.php file in /path/to/nextcloud:


<?php
$CONFIG = array (
  'instanceid' => '********************',
  'passwordsalt' => '******************',
  'secret' => '*******************',
  'trusted_domains' => 
  array (
    0 => 'cloud.nextcloud.nl',
  
  ),
  'datadirectory' => '/var/nc_data',
  'dbtype' => 'mysql',
  'version' => '19.0.5.2',
  'overwrite.cli.url' => 'https://cloud.nextcloud.nl',
  'dbname' => 'nextcloud',
  'dbhost' => 'localhost:/var/run/mysqld/mysqld.sock',
  'dbport' => '',
  'dbtableprefix' => 'oc_',
  'mysql.utf8mb4' => true,
  'dbuser' => 'nextcloud',
  'dbpassword' => 'nextcloud',
  'installed' => true,
  'activity_expire_days' => 14,
  'auth.bruteforce.protection.enabled' => true,
  'blacklisted_files' => 
  array (
    0 => '.htaccess',
    1 => 'Thumbs.db',
    2 => 'thumbs.db',
  ),
  'cron_log' => true,
  'enable_previews' => true,
  'enabledPreviewProviders' => 
  array (
    0 => 'OC\\Preview\\PNG',
    1 => 'OC\\Preview\\JPEG',
    2 => 'OC\\Preview\\GIF',
    3 => 'OC\\Preview\\BMP',
    4 => 'OC\\Preview\\XBitmap',
    5 => 'OC\\Preview\\Movie',
    6 => 'OC\\Preview\\PDF',
    7 => 'OC\\Preview\\MP3',
    8 => 'OC\\Preview\\TXT',
    9 => 'OC\\Preview\\MarkDown',
  ),
  'filesystem_check_changes' => 0,
  'filelocking.enabled' => 'true',
  'htaccess.RewriteBase' => '/',
  'integrity.check.disabled' => false,
  'knowledgebaseenabled' => false,
  'logfile' => '/var/nc_data/nextcloud.log',
  'loglevel' => 2,
  'logtimezone' => 'Europe/Berlin',
  'log_rotate_size' => 104857600,
  'maintenance' => false,
  'memcache.local' => '\\OC\\Memcache\\APCu',
  'memcache.locking' => '\\OC\\Memcache\\Redis',
  'overwriteprotocol' => 'https',
  'preview_max_x' => 1024,
  'preview_max_y' => 768,
  'preview_max_scale_factor' => 1,
  'redis' => 
  array (
    'host' => '/var/run/redis/redis-server.sock',
    'port' => 0,
    'timeout' => 0.0,
  ),
  'quota_include_external_storage' => false,
  'share_folder' => '/Shares',
  'skeletondirectory' => '',
  'theme' => '',
  'trashbin_retention_obligation' => 'auto, 7',
  'updater.release.channel' => 'stable',
  'mail_smtpmode' => 'smtp',
  'mail_smtpauth' => 1,
  'mail_sendmailmode' => 'smtp',
  'mail_from_address' => 'user',
  'mail_domain' => 'domein.nl',
  'mail_smtpauthtype' => 'LOGIN',
  'mail_smtphost' => 'smtp.mail.nl',
  'mail_smtpport' => '587',
  'mail_smtpname' => 'user',
  'mail_smtppassword' => 'jkkjkjkj',
  'twofactor_enforced' => 'true',
  'twofactor_enforced_groups' => 
  array (
  ),
  'twofactor_enforced_excluded_groups' => 
  array (
  ),
  'app_install_overwrite' => 
  array (
    0 => 'occweb',
  ),
);

The output of your Apache/nginx/system log in /var/log/____:

2021/01/23 12:11:21 [error] 1630#1630: *491 FastCGI sent in stderr: "PHP message: PHP Fatal error:  Uncaught Error: Call to a member function getRequest() on null in /var/www/nextcloud/remote.php:53
Stack trace:
#0 /var/www/nextcloud/remote.php(171): handleException()
#1 {main}
  thrown in /var/www/nextcloud/remote.php on line 53" while reading response header from upstream, client: 192.168.1.5, server: cloud.nextcloud.nl, request: "PROPFIND /remote.php/webdav/ HTTP/1.1", upstream: "fastcgi://unix:/run/php/php7.4-fpm.sock:", host: "cloud.nextcloud.nl"
2021/01/23 12:11:21 [error] 1630#1630: *562 FastCGI sent in stderr: "PHP message: PHP Parse error:  syntax error, unexpected '.168' (T_DNUMBER), expecting ')' in /var/www/nextcloud/config/config.php on line 9" while reading upstream, client: 192.168.1.77, server: cloud.nextcloud.nl, request: "GET / HTTP/2.0", upstream: "fastcgi://unix:/run/php/php7.4-fpm.sock:", host: "192.168.1.253"
2021/01/23 12:11:21 [error] 1630#1630: *562 FastCGI sent in stderr: "PHP message: PHP Parse error:  syntax error, unexpected '.168' (T_DNUMBER), expecting ')' in /var/www/nextcloud/config/config.php on line 9" while reading upstream, client: 192.168.1.77, server: cloud.nextcloud.nl, request: "GET /favicon.ico HTTP/2.0", upstream: "fastcgi://unix:/run/php/php7.4-fpm.sock:", host: "192.168.1.253"
2021/01/23 12:11:33 [error] 1630#1630: *565 FastCGI sent in stderr: "PHP message: PHP Parse error:  syntax error, unexpected '.168' (T_DNUMBER), expecting ')' in /var/www/nextcloud/config/config.php on line 9" while reading upstream, client: 192.168.1.5, server: cloud.nextcloud.nl, request: "GET / HTTP/2.0", upstream: "fastcgi://unix:/run/php/php7.4-fpm.sock:", host: "cloud.nextcloud.nl"
2021/01/23 12:11:33 [error] 1630#1630: *565 FastCGI sent in stderr: "PHP message: PHP Parse error:  syntax error, unexpected '.168' (T_DNUMBER), expecting ')' in /var/www/nextcloud/config/config.php on line 9" while reading upstream, client: 192.168.1.5, server: cloud.nextcloud.nl, request: "GET /favicon.ico HTTP/2.0", upstream: "fastcgi://unix:/run/php/php7.4-fpm.sock:", host: "cloud.nextcloud.nl"
2021/01/23 13:56:18 [crit] 789#789: *1 connect() to unix:/run/php/php7.4-fpm.sock failed (2: No such file or directory) while connecting to upstream, client: 192.168.1.5, server: cloud.nextcloud.nl, request: "GET /status.php HTTP/1.1", upstream: "fastcgi://unix:/run/php/php7.4-fpm.sock:", host: "cloud.nextcloud.nl"