(solved) How restore /cust partition?

bly2

Member
Jan 16, 2012
18
2
0
Hello everybody,

I have my X5 flash a Custom Rom from this forum .
Now I will return tostock rom .
I seem however the Custom Rom flash partition /cust to have deleted.
Have now many attempts ( flash via fastboot , various other Rome etc. ) but TWRP always says : unable to mount / cust ( invalid argument )
would I'm grateful if someone could help me .

Please excuse my bad english.

Best wishes

Marc
 
Last edited:

bly2

Member
Jan 16, 2012
18
2
0
Hello,

my phone is a KIW - L21 .

I have tried the following :

- Phone unrootet , original Recovery , on the UpdateApp tried a local update to make - > Failed

- Phone unrootet , original recoverey - > phone off vol + vol- power simultaneously - > update failed

- Phone rooted , TWRP installed , a update.zip created using huwaeiappextractor - > flash process aborts with instructions that the / cust partition can not be established .

- Tried /cust.img to flash via fastboot - > same as above

greeting
 

clsA

Senior Member
Aug 28, 2010
9,799
3,449
253
Central Florida
Hello,

my phone is a KIW - L21 .

I have tried the following :

- Phone unrootet , original Recovery , on the UpdateApp tried a local update to make - > Failed

- Phone unrootet , original recoverey - > phone off vol + vol- power simultaneously - > update failed

- Phone rooted , TWRP installed , a update.zip created using huwaeiappextractor - > flash process aborts with instructions that the / cust partition can not be established .

- Tried /cust.img to flash via fastboot - > same as above

greeting
Flash this with TWRP >> http://loadbalancing.modaco.com/download.php?file=customromtemplate-5x-plk21-b130-r3.zip
 

clsA

Senior Member
Aug 28, 2010
9,799
3,449
253
Central Florida
Thank you for the link. The installation is, however, again with the error "fail to mount / cust invalid commando"
what version of TWRP are you using ? Use this one
did you reboot recovery and try again ?
did you try to go to TWRP / Mount and choose /cust and try again ?

if all these fail your going to need to take it to a service center theirs nothing else to do
 

flibblesan

Senior Member
Feb 12, 2008
472
198
63
Nottingham
I had an issue with /cust partition and managed to fix it last night.

This was a complicated process but I'll try and explain as best as I can.

You need to obtain the original stock CUST.img file. You can download the full system images from https://mega.nz/#!Kg9UiKiD!cCh9UK0Oi-P1UNk-e1RBk_jlUEHGm0MGYa_HSlQ-3c4

You also need simg2img from https://github.com/KinglyWayne/simg2img_win

copy CUST.img into the simg2img directory, edit convert.bat to change the command to: simg2img.exe CUST.img cust.ext4.img

Or open a command prompt and navigate to the folder, running simg2img.exe CUST.img cust.ext4.img

Once run you'll have an ext4 image. The original image is a sparse image - useless for direct writing.

Boot your device into TWRP. Mount internal storage then copy the new cust.ext4.img file to your device.

You need ADB on your computer for the next step. Open adb shell:

now do the following:

dd if=/sdcard/cust.ext4.img of=/dev/block/mmcblk0p23

assuming you copied the cust image to your internal storage

Once the dd process has completed, test this worked by mounting the cust partition inside TWRP. If it mounts then the dd worked correctly and your cust is restored.
 

linux33it

Senior Member
Nov 29, 2009
104
20
0
a question:
cust.img is 205.403 KB (kiw-21L-B130)
the conversion in cust.ext4.img arrive at 524.288 KB
mmcblk0p23 (cust partition) in the device is just 507.904 KB
is normal?
 
Last edited:

readion

Member
Jul 16, 2016
15
2
0
Question

Hi, i have a LeEco Le Max 2 (Le X820). I have the same problem.
Where i can find original stock CUST.img file for this model?
I wanted more, but i can not find.
Thanks.