SM-J100VPP experimental flashing with Odin - Samsung Galaxy J1 ROMs, Kernels, Recoveries, & Oth

Yes I still have this cheap little phone. It is a pain in my ass, but that's why I love it. It creates a challenge for me. I have been experimenting with flashing different system image firmwares, and the rest of the required files without bricking the device and having to start over. A couple of key points, you cannot unpack any of the images at it then, then repack them and Flash the device. Because of the secure boot being enabled, anything that isn't signed or has the same signature affiliated with it as the original firmware, will immediately fail flashing. Though I'm not sure it is so much a issue with signatures as it is with binaries and not being able to flash from, for example ver 4 to ver 3. Or so I thought. Because of the amount of aggravation this device poses even when rooted oh, I have been trying to find ways around flashing original system images to it without triggering a secure authorization fail. So far I have been able to take all of the images from a SM-J100VV, to my J100VPP except for the boot.img and aboot. Neither of those will flash successfully on the device if they come from another. All the other images do flash so long as you do not unpack them and repack. So you can take the system.img.ext4, and extract it from the firmware file for the J100VV, as well as the rest of the images not including the two named above and successfully flash them to J100VPP. And everything is in working order it. Now I'm trying to experiment further and see what else I am able to flash as well. There are several reasons why I think this works. If you look at the build prop for J100VPP, it's literally named four or five different things. the official device code is j1qltevzw. Until I see otherwise I assume that a system image that remains unmodified from one J1 device can potentially flash to the J100VPP. Simply extract all of the images from the firmware file and individually archive them as a .tar and Flash in Odin. Unless you screw around with anything else you shouldn't have to crash the device in the first place , you will not need to flash the boot.img or aboot. Seeing as this is a system root I'm hoping I can either go up or down an Android version at least one stop in either direction. I also cannot get xposed to successfully flash on this device without it bricking. I have tried every Xposed installer I come across to no avail. However virtualxposed dogs work on this device however I've been having trouble getting modules to function properly if at all. But that's beside the point since it's a virtual machine environment you pretty much are operating in a whole new operating system on the side of Android. It's almost like having BlueStacks on a Windows machine. Anyways what I'm trying to get across is potentially very much improving this device a by being able to flash on modified system images from other J1 devices. I know this phone is well past its prime but it still doesn't hurt to experiment.

Related

[Q] recovery.img and recovery-from-boot.p

Hi all,
I am trying to make sense of how the android system is made up w.r.t to boot/kernel.
I have been looking at the .img files in the build (I built for the "passion" device), and have been googling around to find some more information about the various .img files.
I ran into a nice HOWTO in android-dls.com 's WIKI, titled HOWTO:_Unpack%2C_Edit%2C_and_Re-Pack_Boot_Images (I'm sorry, I'm a new user so XDA won't allow me to post links. I will try to modify my post a soon as I'm granted permission for that)
but I am afraid it is a little outdated:
I have several questions, but I will try to be brief, so I'll focus on
one of them, and if that works I'll proceed to the next questions, all related to "Android bringup for dummy embedded linux kernel experts".
I am fairly aware of differences between different linux
configurations, and I am very familiar with linux bringup concepts, so I will just use common examples from the linux world as my terminology. Hope it will be clear enough.
I understood that boot.img a combination of a kernel (e.g. bzImage in linux) and an initial ramdisk (e.g. initrd.gz), wrapped by some header, as in common linux kernel loading practice (piggy.o etc.).
Now, the aforementioned HOWTO says that the "recovery" image is built on
the same way, and that it is stored on the target's /system/
recovery.img .
I would assume that this would be compound of the ramdisk-
recovery.img, and some other kernel.
Now, the problem is that:
1. This /system/recovery.img does not exist from what I saw (on my
Motorola XOOM tablet)
2. What does exist is /system/boot-from-recovery.p , which is
created during the boot process in obj/PACKAGING/
recovery_patch_intermediates/recovery_from_boot.p .
I saw tons of posts referring to the files, all said that "in order to
replace the rescue disk image, this file needs to be renamed" - but I
am looking for a way to figure out what it is, and how to extract its
contents.
I assume /system/recovery.img is deprecated, is that correct?
3. I did not see any flash devices in /proc/mtd (which is strange).
I searched for hours before sending this post, so I would appreciate
your help. I also posted a similar message at the google android-building group, but it has not been answered yet, and I got the impression that these forums are more active and can help me get where I need.
If it is not the right place to ask the question please let me know -
I just assume this is a general android concept and not device
specific.
Thanks,
Ron
I meant of course /system/recovery-from-boot.p , and not recovery-from.boot.p
-R
Hi,
I don't know if you managed to find out what "recovery-from-boot.p" is, since this is quite an old post, but I think I'll try to help anyway.
recovery.img is not deprecated at all. From my own experience, it looks like "recovery-from-boot.p" is a protection measure introduced in Gingerbread, but not the recovery itself. What it does is replacing any recovery currently installed on the phone with the default one on every boot.
I discovered it after flashing a custom recovery on my Android 2.3.4 phone. It worked, but just during the first boot. The next time I rebooted the phone, the default recovery image was there again. After browsing several sites, I found that "recovery-from-boot.p" is responsible for that.
So, if you flash a custom recovery image on a Gingerbread phone and want to keep it forever, you must delete this "recovery-from-boot.p" from /system, or at least rename it. That way, your new custom recovery will never get overwritten buy the default one, unless you do it yourself.
I hope this helps you and clarifies this question.
Well, it helped me. I'm new to rooting and just came across mention of this file. I am trying to learn 'why' as well as 'how'', so your post was informative.
Was going to ask a dumb question but I figured it out
i need to delet those files
bigrammy said:
Was going to ask a dumb question but I figured it out
Click to expand...
Click to collapse
Hello
can't delete those files >> i am rooted but every time i delete or rename it take permission then nothing happen >> how i can delete them plsssssssssssssssssssssssssssssssssssssss
recovery from boot p
ahmed morsy said:
Hello
can't delete those files >> i am rooted but every time i delete or rename it take permission then nothing happen >> how i can delete them plsssssssssssssssssssssssssssssssssssssss
Click to expand...
Click to collapse
Hey good day. Did you get your problem fixed...? I have an xt912 it has the same file. For days I've been trying to wipe the phone. Tryed rooting it. I tryed reprogramming it. And I got through with all of that. But everytime the phone boots up it goes back to the same state. Then I used a root browser and while exploring I saw this recovery from boot file. I need help. And I don't think I can downgrade the Motorola phones. Thanks in advance.
jman0 said:
Hi,
I don't know if you managed to find out what "recovery-from-boot.p" is, since this is quite an old post, but I think I'll try to help anyway.
recovery.img is not deprecated at all. From my own experience, it looks like "recovery-from-boot.p" is a protection measure introduced in Gingerbread, but not the recovery itself. What it does is replacing any recovery currently installed on the phone with the default one on every boot.
I discovered it after flashing a custom recovery on my Android 2.3.4 phone. It worked, but just during the first boot. The next time I rebooted the phone, the default recovery image was there again. After browsing several sites, I found that "recovery-from-boot.p" is responsible for that.
So, if you flash a custom recovery image on a Gingerbread phone and want to keep it forever, you must delete this "recovery-from-boot.p" from /system, or at least rename it. That way, your new custom recovery will never get overwritten buy the default one, unless you do it yourself.
I hope this helps you and clarifies this question.
Click to expand...
Click to collapse
i have deleted it . then flash recovery ,, but it failed .. it wont even now go to stock recovery itself.. any help..
Does recovery from boot has to do anything with ota update applying ? or it will cause issues in system update ?
I have recovery-from-boot.p in my system and i cant root my phone i cant change the recovery img ... Help?
I hadn't had to deal with this for some time, perhaps because I've updated my devices (Nexus 4, Nexus 5, Nexus 7 '13) with the factory images, with "-w" removed from flash-all, then flashing CWM's recovery, ensure SuperSU was installed, then continuing. Today, I used the new OTA image on my Hammerhead/N5, and recovery-from-boot.p seems to be up to its old tricks again.
Solution is simple.
Flash your alternate Recovery in fastboot, fastboot flash recovery [recovery image file] . Boot into Recovery. Apply/install root app (typically via sideload). Mount /system. adb shell mv /system/recovery-from-boot.p /system/recovery-from-boot.p.bak. Reboot. Done. (If you're unfamiliar with fastboot, adb, and flashing new recovery partitions, you have some reading to do. Commence RTFM.)
I also used to have to move /system/etc/install-recovery.sh but that seems to be gone in Marshmallow. :} Or moved...?
well, after following a guide I have extracted the system.img from a pure-nexus ROM(The ROM I'm currently using), now I can see that "recovery-from-boot.p" file is responsible for recovery lock in my phone. I'll keep it short and straight to the question
"Can I remove this file and rebuild the .dat file and flash it?, so that I won't have any other problems at all"
I want to know if recovery-from-boot.p file is linked to anything other than just locking the recovery or re-flashing it innumerable times.

[Q] 100% Original Stock ROM backup before root?

Hi there,
I am new to xda and new to Android hacking.
What I wanna ask is, (I guess it's of most newbies concern as well), can we have a 100% backup of our system (stock ROM)? Obviously, it is important because:
If we perform an official (OTA) update to a new Android version. And we don't like it. It is possible to get back to the old original one which we are used to. (not everybody likes new things, and/or not every new thing is good)
If our phones are having some problems. And we have to give it back to the company for a fix. In most cases they will flash a new ROM for us. If we wanna keep using the old one (explained in #1), we have to keep a copy of it by ourselves.
If we want to try new custom ROMs, we may want to switch it back after trying.
Whenever we do any modifications, it's always better to keep a backup/roll-back point. In case anything goes wrong, we have a safeguard.
For the official warranty issue.
Yup I do see there are some official stock ROMs downloads for some particular phones. But those are not really a backup of our original ROMs. And it's always hard to verify if those downloads are the original official releases. And, if those downloads are 100% stock ROMs, this means some guys out there could make it, so what is the way to do so?
Or, how those mobile phone companies do it in their labs?
I have been doing researches on this topic for a few days. Some posts claim that their methods are "backup stock ROM" or "backup before rooting". But after digging into it, they requires rooting and/or flashing CWM. Here comes a few questions:
Questions
Rooting will in fact changes some files/data of the system. So backup after root is NOT getting the original stock ROM. Is it?
Is there a method to "un-root", so ALL the changes are TOTALLY reverted?
Installing/flashing things like CWM in phone requires rooting, which would make the ROM not original. Is there a way to extract the system backup from a computer externally?
In addition, I have found some related pieces. which could be useful to anyone viewing this post, and might be useful for you to solve this (my) question. :fingers-crossed:
* as I'm a new user, I can't post links directly. Please delete the blank spaces in between.
ht tp://www .modaco .com/topic/351269-backup-original-rom/
In reply #5, user C3C0 raised a method of backing up the original stock ROM without root. But it seems he is flashing CWM and that method is only for ZTE Skate.
adb backup tool of Android SDK
At the first sight i came across this approach, I thought it is the official method to do whole system (ROM) backup (WOW - how nice!). But after studying for a few more posts, I think adb backup can only backup app+app_data, and possibly some system settings only. Am I correct? And also, adb backup is only for ICS (Android 4.0), isn't it?
adb backup usage: ht tp://forum.xda-developers .com/showthread.php?t=1420351
(But mentioned in the bottom of #1 the poster is having some issues on using adb backup. Perhaps there are some bugs and not reliable(?)
One more question on adb backup: Can it backup just one app+app_data, and restore just one app+app_data, without affecting other things? If yes, we don't need to root and don't need Titanium Backup (which requires root) for backup app+app_data. Isn't it?
** In case I have said anything or any terms wrongly in this thread, please DO correct me, for helping me and helping others.
P.S. i am using LG Optimus 3D.
Thanks a lot, wholeheartedly,
midnite_
Backup phone before root
Hello all this is my first post here...woohoo!:fingers-crossed: This forum is amazing as to the amount of information available. I just wish that in looking for what I need to do I did not need to look in so many places. I feel that if I want to root my T-Mobile GS3 that all the information should be in one subsection of the forum, but it is not that simple I guess....lol Anyway any help would be greatly appreciated.
I have a Samsung GS3 with T-Mobile that I want to root. Everyone says to back up the phone before you do it but I am not really seeing how to make a backup before I start. It appears that most of the guides to root just say to backup without telling you how to fo it. Another thing (correct me if I am wrong) I see the nandroid backup that I think is a backup of the phone however it seems to be done after you make changes to the phone and I thought the backup was supposed to be done before you do anything. Is it that there is not a way to make a complete backup with an unrooted phone?
My question is basically the same as the OP here. I have been reading and reading and reading posts here in the forum. There is much information here and much of it is duplicated with slight variances in some of the duplicates. I am not certain as to which rooting method I should use. There seem to be so many choices. As a new person to this forum I will say that you can find just about everything about any phone which is awesome. The hard thing is sifting through the many options to pick one to use for your issue.
I do see that Mr. Robinson has a thread with backups of the original roms. The only thing is that they are default roms that are like an out of the box phone and not my phone with my apps and my settings. That is what I want to backup...My phone with my settings and my apps.
:good: Thank you in advance for any one that can shed some light on this for me and the OP'er
ASharpEdge said:
Hello all this is my first post here...woohoo!:fingers-crossed: This forum is amazing as to the amount of information available. I just wish that in looking for what I need to do I did not need to look in so many places. I feel that if I want to root my T-Mobile GS3 that all the information should be in one subsection of the forum, but it is not that simple I guess....lol Anyway any help would be greatly appreciated.
I have a Samsung GS3 with T-Mobile that I want to root. Everyone says to back up the phone before you do it but I am not really seeing how to make a backup before I start. It appears that most of the guides to root just say to backup without telling you how to fo it. Another thing (correct me if I am wrong) I see the nandroid backup that I think is a backup of the phone however it seems to be done after you make changes to the phone and I thought the backup was supposed to be done before you do anything. Is it that there is not a way to make a complete backup with an unrooted phone?
My question is basically the same as the OP here. I have been reading and reading and reading posts here in the forum. There is much information here and much of it is duplicated with slight variances in some of the duplicates. I am not certain as to which rooting method I should use. There seem to be so many choices. As a new person to this forum I will say that you can find just about everything about any phone which is awesome. The hard thing is sifting through the many options to pick one to use for your issue.
I do see that Mr. Robinson has a thread with backups of the original roms. The only thing is that they are default roms that are like an out of the box phone and not my phone with my apps and my settings. That is what I want to backup...My phone with my settings and my apps.
:good: Thank you in advance for any one that can shed some light on this for me and the OP'er
Click to expand...
Click to collapse
Hi ya,
It's so nice that you are having the same concern as I do.
As far as i know, the approaches of rooting differ from phones to phones. So we may have to find our own specific rooting method in the phone model sub-forums. It won't be hard for your popular S3
I would like to have a look at that Mr. Robinson's thread. If he can backup the stock ROM, those app+app_data wont a big issue (i guess).
cheers,
midnite_
midnite_ said:
Questions
Rooting will in fact changes some files/data of the system. So backup after root is NOT getting the original stock ROM. Is it?
Is there a method to "un-root", so ALL the changes are TOTALLY reverted?
Installing/flashing things like CWM in phone requires rooting, which would make the ROM not original. Is there a way to extract the system backup from a computer externally?
Click to expand...
Click to collapse
Hi midnight, welcome to a new and exciting world of Android and trying new things. First, let me assure you, what you want is NOT something new. People have been doing this type of thing for years. That is flashing and testing roms. As you will learn, it actually becomes quite addictive. We call those folks that get addicted to flashing: Flashaholics or crackflashers, lol
First let me talk about "root". This process consists of unlocking a lower level of the Android system known as the bootloader. Unlocking the bootloader of your device allows you to flash a custom recovery, flashing a custom recovery allows you to flash the Superuser binary and Superuser.apk, This is what allows you to use apps that require "root". The bootloader is not an OS file. So when you are unlocking your bootloader you are not modifying your stock rom. Only when you have flashed the Superuser package have you modified your stock rom. And even that isn't really modifying anything. When you flash the Superuser package, it adds two files to your rom at certain locations of the file system. It adds the Superuser.apk file to system/app and it adds the SU binary to system/bin. Basically you CAN have a totally S-OFF (unlocked) bootloader and still have an entirely stock rom if you want. But the real benifit is flashing a custom recovery like ClockworkMod Recovery and then flash the superuser package.
As far as extracting the stock system, you should try giving adb a go. Do it right now if you like. Ensure you have the android sdk installed and properly set up on your computer and your computer can recognize your phone. Ensure your phone is in debugging mode, connect your phone to your computer, open up a command window, and run this command:
Code:
adb pull \
This command will pull everything off your phone except for data which is where your market or Google Play apps are stored.
Beyond XDA there are aso more resources to learn from. For example, http://www.android.com is a good place to start, and to learn more about adb check out http://developer.android.com/tools/help/adb.html
If you need to learn how to setup the sdk here is the place to learn how: http://developer.android.com/sdk/index.html
I'm sure others will add to this as well which is the good thing about this community.
Welcome to XDA, I hope you have fun learning, and maybe share back someday things you learn along the way.
wildstang83 said:
Hi midnight, welcome to a new and exciting world of Android and trying new things. First, let me assure you, what you want is NOT something new. People have been doing this type of thing for years. That is flashing and testing roms. As you will learn, it actually becomes quite addictive. We call those folks that get addicted to flashing: Flashaholics or crackflashers, lol
First let me talk about "root". This process consists of unlocking a lower level of the Android system known as the bootloader. Unlocking the bootloader of your device allows you to flash a custom recovery, flashing a custom recovery allows you to flash the Superuser binary and Superuser.apk, This is what allows you to use apps that require "root". The bootloader is not an OS file. So when you are unlocking your bootloader you are not modifying your stock rom. Only when you have flashed the Superuser package have you modified your stock rom. And even that isn't really modifying anything. When you flash the Superuser package, it adds two files to your rom at certain locations of the file system. It adds the Superuser.apk file to system/app and it adds the SU binary to system/bin. Basically you CAN have a totally S-OFF (unlocked) bootloader and still have an entirely stock rom if you want. But the real benifit is flashing a custom recovery like ClockworkMod Recovery and then flash the superuser package.
As far as extracting the stock system, you should try giving adb a go. Do it right now if you like. Ensure you have the android sdk installed and properly set up on your computer and your computer can recognize your phone. Ensure your phone is in debugging mode, connect your phone to your computer, open up a command window, and run this command:
Code:
adb pull \
This command will pull everything off your phone except for data which is where your market or Google Play apps are stored.
Beyond XDA there are aso more resources to learn from. For example, ht tp://www .android .com is a good place to start, and to learn more about adb check out ht tp://developer .android .com/tools/help/adb.html
If you need to learn how to setup the sdk here is the place to learn how: ht tp://developer .android .com/sdk/index.html
I'm sure others will add to this as well which is the good thing about this community.
Welcome to XDA, I hope you have fun learning, and maybe share back someday things you learn along the way.
Click to expand...
Click to collapse
Hi Wildstang,
Thanks very much for your warm welcome and very informative reply. So are you a Flashaholics or Crackflashers yet?
As I am a newbie, please forgive me if I am asking dumb questions.
As far as I understand,
The steps of root is
1. Unlock the bootloader
2. Flash Superuser binary & Superuser.apk
** does "flash a custom recovery" means "flash Superuser binary & Superuser.apk"?
"Flash Superuser binary & Superuser.apk" is just "add SU binary to system/bin" and "add Superuser.apk to system/app". Then why not just copy them into place?
I just found on the web that "flashing" means replacing the OS of the phone with a new ROM. Would that still keeping the stock ROM?
To have a backup of the original stock ROM, can I
1. Unlock the bootloader
2. Flash Superuser binary & Superuser.apk
3. Perform the backup
And later, after I have flashed a new ROM, or whatever I do, as long as I didn't brick it, when I want to rollback my phone to its original, I can
1. Restore the backup
2. Delete "SU binary in system/bin" and "Superuser.apk in system/app"
3. re-lock the bootloader
Is this correct?
I don't mean to challenge you. But does adb pull \ really backup the system, or just all the files?
Thanks very much again!
midnite_
Hey midnite_,
I am a newbie too and have a lot of blank spots in my understanding of what we can do with android. I also came here with same question. I found how to root, this isn't a secret. Like you, I want to know how do I fix it if I break it.
So, with regards to your questions.
1. Unlock the bootloader
Not clear on this one, as not every tutorial even mentions this part. My feeling is that this might be specific to some phones, like HTC.
2. Flash Custom Recovery (such as AmonRa, CWR, TWRP...)
Recovery is an intermediate stage of phone booting process after bootloader but before OS.
It is there to allow OTA (Over the air) updates. During those, the OS is halted and replaced with a newer one.
What this means for us is that the recovery is capable of replacing OS (ROM - are these terms interchangeable?).
Recovery is the same as hidden partition on windows, that is sometimes present on a PC. It has a limited interface.
It can replace one OS image with another. It probably checks the checksum and creates the new one after the update. It is probably the gatekeeper.
Stock recovery will not replace OS with an image from SD card or from PC through USB. Only OTA.
This is the reason for flashing the custom (hacked) recovery on.
Custom recovery is made to allow additional options, such as allowing image sources such as PC or SD card, and also a ROM backup (write OS image to PC).
3. Flash update file using "upgrade from SD card" function of custom recovery now in place.
In this step, the Superuser.apk and bin files are placed. Stock recovery will not let us do that.
Also, I think the reason we can't just use ADB to "copy" superuser package to phone is because the system is either running or exists as an image (compressed?), and is probably protective of its modification. (So, likely the superuser package also replaces the checksum that the OS uses to check if it has been compromised?) Yes, this modifies your rom.
I assume that unrooting could be done after this by updating again with a file that removes superuser package and that would make your rom stock again.
4 OR flash custom ROM, which usually includes superuser package. Of course using custom rom means you no longer have stock rom.
To have a backup of original ROM, you would :
1 Unlock bootloader,
2 Flash (install) custom recovery
3 superuser doesn't matter here
4 Use custom recovery function to back up your stock ROM.
I want to know the answers to the rest of your questions as well as some clarifications to mine.
Personally, I am looking for a way to backup the stock recovery as well.
I know there are some people asking about this. The procedure appears to be as follows:
(pieced together so don't take it as a tutorial)
1 Unlock bootloader (again, unclear on this. Also some mention S-OFF and others don't)
2 With USB debugging allowed (meaning connect as device requiring a driver), Connect to a PC with ABD, and a driver installed.
3 From ADB, issue a command "adb boot recoveryimage.name" instead of the usual "adb flash recoveryimage.name".
This will make the phone boot into a custom recovery image that is residing on PC, without first writing it to the phone.
4 Unclear how, but make that custom recovery now being live to back up stock rom to pc.
5 Unclear how, but make that custom recovery now being live to flash either root or custom rom to the phone.
6 Disconnect, reboot the phone. Once in OS, use root privileges to mount recovery partition ? (this makes it visible as drive)
7 Don't know how, but use root privileges to back up now visible stock recovery partition to PC as image.
( This should give you two out of three original parts.)
Keep in mind that even if my peace-by-peace "know-how" ever works, there is at least one clearly faulty step:
The back up of the original state of the boot loader has been never made. I do not know if it is easily can be toggled back and forth from lock to unlock and back without leaving any trace. Also, like yourself, I probably don't quite understand what am I talking about, but I have tried to make as much sense of what I have read here and there.
This is my first smart phone, and my experience with linux is limited to building a minecraft server on MineOS, which was pre-made so that not much was required to make it run. I have "mounted" a partition for the first time last week, trying to break Win7recovery, booting it with Knoppix. This is why I think this is probably will come in play here too, as the recovery partition on W7 was hidden. Until then I didn't understand what mounting means, as windows always does it for you. So, take everything I say with a bunch of salt.
Please, let me know too, if you find out more. I want to flash the hell out of my Prism, but I want to be smart about it.
bump... midnite_ r u still around?
Hi Descent2,
Yes i am still around but i am busy with other stuffs at this moment. Thanks very much for your reply. You have studied a lot and you really did good summarisations. Very informative and I learnt a lot from it. Hope some of the masters or experienced ones would come by and bring us out of the mist
cheers,
midnite_
Descent2 said:
Hey midnite_,
I am a newbie too and have a lot of blank spots in my understanding of what we can do with android. I also came here with same question. I found how to root, this isn't a secret. Like you, I want to know how do I fix it if I break it.
So, with regards to your questions.
1. Unlock the bootloader
Not clear on this one, as not every tutorial even mentions this part. My feeling is that this might be specific to some phones, like HTC.
2. Flash Custom Recovery (such as AmonRa, CWR, TWRP...)
Recovery is an intermediate stage of phone booting process after bootloader but before OS.
It is there to allow OTA (Over the air) updates. During those, the OS is halted and replaced with a newer one.
What this means for us is that the recovery is capable of replacing OS (ROM - are these terms interchangeable?).
Recovery is the same as hidden partition on windows, that is sometimes present on a PC. It has a limited interface.
It can replace one OS image with another. It probably checks the checksum and creates the new one after the update. It is probably the gatekeeper.
Stock recovery will not replace OS with an image from SD card or from PC through USB. Only OTA.
This is the reason for flashing the custom (hacked) recovery on.
Custom recovery is made to allow additional options, such as allowing image sources such as PC or SD card, and also a ROM backup (write OS image to PC).
3. Flash update file using "upgrade from SD card" function of custom recovery now in place.
In this step, the Superuser.apk and bin files are placed. Stock recovery will not let us do that.
Also, I think the reason we can't just use ADB to "copy" superuser package to phone is because the system is either running or exists as an image (compressed?), and is probably protective of its modification. (So, likely the superuser package also replaces the checksum that the OS uses to check if it has been compromised?) Yes, this modifies your rom.
I assume that unrooting could be done after this by updating again with a file that removes superuser package and that would make your rom stock again.
4 OR flash custom ROM, which usually includes superuser package. Of course using custom rom means you no longer have stock rom.
To have a backup of original ROM, you would :
1 Unlock bootloader,
2 Flash (install) custom recovery
3 superuser doesn't matter here
4 Use custom recovery function to back up your stock ROM.
I want to know the answers to the rest of your questions as well as some clarifications to mine.
Personally, I am looking for a way to backup the stock recovery as well.
I know there are some people asking about this. The procedure appears to be as follows:
(pieced together so don't take it as a tutorial)
1 Unlock bootloader (again, unclear on this. Also some mention S-OFF and others don't)
2 With USB debugging allowed (meaning connect as device requiring a driver), Connect to a PC with ABD, and a driver installed.
3 From ADB, issue a command "adb boot recoveryimage.name" instead of the usual "adb flash recoveryimage.name".
This will make the phone boot into a custom recovery image that is residing on PC, without first writing it to the phone.
4 Unclear how, but make that custom recovery now being live to back up stock rom to pc.
5 Unclear how, but make that custom recovery now being live to flash either root or custom rom to the phone.
6 Disconnect, reboot the phone. Once in OS, use root privileges to mount recovery partition ? (this makes it visible as drive)
7 Don't know how, but use root privileges to back up now visible stock recovery partition to PC as image.
( This should give you two out of three original parts.)
Keep in mind that even if my peace-by-peace "know-how" ever works, there is at least one clearly faulty step:
The back up of the original state of the boot loader has been never made. I do not know if it is easily can be toggled back and forth from lock to unlock and back without leaving any trace. Also, like yourself, I probably don't quite understand what am I talking about, but I have tried to make as much sense of what I have read here and there.
This is my first smart phone, and my experience with linux is limited to building a minecraft server on MineOS, which was pre-made so that not much was required to make it run. I have "mounted" a partition for the first time last week, trying to break Win7recovery, booting it with Knoppix. This is why I think this is probably will come in play here too, as the recovery partition on W7 was hidden. Until then I didn't understand what mounting means, as windows always does it for you. So, take everything I say with a bunch of salt.
Please, let me know too, if you find out more. I want to flash the hell out of my Prism, but I want to be smart about it.
Click to expand...
Click to collapse
check here
All your answers can be found here: [REF] [GUIDE] Welcome to your device, the Galaxy S III. For more XDA related issues check here: [GUIDE] - XDA New User Guide - Getting started on XDA
Good Luck!
mf2112
XDA Moderator
ASharpEdge said:
Hello all this is my first post here...woohoo!:fingers-crossed: This forum is amazing as to the amount of information available. I just wish that in looking for what I need to do I did not need to look in so many places. I feel that if I want to root my T-Mobile GS3 that all the information should be in one subsection of the forum, but it is not that simple I guess....lol Anyway any help would be greatly appreciated.
I have a Samsung GS3 with T-Mobile that I want to root. Everyone says to back up the phone before you do it but I am not really seeing how to make a backup before I start. It appears that most of the guides to root just say to backup without telling you how to fo it. Another thing (correct me if I am wrong) I see the nandroid backup that I think is a backup of the phone however it seems to be done after you make changes to the phone and I thought the backup was supposed to be done before you do anything. Is it that there is not a way to make a complete backup with an unrooted phone?
My question is basically the same as the OP here. I have been reading and reading and reading posts here in the forum. There is much information here and much of it is duplicated with slight variances in some of the duplicates. I am not certain as to which rooting method I should use. There seem to be so many choices. As a new person to this forum I will say that you can find just about everything about any phone which is awesome. The hard thing is sifting through the many options to pick one to use for your issue.
I do see that Mr. Robinson has a thread with backups of the original roms. The only thing is that they are default roms that are like an out of the box phone and not my phone with my apps and my settings. That is what I want to backup...My phone with my settings and my apps.
:good: Thank you in advance for any one that can shed some light on this for me and the OP'er
Click to expand...
Click to collapse
Thanks mf2112. But those resources are seem only for GS3. And it seems it is not teaching us to backup our stock ROMs, it provides stock ROMs for us to download instead. Is there a general way to backup our stock ROMs?
Thanks,
midnite_
mf2112 said:
All your answers can be found here: [REF] [GUIDE] Welcome to your device, the Galaxy S III. For more XDA related issues check here: [GUIDE] - XDA New User Guide - Getting started on XDA
Good Luck!
mf2112
XDA Moderator
Click to expand...
Click to collapse
You must unlock your bootloader then flash a custom recovery. You will then use that custom recovery to make a backup of your rom. That backup will be stored on your sd card.
Now, I have tried to help you and so have a couple other folks. You expect us to just give you answers step by step. I am sorry but this is simply not how XDA works. XDA is set up in a way which makes it for any users to find quickly what they want to know. Use the search feature on the site and you will find many answers. I tell you to go do your own research now and be proud of what you learn on your own. And if you cannot, please do not try to modify your phone further, you may just brick it if you aren't careful.
midnite_ said:
Thanks mf2112. But those resources are seem only for GS3. And it seems it is not teaching us to backup our stock ROMs, it provides stock ROMs for us to download instead. Is there a general way to backup our stock ROMs?
Thanks,
midnite_
Click to expand...
Click to collapse
I put in the GS3 links since the OP was using that phone. Every phone will be different so I don't think a general way or guide would be practical.
Sent from my HTC Sensation 4G using xda premium

[Q] Deployment of image to multiple devices

Hi gurus! I have done some searching based on this, but I seem to come across many different answers based on devices, ROMs etc. So I thought I would just ask. Apologies if there is an easy guide I have missed!
I need to configure a number of Android sticks with customized settings and software then deploy them in kiosk environments. Rather than configure each one separately, I'm hoping to be able to deploy an image nice and quickly to them.
The sticks are RK30 based. The webpage is here: http://multitouch.com/istick-a200-fastest-mini-computer.html and the specs are here: http://multitouch.com/download/datasheet/istick-a200-datasheet.pdf.
They are pre-rooted and you can download a "Factory Restore Pack" which includes the ADB driver, RKBatch Tool and a single factory image. It seems pretty easy to use the tool to push the image to the device and reset it.
I'm hoping to be able to configure a single device and then backup or export the image to an img file (like the factory default one) then just push this to the other devices using the same method. Is this possible and if so, how would I create the img file?
I've read and tried to understand about img files, but it seems there are boot.img files, system.img files and a whole bunch of others. I'm guessing this is a system.img file, but if I stuff around with no direction, I'll probably just brick a bunch of devices.
I also guess I could install clockwork mod and then backup to an SD, then install cm on each new device and restore the backup, but I'm hoping to do this without even needing cm by just using the RKBatch tool.
I really appreciate any help anyone can provide. Thanks in advance!
OK - update (maybe)
Can I use this tool: http://vondroid.com/threads/updated-27-08-2012-how-to-dump-current-rom.322/? I'm guessing that the file I then want to get is the system partition? Is this the one that RKBatchTool will push back to the device?
Soooo many ways to brick!!!

How are Android Phones different from PCs; making them harder to modify?

Out of curiosity, someone please explain to me what we are doing at the hardware level when we flash/root etc. I have an excellent understanding of PCs and Windows hard drives, but I don't understand why Android is much more complicated to modify and how the carriers are able to permanently mess up (in our opinion) our phones using OTA updates when there is not a computer virus that exists that can permanently mess up my computer to the point that a wipe and reinstall wont fix it?
My specific questions are as follows:
1. Most thread instructions usually say to root the phone before installing custom recovery (TWRP). If we are doing an ODIN flash, is rooting actually needed to install TWRP? Is root part of the ROM? Or is it a deeper hardware thing unrelated to the ROM?
2. If we are installing a custom rom (cyanogen mod) and we want root, is it necessary to root with a separate method (superuser.zip etc), or does flashing cyanogen mod give us root automatically?
3. If we are flashing images to the phone's hard drive, why does the current operating system on the phone matter? Why is there a different root/TWRP install method (and .tar images?) for android 4.1.1 than there is for 4.1.2 or 3.x.x? Shouldn't the same ODIN images work regardless of what operating system the phone has on it? As in, why do I even need to look at what is currently installed on the phone? If I have a computer and I want to install a new operating system, the current OS doesn't matter, I just wipe the drive and install the new OS. Why are the phones different? Why is it possible to buy a brand new computer, wipe the drive, and install Windows XP, or even DOS, but I can't buy a brand new phone and install Android 1.0.0?
4. How are the carriers able to cause developers so many problems with their OTA updates? If someone upgraded their i747 to 4.3 why can't they just format the phone's drive and reinstall an older operating system like I can on my computer? Even a computer infected with the worst computer virus can still be wiped and reinstalled with any processor compatible operating system, so how do the OTA updates cause irreversible phone problems when nasty computer viruses can't do this?
Basically explain to me what makes the Android phones different from PCs and makes everything so much more complicated than it is to format a Windows drive and install Linux and then format again and install something totally different? I just don't understand what makes them so different? Lastly, if the carriers encrypt a bootloader, like ATT did with the S4, why can't we just erase the bootloader and flash our own not-encrypted bootloader to the phone? Is the bootloader some sort of chip that we would have to physically remove and replace? Or is it 1's and 0's on the drive that we can format and rewrite?
scubapilot said:
Out of curiosity, someone please explain to me what we are doing at the hardware level when we flash/root etc. I have an excellent understanding of PCs and Windows hard drives, but I don't understand why Android is much more complicated to modify and how the carriers are able to permanently mess up (in our opinion) our phones using OTA updates when there is not a computer virus that exists that can permanently mess up my computer to the point that a wipe and reinstall wont fix it?
My specific questions are as follows:
1. Most thread instructions usually say to root the phone before installing custom recovery (TWRP). If we are doing an ODIN flash, is rooting actually needed to install TWRP? Is root part of the ROM? Or is it a deeper hardware thing unrelated to the ROM?
2. If we are installing a custom rom (cyanogen mod) and we want root, is it necessary to root with a separate method (superuser.zip etc), or does flashing cyanogen mod give us root automatically?
3. If we are flashing images to the phone's hard drive, why does the current operating system on the phone matter? Why is there a different root/TWRP install method (and .tar images?) for android 4.1.1 than there is for 4.1.2 or 3.x.x? Shouldn't the same ODIN images work regardless of what operating system the phone has on it? As in, why do I even need to look at what is currently installed on the phone? If I have a computer and I want to install a new operating system, the current OS doesn't matter, I just wipe the drive and install the new OS. Why are the phones different? Why is it possible to buy a brand new computer, wipe the drive, and install Windows XP, or even DOS, but I can't buy a brand new phone and install Android 1.0.0?
4. How are the carriers able to cause developers so many problems with their OTA updates? If someone upgraded their i747 to 4.3 why can't they just format the phone's drive and reinstall an older operating system like I can on my computer? Even a computer infected with the worst computer virus can still be wiped and reinstalled with any processor compatible operating system, so how do the OTA updates cause irreversible phone problems when nasty computer viruses can't do this?
Basically explain to me what makes the Android phones different from PCs and makes everything so much more complicated than it is to format a Windows drive and install Linux and then format again and install something totally different? I just don't understand what makes them so different? Lastly, if the carriers encrypt a bootloader, like ATT did with the S4, why can't we just erase the bootloader and flash our own not-encrypted bootloader to the phone? Is the bootloader some sort of chip that we would have to physically remove and replace? Or is it 1's and 0's on the drive that we can format and rewrite?
Click to expand...
Click to collapse
Reason being is that the manufacturers have control over everything and completely lock you out.
Its not like you have a bios on these phones or you can install a new hard drive with a different OS on it.
They lock it down so much.
It's also not impossible to root any of the phones.
All you need to do is use uart or jtag to talk to the device straight up.
Rotting is part of the rom.
An odin flash will work great for flashing recovery(For samsung devices only)
And roms.
But odin flashes whole partitions only.
Rotting is not a hardware thing.
Its basically finding a way to place a file on the /system partition in the bin folder.
Then being able to execute that file. (File: su)
The su executable changes your uid(User id) to 0 which indicates the root user giving you full access over the device.
To get the su executable on to the device you will have to find exploits in the software to allow you to write to the /system/bin directory.
One such exploit is zergrush which gave you a root shell where you copy the su binary over to the device.
What is rooting?
Pretty much every rom here will be given root access by default.
Some roms(Usually indicated with stock) have no root.
In which case recovery will allow you to flash a zip putting the su files onto your installed rom.
(Recovery is like running a live cd to repair windows.)
A good place to learn is xda-university
What is recovery?
These phones have flash memory.
Not magnetic.
And like I said Odin flashes whole partitions.
So it would completely wipe whatever partition you are flashing to.
/system would contain android.
So an odin package with a system img would wipe the current OS and flash the contents of your odin package to the place where the old OS was.
To summarize, Odin packages are not dependent upon the installed OS at all.
Now that is an interesting question.
The reason that you can't just install any OS is because we don't just have generic drivers built for generic hardware.
We have millions of different phone models.
There really hasn't been any movement for standard compliant hardware in the phone scene.
So building generic stuff for all of the different kinds of phones would be a nightmare.
And the last one.
Its because we rely on software security bugs to break into devices.
Google has made it easy for us to do anything that we want with our devices with a simple command.
samsung's download mode isn't a sure fire way of doing any modding because you would have to build a rom from stock. (Samsung doesn't release their stuff very often. An exception to this is : sammobile )
And again, you could do this with an underlying knowledge of the hardware using Uart or jtag. (Conneting to the board directly and speaking to the processor)
Seriously think about that for a second, how do you install windows. A cd drive.
How do you configure devices. a bios.
In short : These phones aren't made to be messed with for security reasons and because manufacturers are too lazy to make it easy for modders. (Nexus devices are made in mind for modders though)
Need anymore info just ask. :highfive:
Thank you so much Lgrootnoob. A few more questions.
1. When you say
To get the su executable on to the device you will have to find exploits in the software to allow you to write to the /system/bin directory.
Click to expand...
Click to collapse
Do I understand correctly that this is only true when adding root to a stock rom? If I flash cyanogen mod to the system partition, it does not require an exploit because it just erases and overwrites the entire partition? I have been rooting, and then installing TWRP, and then installing Cyanogen Mod. If I understand you correctly, me rooting the stock rom is an unnecessary step, as I am just erasing and overwriting it with Cyanogen Mod later?
Google has made it easy for us to do anything that we want with our devices with a simple command.
Click to expand...
Click to collapse
2. So modding the Google Nexus does not require that we use the exploits you mentioned are needed to modify the other phone(s)?
3. I understand that Android 4.3 has security features that prevent gaining "true root"? As long as Nexus leaves the "easy access" you mentioned, it will still be possible to flash a custom rom that does allow true root, no matter what security features Google puts into its version of Android?
4. Does the Google Play Edition Galaxy S4 require the exploits? Or do the Google Play edition phones have the same "easy access" you mentioned the Nexus has? Is the "easy access" the fastboot function I've read about?
5. With a carrier that encrypts all of their bootloaders, I will most likely be forced to buy only Nexus products or Google Play edition phones if I want to have Cyanogen Mod with full root? I haven't wanted a Nexus because it doesn't have a removable battery or SD card, but having custom firmware is the most important thing to me.
scubapilot said:
Thank you so much Lgrootnoob. A few more questions.
1. When you say Do I understand correctly that this is only true when adding root to a stock rom? If I flash cyanogen mod to the system partition, it does not require an exploit because it just erases and overwrites the entire partition? I have been rooting, and then installing TWRP, and then installing Cyanogen Mod. If I understand you correctly, me rooting the stock rom is an unnecessary step, as I am just erasing and overwriting it with Cyanogen Mod later?
2. So modding the Google Nexus does not require that we use the exploits you mentioned are needed to modify the other phone(s)?
3. I understand that Android 4.3 has security features that prevent gaining "true root"? As long as Nexus leaves the "easy access" you mentioned, it will still be possible to flash a custom rom that does allow true root, no matter what security features Google puts into its version of Android?
4. Does the Google Play Edition Galaxy S4 require the exploits? Or do the Google Play edition phones have the same "easy access" you mentioned the Nexus has? Is the "easy access" the fastboot function I've read about?
5. With a carrier that encrypts all of their bootloaders, I will most likely be forced to buy only Nexus products or Google Play edition phones if I want to have Cyanogen Mod with full root? I haven't wanted a Nexus because it doesn't have a removable battery or SD card, but having custom firmware is the most important thing to me.
Click to expand...
Click to collapse
1. Well, devices that have no way of flashing at the bootloader must be rooted on the stock rom to flash other roms. (Exception: Nexus devices that have fastboot flash system.img functions) But custom roms come su in /system/bin all the time. (Unless said otherwise in their thread)
2. Yup, google gives exclusive access on the nexus phones.
However, you have to unlock the bootloader to flash anything.
Unlocking the bootloader will use the command:
Code:
fastboot oem unlock
Unlocking the bootloader wipes all data.(/data partition) but leaves the system partition intact.
Reasone being is when someone flashes a recovery:
Code:
fastboot flash recovery.img
They could use recovery to dump your data partition.
3. The way processes work in android 4.3 and above is different from 4.3's ancestors.
Root can be obtained with Supersu
But exploits to gain root on the android system have been pretty much put out of business.
Most exploits are bootloader exploits these days. (Or oem rom exploitsem's theming makes their devices vulnerable usually.[They have less tested code or just don't care.])
So root is still widely available on just about any rom out there thanks to chainfire!
^He is an awesome developer by the way.
4. I would figure that the google play editions have easy access with fastboot that would normally be stumped by samsung.
Google makes everything awesome.
" Is the "easy access" the fastboot function I've read about?" In short yes.
It allows you to flash recovery which can dump the whole system and allow you to modify the system however you like and put it back on the device.
There is even an app for recovery by the way: Aroma fm
5. The removable battery doesn't matter unless you wan't to swap batts on the fly.
But it does have a function for restarting the phone without pulling the battery. Hold power button + volume up until it restarts.
And even if you wanted to replace the battery you could take the nexus device apart and disconnect the battery and find a replacement. (Maybe ordered from the manufacturer.)
The devs here are awesome and find exploits in almost all of the bootloaders or the oem (skinned) android versions.
So the nexus devices aren't the only option, but they usually get more development unless your device is truly a powerhouse like the gs4 international.

Serious issues rooting!

Man, TWRP just refuses to flash root to my phone (L29c567b190) I've been able to get twrp on there with no issues, but I can't seem to get /system write access.
Flashing SuperSU reboots halfway through the process, and phh's Superuser simply fails with error 1.
Flashing an unencrypted boot img gets me a bootloop.
I've formatted data and reinstalled data files many a time, and no matter what I do, I can't seem to get the root to take.
I'm fairly happy with stock EMUI, It's nice. I just want the root for simple little things like forcing immersive mode, but mainly I want root on principle! It's my pocket computer and I WILL have administrator rights, you know?
Anyway, I've always had Samsung products and have a little experience in HTC stuff, but this issue is really throwing me for a loop!
dm-verity and decrypting my partitions are all new to me... What am I missing here?
Afaik, phhSuperUser method works by following algorithm.
- When installing it unpacks current boot image, makes changes in fstab, copies su binary, then repacks boot and flashes it onto the phone.
Script doesn't have checks. If you have modified boot already, script will fail. So you have to flash original boot before trying to get root/system writable.
Another note, Huawei can change something in boot in new versions of ROM, so script may fail where did not fail before.
Additionally, script works with one TWRP and fails with other.
So I actually got it using the files from this thread:
forum... xda---developers.. .com/mate-9/how-to/hacking-customizing-managing-huawei-t3589996
I had to downgrade twrp from 3.0.3-1 to 3.0.2-2, and it took the binaries from this person's Dropbox. I guess it was just a matter of finding the right files.
So, yeah, I guess you're absolutely right. Failed with one and not the other.

Categories

Resources