Partitions » History » Version 2
xilokar, 05/09/2022 10:01 AM
Precision on mtd partitions and ubi volumes
1 | 1 | tsaitgaist | h1. Table |
---|---|---|---|
2 | |||
3 | partitions seen during boot: |
||
4 | <pre> |
||
5 | 0: 0001F800 1 0 "bootdata" |
||
6 | 1: 0001F800 1 0 "unitdata" |
||
7 | 2: 004AD000 38 37 "linux-A" |
||
8 | 3: 004AD000 38 37 "linux-B" |
||
9 | 4: 007E0000 64 63 "linux-R" |
||
10 | 5: 00B32800 91 90 "rfs-A" |
||
11 | 6: 00B32800 91 90 "rfs-B" |
||
12 | 7: 00372000 28 27 "app-A" |
||
13 | 8: 00372000 28 27 "app-B" |
||
14 | 9: 00A17000 65 81 "data-A" |
||
15 | 10: 00685800 29 52 "data-B" |
||
16 | 11: 0001F800 1 0 "bootdata_backup" |
||
17 | 12: 0001F800 1 0 "caldata" |
||
18 | 13: 0001F800 1 0 "caldata_backup" |
||
19 | 14: 0001F800 1 0 "unitdata_backup" |
||
20 | </pre> |
||
21 | |||
22 | |||
23 | partitions mapped after boot (using @cat /proc/mtd@): |
||
24 | <pre> |
||
25 | dev: size erasesize name |
||
26 | mtd0: 00020000 00020000 "boot" |
||
27 | mtd1: 07fe0000 00020000 "system" |
||
28 | mtd2: 0003f000 0001f800 "bootdata" |
||
29 | mtd3: 0003f000 0001f800 "unitdata" |
||
30 | mtd4: 0050b800 0001f800 "linux-A" |
||
31 | mtd5: 0050b800 0001f800 "linux-B" |
||
32 | mtd6: 00a17000 0001f800 "linux-R" |
||
33 | mtd7: 0150a800 0001f800 "rfs-A" |
||
34 | mtd8: 0150a800 0001f800 "rfs-B" |
||
35 | mtd9: 00a17000 0001f800 "app-A" |
||
36 | mtd10: 00a17000 0001f800 "app-B" |
||
37 | mtd11: 00a17000 0001f800 "data-A" |
||
38 | mtd12: 00a17000 0001f800 "data-B" |
||
39 | mtd13: 0003f000 0001f800 "bootdata_backup" |
||
40 | mtd14: 0003f000 0001f800 "caldata" |
||
41 | mtd15: 0003f000 0001f800 "caldata_backup" |
||
42 | mtd16: 0144d800 0001f800 "unitdata_backup" |
||
43 | </pre> |
||
44 | |||
45 | 2 | xilokar | @boot@ is the bootloader partition. @system@ is an ubi partition, and remaining mtd partitions are in fact ubi volumes exposed as mtd device through gluebi. |
46 | |||
47 | 1 | tsaitgaist | @/etc/init.d/rcS@ uses the MTD numbers from @/etc/init.d/partnum.sh@: |
48 | <pre> |
||
49 | # MTD numbers |
||
50 | PARTNUM_BOOTDATA=2 |
||
51 | PARTNUM_BOOTDATA_BKP=13 |
||
52 | PARTNUM_KERNEL_A=4 |
||
53 | PARTNUM_KERNEL_B=5 |
||
54 | PARTNUM_KERNEL_R=6 |
||
55 | PARTNUM_RFS_A=7 |
||
56 | PARTNUM_RFS_B=8 |
||
57 | PARTNUM_APP_A=9 |
||
58 | PARTNUM_APP_B=10 |
||
59 | PARTNUM_DATA_A=11 |
||
60 | PARTNUM_DATA_B=12 |
||
61 | PARTNUM_CALDATA=14 |
||
62 | PARTNUM_CALDATA_BKP=15 |
||
63 | PARTNUM_UNITDATA=3 |
||
64 | PARTNUM_UNITDATA_BKP=16 |
||
65 | |||
66 | # UBI offset |
||
67 | PARTNUM_UBI_OFFS=2 |
||
68 | </pre> |
||
69 | |||
70 | h1. Partitions |
||
71 | |||
72 | h2. Systems |
||
73 | |||
74 | There are two systems: A and B. |
||
75 | They use one kernel (Linux), one root file system (standard Linux utilities), one application partition (containing all the femtocell/radio software), and one data partition (containing the operator specific configuration). |
||
76 | |||
77 | h2. Backup |
||
78 | |||
79 | The bootloader and both systems use common partitions: bootdata (for system selection and signatures), unidata (femtocell configuration), caldata (femtocell calibration). |
||
80 | |||
81 | They partition have backups in case the original are invalid (invalid data, can't be mounted, or signature check fails). |
||
82 | |||
83 | h2. Recovery |
||
84 | |||
85 | There is one recovery kernel, but this is only used for local maintenance (not remote) in case the two main systems are broken. |
||
86 | It doesn't download and flash any file automatically. |
||
87 | This is just a Linux kernel with SSH open (serial is also enabled, as opposed to the main OS where it is disabled). |
||
88 | |||
89 | @/etc/shadow@: |
||
90 | <pre> |
||
91 | root:$1$DJQchilX$y00cjFXXOulJnM7jqzcdP.:0:0:99999:7::: |
||
92 | user:$1$PFIa1uaF$kDzrucre2aHSSS8Bxtfv4.:15041:0:99999:7::: |
||
93 | manufop:$1$3Px2QUBG$xgh0jCSm//vPWkKjHUtgP/:15041:0:99999:7::: |
||
94 | </pre> |