AH01797: client denied by server configuration

  • Nextcloud version: 12.0.0.29
  • Operating system and version: Debian 8.8
  • Apache or nginx version: Apache 2.4.26
  • PHP version: 7.0.19
  • Is this the first time you’ve seen this error?: Yes
  • Can you reliably replicate it? (If so, please outline steps): Yes, with a default clean install of Nextcloud.

The issue you are facing: Basically only have read access to all the files after migrating from Owncloud 9.1 to Nextcloud 12. When trying to write something, for example create a New folder, I always get:

Could not create folder “New folder”

Everything else works as expected, all the files are just read only though, nothing can be change or added. When I install a fresh instance of Nextcloud on the same server with a SQLite db the exact same problem occurs. The old OwnCloud 9.1 install worked perfectly and never had this problem. Any ideas on how to fix this, any help would be greatly appreciated of course.

The output of your Nextcloud log in Admin > Logging:

Nothing gets logged when trying to create a New folder, upload file, delete files etc, even with loglevel’ => 0 unfortunately.

The output of your config.php file in /path/to/nextcloud (make sure you remove any identifiable information!):

<?php
$CONFIG = array (
  'instanceid' => 'xxxxxxxxxxx',
  'passwordsalt' => 'xxxxxxxxxxxxx',
  'trusted_domains' =>
  array (
    0 => 'testdomain.com',
  ),
  
  'dbtype' => 'mysql',
  'version' => '12.0.0.29',
  'dbname' => 'user_owncloud',
  'dbhost' => 'localhost',
  'dbtableprefix' => 'oc_',
  'dbuser' => 'user_owncloud',
  'dbpassword' => 'xxxxxxxxxxxx',
  'installed' => true,
  'mail_from_address' => 'info',
  'mail_smtpmode' => 'php',
  'mail_domain' => 'testdomain.com',
  'loglevel' => 0,
  'theme' => '',
  'maintenance' => false,
  'secret' => 'xxxxxxxxxxxxxx',
  'updatechecker' => false,
  'trashbin_retention_obligation' => 'auto',
  'updater.secret' => 'xxxxxxxxxxxxxxxxx',
  'updater.release.channel' => 'stable',
  'overwrite.cli.url' => 'https://testdomain.com/cloud',
);

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

[Fri Jun 23 01:21:47.617135 2017] [access_compat:error] [pid 655] [client 82.161.218.47:57562] AH01797: client denied by server configuration: /home/user/domains/testdomain.com/private_html/nextcloud/remote.php
[Fri Jun 23 01:21:54.402978 2017] [access_compat:error] [pid 655] [client 82.161.218.47:57562] AH01797: client denied by server configuration: /home/user/domains/testdomain.com/private_html/nextcloud/index.php
[Fri Jun 23 01:22:06.788719 2017] [access_compat:error] [pid 659] [client 82.161.218.47:57570] AH01797: client denied by server configuration: /home/user/domains/testdomain.com/private_html/nextcloud/index.php
[Fri Jun 23 01:22:09.580251 2017] [access_compat:error] [pid 667] [client 82.161.218.47:57580] AH01797: client denied by server configuration: /home/user/domains/testdomain.com/private_html/nextcloud/remote.php
[Fri Jun 23 01:24:51.974365 2017] [access_compat:error] [pid 667] [client 82.161.218.47:57605] AH01797: client denied by server configuration: /home/user/domains/testdomain.com/private_html/nextcloud/remote.php
[Fri Jun 23 01:26:58.307839 2017] [access_compat:error] [pid 673] [client 82.161.218.47:57817] AH01797: client denied by server configuration: /home/user/domains/testdomain.com/private_html/nextcloud/remote.php

Already found the solution from:

https://docs.nextcloud.com/server/12/admin_manual/installation/source_installation.html#apache-web-server-configuration

Adding this to the Apache config solved it:

<Directory /home/user/domains/testdomain.com/private_html/nextcloud/>
 Satisfy Any 
</Directory>

Did not help here.

2 Likes