FORUMS
Remove All Ads from XDA

[Q&A] [Guide] CWM ReParted

n/a posts
Thanks Meter: 0
 
By QA Bot, Guest on 12th November 2014, 01:28 PM
Post Reply Email Thread
Q&A for [Guide] CWM ReParted

Some developers prefer that questions remain separate from their main development thread to help keep things organized. Placing your question within this thread will increase its chances of being answered by a member of the community or by the developer.

Before posting, please use the forum search and read through the discussion thread for [Guide] CWM ReParted. If you can't find an answer, post it here, being sure to give as much information as possible (firmware version, steps to reproduce, logcat if available) so that you can get help.

Thanks for understanding and for helping to keep XDA neat and tidy!
12th November 2014, 01:28 PM |#2  
Junior Member
Thanks Meter: 0
 
More
Quote:
Originally Posted by ChronoMonochrome

CWM ReParted is a method of reparition internal SDcard via recovery using flashable zip. It was developed a few months ago, but the message about this method "lost" in a closed thread http://forum.xda-developers.com/show...&postcount=129 so I decided to create separate thread.

It's only for custom (non-stock) based ROMs

Installation method

1) backup your /data partition and /sdcard
2) flash zip archive. It may take a while, be patient.
3) format /data, /cache and /sdcard
4) restore your data
5) swap storages via Novathor settings app

After repartition you'll have:
2,87 Gb on data
~320 Mb on cache (I didn't change cache partition size because I use F2FS and it needs to use more memory in /cache. Anyway, you can edit repartition script as you want)
~51 kb on UMS and HIDDEN
This script will not change your /system partition.
Attachment 2959869

First i would like to thank you for your contribution for our Ace devices. I would like to use your kernel with full f2fs, but the system partition is too small(approx. 600MB) to install GApps that i would like. Is there any way to enlarge system partition? Thank you
12th November 2014, 01:51 PM |#3  
ChronoMonochrome's Avatar
Senior Member
Flag Stavropol
Thanks Meter: 4,639
 
Donate to Me
More
Quote:
Originally Posted by fada3

First i would like to thank you for your contribution for our Ace devices. I would like to use your kernel with full f2fs, but the system partition is too small(approx. 600MB) to install GApps that i would like. Is there any way to enlarge system partition? Thank you

Temporarily there is no repartition script, that changes system partition. You can edit repartition.sh manually(remove system partition, change start/end positions of needed partitions and then create /system. don't forget then to name it "SYSTEM" - without quotes. There's no difference in which order you create partitions, just make sure that number of system is 3, data - 5, cache - 4, etc... ).
Make sure you have backup. To restore partition scheme flash stock with pit file.
P.s. if unsure, read this topic since repartition may be potentially dangerous.
http://forum.xda-developers.com/show....php?t=2596521
14th November 2014, 04:27 PM |#4  
Member
Thanks Meter: 6
 
More
Increase UMS partition size
Hi! Can you tell me how do I edit the script to leave a little more storage on UMS (around 50-100MB) ? Thx for your reply!
14th November 2014, 05:51 PM |#5  
Member
Thanks Meter: 6
 
More
Quote:
Originally Posted by Matteo90

Hi! Can you tell me how do I edit the script to leave a little more storage on UMS (around 50-100MB) ? Thx for your reply!

Forget it, I pretty much figured it out after downloading a proper script editor, instead of messing around in notepad, lol.
By the way, these are the lines I edited in reparted.sh:

parted $MMC unit kb mkpart primary 3578036 3448836
parted $MMC name $CACHEFS CACHEFS

parted $MMC unit kb mkpart primary 747635 3578036
parted $MMC name $DATAFS DATAFS

parted $MMC unit kb mkpart primary 3448836 3948886
parted $MMC name $UMS UMS

Is it going to work as expected, or there's still something that needs editing?
14th November 2014, 07:32 PM |#6  
Senior Member
Thanks Meter: 920
 
More
Quote:
Originally Posted by Matteo90

Is it going to work as expected, or there's still something that needs editing?

Code:
KB						
641.729		SYSTEM		System		mkpart primary 105906 747635
2.971.202	DATAFS		Data		mkpart primary 747635 3718837
130.000		CACHEFS		Cache		mkpart primary 3718837 3848837
100		HIDDEN		Hidden		mkpart primary 3848837 3848937
100.000		UMS		Int. SDCard	mkpart primary 3848937 3948937
Made with my selfmade partition calculator - Call if you need other values...

Chrono's script is still full of (for you) unneeded parts (for automatic backup/recocvery) - mostly hashed and not active

This is a bit cleaned... Anyway.... It's @ChronoMonochrome work - So its his respekt...

EDIT - UPDATED - Now its correct...

Use an CWM Kernel... TWRP has no PARTED integrated

Code:
#!/sbin/sh

#-------------------------------------------------------------------#
#                 CWM ReParted for Codina                           #  
#-------------------------------------------------------------------#

MMC=/dev/block/mmcblk0
CACHEFS=4
UMS=8
Fota=11
HIDDEN=9
SYSTEM=3
DATAFS=5
DEV_UMS=`mount | grep 'sdcard0' | cut -f 1 -d ' ' | grep 'dev'`
p=p

# unmount partitions
umount $DEV_UMS
umount $MMC$p$UMS
umount $MMC$p$Fota
umount $MMC$p$HIDDEN
umount $MMC$p$DATAFS
umount $MMC$p$SYSTEM
umount -l $MMC$p$CACHEFS

# remove partitions
parted $MMC rm $UMS
parted $MMC rm $Fota
parted $MMC rm $HIDDEN
parted $MMC rm $CACHEFS
parted $MMC rm $DATAFS
parted $MMC rm $SYSTEM

# rebuild SYSTEM
parted $MMC unit kb mkpart primary 105906 747635
# rebuild CACHEFS
parted $MMC unit kb mkpart primary 3718837 3848837
# rebuild DATAFS
parted $MMC unit kb mkpart primary 747635 3718837
# rebuild UMS
parted $MMC unit kb mkpart primary 3848937 3948937
# rebuild HIDDEN
parted $MMC unit kb mkpartfs primary ext2 3848837 3848937

# name partitions
parted $MMC name $SYSTEM SYSTEM
parted $MMC name $CACHEFS CACHEFS
parted $MMC name $DATAFS DATAFS
parted $MMC name $UMS UMS
parted $MMC name $HIDDEN HIDDEN
#
Please note that mkpart-part is in the order as the name-part.
The nameing right after mkpart results that DATAFS was not named correctly here... Don't know why...
Therefore I put the naming at the end...

And note that I've already SYSTEM in the script - This can be deleted if you do not need it....
The Following User Says Thank You to fluffi444 For This Useful Post: [ View ] Gift fluffi444 Ad-Free
14th November 2014, 08:21 PM |#7  
Member
Thanks Meter: 6
 
More
Thank you, both you and Chrono!
So all I have to do, is paste your script into reparted.sh, and everything will work like a charm.
One last question, though... Chrono wrote in his original post, that he left cache 320MB because F2FS needs it. If I plan on upgrading to F2FS in the future, is it better for me to leave it at 320 or the 130MB you calculated should be enough?
14th November 2014, 10:01 PM |#8  
Senior Member
Thanks Meter: 920
 
More
Quote:
Originally Posted by Matteo90

Thank you, both you and Chrono!
So all I have to do, is paste your script into reparted.sh, and everything will work like a charm.
One last question, though... Chrono wrote in his original post, that he left cache 320MB because F2FS needs it. If I plan on upgrading to F2FS in the future, is it better for me to leave it at 320 or the 130MB you calculated should be enough?

As you like... I'm also an full F2FS and have the minimum recommended for F2FS whioch is 130MB... This is setted in the script...
Don't know if 320 will imporve it or not - Never tested...

If you want to have the values with 320 on Cache - Here you are

Code:
641.729		SYSTEM		System		mkpart primary 105906 747635		
2.781.202	DATAFS		Data		mkpart primary 747635 3528837		
320.000		CACHEFS		Cache		mkpart primary 3528837 3848837		
100		HIDDEN		Hidden		mkpart primary 3848837 3848937		
100.000		UMS		Int. SDCard	mkpart primary 3848937 3948937
And dont forget to format partitions DATA CACHE (SYSTEM if changed) with the file system you want. Also format Int. SD Card with vfat/fat32.
Keep in mind that if you format SYSTEM with F2FS you would need an ROM.zip with adjusted mounting values (Chrono wrote it in this Kernel thread)

AND: Make this all with a Kernel with CWM (not TWRP) - No PARTED in TWRP...
15th November 2014, 12:52 AM |#9  
Member
Thanks Meter: 6
 
More
Quote:
Originally Posted by fluffi444

And dont forget to format partitions DATA CACHE (SYSTEM if changed) with the file system you want. Also format Int. SD Card with vfat/fat32.
Keep in mind that if you format SYSTEM with F2FS you would need an ROM.zip with adjusted mounting values (Chrono wrote it in this Kernel thread)

AND: Make this all with a Kernel with CWM (not TWRP) - No PARTED in TWRP...

Thanks, but F2FS is still in the future. I'm currently using ace2nutzer kernel, and I'm happy with it, won't convert to F2FS until his kernel supports it. But this adjusted mounting volumes has to do something with this repartitioning, or it's just the same thing Chrono wrote about in the F2FS installation tutorial in the third post of his kernel thread?
Also another noob question In your script, you put HIDDEN partition between CACHE and UMS, while in the original Chrono script HIDDEN is the last partition. Does it matter where this partition is?
15th November 2014, 01:28 AM |#10  
Senior Member
Thanks Meter: 920
 
More
Quote:
Originally Posted by Matteo90

Thanks, but F2FS is still in the future. I'm currently using ace2nutzer kernel, and I'm happy with it, won't convert to F2FS until his kernel supports it. But this adjusted mounting volumes has to do something with this repartitioning, or it's just the same thing Chrono wrote about in the F2FS installation tutorial in the third post of his kernel thread?
Also another noob question In your script, you put HIDDEN partition between CACHE and UMS, while in the original Chrono script HIDDEN is the last partition. Does it matter where this partition is?

The ones were HIDDEN partition is between CACHE and UMS is only for values of each partition (c&p out of my Excel calculation file) - This is not the script...

The script beginns with #!/sbin/sh

And no - This is only for changing partition sizes...
15th November 2014, 02:47 PM |#11  
Member
Thanks Meter: 6
 
More
Quote:
Originally Posted by fluffi444

The ones were HIDDEN partition is between CACHE and UMS is only for values of each partition (c&p out of my Excel calculation file) - This is not the script...

The script beginns with #!/sbin/sh

And no - This is only for changing partition sizes...

Okay, I did it! Now I have 2.55GB on data, thanks to you guys!
Although I got an erron in CWM, saying "E:unknown volume for path [/sd-ext]", but after googling it, I read that it should not cause any problems.
Post Reply Subscribe to Thread

Tags
auto-qa

Guest Quick Reply (no urls or BBcode)
Message:
Previous Thread Next Thread
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes