Android/Data folder content - Android 11

Support for Android version of Total Commander

Moderators: white, Hacker, petermad, Stefan2

kat2
New Member
New Member
Posts: 1
Joined: 2021-08-19, 12:57 UTC

Re: Android/Data folder content - Android 11

Post by *kat2 »

Hi,

in https://android.stackexchange.com/questions/241018/how-to-access-hidden-area-of-sd-card-in-android-11
a question regarding the visibility of the data has been opened.

Could maybe somebody have a look at it?

Thanks in advance!
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48005
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: Android/Data folder content - Android 11

Post by *ghisler(Author) »

/storage/emulated/0/Android/data is the internal phone memory. The sd card should somewhere like
/storage/1234-5678/Android/data with the numbers different from card to card.

While it's possible to access the Android/data folder under /storage/emulated/0, it's not possible to access it on the SD card on Samsung devices.
Author of Total Commander
https://www.ghisler.com
Fluchtachterl
Junior Member
Junior Member
Posts: 5
Joined: 2021-08-23, 08:23 UTC

Re: Android/Data folder content - Android 11

Post by *Fluchtachterl »

tramp20 wrote: 2021-03-17, 12:01 UTC Give Total Commander Root Permission.
Go to “mnt/pass_through/0/emulated/0/Android/data” directory
There you can access the data folder in android 11.
Confirmed that this is working on my Samsung Galaxy Tab S7 (SM-T870) too. I created a bookmark in TC for quicker access.

Thank you! :)
gemeenteraadslid
Junior Member
Junior Member
Posts: 58
Joined: 2011-11-28, 11:27 UTC

Re: Android/Data folder content - Android 11

Post by *gemeenteraadslid »

Access to Android/Data/ on the external SD is crucial. I need to download vector maps from openandromaps.org to my Locus Map dir on extSD.
Ch. Ghisler, is that a Samsung issue or is it about getting an exception by Google for your file manager?
gemeenteraadslid
Junior Member
Junior Member
Posts: 58
Joined: 2011-11-28, 11:27 UTC

Re: Android/Data folder content - Android 11

Post by *gemeenteraadslid »

nvm, I see you are fighting with Android already. https://ghisler.ch/board/viewtopic.php?t=74859
peterb
Junior Member
Junior Member
Posts: 73
Joined: 2004-01-15, 13:49 UTC

Re: Android/Data folder content - Android 11

Post by *peterb »

This helps at least (see topic 74859, I have the same sudden trouble regarding Osmand/Android 11):
> Then I used USB cable on PC / MTP protocol (not the best because refreshing can fake you)

Other option specifically for Osmand (not yet tested, but I think this should work):
Use a folder under the root of the SD-card, for example ..sdcard../Osmand for the Osmand files.
Google Android only restricts the Android/data folder on SDcards (at the moment ...).
gemeenteraadslid
Junior Member
Junior Member
Posts: 58
Joined: 2011-11-28, 11:27 UTC

Re: Android/Data folder content - Android 11

Post by *gemeenteraadslid »

peterb wrote: 2021-12-01, 18:02 UTCOther option specifically for Osmand (not yet tested, but I think this should work):
Use a folder under the root of the SD-card, for example ..sdcard../Osmand for the Osmand files.
Isn't there a restriction as well? Apps not allowed to write? Read? OK in case of Osmand/Locus/etc, it would be a solution if reading is allowed.
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48005
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: Android/Data folder content - Android 11

Post by *ghisler(Author) »

I just tried Lotus Maps, and it doesn't seem to support external maps on SD card any more on Android 11.

Try asking the author to use Android/media on the SD card instead of Android/data. The app should be able to access this folder without special rights, and other apps can write there just fine.
Author of Total Commander
https://www.ghisler.com
Fluchtachterl
Junior Member
Junior Member
Posts: 5
Joined: 2021-08-23, 08:23 UTC

Re: Android/Data folder content - Android 11

Post by *Fluchtachterl »

I can confirm @peterb: I've running Locus Maps on a rooted Samsung Galaxy S7 tablet (SM-T870) with Android 11. Locus Map directory is in the root folder of my SD-card and external maps from Openandromaps are working like a charm.
peterb
Junior Member
Junior Member
Posts: 73
Joined: 2004-01-15, 13:49 UTC

Re: Android/Data folder content - Android 11

Post by *peterb »

I confirm Ghislers note above to use media folder.
So my current solution on my Samsung S20 FE (not rooted) is to put Osmand data files under:
/storage/110E-CBF/Android/media/net.osmand.plus/files (all subfolders, maps, etc)
Osmand and Tcmd have full access here
(Osmand can only get access allowance to Media, checked under APP managment)
gemeenteraadslid
Junior Member
Junior Member
Posts: 58
Joined: 2011-11-28, 11:27 UTC

Re: Android/Data folder content - Android 11

Post by *gemeenteraadslid »

Android/Media sounds like good news. Forwarded the msg, thx.
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48005
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: Android/Data folder content - Android 11

Post by *ghisler(Author) »

In beta 3, which is now on the Play Store, I have managed to add access to Android/data on external SD cards!

Unfortunately there are quite a few restrictions:

1. It only works on _some_ devices with Android 11: It does not work with the Android emulator with the original unpatched Android 11, but it works on Samsung phones with the latest patches. It does work with the Android 12 emulator, though. You should only see the "-> Installed apps" link on devices where it works.

2. It's very slow when you need to copy many small files to Android/data. Why: Copying directly to /Android/data/some.app does not work. I have to create a temporary sub-folder under TC's own folder /Android/data/com.ghisler.android.TotalCommander, copy the file to it, then move it to the actual destination folder.

3. Reading files from /Android/data/ subfolders fails with a "no such file" error when trying to read more data than the size of the file. This is quite common, you normally call read(buffer) with a fixed size buffer of e.g. 64kByte or so, and the function would return the number of actual bytes read. Not in these folders - it gives an exception. So I have to check whether the stream has data available before reading. I have added this to various functions (copying, zip packer, editor, search for text), but some like plugins or media player aren't changed because they are not part of TC.

Please let me know whether it works for you or not, and on which device with which Android version and patch date.
Author of Total Commander
https://www.ghisler.com
peterb
Junior Member
Junior Member
Posts: 73
Joined: 2004-01-15, 13:49 UTC

Re: Android/Data folder content - Android 11

Post by *peterb »

oops, late reply, just found your beta 3 notes.

I can confirm, now I have access to SDcard Android data using beta 3.
Samsung S20FE, Android R (11), Build G780GXXU3AUJ2, 2021-11-24

After giving access to SDcard folder, I tested a few Android/data/<appname> folders
using just copy and delete (of the copied files) for a quick check, works ok here.
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48005
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: Android/Data folder content - Android 11

Post by *ghisler(Author) »

Nice to hear that - so your S20FE has the same functions as my S10e.

Anyone with a non-Samsung device could test it too, please?
Author of Total Commander
https://www.ghisler.com
peterb
Junior Member
Junior Member
Posts: 73
Joined: 2004-01-15, 13:49 UTC

Re: Android/Data folder content - Android 11

Post by *peterb »

More tests:
- zipping files to SDcard Android/data/appsubfolder: not ok (I expected that, no problem from in m opinion)
- copy/rename/move/overwrite: ok (I compared the contents of files usind Tcmd-android)
- move: for big files (1GB OSMAND file): not ok (file is copied, but not deleted, I understand that when reading your explanations item 3)

Seems that you found the wizard in the bathroom mirror ;-)
Have a nice Christmas!
Post Reply