Related
Ive seen many questions in the Q & A forum about this CWM and figured the best way is to get developers and other main contributors to look at the issues some of the "little people" have about using it. DAF was convenient and easy for all because it was one click for the people who could get that far, and since CWM, there where the 3 versions and this one has yet to really be well touched upon as a full tutorial with the copy to SD not being needed any more. I feel as do many others that a main "sticky" thread be made for it with a few FAQ on this section of the forum so they do not have to search too far away from the main thread they are using and get completely confused.
1. Will doing a backup and changing ROMs using CWM with different partition delete my backup?
2. Will doing a backup KEEP my partition?
3. Is it possible to do a partition from CWM or is the partition need to be carried on a computer?
(this to me seemed to defeat the purpose of CWM with some DEVs making their own partition layouts and not using the main ones that were originally laid out for use, no aim towards DEVs because I know they work hard)
4. If I put multiple ROMs on my SD card do I need to change the partition every time if I want to change them?
5. Is there a way to know which backups are from which ROMs I had used?
(I guess this is asking if they can change the name?)
6. How do I know when to "Wipe Cache Partition"?
I know there is *THIS* thread, however there are surely some differences between the copy of those files and not needing to copy amongst other things to which the "new" people do not understand.
If this is just a bother and hindrance to you all, I understand the deletion of this thread, however it did take quite a while to plan out what to write, and what not to should you choose to do so and I would give the answers, however even I do not know all of them and so I leave this to you all for debate. NO PUBLIC BASHING PLEASE
Dude, this forum is for posting dev projects. Why on earth do you think its ok to post a questions topic in here when we have a dedicated questions forum?!?!
TheATHEiST said:
Dude, this forum is for posting dev projects. Why on earth do you think its ok to post a questions topic in here when we have a dedicated questions forum?!?!
Click to expand...
Click to collapse
I said it could be moved or deleted just the questions are not very well maintained in that DEDICATED (? HA) forum there are multiple posts of the same and I felt that since there is a sticky thread here that could answer the forum issue of the DEVELOPED CWM program this should be brought to the attention and as such is a DEV related issue. It can and most likely will be moved, do you have an answer to any of the issues the people asked?
TheATHEiST said:
Dude, this forum is for posting dev projects. Why on earth do you think its ok to post a questions topic in here when we have a dedicated questions forum?!?!
Click to expand...
Click to collapse
now that it's been moved, nobody will discuss the answers and it's a pointless post.
harrystone33 said:
1. Will doing a backup and changing ROMs using CWM with different partition delete my backup?
Click to expand...
Click to collapse
No this will not delete your back up as it is saved on yor SD card when you do the back up.
harrystone33 said:
2. Will doing a backup KEEP my partition?
Click to expand...
Click to collapse
This I am not really sure of as I am not a dev but I think it does as the backup is just a backup of your settings, personal information, your gmail account associated with your Android, boot data, and any cache data that you have built up.
harrystone33 said:
3. Is it possible to do a partition from CWM or is the partition need to be carried on a computer?
(this to me seemed to defeat the purpose of CWM with some DEVs making their own partition layouts and not using the main ones that were originally laid out for use, no aim towards DEVs because I know they work hard)
Click to expand...
Click to collapse
You can partition your SD card with CWM but I do not think you can do a system portion as CWM is what creats the system portion when you flash it. It creates a partition in the CWM.
harrystone33 said:
4. If I put multiple ROMs on my SD card do I need to change the partition every time if I want to change them?
Click to expand...
Click to collapse
Once again I am not a dev (yet) and I am not 100% sure of this. But I would say if the ROMs you have stored on SD card need different portition sizes then yes you will need to change the partition size when you change ROMs. If they require the same partition size then no you do not need to change the partition size.
harrystone33 said:
5. Is there a way to know which backups are from which ROMs I had used?
(I guess this is asking if they can change the name?)
Click to expand...
Click to collapse
You should be able to manually go into your SD card with a computer and change the name on the backup file, but I do not know if this will interfer with CWM being able to detect the backup file. So you might want to write down the original full name of the file befor you change it.
harrystone33 said:
6. How do I know when to "Wipe Cache Partition"?
Click to expand...
Click to collapse
As a rule of thumb I would not delete my cache unless I was about to flash a new ROM.
Also check out my guide I wrote in linked in my sig, you might find it useful.
Hope this helps you out some.
Hi. Maybe few words about me first. I'm not a developer, I don't know how to do it and I have to ask more experienced users. Ok that's it, to the point now. Ah, and I didn't know if this thread was proper to be posted in Development sub-forum, so it's here. If it was possible, if the thread meets requirements to be there, maybe it's possible to move it there? I'm not sure how many devs visit those section, so obviously there is greater chance for finding an answer there, but again, I wasn't sure if it was right.
While I was a G1 user one genius known as "Firerat" created very nasty script - it allowed users to manually, by simply creating a .txt file on sdcard with proper values and running a .zip from recovery, resize partitions like /system, /data and /cache on the phone. I don't know if you're familiar with G1 stuff, but previous there was only one way to chage partitions and it was achieved by custom SPL called Haykuro SPL. This modification (MTD part hack) was created because of need for even more space on /data and allowed to shrink /system and /cache to smallest value possible, so /data took up as much space as it was possible. Here is source thread in G1 Development section:
http://forum.xda-developers.com/showthread.php?t=717874
There you can dive in details, because my knowledge and understanding in this things end very quickly .
On HD2, we have come a great way. From pure Windows Mobile, it was possible to run Linux kernel from sdcard by HaRET.exe, then run Android. After few month team of gods gave us MAGLDR, a tool that allows us to replace Windows Mobile from NAND with Android system. Then after few more weeks someone made Clockworkmod Recovery possible, giving us posibilty to create partitions on sdcard, do a nandroid backup/restore. But one MAJOR thing wasn't done as it should. Recovery in theory should give us possibility to flash ROMs from sdcard without need of computer. And theoretically it's possible, but... Yes, you have to have proper partition configuration flashed by DAF.exe with PC before. Imagine what a great obstacle it is for diagnosed with ORD!
Now you realise what I'm talking about? Combine these two things and bam! I'm just asking, just giving you an idea. Maybe it is possible to adapt those scripts to HD2 and replace old habits (flashing recovery by DAF.exe on PC) with simple script and one .txt file!
Again, maybe it's not possible since we are still using old SPL from WM times. Maybe MAGLDR is build in such way that those scripts are not possible. Maybe there is a thousand reasons... but I've never seen such an idea.
So please, is there one person who are good in this stuff and can explain me wether it's possible or not?
So maybe I can rest assured that I have to cure my ORD
OR
we can move on to work on making this idea reality .
cure for ORD....
I DON'T THINK SO.
Flashed from my fingers to your face
On a serious note, though, have you looked at clk? It is supposed to be useable without a pc. Therefore you can configure the partition on your phone. Is my understanding of that correct?
Maybe T-Macgnolia can explain this better than I .
I'm still trying to get my head round it, before I commit to changing over to clk...
Flashed from my fingers to your face
raven_raven said:
Hi. Maybe few words about me first. I'm not a developer, I don't know how to do it and I have to ask more experienced users. Ok that's it, to the point now. Ah, and I didn't know if this thread was proper to be posted in Development sub-forum, so it's here. If it was possible, if the thread meets requirements to be there, maybe it's possible to move it there? I'm not sure how many devs visit those section, so obviously there is greater chance for finding an answer there, but again, I wasn't sure if it was right.
While I was a G1 user one genius known as "Firerat" created very nasty script - it allowed users to manually, by simply creating a .txt file on sdcard with proper values and running a .zip from recovery, resize partitions like /system, /data and /cache on the phone. I don't know if you're familiar with G1 stuff, but previous there was only one way to chage partitions and it was achieved by custom SPL called Haykuro SPL. This modification (MTD part hack) was created because of need for even more space on /data and allowed to shrink /system and /cache to smallest value possible, so /data took up as much space as it was possible. Here is source thread in G1 Development section:
http://forum.xda-developers.com/showthread.php?t=717874
There you can dive in details, because my knowledge and understanding in this things end very quickly .
On HD2, we have come a great way. From pure Windows Mobile, it was possible to run Linux kernel from sdcard by HaRET.exe, then run Android. After few month team of gods gave us MAGLDR, a tool that allows us to replace Windows Mobile from NAND with Android system. Then after few more weeks someone made Clockworkmod Recovery possible, giving us posibilty to create partitions on sdcard, do a nandroid backup/restore. But one MAJOR thing wasn't done as it should. Recovery in theory should give us possibility to flash ROMs from sdcard without need of computer. And theoretically it's possible, but... Yes, you have to have proper partition configuration flashed by DAF.exe with PC before. Imagine what a great obstacle it is for diagnosed with ORD!
Now you realise what I'm talking about? Combine these two things and bam! I'm just asking, just giving you an idea. Maybe it is possible to adapt those scripts to HD2 and replace old habits (flashing recovery by DAF.exe on PC) with simple script and one .txt file!
Again, maybe it's not possible since we are still using old SPL from WM times. Maybe MAGLDR is build in such way that those scripts are not possible. Maybe there is a thousand reasons... but I've never seen such an idea.
So please, is there one person who are good in this stuff and can explain me wether it's possible or not?
So maybe I can rest assured that I have to cure my ORD
OR
we can move on to work on making this idea reality .
Click to expand...
Click to collapse
Hello raven_raven,
This is indeed a good idea and can make our HD2 PC independable. I will support you as much I can.
Though I have some questions for you.
Q1: Is it possible for this script to brick our device?
Q2: Can we choose the partitions which we resize (for example I would like to resize only /system, /userdata and /cache and leave the others as is) and if yes the other partitions /boot, /recovery will be formated or data will be kept as is?
Q3: What the bootloader has to do with it?
Q4: What SPL has to do with it?
For your knowledge in HD2 their are 2 bootloaders, MAGLDR and cLK (cedesmith's Little Kernel) which makes HD2 a native android device.
In MAGLDR partitions are made along with the flashing of CWM with the help of DAF.exe
In cLK partitions are directly managed by the bootloader when flashed.
malybru said:
On a serious note, though, have you looked at clk? It is supposed to be useable without a pc. Therefore you can configure the partition on your phone. Is my understanding of that correct?
Maybe T-Macgnolia can explain this better than I .
I'm still trying to get my head round it, before I commit to changing over to clk...
Flashed from my fingers to your face
Click to expand...
Click to collapse
Tried cLK, but it can't change partitions as you would like it to, you can't change it on the go without PC.
zach.antre said:
Hello raven_raven,
This is indeed a good idea and can make our HD2 PC independable. I will support you as much I can.
Though I have some questions for you.
Q1: Is it possible for this script to brick our device?
Q2: Can we choose the partitions which we resize (for example I would like to resize only /system, /userdata and /cache and leave the others as is) and if yes the other partitions /boot, /recovery will be formated or data will be kept as is?
Q3: What the bootloader has to do with it?
Q4: What SPL has to do with it?
For your knowledge in HD2 their are 2 bootloaders, MAGLDR and cLK (cedesmith's Little Kernel) which makes HD2 a native android device.
In MAGLDR partitions are made along with the flashing of CWM with the help of DAF.exe
In cLK partitions are directly managed by the bootloader when flashed.
Click to expand...
Click to collapse
A1: No, it is not possible. Firerat is genius and he does masterpiece of scripting, those scripts are 100% safe. It will of course break you ROM, but simple nandroid backup/flashing a new ROM will fix it.
A2: We resize /system, /data and /cache. You simply put two values in text files, i.e.:
Code:
mtd 130 2
First number is how many mb you want to spend on /system, second on /cache. Rest of internal memory is used by /data. /boot and /recovery are not touched by this script.
A3: I don't know for sure, just connected it to Haykuro SPL, which also changed partitions back then.
A4: Don't know for sure, I'm simply intermediate in this stuff, just wanted to pass an idea, I don't have required knowledge and experience to make this idea come true.
I know that there are 2 bootloaders, but I don't know how they work and how far you can modify partitions from recovery by using each of them. HD2 obviously isn't a native Android phone and regarding that either this idea may be impossible to implement or has to be completely redesigned. I really don't know .
Just wanted to pass an idea, but I'm terribly dissapointed how little response I received...
Well you would have more people responsed if you were posting in development forum under the label [call for development].
cLK is modified "little kernel" for HD2...
since there is no danger of bricking our device I am going to test it and report.
Sent from my Nexus One using XDA App
zach.antre said:
Well you would have more people responsed if you were posting in development forum under the label [call for development].
cLK is modified "little kernel" for HD2...
since there is no danger of bricking our device I am going to test it and report.
Sent from my Nexus One using XDA App
Click to expand...
Click to collapse
Great thing to see that someone tries. Be warned though, I'm not responsible for any data loss and damages or whatever, as always . Please be sure that you read original thread and understood how this script is working.
Maybe I'll ask a mod to move this thread to Development section...
raven_raven said:
Great thing to see that someone tries. Be warned though, I'm not responsible for any data loss and damages or whatever, as always . Please be sure that you read original thread and understood how this script is working.
Maybe I'll ask a mod to move this thread to Development section...
Click to expand...
Click to collapse
Yeah i did, don't worry about it.
I have read the original thread, i have compared the different devices mount points (as much i could) and conclude that is the same.
What i have also noticed is that kernel must be patch in order for this script to work and the script checks for a specific bootloader? I'm not sure, i need to restudy that thread.
Anyway, I tried using the script but didn't happen anything.
I formated all partitions except /boot and /recovery
I first created the mtdpartmap.txt in SD root and flashed via CWM the script FR-recovery-v1.5.8-CustomMTD_S.zip
Then reboot and again to recovery
Flashed ROM and then flashed FR-boot-v1.5.8-CustomMTD_S.zip
Reboot to ROM worked fine.
I run terminal
#df
Sizes where the same as before
Exactly, first you apply new partition map to recovery, next you install ROM in those new partitions either by flashing or nandroid backup-ing, then patch kernel to work with this new layout.
Huh, it would be too easy to simply run it and bam! it works. Even Firerat made different scripts for different devices. I'm curious what's the problem. Is recovery on a different level than those in native Android devices, which means that it can't change partition size? Or is it just problem of adjusting script to HD2 like it was done for Hero or Evo? I wonder if Firerat would like to investigate, but it would be impossible to achieve it without HD2, and from what I know he does not have one.
What person should I ask to move my thread to another section?
raven_raven said:
Exactly, first you apply new partition map to recovery, next you install ROM in those new partitions either by flashing or nandroid backup-ing, then patch kernel to work with this new layout.
Huh, it would be too easy to simply run it and bam! it works. Even Firerat made different scripts for different devices. I'm curious what's the problem. Is recovery on a different level than those in native Android devices, which means that it can't change partition size? Or is it just problem of adjusting script to HD2 like it was done for Hero or Evo? I wonder if Firerat would like to investigate, but it would be impossible to achieve it without HD2, and from what I know he does not have one.
What person should I ask to move my thread to another section?
Click to expand...
Click to collapse
Well, I guess Firerat need to come by and post a thread in HD2 Dev forum since it is his work.
He could ask what info he needs for the HD2 such as partition layout and filesystem in each partition etc... I am sure many people are willing to help with that.
I also think that SPL is locking the partition tables (not sure) and the way we are flashing just overcome that. Else when i used the script should have f**cked up my partitioning.
You can ask an HD2 moderator to move this thread but first ask for Firerat permission.
OK so i know a lot of members are intrested in Dual booting their galaxy S2, so i have decided to complice a list of all the dual boot options i can find and have found. I have found two ways as it stands now, but my search has not been that deep yet, so here are the two ways for now and i hope to add more to the list soon.
SGS2 Dual-Boot Setup (LolBoot) - Ok so the first is an app by Hellcatdroid that you can download from Google Play. It only supports GB roms for now, but their is hope that he will put his PSvita down and continue to work on this great app.
Links
Thread
Google Play
SiyahKernel v3.1beta1 Kernel - So option 2 is a kernel from Gokhanmoral, the kernel is stable but the dual boot side is still in beta. This dual boot kernel is working with ICS roms (not GB), Gokhanmoral has tried a dual boot on stock and cm9 and this combo is working, he is pretty sure it will work with MUIU roms. The members on this thread will start to tell of other working combos they have tried, so give this one a go it is looking very good.
Links
Thread
Blog - The blog includes a changelog, and the download link for his kernel
Here is a guide thanks to Phistachio on how to dual boot using Siyah Kernel
[GUIDE] How to Dual Boot using the Siyah Kernel
Here is a fantastic guide, FAQ writen by droidphile for the use with Siyah kernel, it is a fantastic FAQ, so if you use it please go and thank him here -
Dual Booting FAQs
Here are some dual-boot faqs. Some answers may not be 100% true at present since Gokhan is still working on enhancing dual-booting and implementing all the placeholder features in touch recovery dual boot options.
1) So what's dual booting?
A. Option to boot into either two ICS roms - aosp or sammy. Immediately after boot logo is displayed, you will have a 3 seconds time-out where you can boot into secondary rom by pressing the home key. To boot into primary rom, wait for 3 seconds time-out to complete. If you don't like to wait - touch the screen, or press a volume key, or press power key during time-out.
2) What's the basic architecture behind dual booting?
A. Any rom will have /system, /data, /cache partitions and requires a kernel to boot. Primary rom has all these partitions on the same location as if you were single-booting. Secondary rom uses a hidden partition (/dev/block/mmcblk0p9) to be used as /system (it's /dev/block/mmcblk0p12 for primary rom). Second rom uses sdcard to store /data and /cache partitions. They're stored in /sdcard/.secondrom directory as mountable ext4 block device images (data.img and cache.img).
Kernel partition is shared, so same kernel boots both the roms. If you switch from Siyah to a different kernel dual booting will not be available even though you have a clone of secondary rom. Internal sdcard, ofcourse external plastic sdcard, /efs, /emmc, other kernel related virtual filesystem directories, etc are shared among roms.
3) I have just one rom now. How do i setup one more rom to dual boot?
A.
-To use current rom as primary: Assuming the other rom is downloaded and copied to phone memory
i) Flash latest Siyah that supports dual boot.
ii) Nandroid backup your existing rom.
iii) Full wipe, install the rom you need to dual boot into.
iv) Boot into that rom, perform initial setups, flash whatever zip you need to flash on that rom - gapps, themes, mods, etc. (Because after setting up dual boot you don't have an easy way to flash zips onto second rom. Remember /system and /data partitions are different for both roms)
v) Flash latest siyah on this rom.
vi) Boot into recovery, under dual-boot options, select "Clone Primary ROM to Secondary". Be patient and wait about 6-7 minutes.
vii) Within recovery, restore nandroid backup.
viii) Just to be sure, flash latest Siyah again.
-To use current rom as secondary: Assuming the other rom is downloaded and copied to phone memory
i) Flash latest Siyah that supports dual boot.
ii) Boot into recovery, under dual-boot options, select "Clone Primary ROM to Secondary".
ii) Without exiting recovery, Full wipe, install the rom you need to use as primary rom.
iii) Boot into that rom, perform initial setups.
iv) Flash latest Siyah just to be sure.
Now you have two roms. Press home key to boot into second rom when time-out is shown.
4) How much time was it to clone a rom?
A. There's /system, /data/ and /cache to clone. 2 GB data + 103mb cache + 513 mb system = 2.6 gb
Shell prompt read speed = 7mb per second.
Total Time = 2.6*(1024/7) = 380 secs = 6/7 minutes.
5) If i reboot to recovery from power-off state using 3 button method, to which rom's recovery it's booted into?
A. Unified kernel, same recovery. And remember - flashing zips to second rom is not possible.
6) Any solution to flashing zips to secondary rom?
A. Not until secondary rom is "converted" to primary rom. If you know what the updater script in the zip is doing, you can do that manually using Root Explorer (replacing/copy files, setting permissions, etc).
Else, temporarily make secondary rom the primary rom. Goto recovery, dual-boot options, "Clone Secondary Rom to Primary". Now your second rom becomes primary rom. Flash your zips. When you're done, restore nandroid backup of the other rom to make it primary as before.
7) Should i have same versions of kernels on both roms?
A. Flash kernel from any rom. Both uses the same kernel partition anyway.
8) Will i get a prompt to dual-boot if i'm not using dual boot, as in i haven't cloned any rom to use as secondary?
A. NO
9) I don't like waiting for 3 seconds to boot into primary rom.
A. Touch the screen immediately upon prompt.
10) How do i swap primary and secondary roms?
A. Goto recovery, dual-boot options, "Backup secondary rom"
Under original Backup and Restore option, "Backup" to backup your primary rom.
"Restore as secondary rom" or "Restore as secondary rom from internal sd" and select the nandroid backup of what was actually your primary rom.
Then under original Backup and Restore option, "Restore" to restore the rom you backed up as secondary.
11) USB mass storage works?
A. Only external sd is mounted for second rom atm. MTP will work for internal sd also. Both will be mounted for primary rom.
12) If i had the same /data partition shared between roms, i could use same apps on both roms.
A. Data partition can not be shared as they're incompatible between roms. (Sometimes dev asks you to perform full wipe even if you're switching between versions of the same rom right). Even if they were shared, separate dalvik caches has to be used and hence every boot will take a long time to rebuild dalvik.
13) How to undo dual booting?
A. Use "Remove secondary rom" from dual-boot options in recovery.
14) How to remove secondary rom if "remove secondary rom in recovery" fails for some reason?
A. Format /system2 directory partition, remove data.img and cache.img under /sdcard/.secondrom directory manually by booting into primary rom.
15) How to upgrade primary rom?
A. As usual, goto recovery, wipe whatever you need to wipe and install the new version.
16) How to upgrade secondary rom?
A. Temporarily convert secondary rom to primary (like explained above), install new version and revert primary back to secondary.
17) How to replace secondary rom with another?
A. Perform the steps to setup dual boot as if you had only one rom which is going to be used as primary rom.
18) How to replace primary rom with another?
A. Normal procedure - wipe, install from recovery.
19) Can i have both aosp roms/both samsung roms/first aosp, second samsung/first samsung,second aosp?
A. Yes
20) Can i have one GB rom and second ICS rom?
A. No
21) Why?
A. Kernel partition is shared between roms. Dual boot functionality is implemented in ICS kernel. ICS kernel can run only ICS roms.
22) Are init.d scripts and extweaks profiles shared across the roms so that i can make changes by booting into any rom and the other rom automatically inherits the settings?
A. NO. Roms have differet /system partitions so different init.d directories. Roms uses different /data partitions and extweaks profiles are stored under /data/.siyah. So you gotta configure both separately. Initramfs scripts are shared anyway since both rom uses the same kernel.
23) So if at all i format /sdcard, my second rom is gone?
A. Yes
24) Is the size of /system partition of secondary rom re-sizable from user space?
A. NO
25) Can i have different kernels for the two roms?
A. NO
26) What're the options under dual-booting in touch recovery?
A. i) View Status
Displays secondary rom info if found.
ii) Clone Primary ROM to secondary
First time, you will have only one rom. You may clone it as secondary rom (so that another rom can be used as primary by nandroid restoring)
iii) Clone secondary rom to primary
Whatever has been cloned as secondary rom is cloned to primary rom.
iv) Remove secondary rom
Deletes /system, /data and /cache partitions of second rom. You will have normal booting.
v) Backup secondary rom
Nandroid backup secondary rom to external sd.
vi) Restore as secondary rom
Restore any nandroid backup as secondary rom from external sd.
vii) Backup secondary rom to internal SD
Nandroid backup secondary rom to internal sd.
viii) Restore as secondary rom from internal sd
Restore any nandroid backup as secondary rom from internal sd.
ix) init second rom data
Initialize /data parition of secondary rom to resize the partition to make it bigger in case you run out of space for apps. Init also wipes all the data in /data partition. So your existing apps in secondary rom will be gone.
x) wipe second rom davik cache, xi) wipe second rom cache, xii) fix permissions in second rom - self explanatory
Click to expand...
Click to collapse
I am now running a Dual Boot galaxy s2, using Siyah Kernel by Gokhanmoral, i am running CM9 and Resurrection Remix ics v1.2 PRO[4.0.4]
This is what i have got for now, but i am always looking for more dual booting options, if anyone knows of any please let me knowand i can add it to this thread.
If you have found this thread usfull then please hit the Thanks button
Nice work again fella
You should request this and your other thread are made into sticky's
Also, im hoping these two threads will help to stem the flow of threads and questions for previously trodden ground
Keep it up dude
Thanks man, the XDA community has give me so much, I just want to give back. It would be nice to see these as stickies, maybe the FM would be kind enough to consider placing them on the sticky thread.
Sent from my GT-I9100 using XDA
I am now running a Dual Boot galaxy s2, using Siyah Kernel by Gokhanmoral, i am running CM9 and Resurrection Remix ics v1.2 PRO[4.0.4]
I am now running a Dual Boot galaxy s2, using Siyah Kernel by Gokhanmoral, i am running SensatioN ROM 3.3 ICS by Crysis21 as Primary and CM9 as Secondary.. can anyone tell me any app so that i can automatically sync both rom 's SMS, Phone log and Phone Contact.. i know manual process..
What are the pro's/con's of dual booting? Cheers
Sent from my GT-I9100 using Tapatalk
shareking said:
I am now running a Dual Boot galaxy s2, using Siyah Kernel by Gokhanmoral, i am running SensatioN ROM 3.3 ICS by Crysis21 as Primary and CM9 as Secondary.. can anyone tell me any app so that i can automatically sync both rom 's SMS, Phone log and Phone Contact.. i know manual process..
Click to expand...
Click to collapse
You can use Rom Manager to Extract the apps and data from your nandroid backup, or another app that does the same is Nandroid Browser, you can get both of google play. Just as a side note, you should get an automation sync of data when flashing a new rom, as google now store all you apps and setting in the cloud, if you check in your settings it should be under Backup and reset - back up my data - check the box, and you should have an auto sync for your next rom flash.
blade30p said:
What are the pro's/con's of dual booting? Cheers
Sent from my GT-I9100 using Tapatalk
Click to expand...
Click to collapse
For me it is just the chance to have a change never getting bored of the same rom, the con is using a dual boot that is still in better and is buggy at the moment, which may cause problems with your rom mainly the 2nd rom, also the storage of data is causing some people problems, but the thread is give good solutions.
Dual booting rocks. android rules...
Thank you for this guide
So there is an option to boot two GB ROMs but no ICS and now we can boot two ICS ROMs but no GB...
The third option should be... - you know it
Sent from my GT-I9100 using XDA
Probably get flamed - btw, I don't care one jot - but why on earth should this be stickied?
This isn't a guide, it's a post with two links to the relevant threads, where the discussion is going to be a lot more useful than anything here.
s.d. o'connor, your other guides are guides, and are very useful, for which my thanks. This one isn't.
Flame-retardant pants on - fire away.
My defence
B3311 said:
Probably get flamed - btw, I don't care one jot - but why on earth should this be stickied?
This isn't a guide, it's a post with two links to the relevant threads, where the discussion is going to be a lot more useful than anything here.
s.d. o'connor, your other guides are guides, and are very useful, for which my thanks. This one isn't.
Flame-retardant pants on - fire away.
Click to expand...
Click to collapse
Why would you get flamed for having an opinion, you are entiled to that, but here goes my defence. I could only but ask if it could be a sticky i didnt make it one, and the idea is to stop new threads being opened asking the question can you dual boot the galaxy s2. Also as more options of dual booting become avaiable then they can be added to this thread.
P.S I dont want people to get flamed for having a opinion, they have a right to that, as long as they put that across in a good manner.
You don't need a defence (unlike Leeds United, but that's another story).
Flaming is an occupational hazard here sometimes, especially if someone has the temerity to diagree with someone else. I'm way past worrying anyway.
On topic - I still don't think this deserves sticky status. You and others do. No problem. Each to their own. It's up to the mods anyway, not us.
No foul on you SD O'C because you've put together some really good threads, but if this is 'sticky worthy' standards have plummeted on XDA. Rapidly. As has been pointed out, there's a couple of links & pretty much no original content or anything that could remotely be considered a 'guide'.
Droidphile's excellent dualbooting post in the Siyah dev thread a few days ago, now that was a guide (and sticky worthy).
okay, i am on dual boot. using LPQ as primary and cm9 latest nightly as secondary
and i note battery drain
MistahBungle said:
No foul on you SD O'C because you've put together some really good threads, but if this is 'sticky worthy' standards have plummeted on XDA. Rapidly. As has been pointed out, there's a couple of links & pretty much no original content or anything that could remotely be considered a 'guide'.
Droidphile's excellent dualbooting post in the Siyah dev thread a few days ago, now that was a guide (and sticky worthy).
Click to expand...
Click to collapse
What post number is it and i can include it and give him full credit, i will of course ask first. Also i would like to point out this was never intended as a guide, more a point of ref.
P.S If LUFC would like to change his mind on this being a sticky then i would have no problem with this.
ashifr5 said:
okay, i am on dual boot. using LPQ as primary and cm9 latest nightly as secondary
and i note battery drain
Click to expand...
Click to collapse
Battery drain has been noted with the kernel, he has made a fix for most roms and combo's but he will need time as it is still in the early stages. Also when flashing a new rom this can alter the casuse battery drain, a full charge of the batter could fix this problem.
MistahBungle said:
Droidphile's excellent dualbooting post in the Siyah dev thread a few days ago, now that was a guide (and sticky worthy).
Click to expand...
Click to collapse
Here it is, for all the non-searchers.
Off-topic again - s.d.oconnor, to quote an earlier post from yourself:
s.d.oconnor said:
Thanks man, the XDA community has give me so much, I just want to give back.
Click to expand...
Click to collapse
If so, what's the "donate to me" banner doing in your signature? Just awaiting love and affection?
You've compiled some useful guides, but let's face it, your work has mainly been collating readily available links and other posts that any reasonable modicum of searching ability could accumulate.
Nothing in the site rules that forbids you to ask for donations, but for what you've done - especially taking into account that you've been a member here for two months - I can think of an awful lot more contributors ("recognised" or not) whom are far more worthy of donations than yourself.
The "giving back to the community" spiel is very valiant and honourable, but you want donations. Fine, sure you've got some too. But don't dress it up behind the "giving back" line - not exactly sincere, no?
Again, I'm not flaming/trolling - merely my opinion.
B3311 said:
Here it is, for all the non-searchers.
Off-topic again - s.d.oconnor, to quote an earlier post from yourself:
If so, what's the "donate to me" banner doing in your signature? Just awaiting love and affection?
You've compiled some useful guides, but let's face it, your work has mainly been collating readily available links and other posts that any reasonable modicum of searching ability could accumulate.
Nothing in the site rules that forbids you to ask for donations, but for what you've done - especially taking into account that you've been a member here for two months - I can think of an awful lot more contributors ("recognised" or not) whom are far more worthy of donations than yourself.
The "giving back to the community" spiel is very valiant and honourable, but you want donations. Fine, sure you've got some too. But don't dress it up behind the "giving back" line - not exactly sincere, no?
Again, I'm not flaming/trolling - merely my opinion.
Click to expand...
Click to collapse
Ok, the banner donate to me has been their since i joined as you are giventhe option to include one, i was new (still am), i have not recived any donations, and if i did they would be used to go back to the XDA website, if it offends anyone i will remove the banner. Also if any mod belives that i am not worthy of my title and that my guides are not of the standard that is very good then they can by all means remove them from any sticky they may be on, and remove my title if they see fit.
I know you are saying that you are not flaming me, but it seems to be moving in that direction. I know i have only been here a short while but i belive that what i have done is not that bad of a standard, in the short time i have been here.
hi,
I have a rooted s5 and was going to encrypt the phone then factory reset to make sure the data cant be recovered easily. Having just tried to do it i think being rooted is not allowing me to encyprt.
Would formatting data on TWRP give me the same results and make my phone delete everything??
thank you
lumix4321 said:
I have a rooted s5 and was going to encrypt the phone then factory reset to make sure the data cant be recovered easily. Having just tried to do it i think being rooted is not allowing me to encyprt.
Would formatting data on TWRP give me the same results and make my phone delete everything??
Click to expand...
Click to collapse
Most people know enough to "factory reset data" before selling a device. And that does make your user data inaccessible to a normal user. It would not protect you from someone using data recovery software as many read in a recent article.
Formatting or repartitioning will make a would be spy's job incrementally harder. But it won't truly guarantee that your data is irrecoverable. If you know your way around the command line, you could script dd to overwrite the /data partition with several alternating passes of 1's, and 0's to obliterate your personal details. Using dd is dangerous though if you don't understand dd syntax and partition addressing.
Pragmatically, do a search of the app store to see if anyone has made a data wipe utility that supports the S5. If not, then there is an advanced Odin option to wipe the NAND that should suffice. You can find XDA threads explaining it's use.
.
fffft said:
Most people know enough to "factory reset data" before selling a device. And that does make your user data inaccessible to a normal user. It would not protect you from someone using data recovery software as many read in a recent article.
Formatting or repartitioning will make a would be spy's job incrementally harder. But it won't truly guarantee that your data is irrecoverable. If you know your way around the command line, you could script dd to overwrite the /data partition with several alternating passes of 1's, and 0's to obliterate your personal details. Using dd is dangerous though if you don't understand dd syntax and partition addressing.
Pragmatically, do a search of the app store to see if anyone has made a data wipe utility that supports the S5. If not, then there is an advanced Odin option to wipe the NAND that should suffice. You can find XDA threads explaining it's use.
.
Click to expand...
Click to collapse
thank you for an extremely informative answer :good:
fffft said:
Most people know enough to "factory reset data" before selling a device. And that does make your user data inaccessible to a normal user. It would not protect you from someone using data recovery software as many read in a recent article.
Formatting or repartitioning will make a would be spy's job incrementally harder. But it won't truly guarantee that your data is irrecoverable. If you know your way around the command line, you could script dd to overwrite the /data partition with several alternating passes of 1's, and 0's to obliterate your personal details. Using dd is dangerous though if you don't understand dd syntax and partition addressing.
Pragmatically, do a search of the app store to see if anyone has made a data wipe utility that supports the S5. If not, then there is an advanced Odin option to wipe the NAND that should suffice. You can find XDA threads explaining it's use.
.
Click to expand...
Click to collapse
Through factory reset it doesn't delete anything from your sdcard partition....
You might have seen this guide on XDA, but is out-dated and only seems to work on stock firmware. What about people people running CM13, will it work, or will it brick your device?
This guide is updated and works with CM13 tested by me, it was also written with the i9300 16GB model in mind.
FAQ: next post
I take NO responcebility for any bricks, that's on you. Exactly like rooting, or installing anything 3:rd party (right?). Either is is my responsibility if any data is lost.
If you don't follow the guide, and adventure on your own, there's no one to blame but yourself when **** hits the fan.
Now, let's have a look at my partitions before modifying them (kB):
Code:
Filesystem Total Used Available Use% Mounted on
mmcblk0p8 1032088 17732 1014356 2% /cache
mmcblk0p12 11901576 6355436 5546140 53% /data
mmcblk0p12 11901576 6355436 5546140 53% /sdcard
mmcblk0p10 564416 8964 555452 2% /preload
mmcblk0p9 1548144 632704 915440 41% /system
mmcblk0p3 20144 9568 10576 47% /efs
As you can see, stock paritioning is bad. /preload and /cache has a lot of available space which takes up a lot of unnecessary space.
We can minimize all the partitions and use the space to increase your internal storage, neat; let's do it!
1. Check for buggy eMMC chip
First of all we'll be checking if your chip is possible to SDS (sudden death syndrome) which basicly corrupts your eMMC (internal storage) chip.
This only effects the 16GB model, if you're on another model just skip to the flashing part.
A. Download the app eMMC Brickbug Check app from the Play Store.
B. Check eMMC
Check if your device has the following under eMMC chip:
Type: VTU00M
FwRev: 0xF1
If the values match, you should update to the latest ROM + kernel available ASAP, which should fix SDS, if you don't; your eMMC chip might corrupt under the process of flashing REPIT.
2. Flashing guide
A. Before we begin
- Make sure that you're running the latest version of TWRP (i9300, i9305). Any other recovery and the script will NOT work.
- Do NOT continue if you're running stock, or planning to do so. This script is only tested on official CM13.
- Make sure you're plugged into a power source, and not a computer; or else partitions may fail to un-mount.
- Do a backup of your rare cat images so they don't get lost in the worst scenario.
- (optional) If you want to configure the script, see this.
B. Download required tool
We'll be using ourselves with the tool REPIT made by @Lanchon.
Without it I wouldn't make this guide as it is the only(CN) flexible tool for modifying partitions in Android.
Download the required flashable zip file: [updated 2017-01-22]
- i9300 - here
- i9305 - here
Make sure you DON'T rename it; copy it to your device.
C. Boot into recovery - volume up + home button + power button when powered off
D. Flash the zip file
- This process is a really long one, do NOT interrupt the process.
- If the flashing fails, it may tell you that it copied itself to /tmp, navigate to /tmp and flash the script again.
- If x partition fails to un-mount, try un-mounting it via TWRP > Mount.
Inside TWRP navigate to Install > Navigate to saved REPIT and select > Swipe to confirm flash.
3. Done!
You may now restart your device and verify the extra utilized internal storage.
It's not that hard eh? That's because @Lanchon did a great job on his project available on GitHub. Him and I worked closely on #22 to add support for the i9300.
After re-partitioning (still kB):
Code:
Filesystem Total Used Available Use% Mounted on
mmcblk0p8 32240 4200 26404 14% /cache
mmcblk0p12 13457732 574316 12199796 4% /data
mmcblk0p12 13457732 574316 12199796 4% /sdcard
mmcblk0p10 8048 4120 3520 54% /preload
mmcblk0p9 1548144 638168 909976 41% /system
mmcblk0p3 20144 9568 10576 47% /efs
It seems like we've gained 1.5GB in local storage, hoorah! Totally didn't steal from other partitions
Worth it? (my opinion)
Unless you REALLY need that 1.5GB of extra storage; NO, not at all.
On Android 6+ (CM13) sd-cards are now implemented like normal internal storage. Just buy a 8GB micro sd-card which costs a couple of bucks these days and save yourself some trouble.
Not only that, recently a user possibly got SDS (sudden death syndrome, do your own research) after flashing REPIT. Did my own research and I updated the guide with a step to check for this buggy eMMC chip.
Credit:
- @Lanchon for REPIT.
- @forumber2 for original guide.
QnA:
The questions are kinda copied from the old guide.
Q: Why is /cache a large partition?
A: It's because stock software updates saves in the partition. The partition was extended(CN) when upgrading to Android 4.3, as the update was so large, the cache partition had to be as well. AOSP does NOT use the partition when updating.
Q: What is the /preload partition for?
A: It's only really used if you bought the phone locked. Many mobile operators put in extra apps, and bloatware too in the partition only utilized in stock firmware; and even then... There's some random Samsung crap too. REPIT minimizes the partition.
Q: Any consequences of flashing?
A: Yes, you will NOT be able to install stock firmwares (assuming that you're not running stock). A undo is easy as the script is so flexible.
You will also burn a lot of eMMC life cycles using REPIT so don't do it often, and I hope you've read 1. where I covered the buggy eMMC chip thingy.
Q: Something went wrong with flashing the zip file!
A: Please upload the REPIT log usally found in the folder where you placed the flashable zip file to dropbox, or https://paste.tinyw.in; apparently pastebin doesn't like long logs. Can also be in /tmp. Otherwise you can copy the whole TWRP log found in /tmp/recovery.log, /cache/recovery/log or /cache/recovery/last_log. NEVER copy the whole log and make a post out of it, you're spamming the thread by doing so. Issues with REPIT should NOT be reported here, instead go to the REPIT GitHub page here.
Q: I want to undo these changes!
A: Since @Lanchon is taking over this thread :laugh:, ask him. Sorry for me not doing my homework.
Q: How about the x GB model?
A: They all work, REPIT is designed to assign any leftovers to the partition we use.
More questions? Bring them on.
Reserved #2
May be it's better to give proper credits too considering it was a big mess up in past.
Sent from my "i9300/1+2" powered by Carbon/Temasek
Fueled by 7000mAh ZeroLemon Battery
nicesoni_ash said:
May be it's better to give proper credits too considering it was a big mess up in past.
Sent from my "i9300/1+2" powered by Carbon/Temasek
Fueled by 7000mAh ZeroLemon Battery
Click to expand...
Click to collapse
Woops, I made the guide in notepad++, and accedently removed some lines when editing it; including a better credit to @Lanchon; adding in a new one now.
Hawaii_Beach said:
Woops, I made the guide in notepad++, and accedently removed some lines when editing it; including a better credit to @Lanchon; adding in a new one now.
Click to expand...
Click to collapse
I meant in your op too.
Sent from my "i9300/1+2" powered by Carbon/Temasek
Fueled by 7000mAh ZeroLemon Battery
Btw, is it possible to modify this script somehow so that you can reformat the /cache partition to f2fs? Afaik the minimum size is 100mb.
Sincci said:
Btw, is it possible to modify this script somehow so that you can reformat the /cache partition to f2fs? Afaik the minimum size is 100mb.
Click to expand...
Click to collapse
No, I'm sorry. It is already known, on GitHub: #8.
The minimum size of /cache? The script sets /cache to 32240kB which is 32MB..
nicesoni_ash said:
I meant in your op too.
Click to expand...
Click to collapse
OP?
Hawaii_Beach said:
No, I'm sorry. It is already known, on GitHub: #8.
The minimum size of /cache? The script sets /cache to 32240kB which is 32MB..
Click to expand...
Click to collapse
After I read your conversation with @Lanchon on git, it seems to me that there is no need to wipe data and it will still work, it's that right?
OP - Original Post basically referred to first post.
Sent from my "i9300/1+2" powered by Carbon/Temasek
Fueled by 7000mAh ZeroLemon Battery
nicesoni_ash said:
After I read your conversation with @Lanchon on git, it seems to me that there is no need to wipe data and it will still work, it's that right?
OP - Original Post basically referred to first post.
Click to expand...
Click to collapse
Yes, you don't need to wipe /data. It just makes things faster; as you wont have to move the content around. Without wiping, it will take a longer time to re-partition.
The script will NOT wipe /data except you add +wipe to -data=max (-data=max+wipe-i9300)
OP has so many meanings, it's f***ed.
Hawaii_Beach said:
On Android 6+ (CM13) sd-cards are now implemented like normal internal storage. Just buy a 8GB micro sd-card which basicly costs a couple of bucks and save yourself some trouble.
Click to expand...
Click to collapse
hi, thanks for the guide!
actually, the external sdcard will always be slower than the internal eMMC. also, the extra free space gets auto-TRIMmed in /data, making the whole eMMC (and thus your phone) faster. also, adopted storage diminishes the total reliability of your phone and data (more devices can fail).
in all, i'd recommend anybody with less than 2 or 3GB free space in /data to REPIT; it's safe and easy.
---------- Post added at 05:35 PM ---------- Previous post was at 05:22 PM ----------
Sincci said:
Btw, is it possible to modify this script somehow so that you can reformat the /cache partition to f2fs? Afaik the minimum size is 100mb.
Click to expand...
Click to collapse
REPIT does not support f2fs for now.
(future support will not include wipe without resizing, as f2fs does not support that yet.)
but you can get what you want anyway:
"-cache=0.03125+wipe"
actually means
"-cache=0.03125+wipe+ext4"
given that ext4 is the default FS for "cache".
"wipe" means format, and never mind what was there before. even if it was something that wasn't ext4 at all, it will succeed.
so you can use:
"-cache=0.0976+wipe"
to get exactly 100MiB-sized cache (in ext4)
then, afterwards, use TWRP to format cache in F2FS
and you'd get what you want.
but...
DON'T!!!
dont use F2FS in ANY partition besides /data! it makes NO sense!
F2FS has an overhead of about 100MB, so basically you would be creating a /cache that is unable to hold any files at all. (ext4 has 5MB overhead.)
and why have a dysfunctional /cache? what for? to have problems? incompatibilities?
certainly not performance, because cache is NEVER used in android. so why do it?
it's soft of a crazy fad, like /system in f2fs.
/system, the one partition we never write to, lol
---------- Post added at 05:39 PM ---------- Previous post was at 05:35 PM ----------
nicesoni_ash said:
May be it's better to give proper credits too considering it was a big mess up in past.
Sent from my "i9300/1+2" powered by Carbon/Temasek
Fueled by 7000mAh ZeroLemon Battery
Click to expand...
Click to collapse
thanks!
no credit required!!! the GPL allows him to do as he pleases, as long as he doesn't remove the license or claims copyright.
but anyway, thanks for the credit appreciated!
and thanks for invaluable help to port to i9300!!
---------- Post added at 05:43 PM ---------- Previous post was at 05:39 PM ----------
btw, i should start thanking the people who helped with the ports in the comments of the device port file. so far 2. i will back-credit when i get the time.
and i9305 and others are probably trivially supported, i just need the dumps done.
Lanchon said:
really long stuff going on
Click to expand...
Click to collapse
The thing is that not only could REPIT be ported to i9300, but any other Samsung device, right? They all run TouchWiz; for example s4, s5, s6? Have anyone even checked partitions on those devices?
The thing with partitions and the Android community is that almost no one discusses it. If you do a google on partitions on Android; very Little information / threads exist.
Lanchon said:
hi, thanks for the guide!
actually, the external sdcard will always be slower than the internal eMMC. also, the extra free space gets auto-TRIMmed in /data, making the whole eMMC (and thus your phone) faster. also, adopted storage diminishes the total reliability of your phone and data (more devices can fail).
in all, i'd recommend anybody with less than 2 or 3GB free space in /data to REPIT; it's safe and easy
Click to expand...
Click to collapse
To be honest, I never cared about storage speed (same goes for trim), not a heavy user on my phone, and have never been, just doesn't go well when I'm the operator. As long as it doesn't take 1 year to copy my secret .mp4's (ransom.mp4 and many more), there's no worries.
About failure, it's like running a computer. If you shut down a computer without sending signals (unplug from wall etc), it may damage the harddrive; right? Same here. Right?
Any how, If I ever run out of space on my i9300, I'd just add a sd-card. I don't save anything important on my device that doesn't get backed up via TWRP. But..
that's never going to happen! Because my OnePlus One is coming back from RMA service! (finally after 4 months (not kidding)). kinda off topic, but hey; it's my thread right :good:
Hawaii_Beach said:
The thing is that not only could REPIT be ported to i9300, but any other Samsung device, right? They all run TouchWiz; for example s4, s5, s6? Have anyone even checked partitions on those devices?
The thing with partitions and the Android community is that almost no one discusses it. If you do a google on partitions on Android; very Little information / threads exist.
Click to expand...
Click to collapse
lol about the quote
besides the name playing on samsung's PIT files, REPIT can actually work on any device with TWRP support. but the partition layout in most newer devices is friendly enough not to bother. even the stock i9300 layout is sort of friendly. highly problematic are only the devices that shipped before ICS with android 2.x (galaxy S2) or devices that shipped with non-emulated internal sdcard.
discussion is low volume because partitioning is considered 'dangerous'. and it can be, you can brick if you mess up. the idea of REPIT was to make it safe by encapsulating a bit of knowledge of each device in the device port file. motivation was that S2 users suddenly all needed to repit: their devices stopped working after a nightly flash because of /system being too small, it was a mess, lol.
btw, since you asked before, that's the reason why porting is needed: because you can't trust users not to make mistakes with full freedom. users that want full freedom have other tools: gdisk, parted, mkfs.xxx, resize2fs, etc.
Lanchon said:
lol ab...
Click to expand...
Click to collapse
Yeah, I know that other devices doesn't even need to touch the partitions, as it is a waste of time. (so is this??)
edit: still, maybe I want a extra 1.5gb on my s6 Active or whatever.
edit: by for today, it's 00:00 here..
discussion is low volume because partitioning is considered 'dangerous'. and it can be, you can brick if you mess up. the idea of REPIT was to make it safe by encapsulating a bit of knowledge of each device in the device port file. motivation was that S2 users suddenly all needed to repit: their devices stopped working after a nightly flash because of /system being too small, it was a mess, lol.
Click to expand...
Click to collapse
Dangerous!? I've seen way more people fu** their IMEI number (including ME on MINE i9300) by doing something dumb to the /efs content (totally didn't try to unlock the phone), that's dangerous. (got 0049)
The phone was just lying round until I got around to fix it, not going to get into details as XDA doesn't allow this stuff. It was really fustrating as people said that reflashing stock would get back the IMEI (should apparantly work, etc etc).
yet again side tracked, but i'm the operator right? :good: :highfive:
@Lanchon
Since we are talking abt partitions, I would like to ask a question that's not related to this tool but the other way mentioned in first post by flashing a zip file with manually entering the size in script file.
I tried that a while back on my s3 and it worked great. I was on kitkat that time and it was fine till lollipop came. So I flashed lollipop but since the system size was only about 500mb, it failed to flash so I made another zip with system size to 800mb and flashed it again. Although everything went fine but after flashing a new rom or restoring my old backup phone always showed some encryption error and asked to factory reset and even after doing that, still showed the same error even though I never encrypted anything. So the only option was to flash stock with pit file and change the partitions to stock size and then restore or flash a new rom.
I was never able to partition my phone after that coz that error always came back. I have op2 now so all molding goes on it and s3 is like a backup phone but I am still interested to know what was that all about and what could I do to fix that or whether my emmc worn out?
Sent from my "i9300/1+2" powered by Carbon/Temasek
Fueled by 7000mAh ZeroLemon Battery
Hawaii_Beach said:
Dangerous!? I've seen way more people fu** their IMEI number (including ME on MINE i9300) by doing something dumb to the /efs content (totally didn't try to unlock the phone), that's dangerous. (got 0049)
The phone was just lying round until I got around to fix it, not going to get into details as XDA doesn't allow this stuff. It was really fustrating as people said that reflashing stock would get back the IMEI (should apparantly work, etc etc).
yet again side tracked, but i'm the operator right? :good: :highfive:
Click to expand...
Click to collapse
well... effing the bootloader i way worse than borking /efs, believe me.
now, trying to hack /efs WITHOUT A BACKUP (!!) is big jesus f*cking christ sh*t u talking lol!!!
Lanchon said:
well... effing the bootloader i way worse than borking /efs, believe me.
now, trying to hack /efs WITHOUT A BACKUP (!!) is big jesus f*cking christ sh*t u talking lol!!!
Click to expand...
Click to collapse
Hahahaha yep. Didn't know the risk dude.
nicesoni_ash said:
@Lanchon
Since we are talking abt partitions, I would like to ask a question that's not related to this tool but the other way mentioned in first post by flashing a zip file with manually entering the size in script file.
I tried that a while back on my s3 and it worked great. I was on kitkat that time and it was fine till lollipop came. So I flashed lollipop but since the system size was only about 500mb, it failed to flash so I made another zip with system size to 800mb and flashed it again. Although everything went fine but after flashing a new rom or restoring my old backup phone always showed some encryption error and asked to factory reset and even after doing that, still showed the same error even though I never encrypted anything. So the only option was to flash stock with pit file and change the partitions to stock size and then restore or flash a new rom.
I was never able to partition my phone after that coz that error always came back. I have op2 now so all molding goes on it and s3 is like a backup phone but I am still interested to know what was that all about and what could I do to fix that or whether my emmc worn out?
Sent from my "i9300/1+2" powered by Carbon/Temasek
Fueled by 7000mAh ZeroLemon Battery
Click to expand...
Click to collapse
well i cannot answer about scripts and procedures unknown to me but...
an encrypted disk typically is made of 2 things:
-the encrypted disk 'surface' or area (ie: the data)
-and metadata (data describing the data, ie: data describing the encrypted disk)
metadata typically contains:
-cipher info
-and the disk surface encryption key (generated at random), itself encrypted with the access key (such as a passphrase).
why the indirect key? without it:
-changing the passphrase (say, your phone lock pattern) would be a very dangerous operation that would require reading, reencrypting and writing the complete disk, would take a huge amount of time and would drain your battery completely
-erasing the disk would similarly take a long time.
with it:
-when changing the passphrase you just need to reencrypt the surface key with the new passphrase and rewrite the metadata.
-when erasing, just wipe the metadata.
for example the metadata in recent android phones with hardware backing store for keys probably contains:
-cipher info
-and the disk surface encryption key (generated at random), itself encrypted with a secondary key (also random).
the secondary key lives in the hardware keystore. it's generated there and can never leave that processor. the keystore will decrypt the surface key during boot, only if the main processor informs the right passphrase (say, the PIN or pattern). a 4-digit PIN would be very easy to bruteforce, except that the keystore throttles down guesses, and can even wipe the key (rendering the disk forever unreadable) after so many bad guesses.
the keystore should be tamper-proof: a silly small processor, but resistant to voltage spike attacks, rays, etc and decapping to read the storage, to pick up signals in traces, to inject signals in traces, to chip modifications, etc. think of it as the chip in any recent credit card or even some sim cards, but on the main circuit board.
anyway back to metadata in android: it needs to be stored somewhere. the obvious place is an ultra small metadata partition containing just the raw metadata, no file system or anything of the like. this is simple and works great, except for one detail: older phones don't have this partition. basically this means that an android upgrade couldn't give you encryption.
so android can use a "crypto footer": with this scheme the encryptable partition (say /data) has a file system that is 16KiByte short of filling the actual partition, and the 16KiB footer follows. the footer is the metadata.
when you repartitioned before, you probably created a file system that used the complete partition area. there was no space left for the footer, so encryption couldn't be enabled.
you could have solved your issue today by flashing repit with all-default parameters: repit always resizes the encryptable partition's file system to make room for the footer, if not already there.
in REPIT, these commits add general and ext4-particular support for crypto footers:
https://github.com/Lanchon/REPIT/commit/591961adb180a6a03594053a846b698240b4d507
https://github.com/Lanchon/REPIT/commit/de3d3af9813afef7de3a798ce5314c0fb210e30f
https://github.com/Lanchon/REPIT/commit/5c3360b572ff25c7c01d796cabb9400066451ec3
this configures the footer on the i9300:
https://github.com/Lanchon/REPIT/blob/f46b0aafdfeb7860be17a315b4aceb43966325f9/device/i9300.sh#L85