yashsingh1/xdaforums huggingface dataset:
[Mi 3 General] KSKHH:
Google and download this recovery. The latest one having issue, it will always reboot to recovery.

CWM_recovery_r7_cancro_final.zip
[Mi 3 General] SerjP:
Well, I guess if you are using stock ROM, you have to flash stock partitions. Not sure, but I'm feeling stock ROM needs the stock partitions. Correct me if I'm wrong.

I never tried to install stock ROM on extended partition, so have no idea if it supported, sorry.

Also please double check in CWM what active partition you are using. It might be wrong boot partition is selected (partition with no ROM) so you are getting boot loop.
[Mi 3 General] KSKHH:
Stock ROM does not need stock partition. It can be install in extended partition too, only you will not have system1 partition and can not boot the phone with system1 in case any issue.
[Mi 3 General] sam_chk:
Well i am not able to install on extended partition be it through CWM OR TWRP... Moved back to stock I partition.. In fact TWRP Was giving update binary error... Will wait for more suggestion..
[Mi 3 General] KSKHH:
Well, I never faced this issue. I have swap between Stock / Extended several times. I have used MIUI in extended partition too.

Presently I am not in Stock, Nor in Extended. I made Partition as the requirement and extended the userdata partition.

My present Partition is like this and I am using official MIUI ROM:-

System1: 750MB

System2: 5MB

Cache: 400MB

Userdata: Rest

I steal extra space of System 2 to userdata and enjoying. The process was heavily complicated and I screwed up the phone 4 times. Finally got success.

Over the weekend I will try to pull some MB from Cache if possible. So far it was failed.
[Mi 3 General] sam_chk:
[MENTION=5032078]KSKHH[/MENTION] how did you flash stock miui on extended partition? Was it a zip flash using CWM OR TWRP? was it via fastboot or via backup?
[Mi 3 General] KSKHH:
It is just the zip downloaded from MIUI official site. You can not flash thru fastboot in extended/modified partition and again u hv to hv fastboot MIUI ROM to flash thru fastboot.

You can install the zip thru TWRP or CWM whatever it is.
[Mi 3 General] diongdyh:
How did you do that(Your partition) ? Tutorial pls!
[Mi 3 General] yashshah7197:
Two extended systems possible?

Is it possible to modify the script and have two extended systems of 1.2 gigs each? I'd like to dual boot MIUI and CM 12.1 but CM requires an extended partition.

I mean can we pull 1.2 gigs out of the userdata partition and use it for another system partition? I have a 64 gig Mi4 so not really concerned about losing 1.2 gigs from userdata.
[Mi 3 General] TofikLupus:
I'm also interested in the both partition extension to 1.2GB.. But I'm wondering if it affects anything like system not recognizing the upper partitions because their start and end addreses will be moved higher, to be exact I'm talking about the Cache and Userdata partitions. I'm not gonna mess with my phone until I know it's working. My phone is Mi3W 64GB. Thank you.

Odesláno z mého MI 3W pomocí Tapatalk
[Mi 3 General] KSKHH:
Two extended partition is possible but highly risky. I am not sure whether you can have multirom boot facility, bcoz data partition would be same and MIUI is running on Kitkat still now.

---------- Post added at 07:56 AM ---------- Previous post was at 07:50 AM ----------

Sorry buddy it is complicated. I have referred some commands from OP and some of from the extended partition script. It is done completely manually. No auto script.

I am presently using MIUI 5 V34. I like MIUI V5 on V6.

My other ROMs are Ivan, OMNI. Which install without any issue.

I have noticed ROM created with new zip give issues if your system partition is not 1.2GB. However almost all AOSP, CM roms does not need 1.2 GB. There are always space left out in system partition after installation of the ROM, thus we are just wasting space.
[Mi 3 General] TofikLupus:
I guess someone should try it first. I got my MI3 less than 2 weeks ago and I would hate to brick it. I might use the same procedure for expanding /system1, removing both /cache and /userdata and creating them a few hundred MBytes higher.. saving the original partition table and in case it doesn't work, using the same procedure i can revert it back... but i'm not sure how many flashes will the internal emmc survive? That's the main problem I'm afraid of. My last phone was Lenovo A820, featuring MT6589M by Mediatek... i was flashing it a lot when i got it, not that often after some time... but at some point, the phone started to fail from some reason, all applications were crashing on a stable ROM, system was self restarting... In the service they replaced the whole motherboard. So the question remains, how many flashes will the internal memory stand if the issue above was memory related?

Odesláno z mého MI 3W pomocí Tapatalk
[Mi 3 General] diongdyh:
Well I've flashed a million times and it's still alive.
[Mi 3 General] TofikLupus:
That's good, maybe it was just a defective piece, as i read today, NAND memory should survive around 100,000 erase cycles (for each block) before the particular blocks fail. So it's also possible that it wasn't even the memory chip what was defective, but rather something else on the mainboard, could be the SoC itself...

Well I might try repartitioning then, I guess there's nothing much to mess up since it's always possible to edit partitions and flash whatever we want on them, hence reverting to original ones should work too. But if the /cache and /userdata partitions won't exist, will the phone boot into a recovery? Because without recovery, I can't revert the partitions back. Just for any case.

Odesláno z mého MI 3W pomocí Tapatalk
[Mi 3 General] ilnanny:
Thanks for sharing.

Do you have a suggestion for MI3 64 gb?

Thanks in advance
[Mi 3 General] Pi3rluigi:
What are you looking for?

Inviato dal mio MI 3W utilizzando Tapatalk
[Mi 3 General] ilnanny:
I'm trying to partition my terminal in a manner correct . i have a MI3 64GB.

I just wanted to know how to create the right partition table.

thanks :o
[Mi 3 General] Pi3rluigi:
There's a flashable zip file, very easy to use that set the system 1 partition to 1.2 Gb.

Inviato dal mio MI 3W utilizzando Tapatalk
[Mi 3 General] ilnanny:
where? I have not seen it, you can put the link please?

thanks :good:
[Mi 3 General] Pi3rluigi:
Check post #29, my suggestion is to read a little before 'couse you can find some difficulty also flashing this zip file.

Inviato dal mio MI 3W utilizzando Tapatalk
[Mi 3 General] syed.shoaib:
What to do? I can't get adb to work in the cwm r11 recovery (mi4). :(
[Mi 3 General] TofikLupus:
You have to install adb drivers. This should work: https://www.dropbox.com/s/ogvaiu2vbutldy7/xiaomi_usb_driver.rar?dl=0

Open your device manager and install the driver manually.

Hope it helped, I had the same problem and was searching for it for a few hours before i found it.

Odesláno z mého MI 3W pomocí Tapatalk
[Mi 3 General] syed.shoaib:
Thanks a ton mate! Your hard work saved me a ton of time! Thank you for helping :)
[Mi 3 General] rishabh_95:
i just wanted to know that if i flash this zip for extended partition, then will it format my sd card or will it just wipe data n cache?
[Mi 3 General] 24likan:
It will not format your SD card. But both systems will be removed
[Mi 3 General] TofikLupus:
As said earlier, it will remove both systems, but cache, data and "SD card" (userdata) will remain untouched. The process of extending will firstly remove both system partitions and then it will create them again, each with different size, but it doesn't do anything with any other partitions so it's safe for your data.

Odesláno z mého MI 3W pomocí Tapatalk
[Mi 3 General] Arman_Koradia:
Hey man i tried to flash it using CWM but it says that the zip is not signed. I continued still but cannot install the zip. Can you guide what to do now ?? I am eagerly waiting to flash XenonHD on my Mi3
[Mi 3 General] 24likan:
Just flash the zip file in system 1.Does not matter if it says zip is not signed. You can disable signature verification and it will no longer say zip is not signed and blah blah.
[Mi 3 General] Arman_Koradia:
Dude i mentioned that I STILL CONTINUED but the zip was not installed. I don't know why you missed that line. Anyways thanx for the help. If there are any other suggestion or ways please let me know.
[Mi 3 General] 24likan:
What error do you get?

How do you know that the zip is not installed?

What happens after you flash the zip? Please elaborate then only someone can help you.
[Mi 3 General] Arman_Koradia:
It says Signature verification failed. Continue ??

YES

Then it says

Installing update...

Installation aborted.

That's all
[Mi 3 General] diongdyh:
Select System 2.

Wipe data, cache & dalvik.

Select System 1.

Wipe data, cache & dalvik.

Flash the zip.
[Mi 3 General] KiranP23:
Sir , i am facing issue installing [ROM][MI3/Mi4][CM-12.1][Android-5.1.1]CM-Cancro by Bitti09 in my extended Mi3 indian version

finding update package

opening update package

verifing update package

installing update

mount: failed to mount /dev/block//platform/msm_sdcc. 1/by-name/system at system: invalid argument

unmount of /system failed : no such volume

patching system image unconditionally

bikdiscard failedd invalid argument

error in /tmp/update.zip

Number Start End Size File system Name Flags
1 0.02MB 2.10MB 2.08MB sbl1
2 2.10MB 3.15MB 1.05MB rpm
3 3.15MB 4.19MB 1.05MB tz
4 4.19MB 5.24MB 1.05MB DDR
5 5.24MB 6.29MB 1.05MB ssd
6 6.29MB 7.34MB 1.05MB dbi
7 7.34MB 11.5MB 4.19MB aboot
8 11.5MB 16.8MB 5.24MB bk1
9 16.8MB 21.0MB 4.19MB misc
10 21.0MB 29.4MB 8.39MB logo
11 29.4MB 67.1MB 37.7MB bk2
12 67.1MB 68.7MB 1.57MB modemst1
13 68.7MB 70.3MB 1.57MB modemst2
14 70.3MB 70.3MB 0.00MB fsc
15 70.3MB 134MB 64.0MB bk3
16 134MB 136MB 1.57MB fsg
17 136MB 168MB 32.0MB bk4
18 168MB 201MB 33.6MB bk5
19 201MB 218MB 16.8MB boot
20 218MB 235MB 16.8MB boot1
21 235MB 252MB 16.8MB recovery
22 252MB 268MB 16.8MB ext4 persist
23 268MB 336MB 67.1MB fat16 modem
24 336MB 403MB 67.1MB fat16 modem1
25 403MB 1645MB 1242MB ext4 system
26 1645MB 1745MB 99.8MB ext4 system1
27 1745MB 2147MB 403MB ext4 cache
28 2147MB 15758MB 13610MB ext4 userdata

(parted)
C:\WINDOWS\system32>adb sideload "g:\Downloads\cm-12.1-20150709-UNOFFICIAL-cancro.zip"
sending: 'g:\Downloads\cm-12.1-20150709-UNOFFICIAL-cancro.zip' 100%

now i tried flashing stock rom with Mi Flash fastboot rom i am getting error unspecified error 0x800004005 failed size too large
[Mi 3 General] TofikLupus:
The procedure is the same as the extension, just instead of 1.2GB for system1 and a few MB for system2, you use about 670MB for both systems (403MB to 1074MB for system1 and 1074MB to 1745MB for system2), and that's it.

Sent from Xiaomi MI3W 64GB
[Mi 3 General] DetourToNirvana:
Content removed because it was reported as not working. Sorry.
[Mi 3 General] KSKHH:
That does not work. Do not try.

I have done it successfully, however it is very risky. Phone can be bricked. The main problem data partition will not remove so easily as it is in mount state and it will not unmount as well.

I have successfully extend my data partition, used it for few days and return back to stock to sell out my phone.

Believe avoid doing this if you do not have any standby phone.

---------- Post added at 07:46 AM ---------- Previous post was at 07:41 AM ----------
[Mi 3 General] KSKHH:
Flash attachment thru R7 CWM
[Mi 3 General] wasimraja_1982:
I get the same error as reported earlier.

It says Signature verification failed. Continue ??

YES

Then it says

Installing update...

Installation aborted.

I wiped both system1 and system2, tried flashing the zip in both systems but same issue. Any suggestions?
[Mi 3 General] TofikLupus:
Wiping won't help, just uncheck the "check zip signature verification" option and it will skip the verification and install correctly. I thought it's kinda obvious that it won't let install the file if the verification failed. I had no problems flashing it with the latest CWM 11. The phones are the same, the software is the same. Just people aren't. Think about where might be the actual issue :D Not to insult or anything.

Sent from Xiaomi MI3W 64GB
[Mi 3 General] wasimraja_1982:
I have tried disabling signature verification as well. That doesn't help. BTW, even if you had verification turned on and failed, it would still prompt whether you would like to continue.

Once I disable verification, I don't get the error saying "Footer wrong". Thats the only change I see.

I am using CWM v6.0.5.1(R11)
[Mi 3 General] TofikLupus:
Well i was using the v11 R1.. maybe there's some fix of this issue? Idk the changelog so I can't say

Sent from Xiaomi MI3W 64GB
[Mi 3 General] wasimraja_1982:
Found this post in XDA -> http://xdaforums.com/showpost.php?p=60828520&postcount=106

Downloaded the files from there. Flashed the 'Repartition_MI3W_1_2GB.zip' and it worked.

I tested the other file '	Repartition_MI3W_MI4W_1_2GB.zip ' after this and that worked as well.

Contents are exactly the same. Not sure why it didn't work earlier. Maybe third time download is the charm.

Anyway, it worked.
[Mi 3 General] TofikLupus:
Well then I'm sorry about what I said before, though, I can't believe it's downloaded incorrectly two times in a row. Have you tried the original file again? Try to generate an MD5 sum of the original one and the new one, just to tell if they're somehow different.

Sent from Xiaomi MI3W 64GB
[Mi 3 General] wasimraja_1982:
I don't have the original file as I replaced it everytime I downloaded again. The very first time it failed, I was able to open that file and verify contents as well, which was exactly the same as it is now.
[Mi 3 General] TofikLupus:
Yes, you'll always see the same files, but the MD5 will be different if some part of them is missing or is somehow incorrect. Anyway, glad it's working for you now.

Sent from Xiaomi MI3W 64GB
[Mi 3 General] wasimraja_1982:
I flashed Mokee on top after the re-partition and I am unable to install any app via playstore nor via apk. Has anyone faced similar problem and found a solution other than going back to stock partition sizes?
[Mi 3 General] Hadi al-Haiqal:
Maybe they have impliment anti piracy feature..
[Mi 3 General] Ashikraw:
Guys I ran the script, but it ended up in an error. Now i dont have partition 27 with cache. I tried mkpartfs by tryng to remove 28, but it doesnt work. Please help me out, here is a screenshot. can someone help me get my cache back?
[Mi 3 General] TofikLupus:
Try to make a new partition #27, name it cache and create it from 1745MB to 2147MB, filesystem is ext4. Hopefully it should work then.

ALSO:Fix the system2 partition, its filesystem is ext2 instead of ext4, use the guide on the first page for that.

Sent from Xiaomi MI3W 64GB
[Mi 3 General] Ashikraw:
I tried that , and successfully fixed the partition table, but then ROM installs kept failing and the partitions would revert back to ext2.

So i followed a stupid guide given here, and now I have ended up with a completely bricked screen with no fastboot or recovery partition. I was able to run up to the step of flashing via miflash through qloader, but it stopped at 25% and got stuck at waiting for reconnect. After that whenever i reconnect via USB, it doesnt even show the QHS_BULK , and just gets detected as USB input device.

I think this phone is pretty much done, I might remove the battery and try again( few have had success ).

P.S. I also found out why the partition kept failing, we have to set the parted units to Bytes and then fix the table at that accuracy.
[Mi 3 General] Amigo62:
Hi, I can not read whole thread, and I have one question, (for now), this method is tested only for CWM? And what about TWRP?
[Mi 3 General] paul c:
You SHOULD read at least the OP (several times, since it is not a standard process for Android phones, but everything is there) - and search the thread for keywords.

TWRP only works on System1, so you can't use it to change system2...

You need to use CWM to make the changes, though you can use TWRP once you have resized the partitions, since after resizing you are not using system2 anymore.
[Mi 3 General] nguyenquang1985:
Sorry for off topic, but is there any way to find out a custom rom is extend or original partition? Sometimes I would like to come back an old ROM, but checking each thread to answer that question is a nightmare
[Mi 3 General] TofikLupus:
You can install stock-partition ROMs into the extended partition, but you can't install extended-partition ROMs into the stock partition. Very simple. For example, you can install MIUI on both extended and stock partition, but you can't install CM12.1 by Bitti on stock partition because it takes more than 600+MB of space. Basically you can install any ROM on extended partition but you can't install every ROM on stock one. Hopefully the explanation haven't taken too much of your life :D

Sent from Xiaomi MI3W 64GB
[Mi 3 General] nguyenquang1985:
Thanks. I understand that you suggest me to extend my system partition. But I don't want to mess up with my system, since I know almost nothing about ADB, so I am afraid if something wrong happen when flashing extend .zip.

Sometimes dev makes their ROM available for both stock and extend partition (i.e: Biti's CM12.1 had a version that can install on stock. But after that he decided not to support stock partition anymore). But I cannot remember which version. Also I want to try other roms, but normally OP does not mention their rom is for extend or stock partition.

Is there anyway to find out that a ROM take how much MB after install?
[Mi 3 General] TofikLupus:
There's nothing to mess up if you use the correct flash zip, also you can do it manually, which i don't recommend for you if you really don't know what are you doing. Here are the two zips,

https://www.dropbox.com/s/otkltqroyu1upqc/Repartition_MI3W_1_2GB.zip?dl=0 - This one is for extension

https://www.dropbox.com/s/8yuuum7ro13eo3m/Repartition_Stock-Partition_MI3W.zip?dl=0 - This one is to revert back to the stock layout

These are working, i've uploaded them directly from my phone, i've used them before with no problem. The only requirement is that you have to have CWM installed, i was using CWM 11 r1, here's a link:

https://www.dropbox.com/s/iww18kf9mmg5t4z/CWM_recovery_r11_u1_cancro.zip?dl=0

And yes, it is possible to find out how much space a ROM is taking. After installing it, download an application called DiskInfo from Play Store and and take a look at either system or system1 partition, depending on which one is currently in use(or just the first system if extended partition)

Sent from Xiaomi MI3W 64GB
[Mi 3 General] nguyenquang1985:
And yes, it is possible to find out how much space a ROM is taking. After installing it, download an application called DiskInfo from Play Store and and take a look at either system or system1 partition, depending on which one is currently in use(or just the first system if extended partition)

==> But I want to know how much space ROM will take before installing it. Is there any solution?
[Mi 3 General] TofikLupus:
I think the ROM zips are uncompressed, so the size would be the same as the zip itself(i might be wrong). But then, after the first boot, it "optimizes apps" and i guess it generates some additional data, it probably precompiles the apps so they can be started quickly(the new ART runtime). Depending on the apps, the size varies. Unless you wanna bury deep into the topic and do some researches, calculations, and idk what else, the easiest method is to just install the ROM and check your free space.

Sent from Xiaomi MI3W 64GB
[Mi 3 General] xdxds:
i follow your instruction step by step and nothing got wrong, and i see

25 403MB 1645MB 1242MB ext4 system

26 1645MB 1745MB 99.8MB ext4 system1

after execute "print" ,but still result in error 7 when flash big rom such as eos/bisspop.

and then i flash an unoffical cm rom and see system was still about 630MB total space by root explorer.

where got wrong?
[Mi 3 General] yorikkk:
Hi guys,

I have a 64GB Mi3W, and i used the extended partition script...

Not sure if i have more space available right now...

From settings it gives me 55.36 GB available for the user... just to compare, how much u guys have (How much available storage it gives you from Settigs > Storage)....

thanks in advance ... have a nice one
[Mi 3 General] chetank:
I tried this script long ago(On 2nd May 2015), and it was worked for me at that time. :)
[Mi 3 General] sajalsh25:
I HAVE DONE EVERYTHING RIGHT!

But STILL I AM not Being Able To Change My Both Systems From ext2 To ext4 ??

Can Somebody Help Me I Have Attached My Print" Details From CMD!

TAKE A LOOK AND TELL ME HOW TO CHANGE SYSTEM ext2 TO ext4 ??

HELP! :eek:

EDIT ::::

I FELL LIKE KIND OF STUPID!

I JUST DID'nt Write Quit After Creating The New Partition So It Was just Goind IN THE PARTED SECTION!

There Was No Sign (#)"!

Anyway After I Wrote Quit And Wrote the COdes to change to ext4 It Worked Like A Charm! :)
[Mi 3 General] cbhhargava:
Extended but still memory insufficient

I extended my partition using above steps and it worked like charm. I've installed OmniRom and Banks GAPPS. While I'm downloading apps after reaching 640MB it says insufficient storage space :confused: I checked in Diskinfo app and it shows 1.2 GB but still play store doesn't install apps :crying: Solution ASAP ! Thanks in advance !!
[Mi 3 General] chirantantab:
Got Success but using Different zip

No Sys 2 this time

Check the screenshort
[Mi 3 General] szubert51:
Can I create two 1,2 GB system partitions by shrinking userdata partition? Is it require to modify recovery?
[Mi 3 General] jlazkano:
Hello all,

I want to have CM recovery to get OTA updates on the device.

Is it possible to delete system 2 partition and increase the data partition with CM recovery?

Anyone with CM recovery?

Thanks and regards.

---------- Post added at 10:05 PM ---------- Previous post was at 09:51 PM ----------

Hello all,

I want to have CM recovery to get OTA updates on the device.

Is it possible to delete system 2 partition and increase the data partition with CM recovery?

Anyone with CM recovery?

Thanks and regards.
[Mi 3 General] TheAndroidNinja:
Would be great if there was a video showing all these steps for us who are noobs like me
[Mi 3 General] Anvyy:
Can I try this method in redmi 1s for increasing system partition in cost of decreasing partition for data. If not then, Can you please tell the way to do it for redmi 1s
[Mi 3 General] vish0815:
Resize userdata partition

Hi, going by your tutorial, I was able to resize both systems and cache partition, however I wasn't able to resize userdata. Whenever I try to resize, command replies userdata is mounted. Any solution?
[Mi 3 General] novl:
I tried repartition with the tutorial and got the following (strange?) behavior.

So far: script ran completly through, was also marked as successful. When i check the partition list i get the following:

1|shell@cancro:/ $ cat /proc/partitions
cat /proc/partitions
major minor #blocks name

179 0 15388672 mmcblk0
179 1 2031 mmcblk0p1
179 2 1024 mmcblk0p2
179 3 1024 mmcblk0p3
179 4 1024 mmcblk0p4
179 5 1024 mmcblk0p5
179 6 1024 mmcblk0p6
179 7 4096 mmcblk0p7
179 8 5120 mmcblk0p8
179 9 4096 mmcblk0p9
179 10 8192 mmcblk0p10
179 11 36864 mmcblk0p11
179 12 1536 mmcblk0p12
179 13 1536 mmcblk0p13
179 14 1 mmcblk0p14
179 15 62463 mmcblk0p15
179 16 1536 mmcblk0p16
179 17 31232 mmcblk0p17
179 18 32768 mmcblk0p18
179 19 16384 mmcblk0p19
179 20 16384 mmcblk0p20
179 21 16384 mmcblk0p21
179 22 16384 mmcblk0p22
179 23 65536 mmcblk0p23
179 24 65536 mmcblk0p24
179 25 1306003 mmcblk0p25
179 26 4717 mmcblk0p26
179 27 393216 mmcblk0p27
179 28 13291503 mmcblk0p28
179 32 4096 mmcblk0rpmb

partition 25, 1,2 GB - so far ok.

But when i check the internal mounts i have the following:

127|shell@cancro:/ $ df
df
Filesystem Size Used Free Blksize
/dev 910.2M 56.0K 910.2M 4096
/sys/fs/cgroup 910.2M 0.0K 910.2M 4096
/sys/fs/cgroup/memory: Permission denied
/mnt/asec 910.2M 0.0K 910.2M 4096
/mnt/obb 910.2M 0.0K 910.2M 4096
/system 629.9M 617.0M 13.0M 4096
/cache 371.9M 10.1M 361.8M 1024
/data 12.5G 9.5G 3.0G 4096
/persist 15.7M 4.1M 11.6M 4096
/firmware 64.0M 52.4M 11.5M 16384
/mnt/shell/emulated 12.5G 9.5G 3.0G 4096
/mnt/shell/emulated/0 12.5G 9.5G 3.0G 4096

any ideas?