[Q]Flashing Munjeni's Kernel - Sony Xperia P, U, Sola, Go

Hey guys, the title might sound misleading that I need tutorial how to flash, but it's not on this case.
So few days ago I installed CWM (I have Unlocked Bootloader Xperia U, already flashed Speedy Droid mod) and I had stock kernel, now I think I would like to get a rom, but a quite a few roms say that I need Munjeni's kernel.
So now I was reading Munjeni's forum post. And I got across this line:
Warning!!! This boot+CWM reguire unlocked bootloader + stock chargemon!!! Do not use modified chargemon or chargemon that is SCRIPT!!! Double check if your /system/bin/chargemon is script or binary file (you can do it by android terminal emulator by command "cat /system/bin/chargemon" if you see clean text lines than its script, if you see unknown characters than you are sure that your chargemon is binary file!!! If chargemon is script do not use our boot+CWM!!! I am not responsible for any damages or data losts if you use custom chargemon!!! If chargemon is binary you can install our boot+CWM but you need to check if system partition in "mount and storage" is mountable and remountable before you going to erase system partition or to perform backups and restores !!! Allso check ps.log in your sdcard after booting recovery, just this CWM is in test stage for Xperia U and you need to be sure that "/system/bin..." processess is not in ps.log !!! Untill we are surre that these processess is not in ps.log and your chargemon is stock than our CWM will be safe!!!
Click to expand...
Click to collapse
So AFAIK I have Atis112 CWM installed. It has installed a chargemon. So from the post it seems I cannot install Munjeni's Kernel + CWM + Memory Tweak? I know that I can install memory tweak via CWM, but I cannot install Kernel because I don't have the stock chargemon?
Help much appreciated

Related

xRecovery v1.0.0 Installers [FOR SE 2.1 FW based ROMS]

kindly do not use this for X10-GB based ROMS
zdzihu i hope u dont mind me posting this...
ALL CREDITS GO TO ZDZIHU & FREEXPERIA TEAM FOR THEIR GREAT WORK IN KEEPING OUR DEVICES ALIVE AND ROCKING!!!!
I saw that many users were running into problems (bootlooped/stuck at SE text logo) by installing the latest xRecovery v1.0.0 the wrong way/wrong update.zip on different custom roms...
so here i will share some modified installers which i created for my own use but i guess it will help u guys too till ur favorite ROM dev implements it in his/her ROM...
[*] AS ZDZIHU IS CURRENTLY INVESTIGATING THE ISSUES IN xRecovery v1.0.0 and removed links in his thread... I advise you to kindly wait for some time before trying out this new Recovery [*]
the files provided here are for older recoveries (xrec v0.0.x & FreeXperia rec) only...
all the files are update.zip (amend syntax) flashable via recovery
[IMP] installing these files MAY BREAK any special features provided by ur ROM dev (which were incorporated into the chargemon file)
[ Backup Current Recovery ]
just read this post:
http://forum.xda-developers.com/showthread.php?p=14444631#post14444631
[ Installer for xRecovery v1.0.0 ]
2.1 ROMs
Please use the xRecovery-1.0.0-update.zip provided by zdzihu in the xRecovery thread
2.2 ROMs (who dont require custom kernel by default. e.g.: FreeX10)
Please use the FreeX10-beta4-hotfix2.zip provided by zdzihu in the FreeX10 thread
2.3 ROMs (who require custom kernel by default. e.g.: CM7)
THIS CAN BE USED ON CM7/other roms which use custom kernel as default booting option... I have myself tested it & currently using it on CM7.0.3 J021 K011..
xRecovery-1.0.0-rbt_kexec.zip
2.1/2.2/2.3 ROMs
This is for those ROMs who dont require custom kernel by default but have the option to select custom kernel on next bootup.... basically the ROMs which use FreeXperia Recovery but donot boot custom kernel by default... or users who are using freexperia recovery to test custom kernels can also use this file...
xRecovery-1.0.0-rbt_test_kexec.zip
[ Restore older Recovery ]
i am currently having a little trouble with edify syntax + update-binary combination... till then u guys can check the backup current recovery post [RECOMMENDED]
OR
[testing]
just connect the phone (when its booted into the android OS) to PC and use latest FlashTool to install xRecovery (it will actually install FreeXperia Recovery)..
P.S.: once u flash this version of xRecovery (v1.0.0) u will no longer be able to flash Amend syntax update.zips (most of the update.zips available right now including some ROM install update.zips) till the time the devs switch to Edify syntax for their work...
did you check the possibility of creating a backup of your chargemon and xrecovery.
and having a zip which can restore the chargemon and old xrecovery.
anantshri said:
did you check the possibility of creating a backup of your chargemon and xrecovery.
and having a zip which can restore the chargemon and old xrecovery.
Click to expand...
Click to collapse
i had created these file a few days back...
btw creating such backup/restore file is easy (atleast in Amend syntax)...
the problem is with Edify syntax... i am still not able to get consistent results...
anyways will create a BACKUP_chargemon update.zip (amend syntax) asap...
EDIT:
backup current recovery files ready... checking them now...
Have a version who require custom kernel by default in 2.2?
lzyllp said:
Have a version who require custom kernel by default in 2.2?
Click to expand...
Click to collapse
download the 2.3 version which requires custom kernel as default... and check the file system/bin/chargemon with 2.2 rom (which requires custom kernel as default) /system/bin/chargemon file... as far as i know the main loading code should be the same...
if u still have doubts just post ur 2.2 rom (which requires custom kernel as default) /system/bin/chargemon content here... so i can tell u immediately...
Backup current chargemon/recovery
Backup current chargemon/recovery
hey guys as was suggested by anantshri i have made a backup chargemon/recovery update.zip...
just flash this file (via recovery) before u flash any files form post #1:
xRec_v1.0.0_BACKUP_current_rec.zip
Few things to keep in mind:
this script will only backup the following two files:
/system/bin/chargemon
/system/bin/xrecovery.tar (this is the recovery file used by xRecovery v0.0.x)
the backups will be stored as:
/system/bin/chargemon.xr.ori
/system/bin/xrecovery.tar.xr.ori
if ur current recovery is not in /system/bin/xrecovery.tar dont worry as the xRecovery v1.0.0 installers provided in post #1 will anyways not remove those files
currently i am working on a restore script but it might take a bit longer
till then u can manually restore your older recovery by doing the following:
boot into OS
start root explorer (or u can do the same via adb shell)
remount /system as rw
navigate to /system/bin/ folder
locate the files:
chargemon.xr.ori
xrecovery.tar.xr.ori (if this file is not there dont worry, u were using freexperia recovery so that is untouched)
once u have verified that the above files are present (meaning that backup of files was properly done) ONLY THEN locate and delete/remove the following files:
chargemon
xrecovery.tar
and finally rename:
chargemon.xr.ori to chargemon
xrecovery.tar.xr.ori to xrecovery.tar
if by chance there is a failure during flashing/something goes wrong in recovery please check the log file created by this backupscript:
/sdcard/xrecovery_v1.0.0_installer_log.txt
P.S.: for those who want to learn/know wht is goin on while flashing the update.zip in this post just check the take_backup file in the update.zip provided
Hi Doom,
must I install first the Rom (J's CM7) or your file an then the Rom?
THX
Xs3n said:
Hi Doom,
must I install first the Rom (J's CM7) or your file an then the Rom?
THX
Click to expand...
Click to collapse
yup...
first rom then these files...
cause if u try the other way round (i.e. first this recovery and then the rom) then the rom installation will abort cause amend scripts are not supported...
I have a question I have 2.1 stock SE firmware and I want to install k12 kernel. Which of there recoveries should I download ?
marios199546 said:
I have a question I have 2.1 stock SE firmware and I want to install k12 kernel. Which of there recoveries should I download ?
Click to expand...
Click to collapse
i dont think any of the kernel packages available are xRecovery v1.0.0 compatible...
so no need to install xRecovery v1.0.0
use flashtool to install recovery...
i installed xrecovery 1.0.0 before flashing CM7...& now i cannot flash CM7 via the new xrecovery.So now how do i go back to older(0.0.3) xrecovery?
i m not able to install it the easy way...tht means vi .apk.& now i m not getting that old thread of manual install process of 0.0.3 xrecovery.I just remember copying those three files to system/bin....is it that much only?or copy 1 of the 3 files to some other folder?
plz help....
and wot r the files posted by u here for?
leechgod27 said:
i installed xrecovery 1.0.0 before flashing CM7...& now i cannot flash CM7 via the new xrecovery.So now how do i go back to older(0.0.3) xrecovery?
i m not able to install it the easy way...tht means vi .apk.& now i m not getting that old thread of manual install process of 0.0.3 xrecovery.I just remember copying those three files to system/bin....is it that much only?or copy 1 of the 3 files to some other folder?
plz help....
and wot r the files posted by u here for?
Click to expand...
Click to collapse
you should install it after the ROM not before! Just reinstall the phone thru SEUS and do it all over again.
Sent from my X10 using Tapatalk
leechgod27 said:
i installed xrecovery 1.0.0 before flashing CM7...& now i cannot flash CM7 via the new xrecovery.So now how do i go back to older(0.0.3) xrecovery?
i m not able to install it the easy way...tht means vi .apk.& now i m not getting that old thread of manual install process of 0.0.3 xrecovery.I just remember copying those three files to system/bin....is it that much only?or copy 1 of the 3 files to some other folder?
plz help....
and wot r the files posted by u here for?
Click to expand...
Click to collapse
just boot into the android OS and use FLASHTOOL to install xRecovery
if i install xrecovery 1.0. can i install a custom kernel ? if yes which ?
marios199546 said:
if i install xrecovery 1.0. can i install a custom kernel ? if yes which ?
Click to expand...
Click to collapse
http://forum.xda-developers.com/showpost.php?p=14457294&postcount=10
namely no ?
marios199546 said:
namely no ?
Click to expand...
Click to collapse
not on xRecovery v1.0.0 (until edify packages for those kernels are available)
alternatively u can get back to older recovery... flash which ever kernel u want... then flash xRecovery v1.0.0...
wht i personally do is i keep a toggle update.zip, with which i can switch between xRecovery v1.0.0 & FreeXperia recovery... i only need to change chargemon file
DooMLoRD said:
not on xRecovery v1.0.0 (until edify packages for those kernels are available)
alternatively u can get back to older recovery... flash which ever kernel u want... then flash xRecovery v1.0.0...
wht i personally do is i keep a toggle update.zip, with which i can switch between xRecovery v1.0.0 & FreeXperia recovery... i only need to change chargemon file
Click to expand...
Click to collapse
dual recovery is a good solution too, I have it thanks to Cobrato on his miui rom
DooMLoRD said:
not on xRecovery v1.0.0 (until edify packages for those kernels are available)
alternatively u can get back to older recovery... flash which ever kernel u want... then flash xRecovery v1.0.0...
wht i personally do is i keep a toggle update.zip, with which i can switch between xRecovery v1.0.0 & FreeXperia recovery... i only need to change chargemon file
Click to expand...
Click to collapse
how about keeping that as update.zip on sdcard and one click switch.
zip should just say
chargemon -> chagemon_1
chagemon_old -> chargemon
chargemon_1 -> chargemon_old
quick anddirty one click chargemon switcher.
riginal said:
dual recovery is a good solution too, I have it thanks to Cobrato on his miui rom
Click to expand...
Click to collapse
ya i know Cobrato has dual recoveries on his rom...
the thing is that the chargemon he uses for it is non standard... so the functionality will break if the modded chargemon gets replaced...
wht i prefer is to use freexperia recovery (which already comes with CM7 and is located at /system/recovery/) and then install xRecovery v1.0.0 on top of it (this is installed at /system/bin/xrecovery.tar)... and just keep toggling chargmons... i know this is not idea solution... but currently there is no other alternative until all update.zip use edify syntax...

[TUT] Install CWM Recovery and a Rom in x10 mini pro

PLEASE CORRECT ME IF ANYTHING IS WRONG
I do not take any responsibility if you break your device, ask sony to make them easier to update.
Suggestions about roms and kernels are welcome.
1- REQUIREMENTS
Check in Settings -> About phone
there should be
Baseband: M76XX-TSNCJOLYM-53404015
Android: 2.1.1.A.0.6
- Check out if you are root with Root Checker
https://market.android.com/details?id=com.joeykrim.rootcheck&feature=related_apps
- If not, to root you can use this
[APP]SuperOneClick (Root, Unroot, Enable Non-Market App)
http://forum.xda-developers.com/showthread.php?t=803682
Before using it, in android start Settings from the app-menu. Tap Applications > Development > USB debugging. Accept warning-popup by tapping OK.
- Make backups of your things with some app like Titanium Backup or mybackup
- Install Busybox Installer from market and open it
https://market.android.com/details?id=com.jrummy.busybox.installer&feature=search_result
- Install a root file manager (so you can see and modify system files) like
Root Explorer
- Check if your hardware keyboard language layout is supported
Hardware Keyboards | Sony Ericsson Keyboards
http://forum.xda-developers.com/showthread.php?t=982341
- if not, you will need to copy and send to that forum your language files
"I need to the following from you guys so we can make the hardware keyboard work:
your qwerty.kcm.bin and your qwerty.kl from your old Sony Ericsson Firmware (in /system/usr/) i need the entire folder with keyboard-config, keyboard-chars etc..
List your buttons and which button should have which character on blue/sym button and if you need capital letters as well which key should appear on blue/sym and shift button press
List you special signs, like underscore, plus,minus, etc .. even if you need a key frequently which is not on the default keyboard layout from sony we can still place it on a different button suitable for you
and last but not least any special requests, like numbers or so in the wrong place.
If you want to have an exact copy of your hardware keyboard as it is on your device (like the blue letters and number) please post a picture
As for many of you having troubles with "shift" key not working. Touch the text input window and hold you finger on it until a menu appears, choose android keyboard and NOT the HTC one I don't know why but "shift" key will work again"
2 Install a RECOVERY
[RECOVERY] ClockWorkMod Installer
Get it here: http://forum.xda-developers.com/showthread.php?t=1257701
Usage from a Windows computer:
You need to set your phone in Debugging Mode.
Connect your phone to your computer
Open up install.bat and follow the instructions inside that.
Usage from a Linux computer:
Requires your phone to be ROOTed but there is now a ROOTer for Linux that can ROOT your phone if not already done. Can be found in this forum.
You need to set your phone in Debugging Mode
Connect your phone to your computer
Open up terminal
Go to the directory it is extracted to
Start the installer by typing "sh cwm-x10minipro.sh"
3 USE CWM to make a backup of everything:
-Power off phone
-When booting your phone and when the 'Sony Ericsson' letters appear, press and release continuously the 'back' button.
Once you are in the CW recovery, use the volume keys to navigate upwards / downwards, the 'home' or camera button key to select, the 'back' key to go back.
- Make a backup of everything
- Reboot normally, connect the phone to the pc, and copy everything inside the sd card to the pc
4 WITH FULL BATTERY DELETE EVERYTHING AND INSTALL A NEW ROM USING CWM:
DO THE THINGS MARKED WITH *RED
When booting your phone and when the 'Sony Ericsson' letters appear, press and release continuously the 'back' button.
Once you are in the CW recovery, use the volume keys to navigate upwards / downwards, the 'home' or camera button key to select, the 'back' key to go back.
We need to make a full wipe:
ADB root shell
reboot system now
apply update from sdcard
*wipe data / factory reset
*wipe cache partition
install zip from sdcard
backup and restore
backup (also backs up ext partition and installed apps to sdcard)
restore (also restores ext partition and installed apps to sdcard)
restore from xRecovery (Use this in case you want to restore backups done with xRecovery)
advanced restore
mounts and storage
*UNMOUNT ALL OF THESE:
*mount / unmount /cache
*mount / unmount /data
*mount / unmount /sdcard
*mount / unmount /system
*mount / unmount /sd-ext
*mount / unmount /cache
*FORMAT ALL OF THESE:
*format /cache
*format /data
*format /sdcard (not really needed)
*format /system
*format /sd-ext
mount USB storage
advanced
reboot recovery
*wipe Dalvik Cache
wipe Battery Stats
report Error
key Test
*partition SD Card
*Ext Size 512MB (formatting as ext4)
*Swap Size (Set this to 0)
*Rest Size is for vfat
fix permissions
validate recovery
restore recovery
*power off
- After you power off, take the microsd card and put it in a card reader, and connect it to your computer.
(Or you could connect the phone by usb and from CWM go to mounts and storage -> mount sdcard)
- Put inside the big FAT32 partition, the rom-u-want-to-install.zip, it must be CWM compatible
Here you can get some info about some of the latests roms:
http://xperiaminicyanogen.wordpress.com
- go to CWM and do install zip from sdcard
leave it finish and reboot after a bit
SOME OTHER USEFUL LINKS
- Once you finish installing a new rom, you can use this app in Window$ to set up your Hardware Keyboard to your preferred supported language:
[APP] Hardware Keyboard Language Setter KeyboardSwitcher.zip
program so you can switch your Phone's Hardware Keyboard with just two clicks on the PC.
http://forum.xda-developers.com/showthread.php?t=1113863
Compilation of useful links
http://forum.xda-developers.com/showthread.php?p=9219329
[FAQ] CUSTOM Cyanogen Froyo General F.A.Q.
http://forum.xda-developers.com/showthread.php?t=1066824
[GUIDE] Unlock bootloader & relock bootloader | X8 | W8 | X10 mini | X10 mini pro
http://forum.xda-developers.com/showthread.php?t=1254225
Apps Sony
Xperia Arc Timescape (Retail Dump)
http://forum.xda-developers.com/showpost.php?p=11904220&postcount=3
SE Backup & Restore
http://forum.xda-developers.com/showpost.php?p=11908011&postcount=4
[TUT] From stock ROM to custom ROM for n00bs (X10 mini pro) by Emperor.dk
http://forum.xda-developers.com/showthread.php?t=1194499
Awesome and mostly right!
But there is one thing I don't understand: if you managed to install xrecovery and know how to use it, why do you need cwm??? Either install that rom with xrec, or with cwm.
Anyway it's really good!
I read somewhere that clockwork recovery was better and more complete, and that it seems the way to go. Is that right? I wish there was an easier way to instal it. In other phones you can instal it from rom manager app, maybe in the future they support this phone also.
devrruti said:
I read somewhere that clockwork recovery was better and more complete, and that it seems the way to go. Is that right? I wish there was an easier way to instal it. In other phones you can instal it from rom manager app, maybe in the future they support this phone also.
Click to expand...
Click to collapse
i think you should make a video and post it up on youtube; i cant seem to find a in depth tutorial on how to do it (in english anyways). Id like to make sure the complete process before beginning because im afraid of what may happen (people referring it to bricking the phone)
@nilseby: here an answer from slade giving the reasons:
http://forum.xda-developers.com/showpost.php?p=14600846&postcount=1978
tranced_ said:
@nilseby: here an answer from slade giving the reasons:
http://forum.xda-developers.com/showpost.php?p=14600846&postcount=1978
Click to expand...
Click to collapse
Oh, yea? Well thx, now i realized xrec is even better than I thought! So I have no reason why to install cwm ( i never did )
So theres not any benefit of running cwm over xrec?
If anything is wrong please correct it.
It works perfect for my taste is better than Xrecovery.
Who comes to Xrecovery that delete xrecovery.tar in system / bin
aLeex10 said:
It works perfect for my taste is better than Xrecovery.
Who comes to xrecovery that delete xrecovery.tar in system / bin
Click to expand...
Click to collapse
Thanks, that is a problem that both conflict. Best way would be to use cwm only, but I could not find an easier method. I will update the instructions. Maybe installing rom manager app by slade darkness and co?. it is not finished, but it lets you instal cwm
Finally, there is a new app to instal the recovery you want with just a click, seek it on the dev thread
Every recovery you want , check my signature
D4rKn3sSyS said:
Every recovery you want , check my signature
Click to expand...
Click to collapse
Just bought a SE X10 mini pro. Rooted via the one click app.
Want to install CM7
tried all the apps (Rom manager(appstore and here from the forums), d4 recovery installer)
The auto-install apps don't really seem to do anything.
The 'Install xrecovery' options don't actually install it. Clockwork installs the old version 3.0.0.8 if anything (from the market rom manager).
The rom manager app from xda downloads and seemingly installs clockworkrecovery mod / says so in the notifications, but doesn't seem like it really does. I can't boot into it by pressing the back button at the SE writing (before or during)
I did manage to install xrecovery-mini 0.11 via a root file manager and boot into it, but the options didn't match the FAQ for http://forum.xda-developers.com/showthread.php?t=1117713, so I ended up screwing up and reflashing via SEUS.
Could someone please point out what I was doing wrong (or how to flash the CM7 image and then the hotfixes via xrecovery-mini), or maybe if there's really point and click app that works to do the xrecovery/cm mod parts without me screwing things up.
gaah... Installed clockwork recovery mod 3.2.0.0 but when I try to install the CM7 rom it tells me off saying Amend scripting is no longer supported/switch back to edify scripting etc.
What exactly should I do to install the rom ?
(oooh wait, it says to use xrec , fail )
but it is old, the new cwm is with apk install! C:
sure, much more easy now. I updated it, I will try to post the links to rom manager and recovery installer apps
cwm recovery vs xrecovery
I tried installing xrecovery. I should say I succeeded in installing xrecovery, it installed, and worked fine except no bootscreen when I turn the phone on. All 3 green checks showed up, but nothing happens.
Phone is rooted
busybox installed via busybox installer which shows the phone is rooted and the version of busybox.
All files (changemon, busybox and the tar files) in /system/bin with permissions set to rwxrwxrwx.
Am trying to figure out how to instal cmw recovery instead of xrecovery... not much luck so far.
Advice appreciated!
Hello, 1st post criticize me! LOL
I'm trying to figure out the same...
I'm totally new here and I'm trying to install the CWM Recovery.
it says: "Download and instal the recovery installer apk by darknessys"
when I look the installer it is not compatible with stock roms.
which method should I use to install the CWM recovery?
Ummm download this http://www.4shared.com/file/KQf9bym2/AAIS.html
Extract aais.zip to /sdcard
goto terminal emulator and give following commands
su
cd /sdcard/aais
sh install.sh
Click to expand...
Click to collapse
choose ur option and enter the number of the option
only for mini pro as of now!
So recovery installer apk by darknessys or rom manager apk, both can not be used on stock eclair rom? can anyone confirm this?
Edit- it seems that those apps don't support stock rom, that is weird, I thought they would work, try at least with darknessys recovery installer.
if not, the easiest way for now I guess would be to install xrecovery and then cwm.
So if someone knows how to easily install cwm on stock rom, please advise.
I don't know if what galvic suggests works or what it does, but you can take a look to the script.
Getting crazy
I tried now several things from here and Google to get this CWM recovery to work... no success!! Got a new x10 mini with latest SE Update...
Please does anybody know a working way to get this thing to work???
Frustrating

{help}need stock kernel

I jst flashed d custom kernel and it flashed successfully......bt now my phone goes into bootloop.....whenever i start.....and when i try to install any custom rom it says incompatiable baseband found....HELP
stock kernel here
stock-kernel
taufiiqqq said:
stock kernel here
Click to expand...
Click to collapse
brother... thank you very much for thAT KERNEL
taufiiqqq said:
stock kernel here
Click to expand...
Click to collapse
anyone have the stock kernel
maybe it help you witch e10i-x10i (mini).
1. have stock android 2.1, date 10w30 and root device use SuperOneClick
1.1 optional - unlock bootloader with program msm7227 and check in "s1tool"
2. install busybox 3.3.8 use ADB console (adb install x:\*.apk), after opened in device follow the instructions busybox on the screen.
3. install rootexplorer 2.17 use ADB console
4. download and copy to microsd card CWM, open rootexplorer and copy cwm files (system) to root folder next add all permission system/bin/chargemon file.
5. power off and power on device with press 5-30 times back button, cwm loaded -> mounts and storage -> format system - format data - format cache if cwm say "cwm format, restore cwm" press no >> and yes. power off device.
6. flash custom kernel nAa_0.6 with cwm (flashtool on java) reload in cwm
7. download custom rom 4.1.2_jbmp_mini copy to microsd card

CWM solution for [ROM][ICS][LWW] AOKP build 40 for locked bootloader BETA 1[28 MAR 20

Well i have locked bootloader and i wanted something new like a CM rom and i found this thread.
AOKP build 40 for locked bootloader LWW
The only problems is that the rom came with a fews bugs.
-Problem with Videos.
-And not be able to boot onto recovery.
I solve the second one, reading a few threads and testing and erros. I hope this could be usefull for someone other than me.
First of all thanks to script created for ATIS112 and the post of an0nym0us_ that helped to make CWM fully working without FC on rom.
The first step was copy from what Atis112 did for the aokp rom for locked bootloader on Xperia U separating the script for recovery and the ramdisk.
So how an0nym0us_ noticed, if we changed the first line of the recovery scripts.
from this
Code:
#!/system/xbin/sh
to this
Code:
#!/system/xbin/bash
and in the separated ram disk we maintain the first line without change it. Problem solved. We got fully working CWM recovery for this nice rom.
Here i upload my two script for faster use. Just push it to system/bin
Code:
[ATTACH]2038085._xfImport[/ATTACH]
[ATTACH]2038086._xfImport[/ATTACH]
P.S: I hope someone could help me with the video problem. Reading i found that the problems came with the build or maybe with the stock kernel. I don't know really. So enlighten me please.
darkbeowulf said:
Well i have locked bootloader and i wanted something new like a CM rom and i found this thread.
AOKP build 40 for locked bootloader LWW
The only problems is that the rom came with a fews bugs.
-Problem with Videos.
-And not be able to boot onto recovery.
I solve the second one, reading a few threads and testing and erros. I hope this could be usefull for someone other than me.
First of all thanks to script created for ATIS112 and the post of an0nym0us_ that helped to make CWM fully working without FC on rom.
The first step was copy from what Atis112 did for the aokp rom for locked bootloader on Xperia U separating the script for recovery and the ramdisk.
So how an0nym0us_ noticed, if we changed the first line of the recovery scripts.
from this
Code:
#!/system/xbin/sh
to this
Code:
#!/system/xbin/bash
and in the separated ram disk we maintain the first line without change it. Problem solved. We got fully working CWM recovery for this nice rom.
Here i upload my two script for faster use. Just push it to system/bin
Code:
[ATTACH]2038085[/ATTACH]
[ATTACH]2038086[/ATTACH]
P.S: I hope someone could help me with the video problem. Reading i found that the problems came with the build or maybe with the stock kernel. I don't know really. So enlighten me please.
Click to expand...
Click to collapse
No offence but the last couple of posts on that thread were exactly what you said. You should read before you post unnecessary things.
Sent from my WT19i using xda app-developers app
But it doesn't said exactly the same. They didn't tell you that you need to separate both scripts. The original script for recovery and ramdisk was only one.
But doesn't matter i had been testing CWM and it doesn't work. You could boot to recovery without problems, but apparently recovery work in another data folder different from ramdisk. I'm trying to fix this.
Finally i'm just trying to make something for people that wanted to use that rom. And with no offense you could try to really read the and at least comprehend the last posts of that thread. They only gave the solution for make recovery boot, but rom got a lot of FC and not work anymore. I make both, recovery and rom work.
Finally i fixed the problem with data folder.
Comparing some files from ROM recovery and 5.0.2.7 recovery files i noticed that the sh script in the folder xbin was corrupted or wrong in some way.
so i pushed the original sh files that comes with the 5.0.2.7 recovery (ROM version recovery --> not tried yet with version 5.5.0.4) to the following folder.
Code:
sytem/xbin
Now i changed back the first line of the chargemon script to the original.
Code:
#!/system/xbin/sh
The problem that i faced here was that the ramdisk used the same shell and for some reason it got a lot of FC with this, like before when we used bash for chargemon script. But with a little change in the ramdisk script i could bypass this and it worked. I tested a few zip with the recovery, changed bootanimation and adding some cameras and no problems.
So in the ramdisk script i changed the first line to this.
Code:
#!/system/bin/sh
Like before i leave all the files here.
Code:
[ATTACH]2040561._xfImport[/ATTACH]
This is not for flashing.
Instructions:
Push the files chargemon and ramdisk to system/bin (remove or replace older files if needed and set permission to rwxr-xr-x)
and the file sh to the folder system/xbin (remove or replace older file if needed and set permission to rwxrwxrwx)
And please if someone could link this post to the original thread. That way is easier for the rom users.

[Dev][Guide][JB+KK] Dedicated recovery/boot.cpio partition

Hi there!
Today I finally found how to make our codinas' kernels universal, i.e. allow to install kernel on whatever ROM and finally separate recovery from kernel. It's well known, bootloader decides what will be loaded - kernel or recovery. That probably may explain why AnyKernel installer(or other similar) doesn't work on codina, because we can't move recovery partition anywhere.
But there is also a little trick that allow us load recovery and boot.cpio from different partition - https://github.com/ChronoMonochrome/Chrono_Kernel/commit/df9094f1f12618ad9599da266792d6b2f8106170 - just an another approach
Don't worry, we won't touch bootloader at all.
As can be seen, /dev/block/mmcblk0p17 (kernel2 partition) will be used for storing recovery.cpio and boot.cpio. On stock that may not work (I don't know for what exactly uses Kernel2 partition, besides of manually restoring of kernel1 partition. I only know that is almost useless on custom ROMs, and we can use it as we want )
First do some preparations:
Download this kernel and needed recovery/boot scripts(4.4.x.cpio.zip, 4.4.x_f2fs.cpio.zip, etc... 4.4.x.cpio means that it support only ext4) from my google drive (folder ramdisks), unzip recovery (twrp or cwm) and rename to recovery.cpio, then move it to external SD card. Then do it with boot scripts that you've downloaded (e.g. 4.4.x_f2fs.cpio.zip - unzip and rename to boot.cpio)
Well, that all that needs for installation. Read following instruction very carefully, otherwise that may cause brick Keep in mind, all that you do at your own risk! I'm not responsible if you brick your phone!
Installation method:
1) reboot into recovery, plug your phone to your PC, enable adb:
Code:
adb shell
2) Format kernel2 partition to ext4 file system:
Code:
mke2fs -T ext4 /dev/block/mmcblk0p17
Think twice before you hit 'enter' button - wrong command may cause hardbrick!
3) create /ramdisk folder and mount kernel2 partition
Code:
mkdir /ramdisk
mount -t ext4 /dev/block/mmcblk0p17 /ramdisk
move your recovery.cpio and boot.cpio to this folder, give 777 permissions:
Code:
chmod 777 /ramdisk/recovery.cpio
chmod 777 /ramdisk/boot.cpio
4) install downloaded kernel
Now you can change recovery via changing /ramdisk/recovery.cpio - just make a backup of this file, and then replace with one of another recoveries. If you want to install another ROM or change filesystem of partition then replace /ramdisk/boot.cpio with one of needed boot scripts. Don't forget to give 777 permission (probably 644 is enough, but I didn't test it) to both of these files.
This method tested and working on 4.4.x TC ROM + twrp recovery + kernel with full F2FS support.
Well, now it's time to create uncompressed kernel, that may slightly decrease the boot time
@ChronoMonochrome
Thanks. do you mean that kernel2 partition is useless in stock and cyanogenmod firmware?
Is it right that boot loader will read kernel1 partition then it will read system partition? and kernel2 is not necessary for booting?
I have installed new universal kernel (2.5) , so I flashed new ramdisk for 4.4.x , can I roll back to older versions or stock firmware with this ramdisk or I should restore Partition17 backup?
sorset said:
@ChronoMonochrome
Thanks. do you mean that kernel2 partition is useless in stock and cyanogenmod firmware?
Click to expand...
Click to collapse
As it turned out, it's unneeded even on stock. So if you won't restore kernel2 partition, nothing will happen.
Is it right that boot loader will read kernel1 partition then it will read system partition? and kernel2 is not necessary for booting?
I have installed new universal kernel (2.5) , so I flashed new ramdisk for 4.4.x , can I roll back to older versions or stock firmware with this ramdisk or I should restore Partition17 backup?
Click to expand...
Click to collapse
Yes, you can roll back to usual kernels. it doesn't matter what written on kernel2 partition - real kernel or anything else...
ChronoMonochrome said:
As it turned out, it's unneeded even on stock. So if you won't restore kernel2 partition, nothing will happen.
Click to expand...
Click to collapse
Ok, thanks , But why do you mount kernel2 partition inside of OS? As I understand boot.cpio is necessary before booting OS . And inside of OS is just an extra storage! (is that true?)
sorset said:
And inside of OS is just an extra storage! (is that true?)
Click to expand...
Click to collapse
Yes and no, is 16 Mb big enough to be called "storage"? I did it, just to be able replace ramdisks even without booting to recovery. But newest boot scripts doesn't have it.
Ace 2 has 15 - 20 Partitions my Friend
ace2nutzer said:
Ace 2 has 15 - 20 Partitions my Friend
Click to expand...
Click to collapse
And what ? We actually talking about kernel2 partition.
ChronoMonochrome said:
And what ? We actually talking about kernel2 partition.
Click to expand...
Click to collapse
sorry, i meant @sorset
ChronoMonochrome said:
Yes and no, is 16 Mb big enough to be called "storage"? I did it, just to be able replace ramdisks even without booting to recovery. But newest boot scripts doesn't have it.
Click to expand...
Click to collapse
You are right , but I remember days that 1.44MB floppy disk was a large STORAGE and 16MB was HUGE
sry , I have another question , So can I remove its line from fstab to prevent mounting?
I'm confused
boot.img in kernel archive is recovery image that will extract on partition15 (kernel) , but what recovery.cpio exactly is that yu copy on partition17 (kernel2) ?
ace2nutzer said:
Ace 2 has 15 - 20 Partitions my Friend
Click to expand...
Click to collapse
Yes,With counting internal storage , 17 exactly , but thats not the point , I'm afraid.
sorset said:
sry , I have another question , So can I remove its line from fstab to prevent mounting?
Click to expand...
Click to collapse
just redownload bootscripts(kernel/ramdisks), as I said, newest scripts doesn't mount kernel2 partition.
boot.img in kernel archive is recovery image that will extract on partition15 (kernel) , but what recovery.cpio exactly is that yu copy on partition17 (kernel2) ?
Click to expand...
Click to collapse
I don't get it rephrase please
ChronoMonochrome said:
just redownload bootscripts(kernel/ramdisks), as I said, newest scripts doesn't mount kernel2 partition.
I don't get it rephrase please
Click to expand...
Click to collapse
I didn't too
There is an Image named boot.img in kernel flashable zip archive that extracts into partition 15 (named kernel) as I understood is recovery (TWRP or CWM) image and you wont touch linux orginal image , and your modified custom kernel is new modules for linux image that loads while booting (sry, I cant explain fine), So what is recovery.cpio that is in recovery flashable zip image that extracts into partition 17 (named kernel2) ?
sorset said:
as I understood is recovery (TWRP or CWM) image and you wont touch linux orginal image
Click to expand...
Click to collapse
originally kernel + recovery
, and your modified custom kernel is new modules for linux image that loads while booting (sry, I cant explain fine), So what is recovery.cpio that is in recovery flashable zip image that extracts into partition 17 (named kernel2) ?
Click to expand...
Click to collapse
In my mod kernel(mmcblk0p15) and recovery (mmcblk0p17) are splitted.
Thank you. I see.
This is probably the best (and only?) way to rebuild the ramdisk without having to compile anything, which is an excellent base for my NoUMS patches
:good:
<remove>

Categories

Resources