securefs
securefs copied to clipboard
Experience: Windows11, NTFS USB Drive, --format 4, long file paths, and missing user permissions.
tl;dr: Due to long path names, and using USB drive on different computer with different user accounts, whatever code applies the <machine>\Administrators
and <machine>\Users
--format 4
file and folder permissions, didn't work due to "path too long" issues
Not really a bug report, more leaving this here in case other people have similar issues on Windows 11
Edition Windows 11 Pro
Version 23H2
Installed on 11/12/2022
OS build 22631.3235
Experience Windows Feature Experience Pack 1000.22687.1000.0
Initial experience
- drives originally created with winfsp v1.9 and securefs 0.13.1 on my old Windows 10 pro computer in 2022.
- new computer
- decided to install the latest winfsp (2023: v2.0)
- mounted my first usbdrive with securefs 0.13.1 (using winfsp 2023, but not sure, going off memory sorry)
- everything is fine
- unmount, download securefs 0.14.3
- mount second drive (prettry sure was using 0.14.3, but might have been 0.13.1)
- permission denied errors spam the mount window :-/ (https://github.com/netheril96/securefs/issues/76)
- oh no
So I try to fix
- notice folder permissions have weird users (
S-12345-4343-234324-2424
type name, normally that shows when it's a user id that's not known by the running OS) - tried to take over or reset the permissions via explorer, but couldn't due to LONG PATH ISSUE (https://github.com/netheril96/securefs/issues/163)
- tried to use TAKEOWN in the command window, but that also fails due to LONG PATH ISSUE
- Still fails even if I enable the Long Path registry key
Gave up, spent far too long renaming directories to a
so I could delete them manually (should have just NTFS reformatted the drive)
- Tried setting up a new secure drive using
--format 3
but found out that usingrsync
via windows shares goes really, really, really slow (dunno if it's a--format 3
issue like https://github.com/netheril96/securefs/issues/54, or just due to not being the faster--format 4
)
So in the end I deleted the --format 3
folder, and went back to --format 2
keeping in mind I might get this permission denied error in the future when I change computers.
The first drive worked fine the entire time. So I suspect it was me using mismatched winfsp/securefs software combo, or there might be an issue in the latest securefs/winfps
I now use ROBOCOPY
to copy the raw unmounted securefs directory between USB drives, as this does support long file names
Can you try running TAKEOWN
with \\?\
prefixed path? That is, if the directory is D:\a\b\c
, use \\?\D:\a\b\c
instead (only back slash works, and the path must be absolute).