[Bug]: Unnecessary windows system flag (on syned files) causes issues for 3rd party tools
⚠️ Before submitting, please verify the following: ⚠️
- [X] This is a bug, not a question or a configuration issue.
- [X] This issue is not already reported on Github (I've searched it).
- [X] Nextcloud Server and Desktop Client are up to date. See Server Maintenance and Release Schedule and Desktop Releases for supported versions.
- [X] I agree to follow Nextcloud's Code of Conduct
Bug description
Nextcloud windows client creates the System flag on the synced directories. This attribute seems to be unnecessary for nextcloud, but causes other programs to no longer access the files correctly.
Steps to reproduce
- Sync any files with the windows client
- Open Command (cmd)
- Navigate to the parent folder of a synced folder (with "cd")
- Using "dir" does not show the synced folder. Using "dir /as" shows it as system-folder
Sidenote: Other 3rd party tools ignore system flagged folders, e.g. Voidtools Everything (file indexed search tool)
Expected behavior
The nextcloud windows client should refrain from setting the system attribute. If it has any use, the functions should also be possible without the system flag.
Which files are affected by this bug
all synced folder
Operating system
Windows
Which version of the operating system you are running.
Windows 10
Package
Official SNAP package
Nextcloud Server version
24.0.7
Nextcloud Desktop Client version
3.6.4
Is this bug present after an update or on a fresh install?
Fresh desktop client install
Are you using the Nextcloud Server Encryption module?
Encryption is Disabled
Are you using an external user-backend?
- [ ] Default internal user-backend
- [ ] LDAP/ Active Directory
- [ ] SSO - SAML
- [ ] Other
Nextcloud Server logs
No response
Additional info
Additional forum links:
Nextcloud Forum: Why is the Nextcloud data/sync folder created with the System flag? https://help.nextcloud.com/t/why-is-the-nextcloud-data-sync-folder-created-with-the-system-flag/144348
Everything forum: Everything not indexing Nexcloud folders https://www.voidtools.com/forum/viewtopic.php?p=47896
Also a topic in the community: https://help.nextcloud.com/t/why-is-the-nextcloud-data-sync-folder-created-with-the-system-flag/144348
I'd like to hear the reasoning on this behavior as well.
Thanks @gbakeman for getting attention to this.
There should be a good reason to have "main" Nextcloud local directory tagged as "system" in Windows, because it collides with software such as TotalCommander (with default setup, eg. "do not show system files".
I'd be happy with clarification or change :)
Thanks!
No reaction since 2022 year?
Hello,
the client was enhanced significantly since the opening of this ticket. If you are still encountering issues, please get back to us
Hello, I just installed Nextcloud files on Windows 11 (Nextcloud Desktop Client Version 3.17.1, current version as of writing) and I can confirm the original issue is not resolved/changed.
The main Nextcloud local sync folder is still created automatically with the Windows System flag.
Please reopen this issue or elaborate in detail what justifies the closing of this issue. Thanks and best regards.
This attribute is required for Explorer to display the Nextcloud icon, without it the desktop.ini file which defines the folder icon to be used use will not be read by Explorer.
see also:
- MSDN: How to Customize Folders with Desktop.ini
- The Old New Thing: Why is the readonly property for folders so strange?
It seems that in this implementation the system flag is required to change the icon. However, there must be another way to achieve this without setting the system flag. For example, the Dropbox client also displays a custom folder icon in Windows Explorer, even though its folders do not carry the system flag.
@Medius7 hmm... what flags does Dropbox set on its sync folders?
can you paste the output of attrib c:/path/to/Dropbox and icacls c:/path/to/Dropbox here?
@nilsding Thanks for providing those links, interesting look into the behavior of Explorer. I'm not @Medius7 but here's what I see on my end:
> attrib ./Dropbox
A R U C:\Users\[my user]\Dropbox
> icacls .\Dropbox\
.\Dropbox\ NT AUTHORITY\SYSTEM:(I)(OI)(CI)(F)
BUILTIN\Administrators:(I)(OI)(CI)(F)
[my PC name]\[my user name]:(I)(OI)(CI)(F)
Successfully processed 1 files; Failed processing 0 files
Strangely, I'm missing a desktop.ini file in my Nextcloud folder (which of course does not have the icon applied) while Dropbox does have the file and the icon is applied as expected.
@gbakeman thanks for sharing
since the "R" attribute has the same effect it might be possible to change to that attribute as well