Suddenly access to External Storage shares is lost [SOLVED]

Support intro

Sorry to hear you’re facing problems. :slightly_frowning_face:

The community help forum (help.nextcloud.com) is for home and non-enterprise users. Support is provided by other community members on a best effort / “as available” basis. All of those responding are volunteering their time to help you.

If you’re using Nextcloud in a business/critical setting, paid and SLA-based support services can be accessed via portal.nextcloud.com where Nextcloud engineers can help ensure your business keeps running smoothly.

Getting help

In order to help you as efficiently (and quickly!) as possible, please fill in as much of the below requested information as you can.

Before clicking submit: Please check if your query is already addressed via the following resources:

(Utilizing these existing resources is typically faster. It also helps reduce the load on our generous volunteers while elevating the signal to noise ratio of the forums otherwise arising from the same queries being posted repeatedly).

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:

The Basics

  • Nextcloud Server version (e.g., 29.x.x):
    • Autumn Hub 25 (32.0.1)
  • Operating system and version (e.g., Ubuntu 24.04):
    • TrueNAS Scale 25.04
  • Web server and version (e.g, Apache 2.4.25):
    • replace me
  • Reverse proxy and version _(e.g. nginx 1.27.2)
    • replace me
  • PHP version (e.g, 8.3):
    • replace me
  • Is this the first time you’ve seen this error? (Yes / No):
    • Yes
  • When did this problem seem to first start?
    • This morning after stopping Nextcloud app, moving a snapshot of Userdata from one pool to another pool in Truenas, editing the mount point in Truenas for Nextcloud userdata share and starting the nextcloud instance again.
  • Installation method (e.g. AlO, NCP, Bare Metal/Archive, etc.)
    • Truenas IX application
  • Are you using CloudfIare, mod_security, or similar? (Yes / No)
    • Using my own registered domain with SSL certificate

Summary of the issue you are facing:

Edit to add

Main issue: when login in via WebUI I cant access the SMB shares, getting the “failed to fetch” error. When login via desktop/mobile client (different machines) everything works as it should.

End edit

Original issue occurance: This morning after stopping Nextcloud app, moving a snapshot of Userdata from one pool to another pool in Truenas, editing the mount point in Truenas for Nextcloud userdata share and starting the nextcloud instance again.

Steps to replicate it (hint: details matter!):

  1. Working Nextcloud with several SMB shares mounted via External Storage. Both Nextcloud and these SMB shares are located on one and the same TrueNAS server

  2. For an upgrade of the server I want to move the dataset mnt/DataTank/Applications/Nextcloud/Userdata to another pool where it sits with the Postgress and AppData datashares (new path is thus mnt/Apps/Nextcloud/Userdata)

  3. Stopped NextCloud app. Created a snapshot of mnt/DataTank/Applications/Nextcloud/Userdata via CLI zfs snapshot creation, moving the snapshot to new path.

  4. Verified files in new file presence in new path via external file browser.

  5. Edited the mountpath of Userdata in Truenas application of Nextcloud to new file path. restarted Nextcloud

  6. Nextcloud starts properly, but each data folder gives an error with no further details, other than “look at External Storage settings”.

  7. Disconnecting the external storage mount points, and reconnecting them does not result in solving the issue.

Log entries

Nextcloud

Please provide the log entries from your Nextcloud log that are generated during the time of problem (via the Copy raw option from Administration settings->Logging screen or from your nextcloud.log located in your data directory). Feel free to use a pastebin/gist service if necessary.

{"reqId":"4YiXeeQbcNqN5ZMu4z0r","level":0,"time":"2025-10-27T10:37:42+00:00","remoteAddr":"xxx.xxx.xxx.xxx","user":"xxx","app":"files_external","method":"GET","url":"/settings/admin/log/download","message":"The loading of lazy AppConfig values have been triggered by app \"files_external\"","userAgent":"Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/141.0.0.0 Safari/537.36","version":"32.0.1.2","exception":{"Exception":"RuntimeException","Message":"The loading of lazy AppConfig values have been triggered by app \"files_external\"","Code":0,"Trace":[{"file":"/var/www/html/lib/private/AppConfig.php","line":492,"function":"loadConfig","class":"OC\\AppConfig","type":"->","args":["files_external",true]},{"file":"/var/www/html/lib/private/AppConfig.php","line":427,"function":"getTypedValue","class":"OC\\AppConfig","type":"->","args":["files_external","allow_user_mounting","0",true,32]},{"file":"/var/www/html/apps/files_external/lib/Service/BackendService.php","line":65,"function":"getValueBool","class":"OC\\AppConfig","type":"->","args":["files_external","allow_user_mounting"]},{"function":"__construct","class":"OCA\\Files_External\\Service\\BackendService","type":"->","args":[{"__class__":"OC\\AppConfig","cacheFactory":{"__class__":"OC\\Memcache\\Factory"}}]},{"file":"/var/www/html/lib/private/AppFramework/Utility/SimpleContainer.php","line":72,"function":"newInstanceArgs","class":"ReflectionClass","type":"->","args":[[{"__class__":"OC\\AppConfig","cacheFactory":{"__class__":"OC\\Memcache\\Factory"}}]]},{"file":"/var/www/html/lib/private/AppFramework/Utility/SimpleContainer.php","line":122,"function":"buildClass","class":"OC\\AppFramework\\Utility\\SimpleContainer","type":"->","args":[{"__class__":"ReflectionClass","name":"OCA\\Files_External\\Service\\BackendService"}]},{"file":"/var/www/html/lib/private/AppFramework/Utility/SimpleContainer.php","line":140,"function":"resolve","class":"OC\\AppFramework\\Utility\\SimpleContainer","type":"->","args":["OCA\\Files_External\\Service\\BackendService"]},{"file":"/var/www/html/lib/private/AppFramework/DependencyInjection/DIContainer.php","line":352,"function":"query","class":"OC\\AppFramework\\Utility\\SimpleContainer","type":"->","args":["OCA\\Files_External\\Service\\BackendService"]},{"file":"/var/www/html/lib/private/AppFramework/DependencyInjection/DIContainer.php","line":324,"function":"queryNoFallback","class":"OC\\AppFramework\\DependencyInjection\\DIContainer","type":"->","args":["OCA\\Files_External\\Service\\BackendService"]},{"file":"/var/www/html/lib/private/AppFramework/Utility/SimpleContainer.php","line":90,"function":"query","class":"OC\\AppFramework\\DependencyInjection\\DIContainer","type":"->","args":["OCA\\Files_External\\Service\\BackendService",true]},{"function":"OC\\AppFramework\\Utility\\{closure}","class":"OC\\AppFramework\\Utility\\SimpleContainer","type":"->","args":["*** sensitive parameters replaced ***"]},{"file":"/var/www/html/lib/private/AppFramework/Utility/SimpleContainer.php","line":77,"function":"array_map","args":[{"__class__":"Closure"},["*** sensitive parameters replaced ***",{"__class__":"ReflectionParameter","name":"dbConfig"},{"__class__":"ReflectionParameter","name":"userSession"},{"__class__":"ReflectionParameter","name":"userMountCache"},{"__class__":"ReflectionParameter","name":"eventDispatcher"}]]},{"file":"/var/www/html/lib/private/AppFramework/Utility/SimpleContainer.php","line":72,"function":"buildClassConstructorParameters","class":"OC\\AppFramework\\Utility\\SimpleContainer","type":"->","args":[{"__class__":"ReflectionMethod","name":"__construct","class":"OCA\\Files_External\\Service\\UserStoragesService"}]},{"file":"/var/www/html/lib/private/AppFramework/Utility/SimpleContainer.php","line":122,"function":"buildClass","class":"OC\\AppFramework\\Utility\\SimpleContainer","type":"->","args":[{"__class__":"ReflectionClass","name":"OCA\\Files_External\\Service\\UserStoragesService"}]},{"file":"/var/www/html/lib/private/AppFramework/Utility/SimpleContainer.php","line":140,"function":"resolve","class":"OC\\AppFramework\\Utility\\SimpleContainer","type":"->","args":["OCA\\Files_External\\Service\\UserStoragesService"]},{"file":"/var/www/html/lib/private/AppFramework/DependencyInjection/DIContainer.php","line":352,"function":"query","class":"OC\\AppFramework\\Utility\\SimpleContainer","type":"->","args":["OCA\\Files_External\\Service\\UserStoragesService"]},{"file":"/var/www/html/lib/private/AppFramework/DependencyInjection/DIContainer.php","line":324,"function":"queryNoFallback","class":"OC\\AppFramework\\DependencyInjection\\DIContainer","type":"->","args":["OCA\\Files_External\\Service\\UserStoragesService"]},{"file":"/var/www/html/lib/private/AppFramework/Utility/SimpleContainer.php","line":90,"function":"query","class":"OC\\AppFramework\\DependencyInjection\\DIContainer","type":"->","args":["OCA\\Files_External\\Service\\UserStoragesService",true]},{"function":"OC\\AppFramework\\Utility\\{closure}","class":"OC\\AppFramework\\Utility\\SimpleContainer","type":"->","args":["*** sensitive parameters replaced ***"]},{"file":"/var/www/html/lib/private/AppFramework/Utility/SimpleContainer.php","line":77,"function":"array_map","args":[{"__class__":"Closure"},["*** sensitive parameters replaced ***",{"__class__":"ReflectionParameter","name":"userGlobalStoragesService"},{"__class__":"ReflectionParameter","name":"clock"}]]},{"file":"/var/www/html/lib/private/AppFramework/Utility/SimpleContainer.php","line":72,"function":"buildClassConstructorParameters","class":"OC\\AppFramework\\Utility\\SimpleContainer","type":"->","args":[{"__class__":"ReflectionMethod","name":"__construct","class":"OCA\\Files_External\\Config\\ConfigAdapter"}]},{"file":"/var/www/html/lib/private/AppFramework/Utility/SimpleContainer.php","line":122,"function":"buildClass","class":"OC\\AppFramework\\Utility\\SimpleContainer","type":"->","args":[{"__class__":"ReflectionClass","name":"OCA\\Files_External\\Config\\ConfigAdapter"}]},{"file":"/var/www/html/lib/private/AppFramework/Utility/SimpleContainer.php","line":140,"function":"resolve","class":"OC\\AppFramework\\Utility\\SimpleContainer","type":"->","args":["OCA\\Files_External\\Config\\ConfigAdapter"]},{"file":"/var/www/html/lib/private/AppFramework/DependencyInjection/DIContainer.php","line":352,"function":"query","class":"OC\\AppFramework\\Utility\\SimpleContainer","type":"->","args":["OCA\\Files_External\\Config\\ConfigAdapter"]},{"file":"/var/www/html/lib/private/AppFramework/DependencyInjection/DIContainer.php","line":324,"function":"queryNoFallback","class":"OC\\AppFramework\\DependencyInjection\\DIContainer","type":"->","args":["OCA\\Files_External\\Config\\ConfigAdapter"]},{"file":"/var/www/html/lib/private/AppFramework/Utility/SimpleContainer.php","line":45,"function":"query","class":"OC\\AppFramework\\DependencyInjection\\DIContainer","type":"->","args":["OCA\\Files_External\\Config\\ConfigAdapter"]},{"file":"/var/www/html/lib/private/AppFramework/Bootstrap/FunctionInjector.php","line":32,"function":"get","class":"OC\\AppFramework\\Utility\\SimpleContainer","type":"->","args":["OCA\\Files_External\\Config\\ConfigAdapter"]},{"function":"OC\\AppFramework\\Bootstrap\\{closure}","class":"OC\\AppFramework\\Bootstrap\\FunctionInjector","type":"->","args":["*** sensitive parameters replaced ***"]},{"file":"/var/www/html/lib/private/AppFramework/Bootstrap/FunctionInjector.php","line":28,"function":"array_map","args":[{"__class__":"Closure"},[{"__class__":"ReflectionParameter","name":"mountProviderCollection"},"*** sensitive parameters replaced ***"]]},{"file":"/var/www/html/lib/private/AppFramework/Bootstrap/BootContext.php","line":32,"function":"injectFn","class":"OC\\AppFramework\\Bootstrap\\FunctionInjector","type":"->","args":[{"__class__":"Closure"}]},{"file":"/var/www/html/apps/files_external/lib/AppInfo/Application.php","line":79,"function":"injectFn","class":"OC\\AppFramework\\Bootstrap\\BootContext","type":"->","args":[{"__class__":"Closure"}]},{"file":"/var/www/html/lib/private/AppFramework/Bootstrap/Coordinator.php","line":170,"function":"boot","class":"OCA\\Files_External\\AppInfo\\Application","type":"->","args":[{"__class__":"OC\\AppFramework\\Bootstrap\\BootContext"}]},{"file":"/var/www/html/lib/private/App/AppManager.php","line":481,"function":"bootApp","class":"OC\\AppFramework\\Bootstrap\\Coordinator","type":"->","args":["files_external"]},{"file":"/var/www/html/lib/private/App/AppManager.php","line":273,"function":"loadApp","class":"OC\\App\\AppManager","type":"->","args":["files_external"]},{"file":"/var/www/html/lib/base.php","line":1021,"function":"loadApps","class":"OC\\App\\AppManager","type":"->","args":[]},{"file":"/var/www/html/index.php","line":25,"function":"handleRequest","class":"OC","type":"::","args":[]}],"File":"/var/www/html/lib/private/AppConfig.php","Line":1326,"message":"The loading of lazy AppConfig values have been triggered by app \"files_external\"","exception":{},"CustomMessage":"The loading of lazy AppConfig values have been triggered by app \"files_external\""}}

Web Browser

If the problem is related to the Web interface, open your browser inspector Console and Network tabs while refreshing (reloading) and reproducing the problem. Provide any relevant output/errors here that appear.

PASTE

Web server / Reverse Proxy

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

PASTE HERE

Configuration

Nextcloud

The output of occ config:list system or similar is best, but, if not possible, the contents of your config.php file from /path/to/nextcloud is fine (make sure to remove any identifiable information!):

<?php
$CONFIG = array (
  'htaccess.RewriteBase' => '/',
  'memcache.local' => '\\OC\\Memcache\\APCu',
  'apps_paths' => 
  array (
    0 => 
    array (
      'path' => '/var/www/html/apps',
      'url' => '/apps',
      'writable' => false,
    ),
    1 => 
    array (
      'path' => '/var/www/html/custom_apps',
      'url' => '/custom_apps',
      'writable' => true,
    ),
  ),
  'memcache.distributed' => '\\OC\\Memcache\\Redis',
  'memcache.locking' => '\\OC\\Memcache\\Redis',
  'redis' => 
  array (
    'host' => 'redis',
    'password' => 'password',
    'port' => 6379,
  ),
  'upgrade.disable-web' => true,
  'passwordsalt' => 'passwordalt',
  'secret' => 'secret',
  'datadirectory' => '/var/www/html/data',
  'dbtype' => 'pgsql',
  'version' => '32.0.1.2',
  'overwrite.cli.url' => 'mydomain',
  'overwritehost' => 'mydomain',
  'overwriteprotocol' => 'https',
  'dbname' => 'nextcloud',
  'dbhost' => 'postgres:5432',
  'dbport' => '',
  'dbtableprefix' => 'oc_',
  'dbuser' => 'name',
  'dbpassword' => 'password',
  'installed' => true,
  'instanceid' => 'ocdg2bc2ayz3',
  'preview_imaginary_url' => 'http://imaginary:9000',
  'twofactor_enforced' => 'true',
  'twofactor_enforced_groups' => 
  array (
  ),
  'twofactor_enforced_excluded_groups' => 
  array (
  ),
  'wopi' => 
  array (
    'allowlist' => 
    array (
      0 => 'https://mydomain:9980',
    ),
  ),
  'loglevel' => 0,
  'maintenance' => false,
  'maintenance_window_start' => 2,
  'default_phone_region' => 'country',
  'mail_smtpmode' => 'smtp',
  'mail_sendmailmode' => 'smtp',
  'mail_from_address' => 'name',
  'mail_domain' => 'my domain',
  'mail_smtphost' => 'smtp.mydomain',
  'mail_smtpport' => '465',
  'app_install_overwrite' => 
  array (
    0 => 'memories',
    1 => 'camerarawpreviews',
  ),
  'memories.db.triggers.fcu' => true,
  'memories.exiftool' => '/var/www/html/custom_apps/memories/bin-ext/exiftool-amd64-glibc',
  'memories.vod.path' => '/var/www/html/custom_apps/memories/bin-ext/go-vod-amd64',
  'memories.vod.ffmpeg' => '/usr/bin/ffmpeg',
  'memories.vod.ffprobe' => '/usr/bin/ffprobe',
  'config_preset' => 2,
  'memories.gis_type' => 2,
  'mail_smtpsecure' => 'ssl',
  'mail_smtpauth' => true,
  'mail_smtpname' => 'my mail',
  'mail_smtppassword' => 'my mail password',
  'trusted_domains' => 
  array (
    0 => 'xxx.0.0.1',
    1 => 'xxx.xxx.xxx.xxx',
    2 => 'mydomain',
    3 => 'localhost',
    4 => 'nextcloud',
  ),
);

Apps

The output of occ app:list (if possible).

Tips for increasing the likelihood of a response

  • Use the preformatted text formatting option in the editor for all log entries and configuration output.
  • If screenshots are useful, feel free to include them.
    • If possible, also include key error output in text form so it can be searched for.
  • Try to edit log output only minimally (if at all) so that it can be ran through analyzers / formatters by those trying to help you.

What I tried to resolve the issue:

  • moving the Nextcloud app setting in Truenas mount path of dataset Userdata back to its original dataset
  • disconnecting shares in Nextcloud External Storage, and reconnecting them
  • disconnecting shares in Nextcloud External Storage, restarting Nextcloud app from Truenas UI, connecting shares again
  • checked in Truenas if the NC container has access to the SMB shares, which it does. I can succesfully connect to individual SMB shares and see their contents via CLI inside the container.

Okay, I think I’m getting there. When logging in as user (instead of admin) I can see the folders and contents as usual in Nextcloud, nothing is wrong.

When I then log out, and login again as admin everything shows up, problem solved….

Unfortunately the issue is back again, but only for the webUI. The shares are perfectly accesible for Windows and Linux desktop clients, as well as for the mobile Nextcloud app (ANdroid). BUt logging into NExtcloud via web browser is not allowing me to connect to the shares, irrespective from which user account (admin or otherwise) I’m login in.