Project

General

Profile

DataPartition » History » Version 3

Denis 'GNUtoo' Carikli, 10/28/2020 04:57 PM
add section

1 1 Denis 'GNUtoo' Carikli
h1. DataPartition
2
3 2 Denis 'GNUtoo' Carikli
{{toc}}
4
5
h2. /!\ Warning: Draft
6
7
This article is in draft form and is being written:
8
* Everybody is welcome to contribute
9
* Some things might not be accurate yet, so beware before using the information contained in it.
10 1 Denis 'GNUtoo' Carikli
11 3 Denis 'GNUtoo' Carikli
h2. What does the data partition contains?
12
13 1 Denis 'GNUtoo' Carikli
It probably depends on the devices and the Android versions.
14
15
On Replicant 6.0, it contains at least the application internal data: When various applications are installed, they have access to some storage where they can read and write data that is only visible to them and not to other applications. This is part of the Android security model that doesn't trust applications even if they are fully free software.
16
17
In addition, on some devices it also contains the users data. This location and external microSD cards is where users typically their files like Music, photos, etc. This data is made accessible to the users in various location through a mechanism called fuse. In Replicant 6, this data is stored in the media directory in the data partition.
18
19
Summarry:
20
| Mount points    | Content |
21
| /data/          | Applications (internal) data |
22
| /sdcard
23
  /storage/<UUID> | User accessible storage to store music, photos, etc |
24
25
Here's where the sdcard user accessible storage comes from:
26
27
/sdcard -> /storage/self/primary [1]
28
/storage/self/primary -> /mnt/user/0/primary [2]
29
/mnt/user/0/primary -> /storage/emulated/0 [3]
30
31
fn1. <pre>root@i9300:/ # readlink /sdcard                                                                                                                            
32
/mnt/user/0/primary</pre>
33
34
fn2. <pre>root@i9300:/ # readlink /storage/self/primary                                                                                                              
35
/mnt/user/0/primary</pre>
36
37
fn3. <pre>root@i9300:/ # readlink /mnt/user/0/primary                                                                                                                  
38
/storage/emulated/0</pre>
39
40
fn4. <pre>root@i9300:/ # mount | grep "/storage/emulated"                                                                                                              
41
/dev/fuse on /storage/emulated type fuse (rw,nosuid,nodev,noexec,noatime,user_id=1023,group_id=1023,default_permissions,allow_other)</pre>
42
43
44
TODO:
45
* Explain that the user accessible storage is not always present
46
* Explain that it depends on the devices (GTA04)
47
48
h2. Concerns about the application internal data
49
50
TODO:
51
* Explain the issue about the Replicant version <-> application data