yashsingh1/xdaforums huggingface dataset:
[Galaxy S II Android Development] Lister Of Smeg:
Hi [MENTION=5811506]gsstudios[/MENTION],

Thanks for getting back to me, I've found out where i was going wrong with Lanchons re-pit tool... I was trying to run it from EXTERNAL sd card... And it was failing, however it says it when running, that it copies the script to the /tmp folder.

So I ran it from there, and all is working fine... Its partitioning lovely now!!! Although some what slowly... i assume thats the dry runs it does first, just to make sure its safe...

But all going well, hopefully i can install some roms on this phone and not get bootloops on it... As didnt get bootloops on the other S2 and N7000....

Shall keep you posted tomorrow morning... :)

Thanks again for your reply/info.... :D

Cheers, Lister
[Galaxy S II Android Development] rivasol:
Which DorimanX kernel for S2 i9100?

"Update: DorimanX kernel supports isorec recoveries in the newest builds. Flashing a isorec recovery will remove this formatting limit and will be usable in all partition sizes."

Hello,

there are a lot of DorimanX kernel. Which is the right one for S2 i9100, CM12.1 installed?

Best regards,

rivasol
[Galaxy S II Android Development] Saber:
Hi,

The latest DorimanX kernel, 12.0 b011, will work with CM12.1. Note that before flashing, make sure to make a backup using CWM or TWRP recovery just in-case you want to go back to the default kernel.

gsstudios
[Galaxy S II Android Development] Lucas_Skyline:
Guys, need a big help here:

After doing the process, my EFS folder got somehow corrupted and I was getting no IMEI in CM13. Then, I got back to stock, repartioning again, but I got that fake IMEI (004999010640000).

Everything I did:

1. Started in stock.

2. Root and flashed CM12, Ressurection Remix ROM. Made a CWM backup.

3. Flashed CM13. Got no way to install Google Apps, so I decided to increase partition size.

4. Got inside this thread and start to increase partition size. In step 11, it was not possible to format in TWRP, so I mounted as USB and formated in Windows.

5. After all, installed CM13 again and got no IMEI.

6. Got the original .pit file and flashed Stock ROM in Odin.

7. Now I have that fake IMEI and can not call anyone or use 3g data

Can anyone help me? I have no backup on EFS folder itself, just the CWM backup.

Thank you guys so much in advance.
[Galaxy S II Android Development] AbdoRefky:
looks like the formatting part broke my phone

SM-360H
[Galaxy S II Android Development] Saber:
This guide is only for the i9100.

Saber.
[Galaxy S II Android Development] AbdoRefky:
[MENTION=5811506]Saber[/MENTION]

so any idea how to fix my phone ? :(

i keep getting failed to mount data and storage

thanks
[Galaxy S II Android Development] Saber:
If you've used the pit files for your phone, i'm afraid I can not help you. It would be best to find the pit file specific for your device to restore your phone to working state.

Saber.
[Galaxy S II Android Development] AbdoRefky:
well, it's not your pit file who destroyed it . because it tried it many times and id didn't work .

so at the end i said why i don't format my internal memory and i tried apply again .

the format was stuck for an hour. and of course i removed the battery .

i have access to odin and TWRP . but i can't do any thing because this error

failed to mount */data* (invalid argument )

i just need to know who path should i take

[MENTION=5811506]Saber[/MENTION] Thanks
[Galaxy S II Android Development] maseoud:
hi

I am on mm rom and want to get back to jb rom 4.1.2

I read this topic

please help

what should i do

from where should start?

thanks
[Galaxy S II Android Development] Saber:
You need to use the stock pit file attached in the OP. Then you can follow the guide as provided to format all of your partitions.

Once all formatted, you can flash JB rom like normal.

Saber.
[Galaxy S II Android Development] TriboDoP:
Hi [MENTION=5811506]Saber[/MENTION]

Does this concern only stock jb but also custom jb?

I know cm 11 works when repartitioned but do any custom jb also?

Just beeing curious.

Thanks
[Galaxy S II Android Development] Saber:
This only applies to stock JB.

Custom JB like NeatROM can run 1GB system partition and increased data partition size without problems. Just ensure that the preload partition is the default size.

Saber.
[Galaxy S II Android Development] davewpy:
My bad - I have not been following the thread.

Please see the attached. Courtesy of PIT Magic and OP.
[Galaxy S II Android Development] oneleft.ak:
I few bumps

I had some issues when I followed the directions in the OP exactly. I was coming from NeatROM 4.8 and Philz CWM Touch Recovery 5.0. I tried all the kernels posted at the link provided in the OP and was only able to get my device to boot into recovery with the CM 13 recovery which would not allow me to access or mount any of my partitions.

I had success using the .PIT files provided by the OP and the GeniSys kernel found here - http://xdaforums.com/showpost.php?p=60824013&postcount=3.

Please consider adding a link to this Kernel in the OP​
[Galaxy S II Android Development] Saber:
That's strange. Flashing gustavo kernel should give you CWM recovery which should allow you to mount partitions.

One of the kernels provided should give a working recovery, so I don't know why only genisys kernel is working for you.

Saber.
[Galaxy S II Android Development] oneleft.ak:
Agreed. However, given that I am unsure what the cause is... my situation may not be unique. Therefore I suggested the working solution for me be added to the OP.

Also, I wish to say thank you for your helpful guide. You clearly have spent and continue to spend many hours dedicated to helping others in this community.:good:
[Galaxy S II Android Development] Saber:
The OP was updated

It's been a while since I've updated the OP so here are the changes:

Fixed spelling of the instructions heading - lol

The pre-made kernel tar file link will now direct users to the correct post and not the thread

Please also note that my kernel tar conversion guide was also updated to contain Genisys kernel (comes with TWRP recovery) which may be useful for some users.

Saber ;)

Edit: First link to kernel thread was also updated.
[Galaxy S II Android Development] Tmobilefan906:
Works with att galaxy s2? U1att?
[Galaxy S II Android Development] Saber:
This guide is only for the 16GB i9100 international variant.

You can try looking at the repit tool provided by lanchon and look at the documentation to see if your device is supported.

Saber.
[Galaxy S II Android Development] Tmobilefan906:
OK. Did that. But got a status 1 error after flashing zip.
[Galaxy S II Android Development] TriboDoP:
Hi

You might find the answer in thread [TOOL] Lanchon REPIT: A data sparing repartitioning tool ....

Page 9 posts #82 - #83
[Galaxy S II Android Development] Tmobilefan906:
OK. I got it partitioned. What if I want to go go back to stock, do I lose that partition pit?
[Galaxy S II Android Development] TriboDoP:
Yes because in this case you have to flash stock partition or stockrom will not work.
[Galaxy S II Android Development] Tmobilefan906:
OK. I will flash JB stock rom and root. I have a sigh i777. What u suggest I do to partition and flash lp and mm roms?
[Galaxy S II Android Development] Namoi:
AFAIK you don't need to revert to stock partition BUT you need to set the preload partition to stock which is 512MB.

Without this partition used since Jelly Bean to accommodate Samsung bloatware you won't be able to flash a stock rom...

BTW it is also needed for CM 13 as it seems the updater script need it but maybe not 512. Just a few MB (8 as i read) and a formating should do it.

Check last posts from Isorec twrp as a modded recovery was provided for this.
[Galaxy S II Android Development] Tmobilefan906:
Do u have a i900 or i777 device? Just curious

---------- Post added at 09:32 PM ---------- Previous post was at 09:31 PM ----------

I can change that in twrp
[Galaxy S II Android Development] Namoi:
Mine is I9100 european version from 2011.

Your second request i didn't understood, but if you use lanchon script it is easy to increase data while keeping preload. You just have to rename the script for it as it takes its parameters from the provided name.
[Galaxy S II Android Development] vakkah:
not at all.

i've used the lanchon tool to increase the default data partition from 2GB to 6GB, then flash stock JB from for my galaxy s2 gt-i9100.

make sure that you keep the preload partition to at least 100MB or keep it at the default value of 512 MB.

just rename the lanchon tool for the parameters that you need, especially the data and preload.
[Galaxy S II Android Development] Tmobilefan906:
I read the thread but I'm confused. Could u give me an example? I would so appreciate it. I have modded tons of devices, but this one is confusing. Lol. Thanks.
[Galaxy S II Android Development] vakkah:
please see the link below and follow the guide..

http://xdaforums.com/android/software-hacking/tool-lanchon-repit-data-sparing-t3358036
[Galaxy S II Android Development] Tmobilefan906:
Tyvm!

---------- Post added at 03:24 AM ---------- Previous post was at 03:17 AM ----------

One problem. I'm gonna stick to stock JB. What twrp version can I flash without breaking the stock rom?
[Galaxy S II Android Development] ssanjy:
If you wish to use TWRP in stock ROM then one is apolo kernel (which has cwm version as well) but you'll get old version of TWRP as there kernel development has stopped. If you would like to use the latest TWRP then flash dorimanx for stock ROM by GreekDragon or chhapil who have merged the IsoRec patch in Dorimanx JB kernel..
[Galaxy S II Android Development] Tmobilefan906:
I could flash an old recovery, that's fine. I can always flash the IsoRec within recovery anyways. I just wanted a recovery that could be used with a stock rooted ROM.

---------- Post added at 02:24 PM ---------- Previous post was at 02:21 PM ----------

Could u pass me a link? Google is messing up on my device and my PC is running updates. Thanks.
[Galaxy S II Android Development] ssanjy:
Apolo thread

http://xdaforums.com/galaxy-s2/development-derivatives/kernel-t2291756

Dorimanx thread by GreekDragon

http://xdaforums.com/galaxy-s2/development-derivatives/kernel-dorimanx-4-1-x-t3418834
[Galaxy S II Android Development] Acid0057:
You're welcome!

Sent from my GT-I9100 flowing on SwiftKey in Tapatalk
[Galaxy S II Android Development] Hnk1:
Worked like a charm. Great guide

Used 1GB+3GB
[Galaxy S II Android Development] FrizzerACE:
I've followed the tutorial and changed partition with 1-4gb pit. In Odin I put the gustavo's kernel (I'm with apolo and KK by the way) and the pit file and run it. Everything ok. When I entered in TRW recovery I thought I was with Gustavo' Kernel but no, the phone maintained the apolo kernel. It was necessary to mount usb and format the partition in windows. So far so good.

My doubts are:

As I have understood the problem with apolo was only about formating. As that is resolved I can continue wit apolo kernel. correct?

The partition size will continue forever, if I "tomorrow" decide to flash other Rom or Kernel the partition is the same ?

Thanks
[Galaxy S II Android Development] rubentkato77:
Which PIT file did you recommend for Lollipop 5.1 if I want to install full gapps and SU ?

Because someone 's comment said, that cause boot loops because of system partition

Thanx, best regards
[Galaxy S II Android Development] GreekDragon:
Do you want FULL GaPPS? Then download the attachment of this thread named Pit_FILES And use any PIT do you like started by I91001GB_XXXX

There is Root Preinstalled.
[Galaxy S II Android Development] Emrets61:
If I flash I91001GB_4GB version, how much memory will my internal storage exactly have? Will it be true 11 GB or is there something different in our phones?

Edit: It's something like 9 GB. I don't know why it is like that.
[Galaxy S II Android Development] Saber:
This could be due to file system limitations as you can't truly use 100% of the stated storage. Remember there are many other partitions as well on android which may take up more internal storage, leaving less room for us to use.
[Galaxy S II Android Development] Saber:
What do you mean? I recommend the 1GB_3GB or the 1GB_4GB pit. It should be plenty for all of your apps without decreasing too much of your personal internal storage.
[Galaxy S II Android Development] rubentkato77:
I flashed 1GB_4GB thanx guys:good:
[Galaxy S II Android Development] Saber:
Correct. You can still keep your partition sizes one you flash back apolo. It should be fine if you flash a rom or kernel in TWRP, but it's been a while since i've flashed anything with TWRP on modified partitons, so I can't exactly remember if the system partition size will change when formatting with TWRP.
[Galaxy S II Android Development] Emrets61:
I'm having speed issues on internal storage. Is there a fix for it? I can't copy files in normal speed. It's very very very slow. :confused:

Edit: Allocation size unit is set to 4096 byte. Copying speed is around 800 kb/s.
[Galaxy S II Android Development] kamal.rana:
It means now u have 1GB for system rom which will be used for ur installed custom rom and gapps package with other system zip files u flash through recovery like supersu....4GB is for the apps and data.....remaining 9GB as ur internal storage (usb storage )
[Galaxy S II Android Development] GreekDragon:
Nice Dude.

Probably 4GB Internal Storage.Dunno for sure.
[Galaxy S II Android Development] carlusmagnus:
Hi,

I compared your pit file in archive zip and found some difference between file 1GB_3GB and 3GB in three memory section Factory, Data and UMS.

First. If i want 3GB, I should put 3*1024*1024 while in Datafs is 6*1024*1024.

Second. Why in 3GB pit amounts Factoryfs is 1GB while in 1GB_3GB is 2GB?

When I moved to ROM LP every time I flash gapps bigger than 100mb recovery give me an error. This dipend on datafs amounts?

I changed on my device PIT with 2GB before Rom LP. I used a pit file with preload memory to 46mb
[Galaxy S II Android Development] Grigster:
ONLY FOR CUSTOM ROMS (Not Stock Samsung TouchWiz ROM)!!!

Just in case someone wants to have the Preload partition got rid of, I have modified the PIT file accordingly to my preferences.

It has:

1GB - System

3GB - Data

10.5GB - Internal SDCard

20MB - Preload

Hope it is useful for you and if you need any other PITs like this, just give me a PM and when I have spare time I will create them. :)
[Galaxy S II Android Development] wawa9292:
hey dude.. may i ask for a help?? :)

i need pit with this requirement:

1 Gb System

10 Gb Data

preload 1Gb (if possible) i'm using for 2nd ROM..

2.5 Gb Internal SD (storage)

thanks.. I'm sorry if i'm asking too much.. :(
[Galaxy S II Android Development] carlusmagnus:
Hi,

It's possible increase with pit file System memory for custom rom or is unhelpful?
[Galaxy S II Android Development] GreekDragon:
Yes, look the OP #1 Post.
[Galaxy S II Android Development] Skyline:
Tested??
[Galaxy S II Android Development] GreekDragon:
Bootlooped. Already trying to wipe and flash rom but all the time bootloop.
[Galaxy S II Android Development] Tmobilefan906:
so, i flash apolo then the greekdragon? can i do that from the rom im on now, which is the RR ROM?
[Galaxy S II Android Development] Tmobilefan906:
So I flash into recovery, flash kernel then reboot recovery and flash ROM? Thanks
[Galaxy S II Android Development] ssanjy:
You wrote that you wanted to use TWRP for stock ROM... So the kernels are for stock only... You can use either one.... Apolo had old TWRP whereas dorimanx supports IsoRec and youth can have there latest TWRP recovery

Edit: I think we are getting off topic... Please pm me if you still have issues
[Galaxy S II Android Development] Tmobilefan906:
Tyvm!
[Galaxy S II Android Development] Tmobilefan906:
How do I do that...keeping preload partition?
[Galaxy S II Android Development] vakkah:
seriously, have you read the thread and understand how to use the tool?

it's quite straight forward and explicit in that the file name includes the parameters

(fat, ext4, wipe etc.) for the various partitions (system, data, internal storage and preload).

the values you use for the various partitions all determine the layout you need for your device.

additionally, all of the numerical values are in Gigabytes.
[Galaxy S II Android Development] Tmobilefan906:
Um. Yea. I understand that! I was asking what number should I put in the /system data!
[Galaxy S II Android Development] vakkah:
you can't go wrong with anywhere between 1.5-2.0
[Galaxy S II Android Development] Tmobilefan906:
I flashed the zip as is..I now have 1.0 GB. Do I change the number to a 2 GB instead? Maybe that could work?
[Galaxy S II Android Development] Namoi:
1GB for system is ok except maybe if you want to flash the full gapps package. So your good to go on.
[Galaxy S II Android Development] Tmobilefan906:
I would like to do the max if possible.
[Galaxy S II Android Development] vakkah:
full gApps package is better to flash system=2.0
[Galaxy S II Android Development] Namoi:
All of the apps in the biggest package are available through the playstore. I don't see any real advantage to install them as system apps, but if it is what you want indeed 2GB is the way to go.
[Galaxy S II Android Development] Tmobilefan906:
So I change the 1 into a 2 then reflash the zip?
[Galaxy S II Android Development] Namoi:
Yes, replace the 1 by a 2 so if it is 1.0GB then it will be 2.0GB (the .0GB is unchanged you see)

So just replace 1 by 2 and don't change anything else.
[Galaxy S II Android Development] Tmobilefan906:
I went to flash isorec with cwm 6.0.4, not sticking...should I flash apolo or dorminanx kernel, then reboot recovery then flash the zip in isorec twrp 2.8.7? Thanks.
[Galaxy S II Android Development] Namoi:
You need a compatible kernel, so i don't know which one you have but Dorimanx will do. So try it. Then flash iso rec twrp then reboot recovery, flash lanchon repit. It will probably fail at first so reflash it from /tmp were it copied itself and you should be good.
[Galaxy S II Android Development] AnotherFreakinNoob:
Okay so I've got the sgh-959g/i777. I used a pit file from the link about the phone on the i777 forum and was successful in flashing the pit. However I missed something and now the sdcard is unmounted the phone now shows internal storage 0mb. Phone functions fully even flashed a new ROM and GAPPS. Yet I can't download or save photos (use camera etc.) due to no SDcard inserted. What would be the best way to resolve this? I went into TWRP (using TWRP 2.8.7.0) looked under wipe>advanced and saw now option to mount emmc/sdcard (I can go under to change file system after clickong internal storage and it list.....

Partition options for: Internal Storage

Mount Point: /emmc

Current file sytem: auto

Present:Yes Removable:No

Everything else shows 0MB

From there I can change the file system to EXT2, EXT3, EXT4, F2FS, FAT).

Also tried hooking up to computer while in recovery and going under Mount. There was no SD card option and it won't let me click on Internal Storage. Please help. I'm so close to Marshmallow I can taste it, lol.
[Galaxy S II Android Development] Tmobilefan906:
I have the cwm kit Kat compatible one. The one used for Resurrection remix

---------- Post added at 09:35 PM ---------- Previous post was at 08:58 PM ----------

I flashed dorm kernel, then chose read only on 287 twrp. Flashed the newly named zip & it was successful. Thanks!
[Galaxy S II Android Development] Namoi:
Glad you worked it out.

---------- Post added at 10:00 PM ---------- Previous post was at 09:55 PM ----------

Did you tried to wipe internal storage as maybe is it isn't formated.

---------- Post added at 10:03 PM ---------- Previous post was at 10:00 PM ----------

If it doesn't work you should try the Lanchon repit method.
[Galaxy S II Android Development] AnotherFreakinNoob:
I did and kept getting emmc wouldn't format. I changed the internal storage file system from auto to ext4. From there it formatted and now works. Got my internal storage back. Woohoo!
[Galaxy S II Android Development] Namoi:
Great to hear you solved it ?
[Galaxy S II Android Development] Mgonsan:
Pit file, original S2 i9100 8gb

Hi,

I have problems with partition sd, is it isn't formated. I have a S2 with 8gb internal memory and a don´t find a compatible pit file. Anybody has this pit file?

Thanks.
[Galaxy S II Android Development] Namoi:
Try Lanchon repit method : you can choose whatever repartion way you want.

Thread is here or check for github.
[Galaxy S II Android Development] Saber:
OP has been updated

Here are today's changes:

It is now explicitly stated that the guide is only for the 16GB variant of the S2

A long and overdue change but much important nonetheless.

Saber ;)
[Galaxy S II Android Development] ems3132:
If i use 1GB System-4GB Data-512MB-Preload pit file,in future i can flash stock rom from here without repartition again?

Thanks.
[Galaxy S II Android Development] TriboDoP:
I think 4 GB data and 512MB preload can be kept.

But i am not sure about 1GB System.

If nobody can confirm this definitely i would flash stock pitfile together with stock-rom.

(Do not forget to tick on repartition in odin).

Anyway i always do this just to be on the safe side.
[Galaxy S II Android Development] Saber:
First thing in the OP:

You need to go back to complete stock partition layout to go back to stock ROM. Custom ROMs based on stock ROM will not have this issue.

Saber.
[Galaxy S II Android Development] Tilagoon:
Hi,

I am currently on AOSP 4.4.4 with TWRP 2.7.1.0 on my I9100.

I would like to go to RR 7.1.1 or CM14.1 so I understand that I have to repartition my S2.

After a lot of reading (may be not enough) this is what I plan to do:

- Flash image TWRP 3.0.2.1 with adb

- Connect in download mode and with Odin flash Kernel-lanchon-Isorec with pit file ( 1 GB System/3 GB )

- Reboot in recovery do the format and flash RR

- Reboot system

-Reboot recovery , flash Gapps

- Reboot system

Am I going to do something wrong ??? or is there a better way of doing this upgrade ??:confused:
[Galaxy S II Android Development] TriboDoP:
Another way without PC:

- Install unofficial cm11- 20161222 by zjq985062714

together with recovery-the.gangster-isorec-twrp 3.0.2-1.zip.

Now you have isorec kernel and latest twrp.

- in twrp 3 repit by using lanchons repit tool which is a zip-file to be flashed in Recovery (choose 1gb for System and 4 or 3 GB for Data.

- now you are able to install any mm or Nougat Rom and gapps

Your way should also Work but using lanchons Tool will avoid troubles in formatting.
[Galaxy S II Android Development] Tilagoon:
Hi ,

Thanks for the idea, sounds good but I have one concern: I am running TWRP 2.7.1.0 and I have seen some where that to install last TWRP from an older version of TWRP you need to be with 2.8.x.x !

So do you think my old TWRP will be able to do the job correctly ? :confused:
[Galaxy S II Android Development] TriboDoP:
Yes, sure i will work if you follow exactly the steps i described.

Btw nearly any Recovery would install IsoRec twrp but it will only show Up when being on IsoRec kernel.

Thats why you should install latest cm11 which has IsoRec kernel and the twrp recovery zip.
[Galaxy S II Android Development] Tilagoon:
Hi,

Have followed the plan step by step and everything went OK.

Repartition OK and fast (with wipe of system/data/preload) and could install Resurrection Remix 7.1.1 :good:

Many thanks for your help :)
[Galaxy S II Android Development] TriboDoP:
Hi!

Glad to see you being already on this wonderful ROM!

Cheers
[Galaxy S II Android Development] psdfan:
I'm new here. Having this kind of issue - https://xdaforums.com/galaxy-s2/help/samsung-galaxy-sii-stuck-bootloop-t3548945#post71001978

My phone's model is SII GT-I9100. Where can I get the .pit file?

I just did successfully re-partition just like the way you told but after that when reboot with (home button + power button + volume up) it's stuck on boot screen not going into recovery mood. What to do now ?