yashsingh1/xdaforums huggingface dataset:
[Sprint LG Optimus G] Whiplashh:
This was being discussed in the unofficial CM11 thread, So I thought I would give it a home.

Here is the thread for; Development, Discussion, Information, and Also A guide on how to Multiboot different ROMs on the LG optimus G.

I in no way made this MOD,
all the rights and credit go to the original creators.
I Just wanted to give an area and help other people learn how to do this.
I (Or the Creators of this mod) are NOT responsible for anything bad happening after flashing this MOD;
Bricks, Soft Bricks, Explosions, Implosions, Girlfriend leaving you after trying to boot too many roms.
YOU choose what YOU do to your 700$ Device. Now Lets get to the Guide. :)

Before you do ANYTHING, Be sure to read this over many, many times. If you do NOT know what you are doing, do NOT try this. Enjoy. :good:

This is how I multi boot, using a backup.

1st: To multiboot, please be rooted.

2nd: Please Flash the Custom TWRP Multiboot recovery. (Link Below)

2½ (Optional, but still preferred.): If you plan on multibooting a 4.2+ ROM, I would make an "0" (Zero) folder and moving all precious things there. (So that your backup will go there and you can also see your download folder.)

3rd: Make A backup of whatever ROM you are on in that recovery, and as you will see if you reboot, the backup in be in the "0" directory. (I prefer stock as my ROM to backup.)

4th: Flash the Multiboot.zip (Link Below)

5th: Now Wipe as normal like if you installing another ROM. and Set whatever ROM you want as your primary ROM.

6th: In Recovery, go to advanced> add ROM

7th: click next then choose backup as 2nd ROM.

8th: Let it do its thing, and guess what?

Enjoy Multi booting.

This is how to Multiboot with a .zip. (results may vary)

1st: To multiboot, please be rooted.

2nd: Please Flash the Custom TWRP Multiboot recovery. (Link Below)

2½ (Optional, but still preferred.): If you plan on multibooting a 4.2+ ROM, I would make an "0" (Zero) folder and moving all precious things there. (So that your backup will go there and you can also see your download folder.)

3rd: Make A backup of whatever ROM you are on in that recovery, and as you will see if you reboot, the backup in be in the "0" directory. (I prefer stock as my ROM to backup.)

4th: Flash the Multiboot.zip (Link Below)

5th: Make sure you have primary ROM. You don't need to edit this if you want to keep it

To change primary ROM before adding new ones, wipe as normal and setup/backup etc.

6th: In Recovery, go to advanced> add ROM

7th: click next then choose .zip file of ROM as 2nd ROM.

8th: Let it do its thing, and guess what?

Enjoy Multi booting.

Helpful Quotes:

Download Links to MultiBoot Recovery & .Zip: https://drive.google.com/folderview?id=0B3Vq3sppfNgnVjUzMy1YVXZxYmM&usp=sharing

*ALL* credit goes to Gearslam and anyone who helped.
[Sprint LG Optimus G] Whiplashh:
Mine. Muhahahahaahahahaha :good::good::fingers-crossed::laugh::D
[Sprint LG Optimus G] dopy25:
Awesome.

I use this method and am rocking the dual boot with [MENTION=510301]gearslam[/MENTION] 's mods. Thanks again for all the help.

EDIT: 4-29-2014

[MENTION=510301]gearslam[/MENTION] Can you edit the script to allow installation of geespr roms? I tried to install an official rom and it said during installation that the process is for (insert multiple "GEE" type roms) and listed gee_spr but said the one I was trying to install was geespr. I think the underscore might make a difference. And since I have no idea how to update it to allow other roms, would you please?
[Sprint LG Optimus G] PartimusPrime:
Awesome! Thanks for this guide!
[Sprint LG Optimus G] zomgalama:
Thanks for this, and thank you too gearslam! Rocking both cm11 and stocktimus ce. Love it, especially now that the stock Rom is using the 0 folder to load files so there aren't 2 separate areas to search through ( had to use twrps file manager to move some things up so I could view photos I took on stock lol)
[Sprint LG Optimus G] treezy26:
So... Does multibooting mean I can switch between roms and its just how I left it each time I switch? For example if I download an app and switch its still in the rom I downloaded the app for? Like I don't need to create a backup every time ?

idk how I got here...
[Sprint LG Optimus G] Whiplashh:
From what I have personally tested yes. But you will need a backup of a run to use as 2nd. Like I said I use cm11 as primary and stock as backup. Very nice. :)
[Sprint LG Optimus G] dopy25:
Yes,

I use about 5 different ROMS and they all have different apps, and app data for that matter unless you have the app synced to something like facebook. Also, it depends on if you choose restore from my google account and back up this phone to my google account during setup.

Also, a backup to create a secondary rom is not necessary, you can choose to flash a zip to add a rom. I do it every time I want to try a new rom instead of flashing over my current. BUT YOU CAN CHOOSE TO RESTORE A BACKUP AS SECONDARY.

This by far is the most awesome feature I have ever came across. You can even have different kernels for each, just make sure during install that don't share kernel is checked.
[Sprint LG Optimus G] Whiplashh:
You got it to work without a backup? Can you elaborate how? I couldn't get it to. Whenever I tried to flash normal zip ROM, it gave me errors.
[Sprint LG Optimus G] dopy25:
All I do is go to TWRP, Advanced, MultiRom, Add Rom, Make sure it says Android rom and not .mrom, check do not share (I don't know if it's necessary but I prefer not to share the kernel because I am greedy, also I have gproj and GEE roms) zip file then select your zip from storage.

Also, gearslam updated the files again, that might have something to do with it. I noticed a few errors while installing so I sent him a PM. The new files are on the google drive that's linked in the op.

His response was

Try using the ones he said. I was able to flash them in the order they are supposed to be OVER the old ones without losing anything, there is an option to inject multi rom after install, I selected that and everything works great. I can flash pretty much any rom as a secondary. I haven't messed around with much swapping because there hasn't really been a need.

I have Pac gee, Pac LS970 nightly, Beanstalk, Mokee, Lego, and stock. They were all flashed by adding a rom as a zip. No problems with any that I can see so far. I have a problem with Mokee and the keyboard but that might be unrelated.
[Sprint LG Optimus G] Whiplashh:
Okay. Thank you man :)
[Sprint LG Optimus G] dopy25:
Any time. Let me know how it goes if you do flash those other files.

If you try it out and it works for you maybe you could add it to the OP, that the ones to flash are the geehrc4g because anyone looking at them might not know that right off hand.
[Sprint LG Optimus G] treezy26:
Quick question... When flashing a new rom to try, how does one go about doing that?

idk how I got here...
[Sprint LG Optimus G] dopy25:
If you are on the ls970 sprint Optimus make sure to use the geehrc4G and not the geespr versions in the google drive. I know it might not make much sense but they work and they were edited by gearslam to flash pretty much any rom for the ls970 or gee.

Go to twrp, advanced, multiboot, add rom, then follow the prompts. I prefer to use the do not share kernel option. After that you can choose to install a rom from zip. Then the next boot you can choose which one to boot into.

If you want to add stuff, IE; change kernel or flash another zip to that rom (GAPPS) just go to advanced, multirom, list roms, then select the rom you want and you can choose a normal option such as flash zip, wipe data, wipe dalvik, wipe cache. It's all there once you select list roms.
[Sprint LG Optimus G] spleef:
Trying to get this working but running into a few problems when adding a rom tells me can't find my data partition... It does complete and shows it to be added but once I reboot and select it... It has error box pops up says kernel doesn't have kexec I've tried many different ways having stock as primary on internal have PAC on primary internal tried adding as a zip tried adding as back up all ends the same with me only being about to boot into the primary internal ROM...
[Sprint LG Optimus G] Whiplashh:
I had the same problem with the error saying no Kexec. Have you tried making a new backup and then adding as 2nd rom? That is now mine worked.
[Sprint LG Optimus G] dopy25:
Any luck!? I have PAC gee as primary but I forget the kernel at the moment. I'm almost sure it's matr1x. Also make sure to use the geehrc4g version. It works perfect for me. And mine always says it can't find data partition. I think it's because it uses a folder named multirom in the sd0 partition. Also when your in a file manager you can't open that folder. I haven't tried with root permission but I don't want to mess anything up.
[Sprint LG Optimus G] spleef:
Not yet just tried again by making a back up of PAC and flashing a stock ROM but the stock ROM wouldn't boot kept kernel crashing immediately after the lg pop up so I'm going to download another stock ROM which one are you guys using? Says the same thing with trying with liquid though so I'm not sure what's going on tried to dual boot liquid and PAC had same exact results even tried making those two share the kernel as well as not buy of course didn't try that with the stock rom I kept it as is
[Sprint LG Optimus G] dopy25:
EDIT: I added some pics. 2 show the about this device. One is the boot menu the other is the list ROMs function under recovery.

The screenshots are the about info for my primary ROM.

Edit 2: Wow that was a weird double post. I use the stock zvc (from zip on the forum) but only as a secondary. PAC gee version from 4-4 is my primary.

[MENTION=1880287]spleef[/MENTION] ! I just thought of something, when I tried to use solid kernel on liquid smooth ls970 when it was a secondary ROM, my phone would also only boot the primary! I had to use f93 cpq to boot it and any other ROM other than primary. Maybe some kernels are not compatible if they override the primary. Try like I have with gee version of pac as primary and the kernel I'm using (might even be built in kernel) I'm hoping you know more than I do about it based on the about device info.
[Sprint LG Optimus G] spleef:
Nope still couldn't get it going...no matter how i try it get the kexec error doesn't matter which i use a primary stock or custom and same goes for secondary doesn't matter which one kexec error when trying to choose...I'm using geehrc4g version is very confusing
[Sprint LG Optimus G] dopy25:
Here is exactly what I did,

1) Wipe everything except internal storage.

2) Flash PAC gee version from 4-4.

3) Then I flashed the modified TWRP 2.7.0.0

4) Reboot to recovery,

5) Flashed the multirom zip,

6) Reboot to recovery,

7) Select advanced, multirom, add rom,

8) Make sure android (rom type), don't share (kernel) and internal memory are selected and press next.

9) Select "zip file" and find your rom zip that you want as a secondary and swipe to confirm.

10) Press back until you see "list roms" and select it.

11) Choose the second rom you just installed,

12) Select "flash zip" and find your gapps package, swipe to confirm.

13) Press back until you see your rom again (or "find list" roms again)

14) Choose wipe cache, and wipe dalvik, swipe to confirm each,

15) Reboot to system and try any of your roms when the boot menu comes up.

Have you checked out faust93's thread on this for the international version? The only reason I came across this was because you linked his thread for kernels in your rom threads, I really hope you can get it to work.

http://xdaforums.com/showthread.php?t=2528556

I am pretty sure I used the built in kernel now that I think about it, but if that fails try the f93 aosp kernel for your primary, you would flash it normal, so after flashing pac and before doing anything multiboot related try to flash that kernel. In that thread it says that it has the kexec hardboot enabled so it should work unless it only works for the international version but it says gee..
[Sprint LG Optimus G] spleef:
From reading this i realize maybe my problem was not going in and telling it to wipe in the list rom part...i did..

Wiped all but storage

Flashed pac and I've flashed stock

Was already on the recovery

First attempt at it i did flash the multi zip, but every time since then i just ticked the option to inject multi into it

Then I flashed gapps..kernel..also choosing to inject...maybe that's another place i went wrong i didn't add those in the list rom portion i flashed immediately after ...now granted when i used stock there were no additional flashes after the rom.....then i rebooted. ..made sure the primary booted. .then i went back to recovery and tried to add rom , I've tried adding stock and adding a custom rom as secondary...from back up and from zip...though i never did go back and tick any wiping options...after adding i would reboot the option shows up but selecting anything but internal gave me a kexec error regardless If i had stock or had a custom rom set to it.....i got rained out today so I'm going to give this another shot and this time going to do it exactly as you wrote adding the wipes and starting over fresh completely...much thanks for the help really want to get this working for me i think it is an amazing feature that all phones should have

So... After many attempts happy to say am multi booting now.... It took a fresh build of liquid gee with the ak kernel as the primary and now I've got PAC and optimus de on deck... Much much thanks for all the help and the mod
[Sprint LG Optimus G] dopy25:
YAY!!! I have been checking on this hoping you were able to get it working. I am so glad it worked for you. I absolutely love this feature! I love being able to reboot into stock and checking for a PRL update, or getting a GPS lock. It really is amazing to have!
[Sprint LG Optimus G] gearslam:
I just wanted to point out for those that don't know. OTG is working good in this recovery. I've been using a 16Gig flash drive formated to exfat. All you need is an OTG-Y cable. You can easily backup/restore and flash ROM's from USB drive. Another alternative to sideloading if you accidently wipe everything out.
[Sprint LG Optimus G] Whiplashh:
Thank you. I am gonna add this to op
[Sprint LG Optimus G] treezy26:
Idk what happened but I tried to swap roms and its saying something about kexec kernel? Help!!!

Idk how I got here...
[Sprint LG Optimus G] dopy25:
Swap em back. Sounds like the kernel you tried to make primary doesn't have kxec hard boot enabled. You should be fine installing a ROM that has a compatible kernel. If I remember right I'm sure matr1x has that feature because that's what I have on my primary. PAC man gee with matr1x kernel.
[Sprint LG Optimus G] treezy26:
Actually of says kexec hard boot? And when I try to swap them back it says no room available

Idk how I got here...

Edit: I'm trying it now and so far it looks good. Hopefully. Thanks for the response. How do I switch my primary rom back to stock?
[Sprint LG Optimus G] dopy25:
You can't put a stock or any gproj ROM for that matter as primary. None of their kernels have the kexec-hardboot. They can only be secondary or solo, meaning you can have it as the only rom.
[Sprint LG Optimus G] Mr nerd:
So what roms work on for this? can anyone explain?...im not sure how to get this working.

I can get the internals to work no problem and boot ..but any secondary rom just gives me the kexec error.. any help?

The roms im trying to do this with are

Official cm11

Optimus De V5.0
[Sprint LG Optimus G] treezy26:
Since using this has anyone on sprint get the message "insert sim card to text" or something of that nature?

idk how I got here...
[Sprint LG Optimus G] Mr nerd:
i have "sim card is missing" where "sprint" usually is.
[Sprint LG Optimus G] treezy26:
So I'm not the only one... I thought I was losing it lol

idk how I got here...
[Sprint LG Optimus G] Mr nerd:
so i have an issue ...my data just went out with two different roms.. but the second and third still have data how can i fix this... i was using pacrom but my data went out so i flashed a BeanStalk rom and now that too lost data? is anyone else having this issue?
[Sprint LG Optimus G] bizzzle:
Mind Blown

[MENTION=510301]gearslam[/MENTION] [MENTION=1588500]dopy25[/MENTION] [MENTION=4713133]Whiplashh[/MENTION] You guys are my heroes! Of all the mods I have done to my phone, this one is by far the most useful. I have tried tons of ROMs, 3 different recoveries, and lots of apps that I really appreciated, and enjoyed, but never have I ever felt so compelled to give something back. Please let me know who is responsible for creating this masterpiece, as I would like to donate.

One thing maybe you could help me shed some light on. I was running Carbon LS970 as my primary when I installed TWRP multiboot. Everything was successful, and I added Stocktimus as a secondary, but when I tried to boot Stocktimus, I got the Kexec error.

I did my research, and found out that the primary ROM must have a Kexec Hard Boot enabled Kernel in order to multi-boot, and no LS970 or Stock roms have that.

Cool, No prob, I started this project to find out how Carbon Gee would run anyways. I added Carbon Gee as another secondary, then tried to swap that to primary, and move carbon LS970 to secondary. I used the Swap primary into secondary, and secondary into primary option, and after a while, it failed. it seemed that now I had 3 secondaries, and no primary. I could successfully boot into the new Carbon Gee rom, but it would not save any of the system settings, or prompt me to multi-boot.

Since I appeared to no longer have a primary, I fresh installed Carbon Gee again as primary, and everything is fixed and working perfectly. I deleted Carbon Gee from secondary, and I'm now successfully booting carbon gee, carbon LS970 and stocktimus.

Any reason why I shoudn't be able to do the ROM swap I was attempting?

Thanks for all the hard work guys!!!
[Sprint LG Optimus G] dopy25:
Let me start with the "who". I feel ungrateful stating this but I don't know who the creator was but I can tell you that it was created for a device other than ours. I found the information in the international threads under kernels. I got excited when I saw multi boot and started asking questions. Someone said that if I used it my phone would register as E975 and not LS970. So I decided against it at the time. Then I asked something else (can't remember right now) and [MENTION=510301]gearslam[/MENTION] came in with the goods. He made it useable on the LS970 for flashing pretty much any rom. I have even flashed some e975 and e970 roms lol.

We were talking about it in the unofficial CM11 thread so [MENTION=4713133]Whiplashh[/MENTION] decided to make a thread for just this.

I am just a curious dude and like messing with stuff and I try a lot of ROMs. I did not work on any part of this I only tried to do a bunch with it and familiarized myself with it. I only asked gearslam about editing his script to include other gee roms and he made it work just like the newest TWRP for ls970.

Now for the what

Your primary ROM's kernel communicates with the multi rom addition of the recovery. If I had to guess, I would say you were unable to move anything with the swap method due to your primary ROM's kernel not being kexec hardboot enabled. Which in theory would cause the whole thing not to work. You already have it working but here's an idea for next time: create a backup of your primary, then wipe that data and everything else just like you normally would for a new ROM. Flash the GEE rom to primary, then restore your backup as secondary. That would have worked because some ahve reported making a ROM primary and creating a backup every time they wanted to make a secondary. That shouldn't be the case if you use the geehrc4g versions of the files.

If you're that interested, here is the "original" thread (for the E975). I say "original" with quotes is because it was ported to the E975 from the nexus 7.

http://xdaforums.com/showthread.php?t=2528556

Reading over that just now it actually gives a run down of where it came from and who created it.

Have fun!
[Sprint LG Optimus G] bizzzle:
Thanks for the info man. Will read up on that other thread.
[Sprint LG Optimus G] treezy26:
can any one give me the low down on how to make backups and what not? wanted to dirty flash but wasnt sure how to? made a backup and when i looked for it in multirom, i couldnt find it. but it was in twrp backups???
[Sprint LG Optimus G] dopy25:
Yeah. Since it's TWRP that's where the backups go. If you want to restore just chose restore as secondary. You'll have to "list ROMs" and delete the original or the dirty flash or you'll have 2 of the same ROM even though one will be the original and the other will be the one you dirty flash. Just go to advanced, multi ROM. And chose restore. Then restore as secondary.

Is that what you mean? I usually just install a new one and make a backup of the one I've been using, and restore apps and some data with nandroid manager. Pro is the way to go. I love that app.
[Sprint LG Optimus G] dopy25:
This is worth noting, since I have noticed a lot of posts lately in other threads about screen off charging with an unlocked bootloader.

Well as far as I can tell, it's not necessarily the locked bootloader that is stopping it, but the kernel you are using. Since if you notice, stock ROMs and/or stock based kernels do not allow screen off charging, but AOSP ROMs do. I believe that is due to the kernel.

So here is a way to use a stock Rom and still have screen off charging. USE THIS METHOD, the multi boot.

1) Install a GEE ROM as primary.

2) restore a stock ROM as a secondary or install a backup as "add ROM" in the advanced,

Profit) You will be able to leave the phone off and let it charge, and still be able to use stock. If you want to boot into stock every time, you can change the auto boot settings for multibooting.

NOTE) If you are thinking that you have to install a lot of space to use this method, think again. Install SlimKat and remove as much as you can that will still let the ROM boot. Slim is around 100mb and you don't need to install any GApps for this to work.

It is also worth noting that as of now I have not been able to get ARTmod or the GEE3 ROM to boot as a secondary under any circumstance. it might be because of the kernel, I don't know. But I tried installing as a secondary, as well as restoring a working backup as secondary. I even tried swapping them to no avail. If anyone gets one of those ROMs working as a secondary I will love you forever.
[Sprint LG Optimus G] DQEight:
Does artmod work as primary? I really miss multiboot as i switched to philz for artmod.

Sent from my Sprint LG Optimus G on Page Plus.
[Sprint LG Optimus G] dopy25:
It will install as primary but you lose the ability to boot a secondary ROM until you install a primary with a compatible kernel. That's because there are no stock kernels that have the kexec hardboot enabled patch working at the moment. Jollaman's has the patches but it's not fully working. I think he's still working on it though.
[Sprint LG Optimus G] DQEight:
Are you willing to try a little experiment? backup your artmod kernel, and flash a kexec hardboot enabled kernel. Im curious if even if the primary rom wont boot if a secondary will boot if the kernel is there.
[Sprint LG Optimus G] dopy25:
I've tried that before. I think the problem is that it resets drivers, and in the process communicates with files in the primary rom (^^think). I know what you are thinking, it is easier to flash 10mb than to flash and restore gigs in order to get the stock running as secondary and switch between kernels for Art or GEE3 as a primary. It did not work for me.

Do you use multiboot? It doesn't mess anything up. In fact it is safer in my opinion for trying other roms. If you use only or mostly AOSP roms then you are fine. The only ones I have not been able to use multi with are the Art and Gee3. Everything else, no problem. And it also stores efs in the secondary roms, so if you ever accidentally erase efs from primary then you still have it in the secondary :).