Federated Shares showing size of "Pending" "Storage is temporarily unnavailable"

Nextcloud version 16.03
Ubuntu 18.04
Apache/2.4.38
PHP version 7.2.16

The issue you are facing:

Afeter sharing a folder between instances, the web interface displays the folder size as “Pending”. When trying to access it, it replays with “Storage is termporarily not available”.

The logs show a " Sabre\DAV\Exception\ServiceUnavailable:"

Is this the first time you’ve seen this error?

No

Steps to replicate it:

  1. Share a folder with a user in another Nextcloud instance.
  2. The user accepts the share, the folder appears on his web interface
  3. The user can´t access the shared folder.

The output of your Nextcloud log in Admin > Logging:

Sabre\DAV\Exception\ServiceUnavailable: 

    /var/www/html/nextcloud/3rdparty/sabre/dav/lib/DAV/Tree.php - line 76:

    OCA\DAV\Connector\Sabre\Directory->getChild("P020_Dubai_BurjDubai")

    /var/www/html/nextcloud/3rdparty/sabre/dav/lib/DAV/Server.php - line 967:

    Sabre\DAV\Tree->getNodeForPath("files/test/ ... i")

    /var/www/html/nextcloud/3rdparty/sabre/dav/lib/DAV/Server.php - line 1666:

    Sabre\DAV\Server->getPropertiesIteratorForPath("files/test/ ... i", [ "{DAV:}get ... "], 1)

    /var/www/html/nextcloud/3rdparty/sabre/dav/lib/DAV/CorePlugin.php - line 355:

    Sabre\DAV\Server->generateMultiStatus(Generator {}, false)

    <<closure>>

    Sabre\DAV\CorePlugin->httpPropFind(Sabre\HTTP\R ... "}, Sabre\HTTP\Response {})

    /var/www/html/nextcloud/3rdparty/sabre/event/lib/EventEmitterTrait.php - line 105:

    call_user_func_array([ Sabre\DAV\ ... "], [ Sabre\HTTP ... }])

    /var/www/html/nextcloud/3rdparty/sabre/dav/lib/DAV/Server.php - line 479:

    Sabre\Event\EventEmitter->emit("method:PROPFIND", [ Sabre\HTTP ... }])

    /var/www/html/nextcloud/3rdparty/sabre/dav/lib/DAV/Server.php - line 254:

    Sabre\DAV\Server->invokeMethod(Sabre\HTTP\R ... "}, Sabre\HTTP\Response {})

    /var/www/html/nextcloud/apps/dav/lib/Server.php - line 316:

    Sabre\DAV\Server->exec()

    /var/www/html/nextcloud/apps/dav/appinfo/v2/remote.php - line 35:

    OCA\DAV\Server->exec()

    /var/www/html/nextcloud/remote.php - line 163:

    require_once("/var/www/ht ... p")

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

<?php
$CONFIG = array (
  'instanceid' => '*****',
  'passwordsalt' => '',
  'secret' => '',
  'trusted_domains' =>
  array (
    0 => '',
  ),
  'datadirectory' => '/var/www/nextcloud/data',
  'dbtype' => 'mysql',
  'version' => '16.0.3.0',
  'overwrite.cli.url' => 'https://',
  'dbname' => '',
  'dbhost' => 'localhost',
  'dbport' => '',
  'dbtableprefix' => 'oc_',
  'dbuser' => 'nextcloud',
  'dbpassword' => '',
  'skeletondirectory' => '',
  'installed' => true,
  'ldapIgnoreNamingRules' => false,
  'ldapProviderFactory' => 'OCA\\User_LDAP\\LDAPProviderFactory',
  'mail_from_address' => '',
  'mail_smtpauthtype' => 'LOGIN',
  'mail_smtpauth' => 1,
  'mail_smtphost' => '',
  'mail_smtpport' => '587 ',
  'mail_smtpsecure' => 'tls',
  'mail_smtpname' => '',
  'mail_smtppassword' => '',
  'memcache.local' => '\\OC\\Memcache\\APCu',
  'loglevel' => 2,
  'filelocking.ttl' => 14400,
  'updater.release.channel' => 'stable',
  'mail_domain' => '',
  'mail_smtpmode' => 'smtp',
  'maintenance' => false,
  'simpleSignUpLink.shown' => false,
  'theme' => '',
  'mysql.utf8mb4' => false,
);


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

[Wed Aug 07 06:25:17.133259 2019] [:notice] [pid 4360:tid 140530471225216] FastCGI: process manager initialized (pid 4360)
[Wed Aug 07 06:25:17.134739 2019] [ssl:warn] [pid 26590:tid 140530471225216] AH01909: vmi114328.contaboserver.net:443:0 server certificate does NOT include an ID which matches the server name
[Wed Aug 07 06:25:17.140913 2019] [mpm_event:notice] [pid 26590:tid 140530471225216] AH00489: Apache/2.4.38 (Ubuntu) mod_fastcgi/mod_fastcgi-SNAP-0910052141 OpenSSL/1.1.1b configured -- resuming normal operations
[Wed Aug 07 06:25:17.140947 2019] [core:notice] [pid 26590:tid 140530471225216] AH00094: Command line: '/usr/sbin/apache2'
[Wed Aug 07 08:59:25.699703 2019] [authz_core:error] [pid 4362:tid 140530027820800] [client 85.52.79.29:50369] AH01630: client denied by server configuration: /var/www/nextcloud/config
[Wed Aug 07 09:45:52.209049 2019] [authz_core:error] [pid 4362:tid 140529903851264] [client 85.52.79.29:61457] AH01630: client denied by server configuration: /var/www/nextcloud/config
[Wed Aug 07 11:09:05.563529 2019] [proxy_fcgi:error] [pid 4362:tid 140529777960704] [client 85.52.79.29:56492] AH01071: Got error 'PHP message: PHP Fatal error:  Uncaught PDOException: SQLSTATE[40001]: Serialization failure: 1213 Deadlock found when trying to get lock; try restarting transaction in /var/www/nextcloud/3rdparty/doctrine/dbal/lib/Doctrine/DBAL/Driver/PDOStatement.php:141\nStack trace:\n#0 /var/www/nextcloud/3rdparty/doctrine/dbal/lib/Doctrine/DBAL/Driver/PDOStatement.php(141): PDOStatement->execute(NULL)\n#1 /var/www/nextcloud/3rdparty/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(1079): Doctrine\\DBAL\\Driver\\PDOStatement->execute()\n#2 /var/www/nextcloud/lib/private/DB/Connection.php(216): Doctrine\\DBAL\\Connection->executeUpdate('UPDATE `oc_file...', Array, Array)\n#3 /var/www/nextcloud/3rdparty/doctrine/dbal/lib/Doctrine/DBAL/Query/QueryBuilder.php(222): OC\\DB\\Connection->executeUpdate('UPDATE `oc_file...', Array, Array)\n#4 /var/www/nextcloud/lib/private/DB/QueryBuilder/QueryBuilder.php(214): Doctrine\\DBAL\\Query\\QueryBuilder->execute()\n#5 /var/www/nextcloud/lib/private/Lock/DBLockingProvider.php(314): OC\\DB\\QueryBuilder\\Qu...\n'
[Wed Aug 07 11:40:37.832210 2019] [authz_core:error] [pid 4362:tid 140530111870720] [client 85.52.79.29:40760] AH01630: client denied by server configuration: /var/www/nextcloud/data/.ocdata
[Wed Aug 07 11:59:11.851290 2019] [proxy_fcgi:error] [pid 4362:tid 140529794746112] [client 85.52.79.29:34462] AH01071: Got error 'PHP message: PHP Fatal error:  Uncaught PDOException: SQLSTATE[40001]: Serialization failure: 1213 Deadlock found when trying to get lock; try restarting transaction in /var/www/nextcloud/3rdparty/doctrine/dbal/lib/Doctrine/DBAL/Driver/PDOStatement.php:141\nStack trace:\n#0 /var/www/nextcloud/3rdparty/doctrine/dbal/lib/Doctrine/DBAL/Driver/PDOStatement.php(141): PDOStatement->execute(NULL)\n#1 /var/www/nextcloud/3rdparty/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(1079): Doctrine\\DBAL\\Driver\\PDOStatement->execute()\n#2 /var/www/nextcloud/lib/private/DB/Connection.php(216): Doctrine\\DBAL\\Connection->executeUpdate('UPDATE `oc_file...', Array, Array)\n#3 /var/www/nextcloud/3rdparty/doctrine/dbal/lib/Doctrine/DBAL/Query/QueryBuilder.php(222): OC\\DB\\Connection->executeUpdate('UPDATE `oc_file...', Array, Array)\n#4 /var/www/nextcloud/lib/private/DB/QueryBuilder/QueryBuilder.php(214): Doctrine\\DBAL\\Query\\QueryBuilder->execute()\n#5 /var/www/nextcloud/lib/private/Lock/DBLockingProvider.php(314): OC\\DB\\QueryBuilder\\Qu...\n'
[Wed Aug 07 12:10:32.741988 2019] [authz_core:error] [pid 4363:tid 140530036221696] [client 81.39.110.164:1612] AH01630: client denied by server configuration: /var/www/nextcloud/config

Updated with (hopefully) relevant information from the logs

Ok, so I did some testing. Seems to be a size/complexity issue.

If I send a federated share of a single file or a folder with some files and subfolders in it, everything goes according to plan.

However, the folder I need to share is a 120GB project, with a very strict structure of hundreds of sub folders and thousands of files.

So is this a known issue or limit? or should it work regardless of size and folder structure?

Any help would be useful.

Thanks

I’m having the same issue with Nextcloud 17. I’m the end user trying to access 70GB worth of files.

Is there any progress on this issue? We are facing exact the same beahviour…

We try to share a folder to another NC instance via Federated Sharing which has thousands of files / subfolders. On the remote cloud the column “size” shows “pending” for the shared folder.
After clicking the shared folder the main screen gets blank, the spinner is shown and after 30-60 seconds the screens jumps back and the mentioned error “Storage is temporarily unavailable” is shown, exact the error from the ThreadOwner is in the NC Log.

Both clouds are NC 17.0.3 …

1 Like

Nothing, I ended up getting a massive single server to host all the data, and mounting external storages if needed.

Federation sounds cool, but it has been a massive pain in the ass every time I´ve tried to use it. I don´t think it´s reliable or resilient enough for deployment yet.

Sorry.

I am also interested in a solution to this.

We are having the exact same issues as described above, size showing pending / Storage is temporarily unavailable with a share of ~15Gb, lots of files.
Smaller shares work as expected.

We are thinking about sharing the big share using the nc sync tool with an account on the source server.