[Recovery] Customized CWM 3.0.1.3 fake-flash with ext4 support (03/06/2011)

BlaY0

Retired Recognized Developer
Sep 15, 2007
1,553
566
0
Medvode
OK, here's the deal. This is my attempt in customizing CWM. It features several changes in comparison to one from CM source...

Changes
  • removed menu entries for updating via /sdcard/update.zip (useless for fake-flash users)
  • stripped some "No" line entries from confirmation menus
  • removed some insane size values from partitioning list
  • added some sane size values to partitioning list
  • added option to add 2nd ext partition (for some data2sd variants)
  • added block alignment to partitioning part
  • added advanced backup submenu

Plans
  • add block alignment to partitioning part
  • add advanced backup submenu
  • add some additional wipe options

Issues
  • mounting /sdcard again after unmounting not possible

Installation
Just copy this file to root of your SD card and rename it to update.zip. You can also use previous non-customized version.

Source
Source for this project is available on GitHub.

CAUTION! This is still in test phase. And your phone may explode suddenly if you're not careful enough. But in general it is pretty much safe (if you stand several feet from your phone). If you encounter any problems relevant logs are /tmp/recovery.log and /data/sdparted.log which I will need for debugging.
 

Attachments

Last edited:

bjohv052

Senior Member
May 17, 2010
339
55
0
Uppsala
Hi BlaY0!
does this file works even on s-off legend?
Thx
Well, sort of. If you go to recovery via ROM manager, you will not get CWM 3.0.0.6 and if you go to recovery from HBOOT you will not get CWM 3.0.0.6.

The only way is to go to recovery and then choose "Apply update.zip".

So, yes, it works. But it's a bit tricky.
 

Kot_Ik

Senior Member
Apr 30, 2007
171
271
93
Glazov
My ext4 partition still can't mount. Is there any way to collect recovery logs or something?
You can run
Code:
adb shell dmesg
just after trying to mount the sd-ext. Then put it in this thread.
BTW, BlaY0, if i correctly understood, in your B ROM ext4 creates with huge_files option. My ext4 partition was created being under your rom, and all had run smooth except current CWM could not mount partition saying
Code:
<6>[   37.128723] yaffs: dev is 187695106 name is "mmcblk0p2"
<6>[   37.128936] yaffs: passed flags ""
<4>[   37.129150] yaffs: Attempting MTD mount on 179.2, "mmcblk0p2"
<6>[   37.129791] yaffs: dev is 187695106 name is "mmcblk0p2"
<6>[   37.130004] yaffs: passed flags ""
<4>[   37.130371] yaffs: Attempting MTD mount on 179.2, "mmcblk0p2"
<3>[   37.131561] EXT4-fs: mmcblk0p2: Filesystem with huge files cannot be mounted read-write without CONFIG_LBD.
until i turned this option off. Under working system with your kernel/modules ext4 mounts good even with huge_file option.
 
Last edited:

psyionx

Senior Member
Nov 30, 2010
229
50
0
Kota Kinabalu
thanks!but i don't understand !!!I'm not good at these things :eek:
i have update the file by recovery and now?where should I set???:confused:
as picz mentioned, you put this file in the root of your sd card.
than you switch off your phone. than on it holding the Vol- and the power button. Than select recovery. ant the red [!] screen. press Vol+ and the power button. wait for a blue menu list at the top of the screen. than select update.zip...

this is Fake Flash....
 

BlaY0

Retired Recognized Developer
Sep 15, 2007
1,553
566
0
Medvode
BTW, BlaY0, if i correctly understood, in your B ROM ext4 creates with huge_files option. My ext4 partition was created being under your rom, and all had run smooth except current CWM could not mount partition saying
Code:
<6>[   37.128723] yaffs: dev is 187695106 name is "mmcblk0p2"
<6>[   37.128936] yaffs: passed flags ""
<4>[   37.129150] yaffs: Attempting MTD mount on 179.2, "mmcblk0p2"
<6>[   37.129791] yaffs: dev is 187695106 name is "mmcblk0p2"
<6>[   37.130004] yaffs: passed flags ""
<4>[   37.130371] yaffs: Attempting MTD mount on 179.2, "mmcblk0p2"
<3>[   37.131561] EXT4-fs: mmcblk0p2: Filesystem with huge files cannot be mounted read-write without CONFIG_LBD.
until i turned this option off. Under working system with your kernel/modules ext4 mounts good even with huge_file option.
Yeah, formatting ext4 partition under B or CM adds "huge_file" to the filesystem features by default. Actually this is default for mke2fs config (will be changed in the next B release). My customized and also CM kernal got this LBD alias LBDAF support built in but stock kernel from recovery doesn't hence the error. Unfortunately LBD support can't be built as a module so there is actually no way to add this support to stock recovery if your Legend is S-ON.

But... since LBD alias LBDAF and consequently "huge_file" support in ext4 is actually support for files bigger than 2TB we kinda don't need it I guess ;) so what we can do is as you suggested remove "huge_file" feature from ext4 filesystem like this:
Code:
tune2fs -O ^huge_file /dev/block/<ext4_partition>
e2fsck -pf /dev/block/<ext4_partition>
...and we do this via recovery or system but ext4 partition shouldn't be mounted at that point! So unmount it first or disable data2ext/a2sd and reboot, do da above job, enable data2ext/a2sd and reboot again. To check if "huge_file" feature is actually enabled in your ext4 filesystem you do:
Code:
tune2fs -l /dev/block/<ext4_partition>
...and check "Filesystem features:" line.
 
Last edited:

BlaY0

Retired Recognized Developer
Sep 15, 2007
1,553
566
0
Medvode
New update. Check 1st post.

hi BlaY0 !
can you release img for S-off users ? (i know we can use this but i like IMG)
No, I decided not to. Will stick to fake-flash. But if you want, you can do it yourself and post it here...

EDIT: Rather post img in the other thread.
 
Last edited: