SMBSync2 icon indicating copy to clipboard operation
SMBSync2 copied to clipboard

Cannot access /Android/data/ on Android 11

Open bengalih opened this issue 2 years ago • 6 comments

In Android 11, the default permissions no longer allow access to:

/storage/emulated/0/Android/data/[app_package]

Therefore, it is now impossible to sync the data directories for apps on phones with only Internal storage. I have seen other apps which are able to bypass this by granting them permissions directly.

Can you do this with smbsync2? If not, can you consider adding it...or better yet adding a full root access option?

bengalih avatar Aug 16 '21 18:08 bengalih

+1 for root dir access functionality

YouKnowBlom avatar Aug 23 '21 21:08 YouKnowBlom

I got the same issue on my S10. The cause of this is probably the Scoped Storage enforcement introduced in Android 11. See https://developer.android.com/about/versions/11/privacy/storage . It looks like there is a possibility to get the read access to all files on the external storage by requesting the "All file access" permission. See https://developer.android.com/training/data-storage/manage-all-files . I can see that the current version of the Solid Explorer app makes use of it. I can access all files on the SD card with this app and I see this app in the list of apps requested the "All files access" permission. As the SMBsync ist not in this list I assume the corresponding functiionality is not yet implemented there.

dimitri-rebrikov avatar Sep 12 '21 07:09 dimitri-rebrikov

I wonder if the permission can be granted manually with an adb command, though I am not sure which is the correct permission to grant to fix this.

mruac avatar Sep 24 '22 07:09 mruac

I would really appreciate it as well, moved to LOS 19.1 recently and got bitten by this as it worked on A10 before. If anyone can come up with workaround that'd be great.

mahdi1234 avatar Oct 13 '22 13:10 mahdi1234

SMBSync requests access for "Pictures and Videos", "Music and Audio" and "Files" - isn't "Files" Access to all files? Are there permissions "files" and "even more files"? LOL.

If there is no workaround, there should at least be a warning in the app that those folders cannot be accessed, but as this is a backup tool it should be fine to use that "even more files" permissions as referenced by https://github.com/Sentaroh/SMBSync2/issues/247#issuecomment-917573084

JustMyGithub avatar Nov 10 '22 22:11 JustMyGithub

Strange enough, if I connect my phone to my PC using USB, access is possible. So why not with SMBSync2? I would expect the change is not too complicated, indeed a permission issue.

joshuisken avatar Apr 12 '24 15:04 joshuisken