[SOLVED][Q] 4.4.3 after restart restores previous values - One (M7) Q&A, Help & Troubleshooting

Hi!
I have problem with my HTC One m7 (ViperOne 7.0.1).
While I changed something in /system/app folder (eg. deleted a "DriveActivator.apk" - successfully accomplished) and restart phone, I see again that deleted app!!!
Do you know why? I'm using RootExplorer, I have root and granted permissions to r/w.
It seems like system restores some kind of backup - I don't know why, and I don't know how to fix it (I mean do some permanent changes in /system/app).

dry3333 said:
Hi!
I have problem with my HTC One m7 (ViperOne 7.0.1).
While I changed something in /system/app folder (eg. deleted a "DriveActivator.apk" - successfully accomplished) and restart phone, I see again that deleted app!!!
Do you know why? I'm using RootExplorer, I have root and granted permissions to r/w.
It seems like system restores some kind of backup - I don't know why, and I don't know how to fix it (I mean do some permanent changes in /system/app).
Click to expand...
Click to collapse
It appears that the System isn't booted with RW capabilities
There's a nice long command that I'll give you later that will fix it
If you wanna get it sooner and aren't afraid of adb shell (make sure you have root access enabled for adb AND apps, not just apps) you can Google remount Linux system read/write and you should find it
You'll need to modify that command to reflect the One, but the name of the partition should be something like by-name-system or something
I'll get it later if you need it when I wake up

ajbiz11 said:
It appears that the System isn't booted with RW capabilities
There's a nice long command that I'll give you later that will fix it
If you wanna get it sooner and aren't afraid of adb shell (make sure you have root access enabled for adb AND apps, not just apps) you can Google remount Linux system read/write and you should find it
You'll need to modify that command to reflect the One, but the name of the partition should be something like by-name-system or something
I'll get it later if you need it when I wake up
Click to expand...
Click to collapse
Thanks mate!
Stupid question - how I can check whether I have root access enabled for adb and apps? I have superuser app, and in settings I can see: "Superuser Access: Apps and ADB" - is this what you are wrote about?

dry3333 said:
Thanks mate!
Stupid question - how I can check whether I have root access enabled for adb and apps? I have superuser app, and in settings I can see: "Superuser Access: Apps and ADB" - is this what you are wrote about?
Click to expand...
Click to collapse
That's exactly what I'm referring to (The settings thing)
Lemme go find that command for you
---------- Post added at 06:00 AM ---------- Previous post was at 05:56 AM ----------
Wish I knew this existed when I was working on the L port
There's an app to do exactly what you need without looking up partitions
https://play.google.com/store/apps/details?id=com.beansoft.mount_system
Although if you want to go through terminal, here's a tutorial
http://ckirbach.wordpress.com/2012/11/27/how-to-remount-system-as-read-write-in-android/
Basically, you use grep to find the name of the system partition, then run the mount command to remount the partition you found in that precious step

I have this app: Mount /system (rw / ro), also I have this option in superuser and it works fine - I mean that I can change /system/app or for eg. edit /etc/hosts (I get message that ES explorer granted superuser access), but after restart I see previous files (before changes)... I have no idea how make this work - maybe I need custom kernel or something? I want to make permanent changes in system files...
I have reinstalled system (clean option with wipe all data), but still no results...

dry3333 said:
I have this app: Mount /system (rw / ro), also I have this option in superuser and it works fine - I mean that I can change /system/app or for eg. edit /etc/hosts (I get message that ES explorer granted superuser access), but after restart I see previous files (before changes)... I have no idea how make this work - maybe I need custom kernel or something? I want to make permanent changes in system files...
I have reinstalled system (clean option with wipe all data), but still no results...
Click to expand...
Click to collapse
The remount app should do exactly that
Try the command option and make your changes then reboot

ajbiz11 said:
The remount app should do exactly that
Try the command option and make your changes then reboot
Click to expand...
Click to collapse
I have tried - still no results. My system already has RW permissions. Problem is that after restart my files are "restored".
Analogously like in Cisco IOS - commit but without write memory.
Maybe I should go to recovery and do something (but I don't know what)?

dry3333 said:
I have tried - still no results. My system already has RW permissions. Problem is that after restart my files are "restored".
Analogously like in Cisco IOS - commit but without write memory.
Maybe I should go to recovery and do something (but I don't know what)?
Click to expand...
Click to collapse
Check the Viper forum and maybe post there
I only run CM-base so I'm not too experienced with Sense issues

ajbiz11 said:
Check the Viper forum and maybe post there
I only run CM-base so I'm not too experienced with Sense issues
Click to expand...
Click to collapse
Thanks - they said they don't know, but it affects S-ON users....
Can You tell me one thing - I execute this script:
echo off
adb reboot
cd /d %~dp0
echo .
echo Waiting for device...
adb wait-for-device
echo.
adb -d shell stop
adb -d shell su -c "mount -o remount rw /system"
adb -d shell rm /system/app/DriveActivator.apk
adb reboot
This should remove DriveActivator (while script is ongoing I see no errors), but after reboot DriveActivator.apk is still in /system/app...
Is there any other way to permanently remove/change files in /system/app?

dry3333 said:
Thanks - they said they don't know, but it affects S-ON users....
Can You tell me one thing - I execute this script:
echo off
adb reboot
cd /d %~dp0
echo .
echo Waiting for device...
adb wait-for-device
echo.
adb -d shell stop
adb -d shell su -c "mount -o remount rw /system"
adb -d shell rm /system/app/DriveActivator.apk
adb reboot
This should remove DriveActivator (while script is ongoing I see no errors), but after reboot DriveActivator.apk is still in /system/app...
Is there any other way to permanently remove/change files in /system/app?
Click to expand...
Click to collapse
You can remove it from the ViperROM zip and format ONLY system and reflash
That SHOULD work
That's like...the be all end all

dry3333 said:
Thanks - they said they don't know, but it affects S-ON users....
Can You tell me one thing - I execute this script:
echo off
adb reboot
cd /d %~dp0
echo .
echo Waiting for device...
adb wait-for-device
echo.
adb -d shell stop
adb -d shell su -c "mount -o remount rw /system"
adb -d shell rm /system/app/DriveActivator.apk
adb reboot
This should remove DriveActivator (while script is ongoing I see no errors), but after reboot DriveActivator.apk is still in /system/app...
Is there any other way to permanently remove/change files in /system/app?
Click to expand...
Click to collapse
Make life simple: erase the apk while in custom recovery, TWRP has a file manager, or you can use Aroma File Manager
even adb commands while booted in custom recovery are better than booted up ROM.

nkk71 said:
Make life simple: erase the apk while in custom recovery, TWRP has a file manager, or you can use Aroma File Manager
even adb commands while booted in custom recovery are better than booted up ROM.
Click to expand...
Click to collapse
Thanks for advice. Is it possible via TWRP not only remove file, but also replace it? Where shoul I place new file for replace original one?

dry3333 said:
Thanks for advice. Is it possible via TWRP not only remove file, but also replace it? Where shoul I place new file for replace original one?
Click to expand...
Click to collapse
I would recommend using the Aroma File Manager instead of TWRP's, just place all the files you'll need on your internal storage (including Aroma File Manager), then reboot to select "Install" to run the Aroma File Manager and remove/replace whatever you need to.
You may need to also check if the permissions are right, I can't remember if Aroma File Manager has that built in.
remember that once you are in recovery to mount /system (in the Mount menu)
and you can even use adb shell, and adb push commands to replace the .apk.... i'm just guessing it's easier with a GUI interface.

nkk71 said:
I would recommend using the Aroma File Manager instead of TWRP's, just place all the files you'll need on your internal storage (including Aroma File Manager), then reboot to select "Install" to run the Aroma File Manager and remove/replace whatever you need to.
You may need to also check if the permissions are right, I can't remember if Aroma File Manager has that built in.
remember that once you are in recovery to mount /system (in the Mount menu)
and you can even use adb shell, and adb push commands to replace the .apk.... i'm just guessing it's easier with a GUI interface.
Click to expand...
Click to collapse
The windows drivers don't work with recovery mode (usually)

ajbiz11 said:
The windows drivers don't work with recovery mode (usually)
Click to expand...
Click to collapse
they do for me, but sometimes (after flashing a new/different version) i have to manually select the drivers, check FAQ#2 here: http://forum.xda-developers.com/showpost.php?p=52135024&postcount=2

I would like to thank you for advice. I did this via TWRP (after I had mounted /system). It works fine for me

dry3333 said:
I would like to thank you for advice. I did this via TWRP (after I had mounted /system). It works fine for me
Click to expand...
Click to collapse
sure, no problem :good: :good:
if all is good now, can you also edit main thread title to include [SOLVED], thanks
edit the first post -> at the bottom of the edit window, click Go Advanced, and then you can edit main title

Related

[GUIDE] All Tattoo questions and answers see here (from A to Z)!

Hi,
this thread is meant as a starting point for every kind of questions. I will write everything I know into this thread and update it (hopefully) frequently
Here are the topics handled for now (if you have any other questions you want to have answered you can PM me, so I can try to handle it if I know the solution and add this to my to do list in point 5!!! ):
1. How can I root my phone
1.1 General information/Basic adb-commands
1.2 Do I have to create a goldcard?
1.3 Tools you need
1.4 The automated way
1.5 The manual way (recommended by the author)
1.6 Problems and (hopefully good) solutions
1.7 References
2. Flashing images/ROMs
2.1 What is a recovery image
2.2 What is a boot image
2.3 How to flash/tools needed
2.3.1 Creating a Goldcard
2.4 Where can I get an overview of the existing ROMs?
2.5 Problems during flashing and solutions
2.6 References
3. Information about the Tattoo/Useful stuff
3.1 How to install busybox?
3.2 Can it perform multitouch?
3.3 How to increase battery life?
3.4 Using own ringtones for calls/sms
3.5 How to disable data transfer with a custom ROM?
3.6 How to make the Tattoo ring louder?
3.7 How to replace the home screen?
3.8 Disabling xxx-synchronisation with Google-servers
3.9 Backing up apk's and data to your PC
3.10 How to enable more languages on my mobile?
3.11 How to manually delete system apks? Alternatively with GUI?
4. Dev-Goodies
4.1 Modifying update.zips and resigning them
4.2 Modifying resources in apk-files and resigning them
4.3 Installing apks via adb for getting exact error codes if installation fails
4.4 Everything related to ROM cooking
5. Things I will do better in this thread due to user request
Please note: I won't be giving tutorials about Android-apps usage beside the one mentioned in my tutorial!
Let's start now:
1. How can I root my phone?
1.1 General information/Basic adb-commands
Rooting a phone enables you to do things, which normally aren't possible for the average user like:
- Removing apps which were preinstalled by the provider (like Orange, Vodafone, etc.). My Tattoo had Vodafone apps for buying music and other sh*t, which was installed on the system partition (to which a "normal" user has no rights to write to, including deleting).
The Tattoo was successfully rooted by a bunch of guys here, namely -bm-, mainfram3 and Coburn64 (maybe, I don't remember quite correctly ). Also the Tattoo was the first phone having a security mechanism hindering a user to mount the filesystems as read/write, which had to be overridden by remapping the read only memory region to a read/write one. This is done by the module Tattoo-hack.ko, also made by mainfram3. He also created the first boot.img, which enabled su directly from adb and loading Tattoo-hack directly from boot on.
A few words about adb:
ADB is a tool for communicating from the PC with the mobile phone. For this a service is running on the phone enabling the communication via Terminal Emulator. Here are the most useful adb-commands:
Code:
adb push localFileFromPC /path/on/mobilephone
-> pushes a file "localFileFromPC" to a specified location on the phone
adb pull /path/to/file pathFromPC
-> receives a file from the phone and stores it to "pathFromPC"
adb remount
-> This is only possible in custom ROMs, remounts the file system to r/w automatically
adb shell "command"
-> executes "command" and returns to the computer shell
adb shell
-> opens a shell session on the phone (from here on you have to be very careful! Also you can execute now normal linux commands like rm, mv, ls, chmod and so on, but not cp (this can done through busybox)). You will have to use this more often, so get used to it ;)
1.2 Do I have to create a goldcard?
I read this question quite often. For rooting, you don't need it, but for SIM-locked phones you can't flash custom unbranded ROMs (I think).
A guide to create a goldcard follow this link: http://forum.xda-developers.com/showpost.php?p=5179788&postcount=1 (thanks to MiSSigNNo to this point)
1.3 Tools you need
A complete set of tools can be found here Feel free to mirror it:
http://rapidshare.com/files/403766494/Tattoo.rar.html
This package contains:
- adb binaries for Windows (sorry Linux users )
- su (Please note: use the su-binary attached in this post, not the one in the archive!!!!!)
- m7 exploit
- Amon_RA recovery.img
- mainfram3 boot.img
- flash_image binary
- tattoo-hack.ko
1.4 The automated way
This method was created by maverixx and can be found here. This basically consists of a package doing everything you need by itself. It roots the phone and flashes maverixx recovery.img, which (no offense) I don't like as much as I like Amon_RA's one!). Just click the batchfile and it does the rest (you have to connect your phone via USB to your PC though ).
If you want to use the automated way, but flashing Amon_RA's recovery, just replace the recovery.img from maverixx' package with the recovery.img provided in my archive file (see 1.3 for the link).
In my time here I noticed quite a few users experiencing problems either with a fully functional su or with the recovery image not flashing certain update.zip packages. It seems to be a matter of luck.
1.5 The manual way (recommended by the author)
I personally like what is done when and how, that's why I recommend the manual way. So let's get down to business Let's see if you know all the adb-commands I wrote here:
1. Let's say you have everything unpacked into C:\Tattoo
2. In your terminal (on your PC) type:
- adb shell "mkdir /data/local/bin" (if it returns an error it means that the directory already exists, just proceed)
- adb push m7 /data/local/bin/
- adb push su /data/local/bin/
- adb push flash_image /data/local/bin/
- adb push tattoo-hack.ko /data/local/bin/
- adb push recovery.img /sdcard
- adb push boot.img /sdcard
3. We have every needed file on the phone now. Type now (we are still in your terminal):
- adb shell
$ cd /data/local/bin
$ chmod 766 m7 (I don't retain this step as mandatory, so if this process fails, just proceed)
$ while ./m7 ; do : ; done
lots of text until you see something like "wrote shell code", press enter 2 or 3 times enter to see:
#
4. Then perform this:
- # export LD_LIBRARY_PATH=/system/lib
- # export PATH=/system/bin
- # insmod ./tattoo-hack.ko
- # mount -o rw,remount /dev/block/mtdblock5 /data
- # mount -o rw,remount /dev/block/mtdblock3 /system
- # cat ./su > /system/bin/su
- # chmod 4755 /system/bin/su
- # chmod 755 ./flash_image
Click to expand...
Click to collapse
Questions?
1.6 Problems and (hopefully good) solutions
Q: How do I execute my command line tool?
A: On your Windows host, go to Start->Run...->type "cmd"
Q: Where is my adb? When I type it in my shell it says that it was not found!
A: The adb binary is found in the archive I supplied above or in the Google SDK. As my archive-file is quite smaller than the Google SDK you should take mine. Let's suppose your adb binary is unpacked in C:\Tattoo, then type:
Code:
Your\Current\Location> cd C:\Tattoo
C:\Tattoo> adb <command>
Q: adb says "error: device not found" when I try to launch the shell on the phone!
A: Connect the phone with the usb cable and make sure the sd card is not mounted as drive on your PC!!!
Q: When I want to copy something the phone returns that "cp" is not found! Also when I try to move a file, it says "cross-link device".
A: Well, copying from one partition to another is only possible either via busybox or via
Code:
cat file > /location/filename
Example:
cp /data/su /system/bin
is realized by typing
cat /data/su > /system/bin/su
Also make sure that system is r/w!!!
Q: flash_image returns write errors when flashing recovery/boot image!
A:
For boot: Try to redo the flash procedure
For recovery: Note that you can't flash the same recovery.img as the one already installed, so install another recovery.img first (like maverixx) and then Amon_RA's again. If it still doesn't work reboot, remount the partitions r/w, insmod tattoo-hack.ko and retry flashing.
Q: How can I unroot my device?
A: Just delete su from /system/xbin and restore the old boot.img. Alternatively see here for retrieving a stock ROM to flash it on your phone.
PM me with more questions and I'll post them with the possible solution.
1.7 References
- Zecanilis EXCELLENT Root-Recovery-Flash images thread
- maverixx' One-click root method+recovery thread
- Coburn64's Newbie guide for manual rooting (recommended reading!)
2. Flashing images/ROMs
2.1 What is a recovery image
A recovery image is not only useful to flash custom ROMs on your device. It also enables you to backup your entire phone contents to restore it completely in case of a brick, if anything should happen...especially SIM-locked mobiles should be backed up as soon as possible. Also many recovery image modders add several non-standard features like mounting the SD card while in recovery mode or enabling adb support, etc.
2.2 What is a boot image
The boot image not only contains the kernel which brings up your Tattoos, it only can be modified to load up modules enabling ext2/3 support, loading camera, remapping read only code to an r/w area (tattoo-hack.ko), etc. Without a working boot.img, don't even bother trying to boot the phone (maybe if you do a logcat it returns something useful to solve this problem )
2.3 How to flash/tools needed
Execute steps 1 to 4 in topic 1.5 first!
5. Now comes the hard part:
- # ./flash_image boot /sdcard/boot.img
- # ./flash_image recovery /sdcard/recovery.img
it can be that flash_image reports errors in the last step (recovery.img step), but another user said it would be still working to boot to recovery...but to be sure (if you got the error!!!) flash maverixx recovery.img and then again the one I supplied in my archive (Amon_RA)
Reboot once and when you connect with adb to your phone you should see the difference
Click to expand...
Click to collapse
2.3.1 Creating a Goldcard
This is a post I took from MiSSigNNo, kudos to him:
Creating the Gold Card:
[...]
4. We need the android-sdk tools, we can find them here: http://developer.android.com/sdk/index.html download them, and unzip in a folder maybe in C:\androidtools
5. Go the the Command line (Start->Execute->write cmd and OK), and there you should find where you unzip the android-sdk tools, example cd c:\androidtools\tools
6. Run this command "adb shell cat /sys/class/mmc_host/mmc1/mmc1:*/cid" if you had the microSD in the drive you will find a long number like:
532600bd227d9c0347329407514d5402
7. Go to this page to reverse it: http://hexrev.soaa.me/ and copy the code reversed:
In our example it will be: 00544d5107943247039c7d22bd002653
8. Go to this page to generate your GoldCard image: http://revskills.de/pages/goldcard.html
And put your reversed number and you email. You will receive an email with a file called "goldcard.img"
9. Now you need an Hex editor like HXD. Download it from: http://download.cnet.com/HxD-Hex-Edi...html?tag=mncol
10. Exactly the same as the instructions I pasted above:
11. Install and launch HxD Hex Editor program. (make sure you use "Run as Administrator" under Vista and win 7)
12. Go to Extra tab > Open Disk. Under Physical disk, select Removable Disk (Must be your SD card), uncheck “Open as Readonly), click OK. (BEWARE, MUST BE UNDER PHYSICAL DISK NOT LOGICAL DISK, THIS MISTAKE MADE ME BIG PROBLEMS)
13. Go to Extra again, Open Disk Image, open up goldcard.img which you’ve saved/unzipped earlier.
Now, you should have two tabs, one is your removable disk, the other is goldcard.img. Press OK when prompted for “Sector Size” 512 (Hard disks/Floppy disks), click OK.
14. Click on goldcard.img tab. Go to Edit tab > Select All, edit tab again > copy.
15. Click on the “removable disk” tab. Select offset (line) 00000000 till offset (line) 00000170 (including the 00000170 line), click on Edit tab and then Paste Write.
16. Click on File > Save. now you can exit the program. You now have a gold card.
[...]
Click to expand...
Click to collapse
2.4 Where can I get an overview of the existing ROMs?
Look it up here (Excellent work liderzre)
2.5 Problems during flashing and solutions
Q: HEEEEELLLPPP! flash_image says that it couldn't write to some memory addresses! What can I do?
A: Don't panic. First make sure to have loaded tattoo-hack.ko, remounted system and data to r/w and then try again with another recovery.img (either maverixx or Amon_RA). Flashing the same recovery.img again WON'T WORK!!!! That's why you have to take a little detour by first flashing another recovery image.
Q: How do I boot to recovery??
A: Type in your command line while the phone is plugged in:
Code:
adb shell "reboot recovery"
. If this doesn't work, turn off your phone, hold down the home-button and press the power-button. Then when the Tattoo logo can be seen, release the home button and the recovery screen should be seen
2.6 References
- Zecanilis EXCELLENT Root-Recovery-Flash images thread
- maverixx' One-click root method+recovery thread
3. Information about the Tattoo/Useful stuff
3.1 How to install busybox?
Load the busybox binary here (select the one with arm6 at the end). Put this binary onto your data or system partition (I suggest /system/xbin) and now there are two ways to install/enable it. See below
Method 1 (will extract EVERY FEATURE, but consumes A LOT of your disk space so be careful or switch to method 2)
Do this in your command line:
Code:
adb remount (make it r/w if not done already)
adb shell "mkdir /system/xbin" (create dir if it doesn't exist)
adb push busybox /system/xbin (please make sure to have busybox in the same directory as adb ;) )
adb shell
cd /system/xbin
./busybox --install
Method 2 (saves your precious disk space )
Do this in your command line
Code:
/system/xbin/busybox --install -s /system/xbin
3.2 Can it perform multitouch?
Nope, the Tattoo has a resistive touch screen, which is known to be NON-multitouch...newer generation or high-end phones usually have capacitative screens. My suggestion is not taking the Nexus One anymore, since their touch screen type supports only 2 fingers at once, while phones like the Samsung Galaxy S have a SUPER responsiveness and sensibility (and of course 10 fingers support).
3.3 How to increase battery life?
Okay, here are little tips how to increase battery life - mine holds 7 to 8 days and I surf, call ppl and sms almost every day:
1. Flash either fyodor 0.6.4.2 or Abyzou 2.1.9 - my favourite is fyodor ones (if I still would have a Tattoo, of course )
2. Download APNd roid from the market or here and disable your 3G Internet connection (for activating it, just start the program again!)
3. If you see that you have NO RECEPTION AT ALL in one place (at work for instance), turn off your phone as this will DRASTICALLY decrease battery life because the phone tries constantly to search for a network it can log on to.
4. Try to keep your phone in normal temperature areas (between 20 and 27 degrees celsius = 68 - 80.6 degrees fahrenheit)
5. Kill unneeded apps automatically (there are quite a few apps doing this)
3.4 Using own ringtones for calls/sms
Create a folder called "media" on the root of your SD card and a sub-folder called "audio" there you have to create one folder called "notifications" for SMS and "ringtones" for call sounds. Place every desired track into these folders and reboot your phone. You should see the entries now when choosing ringtones. Alternatively just load "Ringo Pro", a really powerful tool also able to display SMS pop-ups and much more.
3.5 How to disable data transfer with a custom ROM?
As already explained above, load APN droid from the market or here.
3.6 How to make the Tattoo ring louder?
There is a little app called "Louder Volume Hack" enabling your phone to ring much louder than normally. You can load it on any popular w*rez-site Unfortunately I cannot enter the link to the app here or PM it. Any questions requesting a link to this app will be deleted instantly, so don't bother trying and use Google. There are several buttons displayed, but for better visibility I suggest enabling the Widget and hacking the system there. Also please note that ROOT access is required!! Refer to section 1 to root your phone.
3.7 How to replace the home screen?
There are two ways to do it. Method 1 is the easier one, but runs the Google Launcher and the replacement laucher in parrallel, which implies more CPU usage and battery drain. Method 2 is the more brutal one, but enables you to run just one launcher.
Method 1:
Install the replacement home app and press the home button. A dialog should appear asking you which Home Launcher should be used.
Method 2:
Put your home replacement apk onto the root of your SD and make sure you have busybox installed and /system mounted as writeable. Rename the Home replacement apk to Launcher.apk and fire up adb shell:
Code:
mv /system/app/Launcher.apk /system/app/Launcher.apk.old && mv /system/app/Launcher.odex /system/app/Launcher.odex.old && cp /sdcard/Launcher.apk /system/app && chmod 755 /system/app/Launcher.apk
Should be a pretty generic approach
3.8 Disabling xxx-synchronisation with Google-servers
Go to settings, data synchonisation and disable the entries you don't want to have synch'ed with Google. Since it's long time ago since I did this (remember that I don't own a Tattoo anymore) the procedure can be slightly different from ROM to ROM.
3.9 Backing up apk's and data to your PC
By popular request, here a topic about how to backup apk's and their corresponding data manually (can be done separately, too if you want just one of the two). Doing it with the tar command HOPEFULLY preserves also all permissions!!! Check it:
Hit up adb shell and make sure have busybox:
Code:
for the apks
# tar -cvf /sdcard/dataAppsBackup.tar /data/app
for the data
# tar -cvf /sdcard/dataDataBAckup.tar /data/data
If you want to decompress these files again do:
Code:
# tar -xvf /sdcard/dataAppsBackup.tar -C /data
# tar -xvf /sdcard/dataDataBackup.tar -C /data
Note that these files won't be compressed! If you want to save some disk space on your SD then add the parameter 'z' (without the quotes) in the tar arguments (e.g. tar -cvfz for compressing and tar -xvfz for decompressing)
3.10 How to enable more languages on my mobile?
There is an app called MoreLocale in the market enabling you to select more languages. Download it, it's free
3.11 How to manually delete system apks? Alternatively with GUI?
For deleting manually you only need root-access. With GUI you need RootExplorer (buy it or do what you need to do to get this app-but with these features I would suggest to buy the app ).
Note: I do not take any responsibility if you delete the wrong apk and you lose any functionality of the phone. Do this only if you know what you're doing!
The manual way:
Connect the phone via USB, fire up adb shell and type:
Code:
insmod /LOCATION TO [URL="http://TATTOOHACK.KO/tattoo-hack.ko"]TATTOOHACK.KO/tattoo-hack.ko[/URL]
mount -o rw,remount /dev/block/mtdblock3 /system
cd /system/app
rm NAMEOFAPK.apk
The GUI way:
Install RootExplorer, open it, navigate to /system/app and press the little "Mount R/W" button at the top of the screen and begin deleting
4. Dev-Goodies
4.1 Modifying update.zips and resigning them
See this thread and get enlightened
4.2 Modifying resources in apk-files and resigning them
Same procedure as above:
1. Extract the file with WinRAR/WinZIP, delete the contents of META-INF and start modifying what you have to modify
2. Pack everything again into a ZIP file and sign it with the signapk.jar file (can be found somewhere in the forum or here). The syntax of how to use this can be found in the last link (yes, it's only 10 KB ).
4.3 Installing apks via adb for getting exact error codes if installation fails
Prerequisites: Either know the exact path to the apk or put it into the same directory as your adb executable and hit up your command line:
Code:
adb install /path/to/apk/file.apk
OR
adb install file.apk (implies that apk is located in same dir as adb)
4.4 Everything related to ROM cooking
Check this link (thanks to Decad3nce) and this one (thanks to mxlaser).
5. Things I will do better in this thread due to user request
- Nothing
The end for now.
Note: If you think that my thread is good, then please rate it with 5 stars
Changelog:
Version 1.0
- Initial draft
Version 1.1
- Added complete topic 1 now
- Fixed layout and some typos
Version 2.0
- Added complete topic 2 and half of 3
Version 2.1
- First prototype with all topics finished (will rework parts which are not quite understandable)
Version 2.2
- Added new question to 1.6
Version 2.3
- Added section 4.4 -> Everything related to ROM Cooking DUDEEEESSSSS
Version 2.4
- Added 3.11 How to manually delete system apks? Alternatively with GUI?
Version 2.5
- attached working su file - thanks to lovenemesis for this
Version 2.6
- added some mirrors for the Tattoo.rar archive - thanks to emb0re for providing some space
Version 3
- added topic about creating gold cards (2.3.1)
hi
very good initiative stuck
Great work
Very intuitive guide for beginner.
Though as an experienced and new android application developer, it really took me a whole afternoon to understand every step of the whole process. I am sure this guide would save many others wonderful Saturday afternoon.
Nice Work
Great Work From You Sir. This Will Be Useful for Beginners I Think This Will Save Lot Of Our Time's. And Mods Too
Thanks for the feedback...I hope that I can fill many topics tomorrow
P.S.: Indeed this is meant for the many unexperienced users who desperately want to flash custom ROMs but don't know how to do it...this also spares a lot senseless thread-posts I hope...^^
Dude
SSj Man Can You Add Tutorial Abt How to get the Apk file which i download from market in my mobile. if that is possible
3. We have every needed file on the phone now. Type now (we are still in your terminal):
- adb shell
$ cd /data/local/bin
$ while ./m7 ; do : ; done
lots of text until you see something like "wrote shell code", press enter 2 or 3 times enter to see:
#
Click to expand...
Click to collapse
For me I need to add execute permission for m7 before expolit, with
Code:
chmod 766 m7
.
jagan_3400 said:
SSj Man Can You Add Tutorial Abt How to get the Apk file which i download from market in my mobile. if that is possible
Click to expand...
Click to collapse
You mean getting the apk from your mobile on your PC for example?
lovenemesis said:
For me I need to add execute permission for m7 before expolit, with
Code:
chmod 766 m7
.
Click to expand...
Click to collapse
Hm, normally when you push the file via adb it will have user permissions, which includes execution...but I will add it to exclude any possible error...thanks for the info.
It might be worth to mention this in 3.1 Busybox installation:
Code:
adb push busybox /system/xbin/
I accidentallly use "adb push busybox /system/xbin" without the ending "/". Well, you know the rest part of the story...
Hmm, probably this one first, at least for the stock HTC ROM
Code:
adb shell "mkdir /system/xbin"
PS: Kind of weird for its name xbin, not the usual sbin on desktop linux. ;-)
TheSSJ said:
You mean getting the apk from your mobile on your PC for example?
Hm, normally when you push the file via adb it will have user permissions, which includes execution...but I will add it to exclude any possible error...thanks for the info.
Click to expand...
Click to collapse
Maybe it's because I am using a Fedora box, which the default permission for files in $HOME does not include execution.
lovenemesis said:
Hmm, probably this one first, at least for the stock HTC ROM
Code:
adb shell "mkdir /system/xbin"
PS: Kind of weird for its name xbin, not the usual sbin on desktop linux. ;-)
Click to expand...
Click to collapse
You're right, I added it already in the guide, thanks for the feedback. Well, /system/xbin isn't a "normal" directory indeed, but it was created for extra executables which normally aren't shipped in stock ROMs (like busybox).
4. Then perform this:
- # export LD_LIBRARY_PATH=/system/lib
- # export PATH=/system/bin
- # insmod ./tattoo-hack.ko
- # mount -o rw,remount /dev/block/mtdblock5 /data
- # mount -o rw,remount /dev/block/mtdblock3 /system
- # cat ./su > /system/bin/su
- # chmod 4755 /system/bin/su
Click to expand...
Click to collapse
I suppose after this step the stock ROM is rooted. Right?
But in Android Terminal Emulator gives me $ still. "su" reports an link_image error, which basically said about missing libbinder.so library.
Is it normal or I need to push an libbinder.so to /system/lib as well?
BTW: "adb shell " gives me # straightly.
Regards,
Hmm, I pushed another "su" binary to overwrite the one in Tattoo.rar. And now it works fine in Android Terminal Emulator.
Here is the su binary I use:
View attachment su.zip
Oops, Titanium Backup still refuses to work despite of working "su" binary.
What else should I do?
market not working
hi
i dont know why but the Market does not work for me can u give any solutions for the same im just not able to log in it keeps saying error i also tried with google mail and gmail id but no luck any suggestion pls
few questons kindly answer
hi
i have afew questions can u kindly answer
1. is wipe a must before flashing a new rom
i have flashed the Modoco rom and it was mentioned that this was not needed but i have read in many threads asking to do the same before flashing
2.to bring back contacts after flashing new rom can i use
a. backup pro or titanium backup
b. can i just use the out look sync and get back my contacts from my PC
3. if i restore the stock rom and latter on want to try one of the cooked roms do i need to do the rooting again ie does flashing stock rom remove the rooting
Note : i have been a WM user new to AM is why im asking such questions in the WM i have one app pim backup which would get back all my contacts in 1 min and when flashing any WM it will automatically wipe all the data from the phone this does not seem to be the case with AM is why i have asked above Questions
thanks in advance
lovenemesis said:
Oops, Titanium Backup still refuses to work despite of working "su" binary.
What else should I do?
Click to expand...
Click to collapse
Titanium Backup needs Busybox and su to work. If Titanium Backup tells you that it found BusyBox, then try to copy "su" to the following to locations:
/system/bin and /system/xbin
I think with the first it should work then.
haree said:
hi
i dont know why but the Market does not work for me can u give any solutions for the same im just not able to log in it keeps saying error i also tried with google mail and gmail id but no luck any suggestion pls
Click to expand...
Click to collapse
Do you use MoDaCo ROM or did u switch now to another? Normally the phone asks for log-in credentials when going online. When you enter them correctly, the login window should disappear and you should be able to access market...I know this sounds stupid, but check if you entered you PW correctly!
haree said:
hi
i have afew questions can u kindly answer
1. is wipe a must before flashing a new rom
i have flashed the Modoco rom and it was mentioned that this was not needed but i have read in many threads asking to do the same before flashing
2.to bring back contacts after flashing new rom can i use
a. backup pro or titanium backup
b. can i just use the out look sync and get back my contacts from my PC
3. if i restore the stock rom and latter on want to try one of the cooked roms do i need to do the rooting again ie does flashing stock rom remove the rooting
Note : i have been a WM user new to AM is why im asking such questions in the WM i have one app pim backup which would get back all my contacts in 1 min and when flashing any WM it will automatically wipe all the data from the phone this does not seem to be the case with AM is why i have asked above Questions
thanks in advance
Click to expand...
Click to collapse
1. As I told you via PM already: If the ROM is based on the same source ROM (HTC stock in your case) then a wipe is NOT required, but if you switch android version (AOSP, Vanilla, FroYo, Eclair) then you HAVE TO wipe.
2.
a) I had only problems with Titanium backup concerning restoring contacts. I would suggest using MyBackup Pro
b) Well, if you can sync to outlook, then I suppose yes, but I really doubt that these features are implemented in custom ROMs...
3. Well, if you mean restoring the NAND-backup and then flashing another cooked ROM (which are all rooted by default ), then no - you don't need to re-root. Only if you would flash the original/official HTC ROM which comes shipped as exe-file, but I don't see the sense in flashing this one...use your NAND-backups
TheSSJ said:
Titanium Backup needs Busybox and su to work. If Titanium Backup tells you that it found BusyBox, then try to copy "su" to the following to locations:
/system/bin and /system/xbin
I think with the first it should work then.
hi
thanks buddy for patiently answering all my Q
i got it now but i dont know why this Bl***dy market does not work what every i try ie when the net is on and ur browsing u see the E on ur phone screen and then the 2 white arrows flash this it self does not happen when i try to log in to market
just dont know what is wrong
right now im using Modoco and happy with it seems to be real fast and everything is working on this ROM
Click to expand...
Click to collapse

[Q] busybox and nandroid issues

I have been experimenting with my new droid/milestone the past couple of days, odd problems which I am past now but still curious about.
Firstly after flashing the 2.1 sbf with rsd it will autoboot and screen slider will be there, then when I reboot, screen slider will be missing. This only happend when I flashed an sbf from the sbf site(2.1 uk version, not service), doing a factory reset didn't have any problem -could reboot as many times and slider would be there.... then suddenly after factory boot it would dissapear after first boot. Anyway solved this problem by installing screen mode widget after first boot after flash, solved problem, but still weird. Fixed this now but still curious about it.
Next, nandroid backup is missing from recovery menu, I have rooted and can execute root commands after typing "su" via Android Terminal emulator, so pretty sure is rooted. So why no nandroid? I thought I could do nandroid backup after rooting.
Next busybox won't install, tried the app, did the "searching system" for over an hour(not exagerrating), eventually gave up and uninstalled.
Trying to do a "manual busybox install" now, using this guide:
Busybox How-to? - Android Forums
Can't execute commands via usb/adb in recovery mode as the other guy suggested so been trying these commands both with terminal emulator on phone, and usb-debugging mode with windows shell. Using these I can go "su" and type "ls" to see files on my droid phone....but when I try to "mount /system" or /sdcard from windows I just get a print about mount options, when I try to "cat /sdcard/busybox > /system/xbin/busybox" I get a "file is read only" error.
I would like advice on how to install busybox, I would like to do it manually(because the app seems to not work for me, remember I waited over an hour while it "searched") and I want to learn to manually do stuff anyway. I tried to chmod /system/xbin too, but that didn't seem to change it from read only.
Also any thoughts on why nandroid backup is missing from my recovery menu even though my droid is rooted. I thought it was meant to appear.
I am still learning and researching, and appreciate any links or tips.
droidtech1 said:
Next, nandroid backup is missing from recovery menu, I have rooted and can execute root commands after typing "su" via Android Terminal emulator, so pretty sure is rooted. So why no nandroid? I thought I could do nandroid backup after rooting.
Click to expand...
Click to collapse
This is odd. Which OpenRecovery did you install? Androidiani? GOT? Or the "original" OpenRecovery? Are you aware, that you come into OpenRecovery by starting Recovery Mode and apply update.zip?
droidtech1 said:
Next busybox won't install, tried the app, did the "searching system" for over an hour(not exagerrating), eventually gave up and uninstalled.
Trying to do a "manual busybox install" now, using this guide:
Busybox How-to? - Android Forums
Click to expand...
Click to collapse
Using the app from the market worked like a charm for me. No idea, what might have gone wrong for you...
droidtech1 said:
Can't execute commands via usb/adb in recovery mode as the other guy suggested so been trying these commands both with terminal emulator on phone, and usb-debugging mode with windows shell. Using these I can go "su" and type "ls" to see files on my droid phone....but when I try to "mount /system" or /sdcard from windows I just get a print about mount options, when I try to "cat /sdcard/busybox > /system/xbin/busybox" I get a "file is read only" error.
Click to expand...
Click to collapse
For remounting, try "mount -o rw,remount /dev/block/mtdblock6 /system" and for undoing this, use "ro" instead of "rw".
droidtech1 said:
I would like advice on how to install busybox, I would like to do it manually(because the app seems to not work for me, remember I waited over an hour while it "searched") and I want to learn to manually do stuff anyway. I tried to chmod /system/xbin too, but that didn't seem to change it from read only.
Click to expand...
Click to collapse
You should download busybox and put the "busybox"-file in the directory /sdcard. After that do:
Code:
# su
# mount -o rw,remount /dev/block/mtdblock6 /system
# cp /sdcard/busybox /system/xbin
# cd /system/xbin
# chmod 755 busybox
# ./busybox --install
# mount -o ro,remount /dev/block/mtdblock6 /system
One thought at the end: How did you root?
I rooted by flashing "vunerable recovery" using RSD lite, copied milestone-root.zip to sd card, renamed it update.zip, rebooted into recovery mode, flashed update.zip from there.
I didn't realise I had to install something like open recovery, think because I remember not having to do that on my pulse? Anyway will try and install one of those now.
Thanks those commands at the end helped, actually managed to copy busybox to /system/xbin, however the 2nd last one "./busybox --install" gave me a load of errors -all being no such file or directory, for example "/usr/bin/wc: no such file"
about 30 of those path errors. Maybe the command path "./busybox" needs to be something else?
ah, okay. sorry, I thought you already installed an openrecovery. for many cool features you will need it (e.g. nandroid, for overclocking it's not a must but a nice-to-have). please don't use GOT, it's rather old already. androidiani is okay, I think.
I think your previous attempts to install busybox via the app etc. mixed up some internal links in the device. please reboot and try again (the above steps except the "cp ..."). seems like the app tried to install busybox to /usr/bin but failed... I hope this failed attempt will be fixed by a simple reboot. otherwise it would be great to have the output of:
Code:
# su
# ls /usr/bin
No I re-flashed my main sbf and also did a factory reset to do a clean start, only thing since that full wipe I have done is rooting in the method I described, installed the screenmode widget, textedit, and android terminal emulator.
I have no such file /usr, are you sure I should have this in droid/milestone?
Here is my full output of my root system using ls:
tmp
pds
cdrom
sqlite_stmt_journals
config
cache
sdcard
d
etc
system
sys
sbin
proc
init_prep_keypad.sh
init.rc
init.mapphone_umts.rc
init.mapphone_cdma.rc
init.goldfish.rc
init
default.prop
data
root
dev
perhaps "/usr" is a sub inside one of the above folders? I tried using "find" to find it but that command dosn't seem to work since it won't even find the ones I can see with ls
I found it, /usr is inside /system... so if busybox was moved to /system/xbin, I'm guessing the ./ means install it to the parent directory which was /system which /usr is also in.
The errors I got said no such file "/usr" so It seems like it is trying to install to the wrong directory.... perhaps the command should be "busybox --install" or "/busybox --install" I don't want to experiment and mess things up before your opinion on this.
*edit almost forgot, output of /system/usr is
keychars
bin
srec
keylayout
share
output of /system/usr/bin is
panic_daemon
gki_pd_notifier
nvm_daemon
clean_dex.sh
brcm_guci_drv
bplogd_daemon
This is really strange. Maybe your busybox-file is corrupt.
Where did you download the busybox-file?
Which sbf did you flash?
So for explanation-purposes: When you put an executable or script file in any directory, you can execute it by first making it executable ("chmod 755 /system/xbin/busybox"), changing to that directory ("cd /system/xbin") and then executing it by adding "./" in front of it. The dot slash always stands for the _current_ directory. The _parent_directory has two dots "../".
If you want, you may try:
# /system/xbin/busybox --install
instead of
# ./busybox --install
Or maybe try this one:
# /system/xbin/busybox --install -s /system/xbin
Last time, I installed busybox into the directory /data/busybox, which worked brilliantly, but this path turned out to be unpractical. So I wanted to reinstall it in a different directory. I removed everything from /data/busybox including the directory itself and tried to start the whole procedure with /system/xbin. But that time it protested, that there were no files in "/data/busybox/...". Conclusion: The last busybox-install affected the second one. When I remember correctly I rebooted after that and used the app from the market *g*
My main sbf I flashed was android 2.1(uk version).
I downloaded busybox 1.17.2(won't let me post url here), was from droidforums dot net.
I don't remember if I tried all of his commands, but the last one on that forum seems to have worked.. I think......... it was:
"busybox --install /system/xbin/"
After remounting with your commands and typing the above command, I didn't get any errors, I synced and rebooted and now when I "ls /system/xbin" it shows a bunch of files/names which look like busybox commands. When I type "busybox" it outputs a bunch of commands too... so I am guessing this means it has succesfully installed? I can't say I tried these before attempting install so I have no comparison but I assume I would have a different output if busybox wasn't installed.
So assuming it worked, why would
"busybox --install /system/xbin/" work, and
"/system/xbin/busybox --install" not?
I also managed to install open recovery and do a nandroid backup succesfully
I have another short question, not specific to android but happens in all terminals I use, windows and linux alike. Sometimes I cannot execute commands anymore and it just becomes text in the terminal(just re-echo'ing my text output, without executing any functions)... can't remember specifically when it happened on my windows or linux pc shells, but on my android it happens whenever I have to give "SU" permission to the terminal, I have to quickly close the terminal and reload it again to get su access. I'm sure there is a name for this "state" where you are locked out of using commands in the shell and just typing text but I can't find a way to get out of it(without closing and re-opening terminal), there must be some key combination to be able to execute commands again in the current terminal session. If you have any idea what I am talking about?
Thanks for all your help so far.
droidtech1 said:
My main sbf I flashed was android 2.1(uk version).
Click to expand...
Click to collapse
Don't want to try one of the 2.2?
droidtech1 said:
I downloaded busybox 1.17.2(won't let me post url here), was from droidforums dot net.
I don't remember if I tried all of his commands, but the last one on that forum seems to have worked.. I think......... it was:
"busybox --install /system/xbin/"
After remounting with your commands and typing the above command, I didn't get any errors, I synced and rebooted and now when I "ls /system/xbin" it shows a bunch of files/names which look like busybox commands. When I type "busybox" it outputs a bunch of commands too... so I am guessing this means it has succesfully installed? I can't say I tried these before attempting install so I have no comparison but I assume I would have a different output if busybox wasn't installed.
Click to expand...
Click to collapse
Yes, this sounds very much like installation was successful.
droidtech1 said:
So assuming it worked, why would
"busybox --install /system/xbin/" work, and
"/system/xbin/busybox --install" not?
Click to expand...
Click to collapse
typing "busybox" without the path in front of it worked, because busybox is in the directory /system/xbin, which is already in your $PATH-variable (try "echo $PATH"). So the command interpreter (shell) will automatically look up "busybox" in /system/xbin.
I had a look at the busybox syntax and it's actually
Code:
busybox --install [-s] [INSTALLDIR]
So you have to put the directory you want to install in at the end. That's what your last command makes use of
droidtech1 said:
I have another short question, not specific to android but happens in all terminals I use, windows and linux alike. Sometimes I cannot execute commands anymore and it just becomes text in the terminal(just re-echo'ing my text output, without executing any functions)... can't remember specifically when it happened on my windows or linux pc shells, but on my android it happens whenever I have to give "SU" permission to the terminal, I have to quickly close the terminal and reload it again to get su access. I'm sure there is a name for this "state" where you are locked out of using commands in the shell and just typing text but I can't find a way to get out of it(without closing and re-opening terminal), there must be some key combination to be able to execute commands again in the current terminal session. If you have any idea what I am talking about?
Click to expand...
Click to collapse
Sounds like this is just the state, when shell is busy, i.e. when the last process you started is still running and no prompt ($ or #) is displayed. You may kill the last process in linux using CTRL+C, which will hopefully bring back the shell prompt. No idea which shortcut replaces this on the milestone/droid. I never use any android terminals, but only the ADB-Shell: http://developer.android.com/guide/developing/tools/adb.html
I'm learning to build apps for android so I thought having 2.1 on my droid would be better for testing (instead of 2.2). I also have a Nexus-S with 2.3 and a tmobile-pulse with 1.5. So I want to keep the most native version on each phone since most consumers won't install custom roms, although some will get updates anyway.
I use my droid a lot when I am out and use the terminal a lot so having busybox too has given me more to play around with. I actually find my droid much better working on than the nexus s, love the keyboard and dpad.

[ADT-1] Casting

So I picked up a ADT-1 due to having Ethernet and more HD space on it. FOund out only certain apps can "cast" to it due to it being a dev device has there been anyone that figured out what needs to get it to have full casting features?
https://developer.android.com/tv/adt-1/index.html
Try changing ro.build.type to eng in build.prop, that should open up all apps.
/sub
let us know if this works
Confirmed this works!
HomerSp = worth his weight in gold.
Sorry
HomerSp said:
Try changing ro.build.type to eng in build.prop, that should open up all apps.
Click to expand...
Click to collapse
Sorry to sound like a newbie, however can someone teach me how to do this? I was trying to look it up on xda but had no luck finding anything. If anyone point me in the right direction, I would be very happy. Thank you again
Bboy_LeoGun said:
Sorry to sound like a newbie, however can someone teach me how to do this? I was trying to look it up on xda but had no luck finding anything. If anyone point me in the right direction, I would be very happy. Thank you again
Click to expand...
Click to collapse
1. Root
2. Open /system/build.prop
3. Change the line
4. Reboot
5. Enjoy.
I'm trying to do this but I'm being very unlucky. Not sure what's going wrong and any light on the matter will be greatly appreciated.
I changed the ro.build.type from `user` to `eng` and my device (on LPX13D) stops booting completely. All I see is the android logo and then blank screen. I already tried two times. The process I did is (from sudo on my Ubuntu 14 machine)
- adb pull /system/build.prop
- edit build.prop on `nano` on Ubuntu (change only that line)
- adb push build.prop /sdcard/
- adb shell
- su
- mount -o remount,rw /system
- mv /sdcard/build.prop /system/
the second time I adb pull /system/build.prop again just to check that the only thing changed was that, and it was fine.
The only thing I've been able to do to recover the system is to:
- install CWM from here https://forum.gtvhacker.com/adt-f52/topic1629.html (fastboot flash recovery <filename>)
- flash the image from here http://forum.xda-developers.com/har...t/adt1-stock-molly-images-unbricking-t2927888
- and then using the root from this post: https://plus.google.com/+Chainfire/posts/a5YshULM8hf to be able to "adb shell su"
any help? Maybe some bizarre permission on my ubuntu machine because I'm on "sudo shell" ?
Budius said:
I'm trying to do this but I'm being very unlucky. Not sure what's going wrong and any light on the matter will be greatly appreciated.
I changed the ro.build.type from `user` to `eng` and my device (on LPX13D) stops booting completely. All I see is the android logo and then blank screen. I already tried two times. The process I did is (from sudo on my Ubuntu 14 machine)
- adb pull /system/build.prop
- edit build.prop on `nano` on Ubuntu (change only that line)
- adb push build.prop /sdcard/
- adb shell
- su
- mount -o remount,rw /system
- mv /sdcard/build.prop /system/
the second time I adb pull /system/build.prop again just to check that the only thing changed was that, and it was fine.
The only thing I've been able to do to recover the system is to:
- install CWM from here https://forum.gtvhacker.com/adt-f52/topic1629.html (fastboot flash recovery <filename>)
- flash the image from here http://forum.xda-developers.com/har...t/adt1-stock-molly-images-unbricking-t2927888
- and then using the root from this post: https://plus.google.com/+Chainfire/posts/a5YshULM8hf to be able to "adb shell su"
any help? Maybe some bizarre permission on my ubuntu machine because I'm on "sudo shell" ?
Click to expand...
Click to collapse
build.prop has to be chmodded to 0644, or the device will not boot.
HomeSp I can't thank you enough!
That was exactly the issue. Third time is a charm.
So at the end of the procedure I:
- cd /system/
- mv build.prop build.prop.bak (just for the the sake of it)
- mv /sdcard/build.prop /system/
- chmod 0644 build.prop
- chown :root build.prop (prolly not needed but what-a-heck, why not)
- ls -l (and checked that both build.prop and build.prop.bak are exactly the same permission, owner and group)
- exit, exit adb reboot and all works great"
Thanks again!!!
Budius said:
- and then using the root from this post: https://plus.google.com/+Chainfire/posts/a5YshULM8hf to be able to "adb shell su"
Click to expand...
Click to collapse
For the purposes of modifying build.prop using "adb shell su", do you only have to flash the bootloader image from the linked post? I'd like to make the bare minimum changes so that future OTA's will install after restoring the original build.prop and flashing the stock bootloader.
jm9843 said:
For the purposes of modifying build.prop using "adb shell su", do you only have to flash the bootloader image from the linked post? I'd like to make the bare minimum changes so that future OTA's will install after restoring the original build.prop and flashing the stock bootloader.
Click to expand...
Click to collapse
my idea was a bare-minimum changes too. I just ended up ****ing up stuff and had to re-built a couple of times until I made it right.
but yeah, if you're comfortable with terminal commands and do the proper `chmod` (which I originally didn't), you can get everything done with "adb shell su" following like this:
- from PC: adb shell pull file to your PC
- from PC: edit file
- from PC: adb shell push file to /sdcard/
- from PC: adb shell
- from device shell: su
- from device shell/su: make /system/ writable, chmod file, rename "old" build.prop, copy new one over, double check chmod before rebooting.
ps.: the root from that post does install SuperUser.apk on the device, it's there on the UI, but after you do those changes there's some options in the .apk to remove root and uninstall it (if you want to)
I just thought that I'd directly use some build prop editor apk and do it easily but now my device is bricked :v
Stock ROM on download.
I'm just getting a black screen and bootloader.
So, the build.prop edit detailed in this thread works fine to make the ADT-1 a cast target for all Google Cast enabled apps. The problem is that it's hardly worth doing right now since Google Cast support on Android TV seems to be a work in progress. There's a support article that details third-party apps that are not supported - https://support.google.com/androidtv/answer/6123347
In addition to the apps listed there, I found that Watch ESPN isn't working on ADT-1 either. It's selectable in the app, but the video playback will not start. Here's to hoping that Google brings the Google Cast Receiver app for Android TV up to snuff soon - https://play.google.com/store/apps/details?id=com.google.android.apps.mediashell
jm9843 said:
So, the build.prop edit detailed in this thread works fine to make the ADT-1 a cast target for all Google Cast enabled apps. The problem is that it's hardly worth doing right now since Google Cast support on Android TV seems to be a work in progress. There's a support article that details third-party apps that are not supported - https://support.google.com/androidtv/answer/6123347
In addition to the apps listed there, I found that Watch ESPN isn't working on ADT-1 either. It's selectable in the app, but the video playback will not start. Here's to hoping that Google brings the Google Cast Receiver app for Android TV up to snuff soon - https://play.google.com/store/apps/details?id=com.google.android.apps.mediashell
Click to expand...
Click to collapse
Have any of you tried Slingplayer casting after changing build.prop?
Apple TV just died recently, it was the most reliable thing for Airplaying Slingplayer. Chromecast slingplayer kind of is ****ty at times.
Followed Budius' instructions and it worked perfectly.
adb pull /system/build.prop
----(edit build.prop on Notepad++ and changed ro.build.type=user to ro.build.type=eng)
adb push build.prop /sdcard/
adb shell
su
mount -o remount,rw /system
cd /system/
mv build.prop build.prop.bak
mv /sdcard/build.prop /system/
chmod 0644 build.prop
chown :root build.prop
ls -l
---(checked that both build.prop and build.prop.bak are exactly the same permission, owner, and group)
mount -o remount,ro /system
exit
exit
adb reboot
during the update from 5.0 -> 5.0.2 my ADT-1 stopped working again
It showed the little droid with the belly open and an error message
so that means here I went again to restore it, and this time I manage to streamline a bit the process, so let's share with you guys. Remember, my idea with this process is to have STOCK, but with Cast working from any app. I have no intention to root, or flash custom this or that. I want something that I can cast without issues and hopefully it will update the next update without problems.
first of all, the CWM link I posted before is giving malware warnings on Chrome so I found an alternative, and of course XDA is the source (see downloads).
so to factory restore ADT-1 to good working condition, was the same I said before:
- install CWM:
Code:
fastboot flash recovery cwm_molly_recovery_lpx13d.img
- install stock image. CWM->install zip-> from ADB:
Code:
adb sideload update-molly-Stock-LPV79-1.zip
- reboot and let auto-update run until the end.
now to enable cast to all apps with absolutely minimal modifications to the system (hopefully enabling future updates to run without issues)
- reboot ADT-1, holding the button, enter fastboot mode
- reboot to the CWM, but without installing it:
Code:
fastboot boot cwm_molly_recovery_lpx13d.img
- in CWM go to `mount n storage` -> mount /system
and carry on to do the build.prop modification from there, the trick is that I did not have to install a custom recovery and did not have to install super user. I made the modification directly via a RAM-only CWM and that's it. So below is just a copy of my previous post
Code:
> adb pull /system/build.prop /home/budius/build.prop
then change the build.prop on my computer and rename to new_build.prop.
And back to terminal
Code:
> adb push /home/budius/new_build.prop /system/new_build.prop
> adb shell
# cd system
# mv build.prop build.prop.bak
# mv new_build.prop build.prop
# chmod 0644 build.prop
And that's all! Full cast enabled to ADT-1 with the most absolutely minimal system changes I could come up with :victory: :highfive:
Downloads:
- here you'll find a very nice workin CWM.
- good working stock Android TV image for ADT-1
bonus:
while searching stuff I found this: https://plus.google.com/+AdamLawrence/posts/5Yr5vG7QJUq
I didn't try it but it seems useful, so the link is there.

[HOW TO] Debrand boot animations without flashing new ROM

** Requires ROOT+Busybox and either Terminal or a capable File Manager
So you don't feel like flashing a new ROM and losing all your data, but your carrier's boot up and shutdown branding is getting on your nerves? Here is what you do, the basic idea is the same as putting on a new boot animation
I'll assume you're using a Terminal and bootsamsung.qmg for the rest of this, the other files follow the same method
Copy stock boot and shutdown animations onto your SD card, I'll call the path to this location %sd%. A copy of the stock files in the attached archive.
Open terminal and become root
Code:
su
You may need to remount your /system partition as writable, if you're connecting via ADB, adb.exe may crash here - that's fine, just re-connect the USB cable and you shouldn't need to repeat this step again
Code:
mount -o remount,rw [COLOR="RoyalBlue"]/system[/COLOR]
Copy bootsamsung.qmg from %sd% to /system/media/,
Code:
busybox cp -f "[COLOR="RoyalBlue"]%sd%[/COLOR][B][COLOR="Green"]bootsamsung.qmg[/COLOR][/B]" "[COLOR="RoyalBlue"]/system/media/[/COLOR][B][COLOR="Green"]bootsamsung.qmg[/COLOR][/B]"
Set the permissions of the file to 644,
Code:
chmod [COLOR="red"]644[/COLOR] "[COLOR="RoyalBlue"]/system/media/[/COLOR][B][COLOR="Green"]bootsamsung.qmg[/COLOR][/B]"
Get rid of the SD card copy if you don't want it anymore,
Code:
rm -f "[COLOR="RoyalBlue"]%sd%[/COLOR][B][COLOR="Green"]bootsamsung.qmg[/COLOR][/B]"
Clean up any overriding animations, I had this happen for my shutdown animation where my carrier had a shutdown directory in /system/media/video/ which contained another copy of shutdown.qmg, so check for the existence of these and remove them, e.g.
Code:
if [ -f [COLOR="RoyalBlue"]/system/media/video/[/COLOR][B][COLOR="Purple"]bootsamsung[/COLOR]/[COLOR="Green"]bootsamsung.qmg[/COLOR][/B] ]; then
rm -f [COLOR="RoyalBlue"]/system/media/video/[/COLOR][B][COLOR="Purple"]bootsamsung[/COLOR]/[COLOR="Green"]bootsamsung.qmg[/COLOR][/B]
fi
Reboot and see what happens!
Extra notes: Always keep backups of original files. If you can't get past the boot animation, restore the backups.
paulie-uk said:
** Requires ROOT+Busybox and either Terminal or a capable File Manager
So you don't feel like flashing a new ROM and losing all your data, but your carrier's boot up and shutdown branding is getting on your nerves? Here is what you do, the basic idea is the same as putting on a new boot animation
I'll assume you're using a Terminal and bootsamsung.qmg for the rest of this, the other files follow the same method
Copy stock boot and shutdown animations onto your SD card, I'll call the path to this location %sd%. A copy of the stock files in the attached archive.
Open terminal and become root
Code:
su
You may need to remount your /system partition as writable, if you're connecting via ADB, adb.exe may crash here - that's fine, just re-connect the USB cable and you shouldn't need to repeat this step again
Code:
mount -o remount,rw [COLOR="RoyalBlue"]/system[/COLOR]
Copy bootsamsung.qmg from %sd% to /system/media/,
Code:
busybox cp -f "[COLOR="RoyalBlue"]%sd%[/COLOR][B][COLOR="Green"]bootsamsung.qmg[/COLOR][/B]" "[COLOR="RoyalBlue"]/system/media/[/COLOR][B][COLOR="Green"]bootsamsung.qmg[/COLOR][/B]"
Set the permissions of the file to 644,
Code:
chmod [COLOR="red"]644[/COLOR] "[COLOR="RoyalBlue"]/system/media/[/COLOR][B][COLOR="Green"]bootsamsung.qmg[/COLOR][/B]"
Get rid of the SD card copy if you don't want it anymore,
Code:
rm -f "[COLOR="RoyalBlue"]%sd%[/COLOR][B][COLOR="Green"]bootsamsung.qmg[/COLOR][/B]"
Clean up any overriding animations, I had this happen for my shutdown animation where my carrier had a shutdown directory in /system/media/video/ which contained another copy of shutdown.qmg, so check for the existence of these and remove them, e.g.
Code:
if [ -f [COLOR="RoyalBlue"]/system/media/video/[/COLOR][B][COLOR="Purple"]bootsamsung[/COLOR]/[COLOR="Green"]bootsamsung.qmg[/COLOR][/B] ]; then
rm -f [COLOR="RoyalBlue"]/system/media/video/[/COLOR][B][COLOR="Purple"]bootsamsung[/COLOR]/[COLOR="Green"]bootsamsung.qmg[/COLOR][/B]
fi
Reboot and see what happens!
Extra notes: Always keep backups of original files. If you can't get past the boot animation, restore the backups.
Click to expand...
Click to collapse
Hello, I'm interested in debranding my verizon s5. I'd love to get rid of the Verizon screen at bootup. I read through your directions and it seems that you are suggesting overwriting the animation with the stock that you provided. All good. It is the use of the terminal that I am completely unfamiliar with. I tried using adb.exe in a command window inside of windows 7 and it didn't even like the first command 'su' My phone is rooted with a custom rom and busybox in developer mode. Could you help me out with what terminal to use and how to connect etc. to enter the commands? I have a decent filemanager installed but It doesn't let me write to system. Thanks for this post.
Eaglebiker said:
Hello, I'm interested in debranding my verizon s5. I'd love to get rid of the Verizon screen at bootup.
Click to expand...
Click to collapse
My first comment must be to say I have a G900F, the international version of the phone and it's using a stock ROM with a few tweaks, e.g. root. A custom ROM will have changed the system partition already so this method shouldn't be applicable there - if it shows a carrier logo on a custom ROM then it's in another partition, not system
Eaglebiker said:
I read through your directions and it seems that you are suggesting overwriting the animation with the stock that you provided. All good. It is the use of the terminal that I am completely unfamiliar with.
Click to expand...
Click to collapse
I gave terminal instructions so people could do it only using their phone but as you've noticed, it's not the only option
Eaglebiker said:
I tried using adb.exe in a command window inside of windows 7 and it didn't even like the first command 'su'
Click to expand...
Click to collapse
If you are using adb, make sure that adb can gain root - the flag should be somewhere in your superuser's settings - then with your USB connected launch adb into shell mode from your computer. This makes adb act as a terminal
Code:
adb shell
If you see a $ then you are not root and will need to gain root, i.e. run su
If you see a # then you are root and don't need to do that
Eaglebiker said:
My phone is rooted with a custom rom and busybox in developer mode.
Click to expand...
Click to collapse
All good things!
Eaglebiker said:
Could you help me out with what terminal to use and how to connect etc. to enter the commands?
Click to expand...
Click to collapse
The terminal I use is can be found here (though I used v1.0.65). Most custom ROMs already include it so you may find it in your apps already. It's all on your phone so you'd type on your phone's keyboard as normal. You shouldn't have to use this if you want to use ADB.
Every time I wrote a %path% you will need to enter the real path for what you have on your device, e.g. %sd% may be /extSdCard/
Eaglebiker said:
I have a decent filemanager installed but It doesn't let me write to system.
Click to expand...
Click to collapse
What doesn't let you do this? If it's "read only" then you may need to remount the /system partition (my step 3). File managers like the one you get with CM do let you do root things but it needs to be in root mode or prompt mode (see it's settings). To find /system in a file manager, the easiest way is to keep going up until you're at /, then you should be able to go down through [/B]/system[/B]
Eaglebiker said:
Thanks for this post.
Click to expand...
Click to collapse
Thank you for letting me give some meaningful answers in post 3!
The Rom I'm using would be better described as a stock lollipop rom for the 900v with a few tweaks.
I now understand that you can have a terminal on the s5. I've installed the terminal and greatly prefer it. Using a terminal on the s5 hadn't even occurred to me and it sounds much easier then hooking to a computer needlessly. Awesome.
I manage to get su access #. in step 2.
in step 3 I type in the mount command and nothing seems to happen. no errors
in step 4 it tells me the folder or file doesn't exist. I'm certain it does. I can see it in my file manager. in the folder /extSdCard/bootsamsung.qmg and the destination folder is /system/media as well. I've tried it with and without quotes and no joy. Any clue what is going on?

Now What?

Now that we have root, what things are we going to be focusing on next? Probably Safestrap and ROMs. What cool things have you guys found with root?
Vlasp said:
Now that we have root, what things are we going to be focusing on next? Probably Safestrap and ROMs. What cool things have you guys found with root?
Click to expand...
Click to collapse
Well for one thing if you disabled/uninstall Unified Search, it allows google search to work correctly in the launcher, also without root you can replace the amazon keyboard with the google keyboard and get voice search.
Edit: We need to probably install Google play services properly to get Google Play Games to work correctly but I am not sure.
The ability to install apps depending on root is awesome.
If you are asking for wishes, then I wish I could use CyanogenMod on this device.
I have de-amazonified my tablet a bit. Cant wait to get a custom rom installed on it though.
we need a safe list with what apps can we delete... i did the same but i don't know for sure what to delete and what to keep... i mention that i don't use amazon apps nor i logged in..
Sent from my KFFOWI using XDA Forums
balanigga said:
we need a safe list with what apps can we delete... i did the same but i don't know for sure what to delete and what to keep... i mention that i don't use amazon apps nor i logged in..
Sent from my KFFOWI using XDA Forums
Click to expand...
Click to collapse
For the moment......
http://forum.xda-developers.com/showpost.php?p=63605889&postcount=77
If wants to remove more can give chmod 000 to apk & reboot before delete
What about reassigning the home button to a different launcher?
xT29c said:
What about reassigning the home button to a different launcher?
Click to expand...
Click to collapse
Just install another launcher and remove FireLauncher from system.
csolanol said:
Just install another launcher and remove FireLauncher from system.
Click to expand...
Click to collapse
Oh, nice. Okay, thanks!
csolanol said:
Just install another launcher and remove FireLauncher from system.
Click to expand...
Click to collapse
how can i do this? thanks in advance
Edit: nevermind I found it, thanks anyway
joelwylde said:
how can i do this? thanks in advance
Click to expand...
Click to collapse
You can use titanium backup, and remove it like that. I would make a backup firs though just in-case.
Also, I need help trying to unhide the firelauncher process. I have the command here "adb shell pm unhide [package:com.amazon.firelauncher]"
But I need the other command first so ADB can talk to my tablet. Because I ran the command, and it just says "true" when it should say "false".
joelwylde said:
how can i do this? thanks in advance
Click to expand...
Click to collapse
Working Launcher replacement thanks to @diegocr and @Awesomeslayerg ! Here's the steps:
1. See @diegocr post at http://forum.xda-developers.com/showpost.php?p=63599598&postcount=23 and download "boot-firelauncher.img"
2. Enable USB debugging
3. Install your launcher of choice!
4. On your computer, run
adb reboot bootloader
Click to expand...
Click to collapse
5. Once your tablet reboots in to fastboot, run on your computer (if you are not in the same directory as boot-firelauncher.img, put the full path):
fastboot boot boot-firelauncher.img
Click to expand...
Click to collapse
6. Tablet will reboot
7. Once booted open an adb shell:
adb shell
Click to expand...
Click to collapse
8. To back up the existing app, run:
cp /system/priv-app/com.amazon.firelauncher/com.amazon.firelauncher.apk /sdcard/Download/com.amazon.firelauncher.apk
Click to expand...
Click to collapse
9. Then nuke it!
rm /system/priv-app/com.amazon.firelauncher/com.amazon.firelauncher.apk
Click to expand...
Click to collapse
10. Now, run to restart your device:
reboot
Click to expand...
Click to collapse
Confirmed working on my tablet with FireOS 5.0.1.
Enjoy!
Forget all the formatting problems
Sent from my KFFOWI using Tapatalk
If you are already rooted you don't need to do all that stuff.
Just adb shell
su
mount -o remount,rw /system
rm -r /system/priv-app/com.amazon.firelauncher or whatever the package is called.
Reboot and it's done.
Remember to install a launcher before this.
csolanol said:
If you are already rooted you don't need to do all that stuff.
Just adb shell
su
mount -o remount,rw /system
rm -r /system/priv-app/com.amazon.firelauncher or whatever the package is called.
Reboot and it's done.
Remember to install a launcher before this.
Click to expand...
Click to collapse
Will this work if I hid the process with ADB before hand? If not, how do I unhide it? What command would I use before "adb shell pm unhide [package:com.amazon.firelauncher]"
Don't know, try if it works hiding, but I doubt it.
I want to replace the hosts file with the one of my Lenovo S660 (China phone). The S660 hosts file is about a mile long and has entries like "0.0.0.0 bad.ad.server" - a very basic but effective way to avoid a lot ads, even at apps. I have not yet took a closer look but I think I would create a mix of both files for the fire.
So, what are the steps?
I have done similar things to my rooted Sony Experia Tipo concerning modifying files at /system, which is mounted RO as default. So I remounted it RW with ES-Explorer, modified what I had to and mounted RO with ES-Explorer again.
I wonder, if this is ok, because of the security means the fire/android has.
I took a chance and I was successfull.
I attached the unchanged hosts file from my Lenovo S660 /system/etc/ as hosts.lenovo.zip file. The fire hosts has just 1 line: 127.0.0.1 localhost. The lenovo's hosts has 25858 lines.
Code:
- unzip hosts.lenovo.zip -> you get host.lenovo
- rename hosts.lenovo to hosts
- connect fire
- adb push hosts /data
- adb shell
- $ su -
- # cd /data
- # chmod 644 hosts
- # exit
- $ exit
- ES Explorer
- Enable root explorer
- remount /system rw
- go to /data
- mark hosts
- cut hosts (to memory)
- go to /system/etc
- mark hosts
- rename hosts to hosts.old
- insert hosts from memory
- remount /system ro
- exit ES Explorer
done.
should work, use at own risk.
Note: You cannot chmod 644 at /mnt/sdcard1 because it is vfat there, that's why you use /data.
Note: You cannot write to /system/etc while at adb shell, even if it is mounted RW, that's why you have to use ES Explorer which will ask you to choose the path with android overlay window - which makes it work (at least my experience).
If you have apps which showed ads before, then you might keep on seeing the very last forever. Or a broken link sign. Or even a popop with broken link sign. Or your ads hosts is missing at the lenovo hosts file and you keep on seeing ads. There even my be websites you cannot visit anymore - which I have not yet experienced, but the risk exists, or will come.
If interested, take a look at http://winhelp2002.mvps.org/hosts.htm for more information and use for your windows or linux pc.
If you don't like it you can go back, you have a copy of your old hosts file.
I want to replace the hosts file with the one of my Lenovo S660 (China phone). The S660 hosts file is about a mile long and has entries like "0.0.0.0 bad.ad.server" - a very basic but effective way to avoid a lot ads, even at apps.
Click to expand...
Click to collapse
Check out the adaway app (open source). It blocks ads through the host file just like you're doing except it puts the host file in place for you, combines host files from a couple different sources (running de-duplication on them) & auto updates your host file as new ad severs are added or removed. Absolutely beats rolling your own host file manually.
That is new information to me, thanks.

Categories

Resources