tags:

views:

1981

answers:

1

Hi!

I have an HTC HERO and I need to push my application.apk
to the /system/app/ folder.

I've followed some tuts on rooting the device
and that is fine, but when I try to push my package to the system/app
folder, I get: "permission denied":

$ push /sdcard/myApp.apk /system/app/
push: permission denied

I also try:

$ su
su
# push /sdcard/myApp.apk /system/app/
push: not found

Is this possible in a device that is not a developer intended device?

Thank you all!

+4  A: 

Firstly, running push from the device doesn't work as it's not a built-in command. Ideally you would use the copy command cp, but I don't think it's included by default (I've added it to my device via busybox).

Anyway, your problem is that the /system partition is mounted as read-only when the device boots.

But if you have root access to the device, you can remount the partition as read-write:

host$ adb shell
hero$ su
hero# mount -o remount,rw -t yaffs2 /dev/block/mtdblock3 /system
hero# cat /sdcard/myApp.adk > /system/app/myApp.adk
hero# mount -o remount,ro -t yaffs2 /dev/block/mtdblock3 /system

Alternatively, after doing the remount, you can use adb push from the host as normal.

Christopher
I've tried to do that and when reach the cat command, I get:"Cannot create /system/app/: is a directory".I also tried mv, and I got:"failed on '/sdcard/myApk.apk' - Cross-device link". Is there still some hope? Thaks :)
Tsimmi
Ooops, I originally was using `cp` rather than `cat`. I've fixed the `cat` command line now.
Christopher