How to get r/w in ADB - LG Optimus 2x

I currently have the 1080p 30fps camera mod on and I'm wanting to go back to the original, i have the camera.apk to go back on but when I try to push it, it says READ ONLY FILE SYSTEM.
I had a hunt around and found this but didn't work
adb shell sysrw
adb push (file name.apk /system/app/)
adb shell sync
adb shell sysro
then i found this
adb shell mount -o remount,rw,codepage=utf8,vfat,xattr,check=no /dev/stl5 /system
and that didn't work, Im pretty new to ADB etc and trying to get the hang of it so take it easy on me

Kickasskev said:
I currently have the 1080p 30fps camera mod on and I'm wanting to go back to the original, i have the camera.apk to go back on but when I try to push it, it says READ ONLY FILE SYSTEM.
I had a hunt around and found this but didn't work
adb shell sysrw
adb push (file name.apk /system/app/)
adb shell sync
adb shell sysro
then i found this
adb shell mount -o remount,rw,codepage=utf8,vfat,xattr,check=no /dev/stl5 /system
and that didn't work, Im pretty new to ADB etc and trying to get the hang of it so take it easy on me
Click to expand...
Click to collapse
you can use my zip in recovery
stock_Camera

LOOOOL this is the 1080p 30fps that i already have on my phone I wanna go back to stock.
I will put my STOCK camera.apk in the zip
Thanks

didn't work
Anymore idea's
Or Commands

Bump......
Sent from my LG-P990 using XDA App

i think you need to su first?

adb remount before adb shell

Hi, You can download the original LGE-Camera.apk file below...
Google or yahoo or find your way to get an app called: root manager(Paid app on market)
Not suppose to talk about 'where-to-download-paid-app' here... So i guess you need to google.
Copy the Camera.apk to SDCARD
Go to System>App>, Mount R/W, Delete the camera app.
Go back to SDCARD and cut/copy the camera.apk
Return to System>App>Paste file here.
You can see the 'Mount R/W' Button on the 'App' folder itself. So don't ask me how to mount R/W.
Cheers A reboot may be necessary.

in adb you need to enter
su
mount -o rw,remount -t yaffs2 /dev/block/mtdblock3 /system

Thanks for all the replys i will try them when i get home from work
Sent from my LG-P990 using XDA App

I tried to instal the LG Contact.apk this way (to replace the stock one)
Code:
C:\Program Files\Android\android-sdk\platform-
1908 KB/s (3175637 bytes in 1.625s)
pkg: /data/local/tmp/Contacts_lg.apk
Failure [INSTALL_FAILED_ALREADY_EXISTS]
Any idea ?

Don't install it, push it into place.

Rusty! said:
Don't install it, push it into place.
Click to expand...
Click to collapse
Yes, by you don't need to install those default apk. Just place it in system/app, and you will see it in your menu screen. If nothing happen, reboot your phone.

Related

How do you install new HTC_IME?

Hi I was trying to install the new HTC_IME on my phone right now I am currently using 2.0 and I tried to install with appsinstaller and it didn't work. So is there a way to do it threw terminal emulator, or threw recovery?
I don't use adb cause I tried setting it up and it didn't work.
So somebody please give me a good reply! Thanks!
try with astro
if astro doesn't work try this.
you must have adb working. adb does wonders. works every time. top cmds is for adb and bttm is terminal on phone.
Adb remount
Adb push HTC_IME.apk system/app
Adb shell rm system/sd/app/HTC_IME.apk
Adb shell rm data/app/HTC_IME.apk
Adb shell reboot
Or from terminal
Mount -o rw,remount -t yaffs2 dev/block/mtdblock3 /system
Cp *yourdir*/HTC_IME.apk system/app
rm data/app/HTC_IME.apk
rm system/app/HTC_IME.apk
reboot
PHP:
since you dont use adb, if your using any kind of windows let me know and i can personally walk you thru an adb setup. i have encountered the worst of worst mess ups. durrr lol... fosho . . . . .
that doesnt make any sense, why are you removing HTC_IME right after you're done pushing it?
You need three files for HTC IME to work, HTC_IME.apk, Clicker.apk (both of those in /system/app or /data/app) and libt9.so (in /system/lib)
Assuming you place all three in C:\
Code:
adb remount
adb push C:\libt9.so /system/lib
adb push C:\Clicker.apk /system/app (or /data/app if you don't have space)
adb push C:\HTC_IME.apk /system/app (or /data/app if you don't have space)
no need to reboot, just give it time to finish dexopting (about a minute) then go to Settings>Locale & Text and enable (checkmark) Touch Input, disable Android Keyboard if you wish.
About where to get the files? search, but it's easier if you search inside Cyanogen's (version 4.0.4 and below) roms and pull them from those.
rockin_mod said:
if astro doesn't work try this.
you must have adb working. adb does wonders. works every time. top cmds is for adb and bttm is terminal on phone.
Adb remount
Adb push HTC_IME.apk system/app
Adb shell rm system/sd/app/HTC_IME.apk
Adb shell rm data/app/HTC_IME.apk
Adb shell reboot
Or from terminal
Mount -o rw,remount -t yaffs2 dev/block/mtdblock3 /system
Cp *yourdir*/HTC_IME.apk system/app
rm data/app/HTC_IME.apk
rm system/app/HTC_IME.apk
reboot
PHP:
since you dont use adb, if your using any kind of windows let me know and i can personally walk you thru an adb setup. i have encountered the worst of worst mess ups. durrr lol... fosho . . . . .
Click to expand...
Click to collapse
What do you mean by *yourdir*? Lol sorry kinda of a noob to this
Brandice128 said:
What do you mean by *yourdir*? Lol sorry kinda of a noob to this
Click to expand...
Click to collapse
First of all thank you for taking my advice , the Q & A section is the best place for all your questions about android . Seeing that your new here it would be wise that you do some research on the following
ADB
zip7
rar
cyanogen's 1.4 recovery
terminal commands
and so on . There's a lot but as you search you will find them ...
NOW the yourdir question ,it's on your SDcard where you downloaded your htc_ime.apk , if it's on the root of the sdcard (not in any folders) then just use cp sdcard/HTC_IME.apk or if you downloaded it then it's in your download folder then you do cp sdcard/download/HTC_IME.apk
adb remount
adb install directoryofyourfile\HTC_IME.apk
Click to expand...
Click to collapse
worked for me

FaceBook not installed. Market thinks it is. Need a fix.

So, I had facebook for android installed and recently update to cyanogens latest ad somehow it got deleted. Could have been a theme that removed it, as I didn't notice it until after I applied a theme. The icon was still on my home screen, but not in the app tray and the widget is gone.
Anyway I when into the market and it says its installed, its not and the option to uninstall or open is grayed out.
Any way to fix this?
In order to get it fixed for me I had to go into adb and
Code:
adb shell
rm -r /system/app/com.facebook.katana
rm -r /data/data/com.facebook.katana
exit
adp push Facebook.apk /system/sd/app
The app still didn't work but I was then able to uninstall it in the market and reinstall the market version and it has worked fine.
jairomeo said:
In order to get it fixed for me I had to go into adb and
Code:
adb shell
rm -r /system/app/com.facebook.katana
rm -r /data/data/com.facebook.katana
exit
adp push Facebook.apk /system/sd/app
The app still didn't work but I was then able to uninstall it in the market and reinstall the market version and it has worked fine.
Click to expand...
Click to collapse
I get "can not remove /system/app/com.facebook.katana"
The reason you're getting that, is because it doesn't exist in that directory, try the second command, and see if it gives you the same error.
put the apk on sd and try this :
1. Open a Terminal Window:
2. Type the following:
- su
- mount /system -o remount,rw
- cd /sdcard
- cp "appname".apk /system/app
rp1783 said:
The reason you're getting that, is because it doesn't exist in that directory, try the second command, and see if it gives you the same error.
Click to expand...
Click to collapse
Thats what I thought and I get the same error with the other command.
yozpalang said:
put the apk on sd and try this :
1. Open a Terminal Window:
2. Type the following:
- su
- mount /system -o remount,rw
- cd /sdcard
- cp "appname".apk /system/app
Click to expand...
Click to collapse
This was my next step, but, don't have the apk. Anyone care to upload it or send me a link?
http://www.androidspin.com/downloads...e=Facebook.apk
yozpalang said:
http://www.androidspin.com/downloads...e=Facebook.apk
Click to expand...
Click to collapse
Not Found
The requested URL /downloads...e=Facebook.apk was not found on this server.
Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.
this is where i got it http://forum.xda-developers.com/showthread.php?t=582302
Got it! Thanks all for the help. Installed and working now.

Custom Recovery without Root?

I had previously unlocked my bootloader and was running CM6.1, but I had to go back to stock because my company's email app (Good for Enterprise) refuses access on rooted devices.
I would like to monkey around with different configurations to see if I can find a way to run Good on CM6.1. I don't want to do this if I have to reinstall everything if it doesn't work however.
So my question is this. I just want to get the Clockwork recovery on my N1 so I can back up the non-rooted OS and monkey around a little. Can this be done with ABD on a non-rooted device?
Gave it a shot, worked fine.
"fastboot flash recovery clockwork-image-name.img"
Good for Enterprise still runs, so it isn't looking at the recovery to determine rooted status.
Nevermind, clockwork didn't survive a reboot. Good news is I was able to get a backup first.
After installing recovery via fastboot, try removing the following files via adb:
/system/etc/install-recovery.sh
/system/recovery-from-boot.p
Sent from my Nexus One using XDA App
danger-rat said:
After installing recovery via fastboot, try removing the following files via adb:
/system/etc/install-recovery.sh
/system/recovery-from-boot.p
Sent from my Nexus One using XDA App
Click to expand...
Click to collapse
When I try to do this from the recovery, these files are not found, and adb can't see the device from the bootloader. If I boot into the OS, it will be too late - the recovery would be wiped by then and I am back to square one. I must be missing something.
Is there any way to pull the System partition and mount the .img file on my PC to do this? That sounds a little dangerous though
Just thought, you need root to delete the files.
You'd probably have to root, install recovery, then install a non-rooted ROM, but keep custom recovery...
Sent from my Nexus One using XDA App
This is what you need to do:
1) boot your device into the OS
2) download the rageagainstthecage binary and save it as rageagainstthecage in the /tools folder (in the android SDK)
3) plug your device to your computer
4) open a command prompt in the /tools directory
5) type adb devices to make sure your computer sees your device
6) push the rageagainstthecage binary to /data/local/tmp/ by typing adb push rageagainstthecage /data/local/tmp/rageagainstthecage
7) type adb shell to open a shell
8) change the permissions on the binary to allow it to run by typing chmod 700 /data/local/tmp/rageagainstthecage
9) navigate to the directory (cd /data/local/tmp) and execute the binary by typing ./rageagainstthecage
10) wait for it to run, and it will exit the shell
enter the following command at the prompt: adb kill-server
11) enter the following command at the prompt: adb start-server
12) open an adb shell again: adb shell
13) now you should have a temporary root shell. You should see a # instead of a $. if you still see the $, go back to step 9. You may have to do this a few times (I had to do it 3 times before I got root access)
14) now, mount the /system partition as r/w by typing mount -o remount,rw -t yaffs2 /dev/block/mtdblock3 /system
15) delete the two files: rm /system/etc/install-recovery.sh and rm /system/recovery-from-boot.p
16) mount the partition as r/o by typing mount -o remount,ro -t yaffs2 /dev/block/mtdblock3 /system
17) exit the shell
18) now flash your custom recovery
Awesome, thanks. I'll give it a shot later!
This worked flawlessly, thanks for the great writeup!
Santoro said:
This worked flawlessly, thanks for the great writeup!
Click to expand...
Click to collapse
Two things: First, don't forget that any update from Google always has those two files in it, so they will reappear after every update.
Second, I just reread your first post again. I think you should still be able to kepp root and have your company's email working. I think the problem was that you were using an AOSP-based ROM instead of a stock-based one. Follow the directions for rooting in my signature (the first part is essentially the same as what you just did to gain r/w access to the system partition via adb, the second part is copying su and Superuser.apk to the right directories). Root is essentially one additional file copied to your /system directory, so I believe your company's email will still work with root.
efrant said:
This is what you need to do:
1) boot your device into the OS
2) download the rageagainstthecage binary and save it as rageagainstthecage in the /tools folder (in the android SDK)
3) plug your device to your computer
4) open a command prompt in the /tools directory
5) type adb devices to make sure your computer sees your device
6) push the rageagainstthecage binary to /data/local/tmp/ by typing adb push rageagainstthecage /data/local/tmp/rageagainstthecage
7) type adb shell to open a shell
8) change the permissions on the binary to allow it to run by typing chmod 700 /data/local/tmp/rageagainstthecage
9) navigate to the directory (cd /data/local/tmp) and execute the binary by typing ./rageagainstthecage
10) wait for it to run, and it will exit the shell
enter the following command at the prompt: adb kill-server
11) enter the following command at the prompt: adb start-server
12) open an adb shell again: adb shell
13) now you should have a temporary root shell. You should see a # instead of a $. if you still see the $, go back to step 9. You may have to do this a few times (I had to do it 3 times before I got root access)
14) now, mount the /system partition as r/w by typing mount -o remount,rw -t yaffs2 /dev/block/mtdblock3 /system
15) delete the two files: rm /system/etc/install-recovery.sh and rm /system/recovery-from-boot.p
16) mount the partition as r/o by typing mount -o remount,ro -t yaffs2 /dev/block/mtdblock3 /system
17) exit the shell
18) now flash your custom recovery
Click to expand...
Click to collapse
Without unlock recovery i can install Amon RA?(‘fastboot oem unlock‘)In this way as u typed.
W3ber said:
Without unlock recovery i can install Amon RA?(‘fastboot oem unlock‘)In this way as u typed.
Click to expand...
Click to collapse
Not sure what you are asking.
If your bootloader is unlocked, you can use fastboot. Download the recovery image you want into the /tools directory of your SDK and rename it recovery.img. Open a command prompt in the same directory. Type fastboot devices to make sure fastboot sees you device. Then type fastboot flash recovery recovery.img and you are done.
If your bootloader is not unlocked, you can use flash_image, but you need root access. See attachments on how to get root if your bootloader is locked, and how to flash a custom recovery with a locked bootloader.
efrant said:
Two things: First, don't forget that any update from Google always has those two files in it, so they will reappear after every update.
Second, I just reread your first post again. I think you should still be able to kepp root and have your company's email working. I think the problem was that you were using an AOSP-based ROM instead of a stock-based one. Follow the directions for rooting in my signature (the first part is essentially the same as what you just did to gain r/w access to the system partition via adb, the second part is copying su and Superuser.apk to the right directories). Root is essentially one additional file copied to your /system directory, so I believe your company's email will still work with root.
Click to expand...
Click to collapse
I was using the Nexus One 2.2.1 stock image directly from Google. My problem is that the Good for Enterprise actively checks for root. Specifically if the Superuser.apk exists, it refuses to let me in and cites corporate policy.
Since getting my stock backup, I was free to experiment and I had some success getting Good running on CM 6.1. Taking clues from your earlier instructions, I used adb shell to rename su to su.bak and Superuser.apk to Superuserapk.bak on the phone, then rebooted. After the reboot, I don't have root anymore.
This is a compromise, but at least I don't have to give up that CM6 goodness just to use my corporate email. So far I have not seen any issues in CM6 resulting from not having root. In an emergency I can rename them the superuser files back using rageagainsthecage as you outlined but I probably won't do it often.
Thanks for the help!
Santoro said:
I was using the Nexus One 2.2.1 stock image directly from Google. My problem is that the Good for Enterprise actively checks for root. Specifically if the Superuser.apk exists, it refuses to let me in and cites corporate policy.
Since getting my stock backup, I was free to experiment and I had some success getting Good running on CM 6.1. Taking clues from your earlier instructions, I used adb shell to rename su to su.bak and Superuser.apk to Superuserapk.bak on the phone, then rebooted. After the reboot, I don't have root anymore.
This is a compromise, but at least I don't have to give up that CM6 goodness just to use my corporate email. So far I have not seen any issues in CM6 resulting from not having root. In an emergency I can rename them the superuser files back using rageagainsthecage as you outlined but I probably won't do it often.
Thanks for the help!
Click to expand...
Click to collapse
Just for your info, Superuser.apk does not give you root, it only manages the root permissions. If your corporate email application checks only for Superuser.apk, you could technically delete Superuser.apk and keep the su binary. Your would still have root, and your corporate email app would work. The su binary is what actually gives you root access. All that the Superuser.apk file does is manages the permissions for root access, i.e., it allows or denies applications from using the su binary. Everything would work fine (including all apps that require root) without Superuser.apk. HOWEVER, just as a warning, without Superuser.apk, you would have no control over which apps have root access...
I will have to put su back and see what happens. I may be recalling wrong, maybe it checks for su also...
I experimented a bit more and it looks for both files. Sorry for the confusion.

[Q] Removed apps come back - WHAT?

How do I avoid that built-in apps like Gallery re-appear after deletion??
When I try this on htc Hero with CM6 (and CM7) and my rooted Motorola Charm the removed apps don't re-appear - they nicely stay gone.
But in this case I run CM6.1 stable on my Wildfire and when remove apps Titanum says success but the apps still work and re-appear in Titanium after reboot. E.g. CMStats (CyanogenMod stats), Weather, Livewallpapers etc. My device is rooted but I simply can't get rid of any built-in app.
Titanum is in the SuperUser app and in Terminal su and id says I'm too allright. I've even tried
mount -o rw,remount -t yaffs2 /dev/block/mtdblock3
chmod 777 /system
mount -o rw,remount -t rootfs /
chmod 777 /
But it still doesn't work even though filesystem says rw
Root Explorer says success when it deletes or renames APKs in /system/app - but the apps are still there later! VERY odd. But Root Explorer can't create dirs or copy files to system/app...
What am I missing here?
I got the same prob pal..both methods weren't working for me on CM 6.1 stable..try ADB it worked flawlessly..
Sent from my HTC Wildfire
read this thread will help u Creating your own Update Zip's
http://forum.xda-developers.com/showthread.php?t=917922
I think this is because wildfire doesn't have s-off. You could remove the apps from the rom before flashing, or remove using adb in recovery
boot into recovery
unmount /system (get r/w access )
adb shell rm /system/app/xxx.apk
ww231 said:
boot into recovery
unmount /system (get r/w access )
adb shell rm /system/app/xxx.apk
Click to expand...
Click to collapse
that takes for eva if u create a zip with all the files u wont gone u just flash and done no more apps very easy and simple no hazzle

[Q] how to get market

I just put cm7 on a sd and am running it on my NC. how do I get the market on it? I saw one link but don't understand how to do it.
If all you want is the market, you can download the newest market APK from my webserver. The link is:
http://www.r00tyou.com/android/tools/Vending(new).apk
To push it to the device simple connect the device to your computer using ADB and type the following in the console:
adb devices
adb install \path\to\the\downloaded\apk.apk
Click to expand...
Click to collapse
Wait for it to successfully transfer over and install.
The viola, you have the newest market APK.
However, I suggest that you download the newest GAPPS from the cyanogen website and push over the whole gapps.
To do this, simply download the latest GAPPS from here:
http://wiki.cyanogenmod.com/index.php?title=Latest_Version#Google_Apps
Again, using ADB type the following commands:
adb shell mount -o remount,rw /dev/block/mmcblk0p5 /system
adb push [the path to your SDK tools folder]\system system/
adb reboot
Click to expand...
Click to collapse
The console will show the progress of what apps are being transferred over and installed. Once it is done rebooting it will prompt you for logging in to your google account to setup your device. You can simply skip this (Tapping in each corner of the screen starting from the top left going clockwise) or you can proceed with the setup process.
Hope that helps
Thanks for the info. It took some doing because I haven't written code since DOS.
Thanx alot man i had the same problem and this worked perfecty
Not sure if it's important since /system/ is mounted ro anyway but all apps in /system/app/ have 644 permissions, pushing files with adb (whether in linux or windoz) will give them 755 permissions defaultly, so I usually do a:
chmod 644 [app-name].apk
after I transfer the file. Might be a good idea to do this if you are remounting it a lot.
Cheers,
Mike
PS. Themed Markets :-D

Categories

Resources