I followed the tutorial for installing Nextcloud on Ubuntu 18.04, but I get to the last step I get a 404 at the end..

Posted May 13, 2019 1.1k views
UbuntuGetting Started

I followed the steps in the tutorial on installing Nextcloud on an Ubuntu 18.04 server, but when I got to the last step I wasn’t able to configure Nextcloud because I got a 404 message. I’ve tried changing the ownership of the Nextcloud directory but I still get 404. Can anyone help?

1 comment
  • Hello,

    It’s possible the configuration file is wrong. Can you provide you it here in order to see if everything is correct?

    Alongside the configuration file, can you please confirm the following :

    Path to the root of your installation
    Ownership of the root folder
    Permissions of the root folder
    Have you created the database for the service

    Once we have this information, we should be able to further troubleshoot the problem.

    Looking forward to your reply.

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Submit an Answer
1 answer

Thanks for the help! Here’s the content of my config.php file, found in /var/www/html/nextcloud/config/config.php:

$CONFIG = array (
  'instanceid' => 'ocqwzk5v4jkq',
  'passwordsalt' => 'F49DxXdKC9Rfmao/FbDSpg8AXF87yG',
  'secret' => 'hNgBS5HBfGPwa4sYIf/lN/Bl0JV474LkxsciZITDNtN5hopU',
  'trusted_domains' => 
  array (
    0 => '',
  'datadirectory' => '/var/www/html/nextcloud/data',
  'dbtype' => 'mysql',
  'version' => '',
  'overwrite.cli.url' => '',
  'dbname' => 'nextcloud',
  'dbhost' => 'localhost:5432',
  'dbport' => '',
  'dbtableprefix' => 'oc_',
  'dbuser' => 'kwright',
  'dbpassword' => 'wizard',
  'installed' => true,

As seen above, the path to the Nextcloud root is /var/www/html/nextcloud. It is owned by the www-data user, and its permissions are 755. The database has been created, with the name nextcloud.

edited by MattIPv4
  • Okay, I’ve been poking around a little bit. I looked at nextcloud/index.html and found a missing opening quote. I put it in and now I’m no longer getting 404; I’m just getting blank pages. I suppose that’s some sort of progress?