desktop
desktop copied to clipboard
`You have no permission to write to the selected folder` checkPathValidityForNewFolder failes for SMB-folders
I am using the Windows Desktop Client to sync a folder located on a SMB share to a self hosted nextcloud instance. This worked for Versions up to 3.1.3. Starting with 3.2.0-rc1 (tested up to 3.4.4) a error ("You have no permission to write to the selected folder!
") appears when adding a folder synchronization pair. My account has full write permission for the share/folder, creating files using Windows Explorer, Folder Wizard (new folder) or Settings-GUI (save debug logs) works fine. Folders located on local disks work as expected.
Ref: https://help.nextcloud.com/t/you-have-no-permission-to-write-to-the-selected-folder/125486
Expected behaviour
Add writable SMB-folder to sync pair
Actual behaviour
Error You have no permission to write to the selected folder!
is displayed while writing should work fine. Next-button is disabled.
Steps to reproduce
- Map a NAS drive using SMB ("Windows file share") to a local drive letter (Tested targets: Samba 4.9.x, Windows Server 2012R2, Windows 10)
- Install Windows Client 3.2.0 - 3.4.4
- Connect to a NC Server
- When asked for a local directory browse to the mapped drive, create an empty folder using the NC GUI (aka: prove it is writable) and try to select it
Client configuration
Client version:
- 3.2.0-rc1 (x64)
- 3.3.5stable-Win64 (build 20210930); 0d9a6987ebb0040b34451e51f54121dbd339ddf8; Sep 30 2021, 13:30:50; Qt 5.12.10, OpenSSL 1.1.1g 21 Apr 2020
- (Answers: 3.4.1-3.4.4)
Operating system:
- Windows 10 Pro
- Windows 11
- (Forum: Windows 8.1)
OS language:
- German
- English
Installation path of client: Default (C:\Program Files\Nextcloud)
Logs
- Client logfile (Win10 German 3.3.5):
2021-10-19 21:34:24:941 [ info nextcloud.gui.folder.manager ]: Folders to sync: 0
2021-10-19 21:34:24:941 [ info nextcloud.gui.folder.manager ]: Number of folders that don't use push notifications: 0
2021-10-19 21:34:37:263 [ debug nextcloud.gui.folder.manager ] [ OCC::FolderMan::checkPathValidityForNewFolder ]: "d" "Sie haben keine Schreibberechtigung für den ausgewählten Ordner!"
2021-10-19 21:34:37:263 [ debug nextcloud.gui.folder.manager ] [ OCC::FolderMan::checkPathValidityForNewFolder ]: "d" "Sie haben keine Schreibberechtigung für den ausgewählten Ordner!"
2021-10-19 21:34:37:264 [ debug nextcloud.gui.folder.manager ] [ OCC::FolderMan::checkPathValidityForNewFolder ]: "d" "Sie haben keine Schreibberechtigung für den ausgewählten Ordner!"
2021-10-19 21:34:37:440 [ debug nextcloud.gui.folder.manager ] [ OCC::FolderMan::checkPathValidityForNewFolder ]: "d:" "Sie haben keine Schreibberechtigung für den ausgewählten Ordner!"
2021-10-19 21:34:37:666 [ debug nextcloud.gui.folder.manager ] [ OCC::FolderMan::checkPathValidityForNewFolder ]: "d:/" "Sie haben keine Schreibberechtigung für den ausgewählten Ordner!"
2021-10-19 21:34:38:317 [ debug nextcloud.gui.folder.manager ] [ OCC::FolderMan::checkPathValidityForNewFolder ]: "d:/o" "Sie haben keine Schreibberechtigung für den ausgewählten Ordner!"
2021-10-19 21:34:38:423 [ debug nextcloud.gui.folder.manager ] [ OCC::FolderMan::checkPathValidityForNewFolder ]: "d:/ow" "Sie haben keine Schreibberechtigung für den ausgewählten Ordner!"
2021-10-19 21:34:38:643 [ debug nextcloud.gui.folder.manager ] [ OCC::FolderMan::checkPathValidityForNewFolder ]: "d:/own" "Sie haben keine Schreibberechtigung für den ausgewählten Ordner!"
2021-10-19 21:34:52:133 [ debug nextcloud.gui.folder.manager ] [ OCC::FolderMan::checkPathValidityForNewFolder ]: "D:/Owncloud-Test/test2" "Sie haben keine Schreibberechtigung für den ausgewählten Ordner!"
2021-10-19 21:34:52:208 [ debug nextcloud.gui.folder.manager ] [ OCC::FolderMan::checkPathValidityForNewFolder ]: "D:/Owncloud-Test/test2" "Sie haben keine Schreibberechtigung für den ausgewählten Ordner!"
2021-10-19 21:34:52:279 [ debug nextcloud.gui.folder.manager ] [ OCC::FolderMan::checkPathValidityForNewFolder ]: "D:/Owncloud-Test/test2" "Sie haben keine Schreibberechtigung für den ausgewählten Ordner!"
2021-10-19 21:34:54:942 [ info nextcloud.gui.folder.manager ]: Etag poll timer timeout
2021-10-19 21:34:54:942 [ info nextcloud.gui.folder.manager ]: Folders to sync: 0
2021-10-19 21:34:54:942 [ info nextcloud.gui.folder.manager ]: Number of folders that don't use push notifications: 0
2021-10-19 21:34:56:244 [ info nextcloud.gui.account.settings ]: Folder wizard cancelled
Same behaviour if using \\servername\share
Syntax instead of a local drive letter.
- Confirmed this is still an issue on 3.4.1.
I am having the same issue! +1
+1
+1
+1
+1 here as well. If I can provide anything to help reproduce, test, or provide info for this, I'm happy to. This is a fairly critical piece of my nextcloud syncing workflow.
+1
+1
+1 on Ubuntu 21.10. If there's anything I can provide to assist with fixing this, I'll gladly help.
+1 on Ubuntu 21.10. If there's anything I can provide to assist with fixing this, I'll gladly help.
Could you share how the path is configured? Locally mounted or using a virtual file system like GVFS?
As I guess the problem might be in Qt and not Nextcloud itself it might be worth a shot compiling against a newer or older version of Qt.
I just have it mounted with cifs-utils under /home/my-user/Nextcloud and it wouldn't allow me to configure that path (or any folder within) as my data folder. I was observing this issue in Windows as well, so I assumed the cause was related.
our config: Windows sync client, Network share on a Synology Nas
+1
+1
Confirmed still an issue on 3.4.1.
I am also seeing this issue trying to sync a file mounted in WSL2. Windows can read/write just fine, but the Nextcloud client detects it as unwritable. (3.4.1)
Same here. SMB share from TrueNAS. I'm able to read and write in Windows, but sync client says I don't have permissions. Trying to add sync folders from NFS shares will make the sync client freeze and then crash.
+1 Also have the same issue. Was able to work around it, by downgrading client to version 3.1.3. Then added the folder synchronisation. Then I immediatly upgraded again to version 3.4.2 and synchronization started.
I use a Synology NAS which I mount in Windows as a drive via Samba
Here the same and without that SMB is involved.
This problem also exists with a normal Windows share.
Today I wanted to re-set up a machine that previously had the Nextcloud client (Windows) installed as well. The local Nextcloud directory is on a Windows share of another machine - it can be selected, but according to the message there is no write permission. Neither under the mounted drive letter nor under the server path.
But I can otherwise write from the computers as I want and have all access. Only Nextcloud is complaining.
For me, this means that I can no longer set up the synchronization and the desktop client is useless until the problem is solved.
Here the same and without that SMB is involved. This problem also exists with a normal Windows share.
Windows shares are using the SMB protocol.
For me, this means that I can no longer set up the synchronization and the desktop client is useless until the problem is solved.
As pointed out you can install an older version and dismiss any popups prompting you to upgrade until the bug is fixed.
same problem ! Trying to sync a mapped NAS-share via mapped drive-letter or UNC-path leads to write-permission-message.
strange: sync with V:\ seemed to work -> V:\data gets the error
+1
I have a dualboot system with Win10 and opensuse. The same folder sync on opensuse works, on Win10 no.
same Problem with client 3.4.3
+1 Problem still present in 3.4.4
Please don't leave client-breaking bugs open for years. Please. Syncing to a network share CAN'T be an edge case.
+1 Same problem: SMB-shares won't work. Workaround: select a local directory (e.g. C:\temp\whatever), then close Nextclient, head over to %APPDATA%/Nextcloud and change that path in the nextcloud.cfg file to your SMB-network path (e.g. W:\cloud), start Nextcloud client.
+1
Another workaround that worked for me: setup Nextcloud client using version 3.1.3, then upgrade to the latest release.
Issue confirmed
This is really a Nextcloud desktop client bug which seems confirmed by multiple sources and was introduced after 3.1.3.
Some ranting
This is a major issue and I can't believe it's still not fixed after almost a year. I wish I spoke these languages in order to submit a fix... Anyone being a C# / VBS (or whatever language this is) dev here, feel free to submit fixes. Remember that this is open source.
Use case leading to issue
Got a NAS running OpenMediaVault, with a 32TB volume, which includes an SMB share mounted as S:\ in my Windows. I've got to sync a 5TB dir to my Nextcloud instance (80TB available storage server) using a Windows desktop Nextcloud client. There is no way that I store what's on the NAS on a regular Windows desktop as I need to ensure data integrity, high availability, great read speed, and also I want HDD away from my desktop, therefore it's on a Linux NAS in RAID and connected in 10Gbit/s to my Windows while being in another room.
Context for issue
While I previously had this config working, after re-installing Windows (in order to switch from Win10 to Win11), a fresh install wouldn't be able to add it anymore as the client is claiming a permission issue. My SMB permissions seem alright to me as I'm able to create, move, modify files using the file explorer...
Known workarounds
- Workaround 1: You can temporarily set a wrong dir on a local drive, close Nextcloud, edit config file (in my case in C:\Users[USERNAME]\AppData\Roaming\Nextcloud\nextcloud.cfg) and then change drive location. Might have more issues if your local drive doesn't have enough room for your data on the cloud. If so you'll need to select which dirs to sync first and It'll be alright.
- Workaround 2: Setup using client 3.1.3 https://github.com/nextcloud/desktop/releases/tag/v3.1.3 I would most likely recommend this, even though I was afraid to try it as I'm now running Windows 11 and wasn't sure if compatibility was alright with an older client. But it's from Feb 18, 2021 so it should be OK.
+1