[Discussion] [q/a] Development for flashing kernel image from cwm for xperia devices - Sony Ericsson Xperia Mini, Mini Pro, Xperia Pro, A

Disclaimers :
#i am no-developer.im just a geek xperian..like many of u.i have created this ,my first ever thread typing on my mob keypad.so forgive me for short words and untidy post.
#links included below is noway related to me.respective links are included as per my findings to support the main moto of this thread.im thankfull to all of them who have tried to scratch on this through their posts and threads
#with all do respect,this thread is intended for our devs who can take this as pre-requsites for development.
#its a humble request for devs to put there effort on this.
#i request all xperians...from devs to simple users...whoever thinks this post worth discussing/developing,ur valueable words on this are highly appreciated.
#and please no trollers
Click to expand...
Click to collapse
I was doodling around today,i got my eyes poped-up wen i encounterd this
[samsung kernel flashing from cwm zip] -> http://forum.xda-developers.com/showthread.php?t=1301756 and this
[samsung general cwm kernel updater] ->http://forum.xda-developers.com/showthread.php?t=2132208
It all began then when i had to be far from my pc.then flashing new kernls for new custom roms began to be a problem.i presume their are a lot of users like me who cant access pc with as ease as many can.or simply to them who dont want to connect to pc just to flash kernels.if this would be success,just imagine how ease it would be?
But before starting to dream lets put together what i have come across till now.
Then i started digging more...on google & found this Tutorial [many devs might be intrestd &could help xperia users& start to run xperiment in our xperia ] --> http://www.modaco.com/topic/360180-howto-build-and-update-kernel-using-cwm/
In my findings i did aknowledge that this matter has/have/had been left out in corner just for some taboos/nerms like our xperia doesnt ship with normal recovery partition or like our custm recovry doesnt support some disk formats.
But whatsoever, i was little arosed by above things....then came a point whereafter i was too excited,wen i found this in our very xperia forum,xperia p forum ->> http://forum.xda-developers.com/showthread.php?t=2409021
Here the dev has created a zip with updatr script writng the kernel image,which stays inside the boot.img file .i couldnt dig more on this zip,as it was not so popular thread.i dont even know for it works or not,all i know is there are devs wanting to build,which is the main moto of this thread to let devs rethink the possibilty.
And yes, its a convincing reason for acceptance that our xperia doesnt have recovry partition like as other vendors device..and what we get as a recovry is hard coded to ramdisk.but like as ,A xperia s user,i too want to question an enlightning point on this...like using recovry fota partition,wich gets blokd and remains unusable aftr bootloader unlockd....why not use that...if not what about repartitioning empty space in device for recovry usage partition... http://forum.xda-developers.com/showthread.php?t=2163643
i too presume, even though we dont have that heavy intrnl space,but i guess we have enough for just a recovry partition.i guess so.correct me.
FOTA partition :
The FOTAKernel partition is used by Sony to do FOTA updates when updating the boot image. Unlocked devices can't take Sony FOTA updates so using this partition for storing the recovery ramdisk seems like a good idea. Unlocked users aren't able to use this partition anyway and the FOTAKernel partition is effectively the "recovery" partition on Sony devices.
Kernel changes : extract_elf_ramdisk setup in kernel
if some body wants a detailed info it can be found here (( **thanks to @officiallysonyrebel ,for the supportive conversation.above words are his ** )) -- http://forum.xda-developers.com/showpost.php?p=38640389&postcount=2
*** Summing up in total ***
It may b a horizon-touching dream..but as a geek user, like me,we dream of it.
Our charming devs can unlock bootloaders/root/giv us custm roms/give us a taste with unimaginable upgrowing ever, android version updates in roms/ ports.these all would also be impossible without their immense hardwork/researchs/xperimnts...i do aknowledge its a lot to ask for this.but with all do respect i wish devs get ther hands on it.
I predict most of xda-ians might already know abt all this,if yes do enlighten us more...ur comments and findings are most needed thing currently.
but truely saying i really dream of using cwm @ its maximum capacity,as of its easeness,isnt it? Different vendors like samsung,zte,etc evn can get rooted simply from cwm only...even most htc can. So why cant our xperia?is it coz of less devs in our xperia?i humbly request all devs to put some work on this so that me,like users who cant access pc with ease/dont want to,can easily get the work done.i also presume there r a lot of xperians,who want this.it cant be more handy than this...can it?
Hope in near future ,we xperians could getwith like these features as others.(rootng/flashng kernels from cwm).
Cheers!!
Xperia-lover!!

Most Xperia kernels are probably including CWM by default in the boot image. About a month ago Dees_Troy submitted some changes to the CyanogenMod repos that were accepted. Newer builds of CM include a special extract_elf_ramdisk utility that Dees_Troy wrote to read and extract a recovery ramdisk from the FOTAKernel partition instead of using the ramdisk that is included in the boot image. If the ramdisk in the FOTAKernel partition is a stock Sony ramdisk or not present, then the existing ramdisk in the boot image is used instead. This setup allows users to choose which recovery they want to keep installed.and whole a lot possibilites
but my major concern is if after unlocking bootloader FOTA partition gets blocked then how can we access it ..
so, first we have to acess FOTA partion then we can start dreaming on

officiallysonyrebel said:
Most Xperia kernels are probably including CWM by default in the boot image. About a month ago Dees_Troy submitted some changes to the CyanogenMod repos that were accepted. Newer builds of CM include a special extract_elf_ramdisk utility that Dees_Troy wrote to read and extract a recovery ramdisk from the FOTAKernel partition instead of using the ramdisk that is included in the boot image. If the ramdisk in the FOTAKernel partition is a stock Sony ramdisk or not present, then the existing ramdisk in the boot image is used instead. This setup allows users to choose which recovery they want to keep installed.and whole a lot possibilites
but my major concern is if after unlocking bootloader FOTA partition gets blocked then how can we access it ..
so, first we have to acess FOTA partion then we can start dreaming on
Click to expand...
Click to collapse
Ya i had read in the link u dirctd...i got to know that aftr unlockng bootloadr, that partition becomes unusuable/inaccessble.if that could be attained...then we can hope...isnt it?if i undrstud... wish devs could wave their magicstick soon.
Sent from my Xperia Ray using xda premium

I'm not sure but what about installing the recovery in /system?
Then we could write a script that detects if the recovery is installed in /system and it will choose the /system recovery over the kernel recovery while booting in recovery. Then we could try mounting the kernel partition and flash the boot.img. Then you flash a zip to remove the /system recovery and boot the new kernel
Not sure if that's possible, and don't have any idea how to do that. It was just an idea :good:
Sent from my Nexus 4 running Android 4.3

mihahn said:
I'm not sure but what about installing the recovery in /system?
Then we could write a script that detects if the recovery is installed in /system and it will choose the /system recovery over the kernel recovery while booting in recovery. Then we could try mounting the kernel partition and flash the boot.img. Then you flash a zip to remove the /system recovery and boot the new kernel
Not sure if that's possible, and don't have any idea how to do that. It was just an idea :good:
Sent from my Nexus 4 running Android 4.3
Click to expand...
Click to collapse
we can't do it in /system basicially we have to do this thing using only FOTA partition ..but our main concern is when we unlock our bootloaders that partition becomes inaccesible for us...
if we somehow gets access to FOTApatition then script will do work..

mihahn said:
I'm not sure but what about installing the recovery in /system?
Then we could write a script that detects if the recovery is installed in /system and it will choose the /system recovery over the kernel recovery while booting in recovery. Then we could try mounting the kernel partition and flash the boot.img. Then you flash a zip to remove the /system recovery and boot the new kernel
Not sure if that's possible, and don't have any idea how to do that. It was just an idea :good:
Sent from my Nexus 4 running Android 4.3
Click to expand...
Click to collapse
Nope...You are still using the same kernel....just booting from different ramdisk when "installed in /system"...
We need to boot from a "second" kernel which can be used to flash the primary kernel ...Most other phone can boot into two kernels ,one stock and one recovery ,hence they can be used to flash kernels via recovery and use flash_image to install recovery in system ...
The problem is not where kernel/recovery is installed
The problem is how to boot the secondary kernel after installation ...It's very difficult to do that ...
lets say I dd the recovery.img to /mmcblk0p4 which is the fourth partition in an SD card
How do I instruct the bootloader to boot the device from /mmcblk0p4(or fota 1 or whatever) instead of /boot ...Thats the problem ...

Okay that's sad
But what about checking the partitions and if we know which blocks contain the Fota partition, could we try to mount it?
The problem would be how to tell the bootloader to boot the recovery or the 2nd kernel right?
Sent from my Nexus 4 running Android 4.3

Still the same problem ,how to instruct the bootloader to boot from fota 1 instead of /boot !!

Check that. It's exactly the same what we want to do, right?
Okay not exactly but we could use that too. But I'm not sure if he is able to install another kernel in the recovery...
Sent from my Nexus 4 running Android 4.3

mihahn said:
Check that. It's exactly the same what we want to do, right?
Sent from my Nexus 4 running Android 4.3
Click to expand...
Click to collapse
Exactly ...we can use Multi partitioned SD card but thats extremely wishful thinking ...Also we need a lot of devices to brick :rofl:
Edit: He can use recovery to install kernels since ,the S1 boot boots LK from mmcblk0p4 (equivalent to /boot) which in turn gives an option to boot to fota1(which is recovery ) or the mmcblk016(which is the new place from which the system boots)

karandpr said:
Exactly ...we can use Multi partitioned SD card but thats extremely wishful thinking ...Also we need a lot of devices to brick :rofl:
Edit: He can use recovery to install kernels since ,the S1 boot boots LK from mmcblk0p4 (equivalent to /boot) which in turn gives an option to boot to fota1(which is recovery ) or the mmcblk016(which is the new place from which the system boots)
Click to expand...
Click to collapse
But later in OP they said it could be possible to reflash the stock rom to restore the partition table. So if we don't touch fastboot and flashmode partitions we should be able to recover the phone
I wrote the OP a PM if he could help us, let's see what happens
Sent from my Nexus 4 running Android 4.3

mihahn said:
But later in OP they said it could be possible to reflash the stock rom to restore the partition table. So if we don't touch fastboot and flashmode partitions we should be able to recover the phone
I wrote the OP a PM if he could help us, let's see what happens
Sent from my Nexus 4 running Android 4.3
Click to expand...
Click to collapse
Unlike them we aren't modifying partitions ...we can use multi SD card but then we need to get SD card mounted by LK ...
There is a fundamental diffrence in two phones ,that they are using an emmc+ext4 and we are using a raw nand/yaffs device . i think the difference is night and day ...I dont think we can modify partitions easily ...
If however we get to mount SD card with LK then it's a different story ...

karandpr said:
Unlike them we aren't modifying partitions ...we can use multi SD card but then we need to get SD card mounted by LK ...
There is a fundamental diffrence in two phones ,that they are using an emmc+ext4 and we are using a raw nand/yaffs device . i think the difference is night and day ...I dont think we can modify partitions easily ...
If however we get to mount SD card with LK then it's a different story ...
Click to expand...
Click to collapse
So you mean we partition the sdcard and use a partition as the recovery partition?
I read about that with multiboot for xperia play (I guess). So maybe it could work for us too?
Sent from my Nexus 4 running Android 4.3

mihahn said:
So you mean we partition the sdcard and use a partition as the recovery partition?
I read about that with multiboot for xperia play (I guess). So maybe it could work for us too?
Sent from my Nexus 4 running Android 4.3
Click to expand...
Click to collapse
it's more logical(and safer) than editing nand ...AFAIK ,the partition setup of nand is included in kernel ...we can partition SD card to whatever we want and is more feasible

karandpr said:
it's more logical(and safer) than editing nand ...AFAIK ,the partition setup of nand is included in kernel ...we can partition SD card to whatever we want and is more feasible
Click to expand...
Click to collapse
Okay so how to start? What could we do to get the project to a higher level?
We have to find out how to get the bootloader to boot the 2nd kernel/recovery partition, right?
Sent from my Nexus 4 running Android 4.3

mihahn said:
Okay so how to start? What could we do to get the project to a higher level?
We have to find out how to get the bootloader to boot the 2nd kernel/recovery partition, right?
Sent from my Nexus 4 running Android 4.3
Click to expand...
Click to collapse
Not really ....we can attempt/try/wish to do what the Xperia T folks did ,flash a bootloader at /boot instead of boot image ...
First thing we really need to know how actually LK works and can it be made to boot a kernel stored in a memory card ,
Editing a nand partition is currently out of question imo ,there is no free space for two kernels...
Edit : TBH ,We should look at HTC HD2 development more than anything since that section has "Android SD development" and Nand development ..
Even saying that we might just be scratching the surface :/

karandpr said:
Not really ....we can attempt/try/wish to do what the Xperia T folks did ,flash a bootloader at /boot instead of boot image ...
First thing we really need to know how actually LK works and can it be made to boot a kernel stored in a memory card ,
Editing a nand partition is currently out of question imo ,there is no free space for two kernels...
Edit : TBH ,We should look at HTC HD2 development more than anything since that section has "Android SD development" and Nand development ..
Even saying that we might just be scratching the surface :/
Click to expand...
Click to collapse
Yes the HTC HD2 has great development support and I already worked with a HD2 of a friend, but I have actually no idea how to use the method they are using for the HD2 for our devices. I think I will dive into it when I'm back at home from my vacation trip
Sent from my Nexus 4 running Android 4.3

maybe at deeper lok of possibiltes
i was searching on sd card booting nd found this
http://glasskeys.com/2011/06/27/how...-card-running-cyanogenmod-for-the-nook-color/
we need to make a seprate partition and kernel to use triggers to boot like we always do but it will call from SD card..
i think it may not work cause calling a kernel from SD card

officiallysonyrebel said:
maybe at deeper lok of possibiltes
i was searching on sd card booting nd found this
http://glasskeys.com/2011/06/27/how...-card-running-cyanogenmod-for-the-nook-color/
we need to make a seprate partition and kernel to use triggers to boot like we always do but it will call from SD card..
i think it may not work cause calling a kernel from SD card
Click to expand...
Click to collapse
Ehh...no it won't work ...the S1boot boots only from /boot...
The thread you cited is too old and worked probably due to an exploit in nook color ...
I think something like LK should work ,provided it waits for sd card to mount...

officiallysonyrebel said:
we can't do it in /system basicially we have to do this thing using only FOTA partition ..but our main concern is when we unlock our bootloaders that partition becomes inaccesible for us...
if we somehow gets access to FOTApatition then script will do work..
Click to expand...
Click to collapse
Correct me if i m wrong.its a noobish thought.
Can we access fota partition before bootloader is unlocked?if we can so what r we waiting for?
lets rehearse for the magick show,do what u have thought of.
(I presume when device is still locked....or if we revert back to locked state from unlocked... we could acces that partition.. .we get space for secondry kernel...if still quesn is letting bootloader know we want to boot from that,then again we r far behind)
Sent from my Xperia Ray using xda premium

Related

Will we ever have a SWITCH-ROM app?

Will this ever be possible?
Like probably not a actual app... but like dual boot?
where you can go into 2 different roms back and forth with no problems....
No sorry to burst your bubble
Dual booting a phone is really hard i mean dual booting a pc is already difficult but a phone will be more hard
Sent from my SGH-T959 using XDA App
i boot two systems ,i had to partitoin my internal memory on my own with partiton magic ,i can run ext4 system and rfs but everytime you want to run another rom u have to flash it to it so it takes 3 min out of Your daily schedule and if you go back another 3 .
but thats the filesystem, since you said ext4 and rfs i'm talking about actual ROMS since our phones have so much memory...
yes one partition EXT4 PARTITION! is one system (apss and whatever you have on it) , another partition is RFS PARTITON ! (with all apps u have put there) switchin back and forth the roms does not wipe setting u appiled to another rom so u switch back beatwen systems not losing your apps and stuff ( you can run different roms they dont have to match anyhow)
Crystal clear ?
You know fat32 fat ext4 jfs rfs are partitons right AND THERE IS ABOUT 8 MORE YOU CAN FORMAT YOUR MEMORY OR EXTERNAL SD
p.s if no1 is correcting me on this that means i am right?
If the data was indexed in a system exclusive method then it could be possible, but consider this how many 2009 Honda parts can you remove and put in a 1011 car........... not many, builders of the phone both hardware and software will never agree so.......... dual boots will be ported methods...... until some awesome dev here figures it out for the rest.........
dual boot worked for me try it out .
+1
Someone else posted about this the other day. Someone has written a bootloader that allows for dual booting different roms but I think it was for an HD2 or something. I'll try to find a link to it.
CrazyCharlie said:
Someone else posted about this the other day. Someone has written a bootloader that allows for dual booting different roms but I think it was for an HD2 or something. I'll try to find a link to it.
Click to expand...
Click to collapse
Here it is http://www.xda-developers.com/android/new-dual-boot-now-for-the-hd2/
If you can dual boot Windows Phone and Android on one device surely it's possible to have two different Android ROM's on the same device.

Rootfs and boot? - full device access?

I've been looking about on the forums .. but can't find no real answer to my question
Basicly I have a working knowlage of unix based systems with basic bash python pascal vb knowlage
I know how to flash our roms to our phones and I have unlocked bootloader rooted and so on but I can't understand
This ...
If our android phones ( mine is x10 mini pro U20I ) are linux based
Then why the hell can I access rootfs or more specificly /boot
Why can't I recompile the kernal on the device in place ... ok I understand
My 600mhz overclocked to 690mhz never more than 65mb ram free device
Ain't gonna like doing it and may be quite slow .. but if I wanted to ...
I guess my basic point is that I'm sure a linux based device must be able albeit dagerously
Gain access to the nand and in turn flash OR read write to nand memory so that I can access the internal
Filesystem more '' PC '' like I mean gain full read write access to the phones memory / bootloader and such
Is there no way to flash a kernel ' on device ' or simply gain write access to simply modify just 1 or 2 files within the kernel?
It is possible but it has to be coded into the kernel. Then you can write to /boot from CWM and flash kernels from there.
The locked bootloader means it has a check for whether.it knows the kernel. Like grub but it has a check so only official kernels from the distribution 's repo will boot not user-compiled ones.
If you want to try Modding nAa kernel for write to boot make sure you have JTAG because you'll probably kill the phone and need it
X10man
Sent from my Fender Stratocaster to your face via XDA Premium

Dump extremely old I9505 software

I have 2 pre launch models I9505 with extremely old software (and a non-secure bootloader ! )
Could someone point me in the right direction on HOW to extract the partition layout and all firmware related files ?
both devices are on different software
1st device hasn't even got TouchWiz yet, it was delivered on Google software and looks like this:
2nd device has this in download mode:
Can someone help me ?
Obviously this is an effort to get a modded bootloader which will allow us to install the FULL I9505G firmware on our I9505 devices !!
karoolus said:
I have 2 pre launch models I9505 with extremely old software (and a non-secure bootloader ! )
Could someone point me in the right direction on HOW to extract the partition layout and all firmware related files ?
both devices are on different software
1st device hasn't even got TouchWiz yet, it was delivered on Google software and looks like this:
2nd device has this in download mode:
Can someone help me ?
Obviously this is an effort to get a modded bootloader which will allow us to install the FULL I9505G firmware on our I9505 devices !!
Click to expand...
Click to collapse
You must dd all of the things in /dev/block/ I.E.
dd if=/dev/block/mmcblk0p1 of=/sdcard/mmcblk0p1.img
dd if=/dev/block/mmcblk0p2 of=/sdcard/mmcblk0p2.img
Etc...
Sent from my GT-I9505G
System status = Custom
I don't think you will receive OTA with this + are the specs even the same ??? the model is totally different.
Just try..
Sent from my HTC One using Tapatalk 4 Beta
MichelN said:
System status = Custom
I don't think you will receive OTA with this + are the specs even the same ??? the model is totally different.
Click to expand...
Click to collapse
I don't think he's worked about OTA, lol. His model reads GT-i9505. How is that different?
Sent from my GT-I9505G
Fenny said:
I don't think he's worked about OTA, lol. His model reads GT-i9505. How is that different?
Sent from my GT-I9505G
Click to expand...
Click to collapse
Look at the phone model, sammy might have used other chips for the pre-release.
MichelN said:
Look at the phone model, sammy might have used other chips for the pre-release.
Click to expand...
Click to collapse
You mean physically? Yeah engineering devices will often look different than the official release. But usually they have most of the same guts. In this case I am concerned that they would have used an unsigned bootloader and a blown (or not blown as the case may be) efuse. But if that bootloader is signed and insecure... Ooooh baby we could have some fun with that.
I'll try that as soon as i can, but the devices are at work.. so i guess it'll have to wait.. and the hardware is the same, those devices are used to test firmwares and applications
They look different because the design was still confidential
I know both devices will allow flashing the GED software, but i bricked 2 already it's a tricky flash procedure :/
Sent from my SM-T311 using xda app-developers app
karoolus said:
I'll try that as soon as i can, but the devices are at work.. so i guess it'll have to wait.. and the hardware is the same, those devices are used to test firmwares and applications
They look different because the design was still confidential
I know both devices will allow flashing the GED software, but i bricked 2 already it's a tricky flash procedure :/
Sent from my SM-T311 using xda app-developers app
Click to expand...
Click to collapse
Make backups of those partitions for us before you try any of this.
Next, Load the Google edition ROM.
So here would be my method for changing partition layout: boot to a custom recovery adb shell in. Copy the contents of /sbin/ to /system/sbin/. Make a backup using nandroid. Unmount /system/, use parted to resize system to the size in your pit. (You may have to mkfs ext2 before it will do this, if so, just mkfs ext4 after). Advanced restore your system backup to your now smaller partition. Now, dd all of the things after your system partition except the data partition to your sdcard or to your internal storage (risky, back these up to your computer just in case). Proceed to delete, readd, and dd restore all of the partitions until you get to the recovery partition, this is where it is tricky. Delete the partition before the recovery partition (noting the next available block.) Recreate the previous partition in the bounds of the recovery partition. DD the recovery image into that space. Recreate the previous partition again, where it should be. One of two things will happen here. Your pit will immediately take effect, overwriting the partition table, and you will have to boot to recovery, and DD restore your images and nandroid, or you it won't, and you will continue on. Now we need to be in normal mode again, so make sure your ROM is rooted. From the normal rom, delete the recovery partition, and move it to where it should be. Boot back to recovery now. Proceed to move the rest of the partitions, and restore your nandroid to restore the cache, etc.
Sent from my GT-I9505G
Could you please post dumps of the bootloader on the forum it could really help at the verizon s4 scene
Thanks!
You can get the pit by Heimdall. I suggest pulling this too because partitions for engineering devices could be different than release.
Sent from my SPH-L900 using Tapatalk 2
Could you post or pm me the links to the .pit and partitions
This will be amazing.. Hopefully we can get are much needed storage
Sent from my SGH-M919 using xda premium
rajat12345 said:
Could you post or pm me the links to the .pit and partitions
Click to expand...
Click to collapse
This THREAD have system dump wit pit included, also you can contact op of that thread as he stated that he is willing to provide any info.
cheers mate
That isn't the same file Is it?
Sent from my SGH-M919 using xda premium
Sent from my GT-I9505 using XDA Premium HD app
I have a i9505G and the bootloaders is still secure
the pic you sent look to be downloader mode
Send a pic of the screen when you do "adb reboot bootloader"
or hold both volup+voldwn during power up
when need to get that secure boot to disable
look at my Signature for how to dump your rom, that should help
since the partition layout may be different i would like to make sure.
btw are you sure you didn't just get a clone, there has been a few copies out know that look like the real thing.
warwolfx0 said:
I have a i9505G and the bootloaders is still secure
the pic you sent look to be downloader mode
Send a pic of the screen when you do "adb reboot bootloader"
or hold both volup+voldwn during power up
when need to get that secure boot to disable
look at my Signature for how to dump your rom, that should help
since the partition layout may be different i would like to make sure.
btw are you sure you didn't just get a clone, there has been a few copies out know that look like the real thing.
Click to expand...
Click to collapse
I'm sure that the partition layout between i9505 and i9505G are different, the pit files don't match!
I'll look into dumping the rom, although i have my hopes on some tool i found this weekend
and a clone ? dude, are you serious ? i've had these devices since somewhere in february..
karoolus said:
I'm sure that the partition layout between i9505 and i9505G are different, the pit files don't match!
I'll look into dumping the rom, although i have my hopes on some tool i found this weekend
and a clone ? dude, are you serious ? i've had these devices since somewhere in february..
Click to expand...
Click to collapse
Well i hope you can extract everything
karoolus said:
I'm sure that the partition layout between i9505 and i9505G are different, the pit files don't match!
I'll look into dumping the rom, although i have my hopes on some tool i found this weekend
and a clone ? dude, are you serious ? i've had these devices since somewhere in february..
Click to expand...
Click to collapse
Yes, get us some dd images by all means.
Sent from my GT-I9505G

[Q] Mlais MX28 mounting /system read-write

Please excuse asking questions as a first post, but I'm at the stage where I'm stumped and a search isn't helping.
Mlais MX28 fresh from MM pre-rooted. Managed to get the ROM backed up and CWM installed with Rua1's excellent MTK Droid Root & Tools. However, removing the Chinese useless (for me - no offence intended) apks proved not to be happening from the one-click button in that excellent piece of software. No bother, thought I, I'll just use adb and remove the relevant apks manually from /system/app. Famous last words.
Here's where things get really odd. I can mount root fine using the usual procedure but mount -o rw,remount /[email protected] /system works once and once only. Even stranger is that the first time gets you a rw mounted filesystem for about 10 seconds, at which point it gets remounted ro and no amount of faff will get it back to rw without a full power off and restart. All it does is spits out
Code:
mount: Read-only file system
Any ideas, please? I suspect there's some write protection going on but I haven't the first idea where to look.
Edit: Having done a little more searching on this issue, it seems there's a few Acers with the same behaviour, caused by a compiled-in kernel option. Looks like it may well be "wait for a custom ROM" is the answer. Not sure if rolling our own is possible unless anyone knows where to get the Mediatek sources for this device from?
Anyway, :good: to all those who have viewed my question. It's appreciated.
Edit 2: There's an S4UI ROM on needrom<dot>com that is rumoured to have solved this issue. Note that if you have installed CWM using the "magic" MTK Droid Root & Tools method, chances are you can't mount /system rw using ADB in CWM either - I suspect they share the same kernel. I haven't tried the S4UI ROM myself as the recovery needed to install it seems to be in Chinese. Possible solution for anyone with a grasp of that language and script but that someone isn't me
[Q] Mlais MX28 Recovery in Chinese Any help with translation
Hello, bud Any help yet also gut stuck in this.
I'm afraid not at the moment. The S4UI ROM on needrom does indeed enable /system rw but the WiFi and Bluetooth will not activate. Replacing mtk_stp_wmt.ko in /system/lib/modules/ with the version from the stock ROM that should fix this issue, doesn't fix this issue. It's a shame as the S4UI ROM is rather pleasant to use and if I could get that fully operational I expect I would be quite happy with this device. Oddly, the stock ROM came back with a different MAC for the WiFi. As I restored from a backup created with MTKDR&T, this is a little perplexing.
I'll update if I find any more clues.
{Possible solution/nasty hack]
Here's a way to get full /system access on the stock ROM. It requires
Clockwork Mod recovery
ADB
Courage
Install/create Clockwork Mod with MTKDR&T. Now boot into recovery by holding Vol+ and power until the boot selection screen appears and then select recovery with Vol+ and press Vol- to accept.
Do not mount /system in CWM.
On your ADB equipped computer, start
Code:
adb shell
Now issue the following at the root shell prompt:
Code:
tune2fs -e continue /dev/block/mmcblk0p5
Reboot the system and enjoy the power of full root.
This may well be a nasty hack. I was convinced the issue was a protected kernel module but it seems the ext4fs image of the system block is corrupt in some way and the default error action is to mount -o ro. We're disabling that default action and letting the mount remain unchanged.
As always with these things, proceed at your own risk. If you break it, you have the privilege of keeping both bits.
Good way around mate, but risky as no CWM yet installed, seem's the mobile gut some bug problem, should expect an official update rom soon enough, Root method you used for this? i intend flashing Clockwork Mod can seem to understand fully as i'm new to android development and customizing, again problem with battery do you get a full day (few moment on screen) light usage? Feel its no actual 25000mah on board.
codedmax said:
Good way around mate, but risky as no CWM yet installed, seem's the mobile gut some bug problem, should expect an official update rom soon enough, Root method you used for this? i intend flashing Clockwork Mod can seem to understand fully as i'm new to android development and customizing, again problem with battery do you get a full day (few moment on screen) light usage? Feel its no actual 25000mah on board.
Click to expand...
Click to collapse
It appears there's an fsck implementation in the shell of CWM as well.
Code:
e2fsck -pfv /dev/block/mmcblk0p5
That should fix most of the errors in the filesystem.
The device came with su and SuperSU installed but it was fairly useless without /system access.
CWM can be easily installed using MTK Droid Root & Tools to extract the boot image, auto-patch, build CWM and install the lot. It really is a slick piece of software.
As for the battery, an even bigger issue is the supplied charger which is puny. Of course, looking at the battery and then looking at a proper, honest-to-goodness 2.2Ah Panasonic 18650 cylindrical cell you have to wonder if 2.5Ah isn't awfully optimistic.
Chron0s said:
It appears there's an fsck implementation in the shell of CWM as well.
Code:
e2fsck -pfv /dev/block/mmcblk0p5
That should fix most of the errors in the filesystem.
The device came with su and SuperSU installed but it was fairly useless without /system access.
CWM can be easily installed using MTK Droid Root & Tools to extract the boot image, auto-patch, build CWM and install the lot. It really is a slick piece of software.
As for the battery, an even bigger issue is the supplied charger which is puny. Of course, looking at the battery and then looking at a proper, honest-to-goodness 2.2Ah Panasonic 18650 cylindrical cell you have to wonder if 2.5Ah isn't awfully optimistic.
Click to expand...
Click to collapse
Very Well concerned,
once again good job, but how do i go about implementing this,
would you be kind enough to put in some more details on the file system code and CWM flashing with MTK Droid root & Tool did you manage to get a translation on the chinese langauage recovery problem,
(a tutorial is just fine) Thanks alot bud.
Okay, give me a little time to set it all up for screenshots as I don't generally use Windows unless I have to. It's all fairly straightforward. The CWM installation is four clicks and some waiting and repairing the /system block is a couple of commands.
Oscarblue48 has a tutorial on installing CWM on Mediatek devices here or here if your MX28 isn't rooted which is the procedure I followed. Then it's just a case of booting into CWM, connecting your device to USB and using adb's shell to fsck the filesystem on that block.
really nice, okay as you say,
i would look forward to it (some screen shots aid), in the main time with full study & concentration on the CWM tutorial you gave, quite interesting if you ask me.
#back to studying, looking forward to a bug free final optimization of the Mlais MX28 as its a great buy for such a price.
codedmax said:
really nice, okay as you say,
i would look forward to it (some screen shots aid), in the main time with full study & concentration on the CWM tutorial you gave, quite interesting if you ask me.
#back to studying, looking forward to a bug free final optimization of the Mlais MX28 as its a great buy for such a price.
Click to expand...
Click to collapse
Sorry for the delay, I ran into a few issues and had to work out what was going on. Basically the e2fsck in CWM cannot write back to the block device so is useless. I extracted the system.ext4.img, added it as a file backed memory disk on my main computer and ran an e2fsck from there, which found and fixed the errors in the FS image. Writing that back after changing a few MD5sums in the file MTKDR&T creates allowed me to flash it back.
However it makes absolutely no difference to the mount behaviour. It still drops back to ro without the tune2fs -e continue set so that is, barring someone else coming up with a more elegant fix, the workaround. In a nutshell, follow the guide for either root or CWM recovery installation that others have posted linked above (no point wasting board space on repetition) and then simply follow my instructions for setting the error behaviour on the mmcblk0p5 slice and you should be good to go.
It's still an awful hack IMHO but, since there's nothing else so far that works, it's the uncomplicated way to get full root. Most of us will install CWM anyway, so it's no big chore just to boot into recovery and type one command "tune2fs -e continue /dev/block/mmcblk0p5" at the ADB shell.
Chron0s said:
Sorry for the delay, I ran into a few issues and had to work out what was going on. Basically the e2fsck in CWM cannot write back to the block device so is useless. I extracted the system.ext4.img, added it as a file backed memory disk on my main computer and ran an e2fsck from there, which found and fixed the errors in the FS image. Writing that back after changing a few MD5sums in the file MTKDR&T creates allowed me to flash it back.
However it makes absolutely no difference to the mount behaviour. It still drops back to ro without the tune2fs -e continue set so that is, barring someone else coming up with a more elegant fix, the workaround. In a nutshell, follow the guide for either root or CWM recovery installation that others have posted linked above (no point wasting board space on repetition) and then simply follow my instructions for setting the error behaviour on the mmcblk0p5 slice and you should be good to go.
It's still an awful hack IMHO but, since there's nothing else so far that works, it's the uncomplicated way to get full root. Most of us will install CWM anyway, so it's no big chore just to boot into recovery and type one command "tune2fs -e continue /dev/block/mmcblk0p5" at the ADB shell.
Click to expand...
Click to collapse
Greetings bud, gut CWM installed, all thanks to you (indeed greatful), have you been lucky with any custom rom as of now that works efficently on your device?
I seem to find a few bug here and there on the manufacturer stock, puny wifi & gps lock in, slight screen maulfuctions a little times.
As with most mtk gps can not finding a lock in hows it with your device.
codedmax said:
Greetings bud, gut CWM installed, all thanks to you (indeed greatful), have you been lucky with any custom rom as of now that works efficently on your device?
Click to expand...
Click to collapse
None of the custom ROMs on needrom work correctly which is a shame. The stock ROM's UI is awful.
codedmax said:
I seem to find a few bug here and there on the manufacturer stock, puny wifi & gps lock in, slight screen maulfuctions a little times. As with most mtk gps can not finding a lock in hows it with your device.
Click to expand...
Click to collapse
Now you have root you can use FasterGPS from FDroid to intialise the gps.conf file with appropriate settings for your location. My GPS is rock solid now, even in a moving vehicle. Not had any screen malfunctions. What version is your stock ROM? Mine's the 20140221 update.
Chron0s said:
None of the custom ROMs on needrom work correctly which is a shame. The stock ROM's UI is awful.
Now you have root you can use FasterGPS from FDroid to intialise the gps.conf file with appropriate settings for your location. My GPS is rock solid now, even in a moving vehicle. Not had any screen malfunctions. What version is your stock ROM? Mine's the 20140221 update.
Click to expand...
Click to collapse
Hello great bud,
Sorry for late reply, been up with alot on my plate from work lately, gps has been improved upon using that wonderful app "FasterGPS" now able lock in under a split couple of min not as before were it take like forever *Nice*
gut the same stock version "20140221" gusse its down to my own unit with the screen ish
Did a little searching around found a recent update from a online retailer outlet via their forum "merimobiles"
forum.merimobilesdotcom.previewdnsdotcom/showthread.php?465-Unified-thread -for-Mlais-MX28-stock-ROM-updates
Hope im not infringing on any xda TOS as i just seek some help.
Thanks
Please i need help, i have a mlais mx28 buy in buyincoins, with the refer gordete200, it´s all ok.
i´m very happy with the mlais mx28, but i used a 8 gigas sd card, it´s all ok.
My problem: i have install with flashtools the new rom stock update : mx28_0312_N2.rar from the official mlais mx28 web
When i have install this ultimate ( update ) ROM, it´s was with reebots, and the wifi and blutooth crash 0_0 !!! what happend?
I back to the Rom stock : 0115 but the sd partitions was changed : 1 gb for apps, and 1.75 gb for internal memory, it´s very strange, before install the Update, i had 2,3 gb for apps and 256 gb for internal memory...
I´m very worry, the actual problem is the sd card:
With 8 gb sd card class 10, it´s all ok, all correct, but when i put the 16 gb sd card class 10, it´s don´t mount sd correctly always.
I´m very crazy for all...
codedmax said:
Hello great bud,
Sorry for late reply, been up with alot on my plate from work lately, gps has been improved upon using that wonderful app "FasterGPS" now able lock in under a split couple of min not as before were it take like forever *Nice*
Click to expand...
Click to collapse
Good stuff. Once you have the gps.conf set up, try using Mobileuncle Tools to pull in the EPO (extended prediction orbit, basically a nice big list of keplers for the satellites so it knows which to expect to be in view at a given time without having to scan the sky for what's actually there) data which should stabilise the GPS even further.
codedmax said:
gut the same stock version "20140221" gusse its down to my own unit with the screen ish
Did a little searching around found a recent update from a online retailer outlet via their forum "merimobiles"
forum.merimobilesdotcom.previewdnsdotcom/showthread.php?465-Unified-thread -for-Mlais-MX28-stock-ROM-updates
Hope im not infringing on any xda TOS as i just seek some help.
Thanks
Click to expand...
Click to collapse
I wonder if it's the bodged Trebuchet they're using? It's a bit of a disaster as they've taken the CM launcher, bodged bits of MIUI into it and given the whole thing a "that'll do" look and feel. I replaced it with the real Trebuchet after a thorough decrapify, along with the AOSP stock keyboard. There's a "modified" apk of Trebuchet (all the dev did was lower the base API level so it would install on 4.1) floating about on the 'net somewhere. The various KitKat-alikes work fairly well but I wanted something open source that I could slam into /system/app without worrying.
It has taken a lot of faff to get to this stage but I now have a very usable and fast device for not a great deal of outlay.
gordo100 said:
Please i need help, i have a mlais mx28 buy in buyincoins, with the refer gordete200, it´s all ok.
i´m very happy with the mlais mx28, but i used a 8 gigas sd card, it´s all ok.
My problem: i have install with flashtools the new rom stock update : mx28_0312_N2.rar from the official mlais mx28 web
When i have install this ultimate ( update ) ROM, it´s was with reebots, and the wifi and blutooth crash 0_0 !!! what happend?
I back to the Rom stock : 0115 but the sd partitions was changed : 1 gb for apps, and 1.75 gb for internal memory, it´s very strange, before install the Update, i had 2,3 gb for apps and 256 gb for internal memory...
I´m very worry, the actual problem is the sd card:
With 8 gb sd card class 10, it´s all ok, all correct, but when i put the 16 gb sd card class 10, it´s don´t mount sd correctly always.
I´m very crazy for all...
Click to expand...
Click to collapse
Do you have a backup of the original ROM and scatter (partition layout) file? You really should (read: MUST) back up these devices before flashing new firmware as there's often bits missing, as you found with the WiFi and Bluetooth issue. MTK Droid Root & Tools will create a useful backup of the partition layout and contents for you without too much difficulty.
Please do not write to the preloader partition with the SP flash tool. Once the preloader is corrupt, your device is a brick which only JTAG will recover. I seriously doubt anyone has a JTAG solution for this device right now. There is no need to rewrite the preloader at all in any case so simply deselect the preloader block in SP Flash tool before downloading.
As for the SD cards, you need to make sure your card is formatted FAT, not NTFS, and the card must be partitioned correctly, i.e. the FAT partition must be the first primary. The MX28 will accept a card of up to 32GB if I recall correctly, which is the limit of SD-HC. Clockwork Mod can format your card for you.
Chron0s said:
Do you have a backup of the original ROM and scatter (partition layout) file? You really should (read: MUST) back up these devices before flashing new firmware as there's often bits missing, as you found with the WiFi and Bluetooth issue. MTK Droid Root & Tools will create a useful backup of the partition layout and contents for you without too much difficulty.
Please do not write to the preloader partition with the SP flash tool. Once the preloader is corrupt, your device is a brick which only JTAG will recover. I seriously doubt anyone has a JTAG solution for this device right now. There is no need to rewrite the preloader at all in any case so simply deselect the preloader block in SP Flash tool before downloading.
As for the SD cards, you need to make sure your card is formatted FAT, not NTFS, and the card must be partitioned correctly, i.e. the FAT partition must be the first primary. The MX28 will accept a card of up to 32GB if I recall correctly, which is the limit of SD-HC. Clockwork Mod can format your card for you.
Click to expand...
Click to collapse
Many thanks for your help. I have a back up of my mlais, i have a back up with mtk droid and tools 2.5.3 ( new version ), but when i put it on the flash tools, the cache and user is missing, and it´s imposible to download it. and then i put a recovery CWM on the mlais with droid and tools ( very easy ), and use a nandroid back up, it´s no problem, but the internal sd partition is always changed : 1 gb for apps and 1.75 for sd internal, i´m very sad because i would like back to the 2,3 gb for apps ( original partition )
Yes... always fat32 sd cards of course, but i have problems with the sd up to 8 gb, the mlais freeze, or sd desmount ( it´s imposible sometimes write in sd external ) i don´t find the problem with this... i have the rom stock : 115.
Other problem, i would like to up the ultimate ROM stock 221. but the wifi and bluetooth crash, and reboot the phone sometimes ( terrible...) , what can i do ? your solution is don´t stick the PRELOADER on the Flashtool when i upload the firmware ? it´s correct? ( i think that if don´t mark the preloader it´s imposible flash... ?¿ )
Many thanks for your help !
gordo100 said:
Other problem, i would like to up the ultimate ROM stock 221. but the wifi and bluetooth crash, and reboot the phone sometimes ( terrible...) , what can i do ? your solution is don´t stick the PRELOADER on the Flashtool when i upload the firmware ? it´s correct? ( i think that if don´t mark the preloader it´s imposible flash... ?¿ )
Click to expand...
Click to collapse
No, what I'm saying is we don't yet know why the WLAN and Bluetooth stop working when a different ROM from the one flashed at the factory is installed. There is clearly some mechanism at work here that is blocking those two devices after an update and it's not the usual shared objects as it is on other devices. It also doesn't seem to be NVRAM related as the MAC and BDaddr remain once the old firmware is re-flashed.
This same problem occurs with all the custom ROMs on needrom.
The reason I say do not needlessly flash the preloader is the danger of a full brick from which you cannot recover. The preloader code very rarely changes - its only purpose is to provide an interface to SP flash tools or boot; think "BIOS" in PC terms - so it is a pointless risk. You most certainly can flash the other blocks with the preloader block deselected.
The bottom line right now is stick with the factory ROM, install CWM, apply the system mount fix and use Xposed and suchlike to customise until we come up with something a little more sensible or at least find out why the WLAN and Bluetooth stop working.
Given that the Wiko Darkmoon is based on the same SoC and has full sources available <EDIT: It isn't. It's just the kernel as usual.>, it may be prudent to wait until someone with more clue than I has a look at what makes these things tick.
Chron0s said:
No, what I'm saying is we don't yet know why the WLAN and Bluetooth stop working when a different ROM from the one flashed at the factory is installed. There is clearly some mechanism at work here that is blocking those two devices after an update and it's not the usual shared objects as it is on other devices. It also doesn't seem to be NVRAM related as the MAC and BDaddr remain once the old firmware is re-flashed.
This same problem occurs with all the custom ROMs on needrom.
The reason I say do not needlessly flash the preloader is the danger of a full brick from which you cannot recover. The preloader code very rarely changes - its only purpose is to provide an interface to SP flash tools or boot; think "BIOS" in PC terms - so it is a pointless risk. You most certainly can flash the other blocks with the preloader block deselected.
The bottom line right now is stick with the factory ROM, install CWM, apply the system mount fix and use Xposed and suchlike to customise until we come up with something a little more sensible or at least find out why the WLAN and Bluetooth stop working.
Given that the Wiko Darkmoon is based on the same SoC and has full sources available <EDIT: It isn't. It's just the kernel as usual.>, it may be prudent to wait until someone with more clue than I has a look at what makes these things tick.
Click to expand...
Click to collapse
Many thanks Chronos!, The problem is also with the official ROMS on mlais.com/mlaismx28 i don´t understand it...
Please i need help to back restore the partitions of my sd internal ( ROM ), i would like back to 2,3 gb for apps, actually i have only 0,98 gb and 1,75 gb internal store.
I think that the solution is back up for flash tools and reflash with the rom stock ( the back up of mlais mx28 of my friend, he have other new mx28 )
But my BIG problem with the flash with flash tools is the USER DATA and CACHE is always empty, and then it´s imposible to reflash it it´s always and error : Rom changed PTM ...
Please, what can i do for have USER DATA and CACHE with mtk droid and tools 2.5.3 versión?? ( in this version to click User data and Cache with to do the back it´s imposible, this option is missing in 2.5.3. version )
http://dl.xda-developers.com/attachdl/b2f11c741aab592a8f66616d932af983/533c2dcc/2/6/6/4/5/2/2/Sin_t_tulo.jpg
[ROM] Official Update
Hello guys, there's a new rom update for the mx28
Official Mlais MX28 version: Mlais_MX28_20140312
www.needrom.com/mobile/mlais-mx28-2/
Try it out seems, it works perfect.
Cheers!!

Recovery as a another operating system?

Hey everybody!!! I was just wondering to myself, is it possible that someone out there will make an android recovery which will work just like the actual operating system?
I mean that when you would boot into recovery - you will see a homescreen with apps you can tap on and open - just like android.
Soooooo is it possible? And if it is - is there anyone out ther willing to do it? Because it will be awesome!!!!!!!!!!! ( i know it's like dual boot, but it's cooler!!!!)
because the partition of recovery is too small, we can't put full features os like android into recovery partition
Sent from my Redmi 2 using Tapatalk
Maybe with root rights you can change that partition? I'm nearly 100% sure it's possible
The recovery is already a separate operating system. However it's not Android - as other users have pointed out, there is no space for a second Android system on a normal device.
Most devices have two boot images that each contain a Linux kernel and a ramdisk image - one boot image for Android, one for the recovery. The bulk of the Android OS is on a separate /system partition. Recovery runs fully from the ramdisk.
If you have a storage device (like a microSD card) with additional free space, then it is possible to create separate /system and /data partitions there for a second independent OS. You could use the recovery boot image to boot that OS, but you may still need a recovery, so you'd need to add some code in your secondary boot image to switch between recovery and your secondary OS.
So... is it possible? Yes. Will I do it? No.
Thanks for the answer and clarification!!!
And if you could help me a bit more: do you know of some kind of dual - boot development project which has already been started for the gs5? I have a micro sd card and am flabberghasted by the idea of two OSs on one device. Thanks!!!
You can try this http://forum.xda-developers.com/showthread.php?t=2447534
Thanks!

Categories

Resources