server icon indicating copy to clipboard operation
server copied to clipboard

Couldn't connect to external WebDAV storage -> Gallery doesn't work

Open igrekbs opened this issue 9 years ago • 6 comments

Steps to reproduce

  1. Add external WebDAV storage (Yandex.Disk https://disk.yandex.ru/)
  2. Configure type: WebDAV auth type: "username and password" link: "https://webdav.yandex.ru" (both with and w/o https:// prefix) cred.: xxxx xxxx (hidden) "https://": any (checked or unchecked) root dir: / or blank
  3. Status icon -> changes to green (seems it's all ok)

Expected behaviour

  1. Open folder with external storage & manipulate files and directories
  2. Open gallery and show pictures

Actual behaviour

  1. After trying to access external storage folder error occurs: Fatal WebDAV Sabre\DAV\Exception\ServiceUnavailable: HTTP/1.1 503 Storage is temporarily not available

  2. After trying to access gallery app after step 1. content doesn't load. and error occurs^ An error occurred. Request ID: wUSZyPlDjiD1uwTM07xH

Server configuration

Operating system: Ubuntu 16.04.2 LTS (GNU/Linux 4.4.0-72-generic x86_64)

Web server: Apache 2.4.18-2ubuntu3

Database: mysql 5.7.17

PHP version: 7.0.15

Nextcloud version: 11.0.2 (stable)

Updated from an older Nextcloud/ownCloud or fresh install: Updated from an older Nextcloud 11.0.1

Where did you install Nextcloud from: Official site

Signing status:

Signing status
No errors have been found.

List of activated apps:

App list
Enabled:
  - activity: 2.4.1
  - activitylog: 0.0.1
  - admin_audit: 1.1.0
  - admin_notifications: 1.0.0
  - announcementcenter: 3.0.0
  - audioplayer: 1.5.1
  - bookmarks: 0.9.1
  - calendar: 1.5.2
  - comments: 1.1.0
  - contacts: 1.5.3
  - dav: 1.1.1
  - federatedfilesharing: 1.1.1
  - federation: 1.1.1
  - files: 1.6.1
  - files_accesscontrol: 1.1.2
  - files_automatedtagging: 1.1.1
  - files_downloadactivity: 1.0.1
  - files_external: 1.1.2
  - files_pdfviewer: 1.0.1
  - files_reader: 1.0.4
  - files_retention: 1.0.1
  - files_sharing: 1.1.1
  - files_texteditor: 2.2
  - files_trashbin: 1.1.0
  - files_versions: 1.4.0
  - files_videoplayer: 1.0.0
  - firstrunwizard: 2.0
  - gallery: 16.0.0
  - logreader: 2.0.0
  - lookup_server_connector: 1.0.0
  - nextant: 1.0.6
  - nextcloud_announcements: 1.0
  - notifications: 1.0.1
  - password_policy: 1.1.0
  - provisioning_api: 1.1.0
  - serverinfo: 1.1.1
  - sharebymail: 1.0.1
  - spreed: 1.2.0
  - systemtags: 1.1.3
  - tasks: 0.9.5
  - theming: 1.1.1
  - twofactor_backupcodes: 1.0.0
  - updatenotification: 1.1.1
  - weather: 1.3.5
  - workflowengine: 1.1.1
Disabled:
  - encryption
  - external
  - survey_client
  - templateeditor
  - user_external
  - user_ldap
  - user_saml

Nextcloud configuration:

Config report
{
    "system": {
        "instanceid": "ocg....",
        "passwordsalt": "***REMOVED SENSITIVE VALUE***",
        "secret": "***REMOVED SENSITIVE VALUE***",
        "trusted_domains": [
            "xxxxxxxxxxxxxx",
            "xxxxxxxxxxxxxx",
            "xxxxxxxxxxxxxx",
            "xxxxxxxxxxxxxx"
        ],
        "datadirectory": "\/var\/strg\/ncdata\/data",
        "overwrite.cli.url": "https:\/\/xxxxxxxxxxxx",
        "dbtype": "mysql",
        "version": "11.0.2.7",
        "dbname": "xxxxxxxxxxxxxx",
        "dbhost": "localhost",
        "dbport": "",
        "dbtableprefix": "oc_",
        "dbuser": "***REMOVED SENSITIVE VALUE***",
        "dbpassword": "***REMOVED SENSITIVE VALUE***",
        "logtimezone": "UTC",
        "log_rotate_size": 10485760,
        "installed": true,
        "filelocking.enabled": true,
        "memcache.locking": "OC\\Memcache\\Redis",
        "memcache.local": "OC\\Memcache\\Redis",
        "redis": {
            "host": "\/var\/run\/redis\/redis.sock",
            "port": 0,
            "timeout": 0
        },
        "mail_from_address": "xxxxxxxxxx",
        "mail_smtpmode": "smtp",
        "mail_domain": "xxxxxxxxxx",
        "mail_smtpauth": 1,
        "mail_smtphost": "xxxxxxxxxx",
        "mail_smtpport": "25",
        "mail_smtpname": "***REMOVED SENSITIVE VALUE***",
        "mail_smtppassword": "***REMOVED SENSITIVE VALUE***",
        "loglevel": 0,
        "mail_smtpsecure": "tls",
        "mail_smtpauthtype": "LOGIN",
        "maintenance": false,
        "theme": "",
        "updater.release.channel": "stable",
        "updater.secret": "***REMOVED SENSITIVE VALUE***"
    }
}

Are you using external storage, if yes which one: WebDAV

Are you using encryption: no

Are you using an external user-backend, if yes which one: no

Client configuration

Browser: Firefox 52.0.2 (32 bit)

Operating system: Windows 10Pro, build 1703

Logs

Nextcloud log (data/nextcloud.log)

Nextcloud log
1. WebDAV external storage
Fatal	 webdav Sabre\DAV\Exception\ServiceUnavailable: HTTP/1.1 503 Storage is temporarily not available

    /var/www/nextcloud/3rdparty/sabre/dav/lib/DAV/Server.php - line 939: OCA\DAV\Connector\Sabre\ObjectTree->getNodeForPath('Yandex')
    /var/www/nextcloud/3rdparty/sabre/dav/lib/DAV/CorePlugin.php - line 336: Sabre\DAV\Server->getPropertiesForPath('Yandex', Array, 1)
    [internal function] Sabre\DAV\CorePlugin->httpPropFind(Object(Sabre\HTTP\Request), Object(Sabre\HTTP\Response))
    /var/www/nextcloud/3rdparty/sabre/event/lib/EventEmitterTrait.php - line 105: call_user_func_array(Array, Array)
    /var/www/nextcloud/3rdparty/sabre/dav/lib/DAV/Server.php - line 479: Sabre\Event\EventEmitter->emit('method PROPFIND', Array)
    /var/www/nextcloud/3rdparty/sabre/dav/lib/DAV/Server.php - line 254: Sabre\DAV\Server->invokeMethod(Object(Sabre\HTTP\Request), Object(Sabre\HTTP\Response))
    /var/www/nextcloud/apps/dav/appinfo/v1/webdav.php - line 60: Sabre\DAV\Server->exec()
    /var/www/nextcloud/remote.php - line 165: require_once('/var/www/nextcl...')
    {main}


2. Gallery

Error	gallery OCP\Files\StorageNotAvailableException: Storage with mount id 1 is not available

    /var/www/nextcloud/lib/private/Files/Storage/Wrapper/Wrapper.php - line 588: OC\Files\Storage\FailedStorage->acquireLock('.nomedia', 1, Object(OC\Lock\MemcacheLockingProvider))
    /var/www/nextcloud/lib/private/Files/Storage/Wrapper/Wrapper.php - line 588: OC\Files\Storage\Wrapper\Wrapper->acquireLock('.nomedia', 1, Object(OC\Lock\MemcacheLockingProvider))
    /var/www/nextcloud/lib/private/Files/Storage/Wrapper/Wrapper.php - line 588: OC\Files\Storage\Wrapper\Wrapper->acquireLock('.nomedia', 1, Object(OC\Lock\MemcacheLockingProvider))
    /var/www/nextcloud/lib/private/Files/Storage/Wrapper/Wrapper.php - line 588: OC\Files\Storage\Wrapper\Wrapper->acquireLock('.nomedia', 1, Object(OC\Lock\MemcacheLockingProvider))
    /var/www/nextcloud/lib/private/Files/Storage/Wrapper/Wrapper.php - line 588: OC\Files\Storage\Wrapper\Wrapper->acquireLock('.nomedia', 1, Object(OC\Lock\MemcacheLockingProvider))
    /var/www/nextcloud/lib/private/Files/Storage/Wrapper/Wrapper.php - line 588: OC\Files\Storage\Wrapper\Wrapper->acquireLock('.nomedia', 1, Object(OC\Lock\MemcacheLockingProvider))
    /var/www/nextcloud/lib/private/Files/View.php - line 1894: OC\Files\Storage\Wrapper\Wrapper->acquireLock('.nomedia', 1, Object(OC\Lock\MemcacheLockingProvider))
    /var/www/nextcloud/lib/private/Files/View.php - line 1997: OC\Files\View->lockPath('/xxxx/files/Yan...', 1, false)
    /var/www/nextcloud/lib/private/Files/View.php - line 1295: OC\Files\View->lockFile('/xxxx/files/Yan...', 1)
    /var/www/nextcloud/lib/private/Files/View.php - line 1342: OC\Files\View->getCacheEntry(Object(OCA\FilesAccessControl\StorageWrapper), '.nomedia', '/xxxx/files/Yan...')
    /var/www/nextcloud/lib/private/Files/Node/Root.php - line 196: OC\Files\View->getFileInfo('/xxxx/files/Yan...')
    /var/www/nextcloud/lib/private/Files/Node/Folder.php - line 122: OC\Files\Node\Root->get('/xxxx/files/Yan...')
    /var/www/nextcloud/lib/private/Files/Node/Folder.php - line 131: OC\Files\Node\Folder->get('.nomedia')
    /var/www/nextcloud/apps/gallery/service/filesservice.php - line 145: OC\Files\Node\Folder->nodeExists('.nomedia')
    /var/www/nextcloud/apps/gallery/service/searchmediaservice.php - line 67: OCA\Gallery\Service\FilesService->getAllowedSubFolder(Object(OC\Files\Node\Folder), 'dir')
    /var/www/nextcloud/apps/gallery/service/searchmediaservice.php - line 44: OCA\Gallery\Service\SearchMediaService->searchFolder(Object(OC\Files\Node\Folder))
    /var/www/nextcloud/apps/gallery/controller/files.php - line 76: OCA\Gallery\Service\SearchMediaService->getMediaFiles(Object(OC\Files\Node\Folder), Array, Array)
    /var/www/nextcloud/apps/gallery/controller/filescontroller.php - line 98: OCA\Gallery\Controller\FilesController->getFilesAndAlbums('', Array, '', Array)
    [internal function] OCA\Gallery\Controller\FilesController->getList('', '', '', 'image/png;image...')
    /var/www/nextcloud/lib/private/AppFramework/Http/Dispatcher.php - line 160: call_user_func_array(Array, Array)
    /var/www/nextcloud/lib/private/AppFramework/Http/Dispatcher.php - line 90: OC\AppFramework\Http\Dispatcher->executeController(Object(OCA\Gallery\Controller\FilesController), 'getList')
    /var/www/nextcloud/lib/private/AppFramework/App.php - line 114: OC\AppFramework\Http\Dispatcher->dispatch(Object(OCA\Gallery\Controller\FilesController), 'getList')
    /var/www/nextcloud/lib/private/AppFramework/Routing/RouteActionHandler.php - line 47: OC\AppFramework\App main('FilesController', 'getList', Object(OC\AppFramework\DependencyInjection\DIContainer), Array)
    [internal function] OC\AppFramework\Routing\RouteActionHandler->__invoke(Array)
    /var/www/nextcloud/lib/private/Route/Router.php - line 299: call_user_func(Object(OC\AppFramework\Routing\RouteActionHandler), Array)
    /var/www/nextcloud/lib/base.php - line 1010: OC\Route\Router->match('/apps/gallery/f...')
    /var/www/nextcloud/index.php - line 40: OC handleRequest()
    {main}

igrekbs avatar Apr 19 '17 07:04 igrekbs

I can confirm, same here!

OS Ubuntu 16.04.2 NC 11.0.3.2 PHP Version: 7.0.15 mysql Version: 5.7.17

Nextcloud log Fatal webdav Sabre\DAV\Exception\ServiceUnavailable: HTTP/1.1 503 Storage is temporarily not available /var/www/nextcloud/3rdparty/sabre/dav/lib/DAV/Server.php - line 939: OCA\DAV\Connector\Sabre\ObjectTree->getNodeForPath('YANDEX') /var/www/nextcloud/3rdparty/sabre/dav/lib/DAV/CorePlugin.php - line 336: Sabre\DAV\Server->getPropertiesForPath('YANDEX', Array, 1) [internal function] Sabre\DAV\CorePlugin->httpPropFind(Object(Sabre\HTTP\Request), Object(Sabre\HTTP\Response)) /var/www/nextcloud/3rdparty/sabre/event/lib/EventEmitterTrait.php - line 105: call_user_func_array(Array, Array) /var/www/nextcloud/3rdparty/sabre/dav/lib/DAV/Server.php - line 479: Sabre\Event\EventEmitter->emit('method PROPFIND', Array) /var/www/nextcloud/3rdparty/sabre/dav/lib/DAV/Server.php - line 254: Sabre\DAV\Server->invokeMethod(Object(Sabre\HTTP\Request), Object(Sabre\HTTP\Response)) /var/www/nextcloud/apps/dav/appinfo/v1/webdav.php - line 60: Sabre\DAV\Server->exec() /var/www/nextcloud/remote.php - line 165: require_once('/var/www/nextcl...') {main}

kknishev avatar Apr 21 '17 14:04 kknishev

in Nextcloud 12 Beta 3 its still not working and the patch is in place.

lefty78 avatar May 16 '17 19:05 lefty78

in Nextcloud 12 Beta 3 its still not working and the patch is in place.

Same error message?

MorrisJobke avatar May 17 '17 02:05 MorrisJobke

In Yandex:

  1. Create an application password in Yandex for WebDAV (https://yandex.com/support/passport/authorization/app-passwords.html) go to https://passport.yandex.ru/profile Access management:
  • Enable app passwords
  • Create an app password: select "Webdav", "Name of password for access to files": nextcloud

In Nextcloud 12.0.0:

  1. Add external WebDAV storage (Yandex Disk)
  2. Configure catalog name: #disk.yandex type: WebDAV auth type: username and password link: https://webdav.yandex.ru root dir: / checked https:// login: mylogin (without @yandex.ru) password: app password from Yandex for WebDAV (see step 1)
  3. Status icon -> changes to green

Checked, external storage opens.

mnsold avatar Jun 18 '17 21:06 mnsold

Confirm. Ver. 12.0.0 yandex storage opens correctly!

igrekbs avatar Jun 18 '17 22:06 igrekbs