Nextcloud version: 20.0.2
Operating system and version: Ubuntu 20.0.4
Apache or nginx version: Apache 2.4.41
PHP version: 7.4.12
I have a couple of different SMB shares setup via External storages. One of them is working successfully with ‘$user’ as the remote subfolder, the others are failing to connect with any remote subfolder specified. This was previously working, but has stopped for some reason. I’ve been banging my head against the wall for a couple of weeks, off-and-on, trying to remedy the situation.
All SMB shares are hosted on a local TrueNAS core (v.12) server. There is a nextcloud user with full control of all the shares I am attempting to connect.
More specifically, the SMB share working as expected is ‘Pictures’. The ACLs for this share allow the desired user to access their own subdirectory, but no others, e.g. user1 can access Pictures > user1. The nextcloud user also has full control of Pictures and all subdirectories (full control meaning all permissions are allowed).
I have a second share with user data stored on it. Like the Pictures share, each user only has access to their own subdirectory, per the TrueNAS ACLs. The ACLs are setup the same for this share as above, for example Data > user1 can be accessed by user1 and nextcloud.
When accessing these network shares via Windows Explorer, the nextcloud user is able to navigate all directories, open folder, etc.
What Happens in NextCloud:
When attempting to setup the share in External storages, Pictures is setup as follows:
Host: 192.168.x.x Share: Pictures Remote subfolder: $user Domain: [blank] Show hidden files: no Verify ACL...: no Username: nextcloud Password: [nextcloud_user_password]
As mentioned above, this config successfully connects.
The following configuration for user data will connect IF Remote subfolder is blank. It will not connect when remote subfolder is populated with anything. I’ve tried $user and specific subfolder names.
Host: 192.168.x.x Share: nextcloud Remote subfolder: +/- [$user] or [actual_subfolder_name] Domain: [blank] Show hidden files: no Verify ACL...: no Username: nextcloud Password: [nextcloud_user_password]
I have gone as far as stripping and re-creating the ACLs for the shares. No change in the behavior seen in NextCloud. As mentioned above, these ACLs are exactly the same between Pictures and nextcloud shares. The only difference is that they’re hosted on two different data pools on the TrueNAS server.
Is this the first time you’ve seen this error? (Y/N): Y
Steps to replicate it:
- See above, in “What Happens in NextCloud”
The output of your Nextcloud log in Admin > Logging:
[no app in context] Info: External storage not available: stat() failed GET /apps/files_external/globalstorages/5?testOnly=true from 192.168.255.5 by matt at 2020-11-21T15:54:34+00:00
The output of your config.php file in
/path/to/nextcloud (make sure you remove any identifiable information!):
$CONFIG = array ( 'instanceid' => '[id]', 'passwordsalt' => '[salt]', 'secret' => '[secret]', 'trusted_domains' => array ( 0 => 'localhost', 1 => 'my.sub.domain', 2 => '[local_internal_ip]', 3 => '[local_external_ip]', ), 'datadirectory' => '/var/www/nextcloud-data', 'dbtype' => 'mysql', 'version' => '126.96.36.199', 'overwriteprotocol' => 'https', 'overwrite.cli.url' => 'https://my.sub.domain', 'htaccess.RewriteBase' => '/', 'dbname' => 'nextcloud', 'dbhost' => 'localhost', 'dbport' => '', 'dbtableprefix' => 'oc_', 'mysql.utf8mb4' => true, 'dbuser' => '[user]', 'dbpassword' => '[password]', 'installed' => true, 'mail_smtpmode' => 'smtp', 'mail_sendmailmode' => 'smtp', 'mail_smtpauthtype' => 'LOGIN', 'mail_smtpauth' => 1, 'mail_from_address' => 'admin', 'mail_domain' => '[domain]', 'mail_smtphost' => '[host]', 'mail_smtpport' => '587', 'mail_smtpname' => '[user_name]', 'mail_smtppassword' => '[password]', 'mail_smtpsecure' => 'tls', 'maintenance' => false, 'updater.secret' => '[secret]', 'theme' => '', 'loglevel' => 0, 'memcache.local' => '\\OC\\Memcache\\APCu', 'preview_libreoffice_path' => '/usr/bin/libreoffice', 'enable_previews' => true, 'enablePreviewProviders' => array ( 0 => 'OC\\Preview\\TXT', 1 => 'OC\\Preview\\MarkDown', 2 => 'OC\\Preview\\OpenDocument', 3 => 'OC\\Preview\\PDF', 4 => 'OC\\Preview\\MSOffice2003', 5 => 'OC\\Preview\\MSOfficeDoc', 6 => 'OC\\Preview\\PDF', 7 => 'OC\\Preview\\Image', 8 => 'OC\\Preview\\Photoshop', 9 => 'OC\\Preview\\TIFF', 10 => 'OC\\Preview\\SVG', 11 => 'OC\\Preview\\Font', 12 => 'OC\\Preview\\MP3', 13 => 'OC\\Preview\\Movie', 14 => 'OC\\Preview\\MKV', 15 => 'OC\\Preview\\MP4', 16 => 'OC\\Preview\\AVI', ), );
The output of your Apache/nginx/system log in