Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

writing to /system/framework in emulator

I'm in the process of extending monkey for software testing purposes, so I would like to replace the current monkey.jar which my own compiled monkey.jar in the emulator. The current monkey.jar is located at /system/framework/monkey.jar.

When I try to run the following command:

adb push monkey.jar /system/framework/monkey.jar

i get the following: 'failed to copy 'monkey.jar' to '/system/framework/monkey.jar': Out of memory'

Any ideas on how to replace the current monkey.jar?

This actually works if I'm running Android 1.6 in the Emulator, but nothing after that. Yes, i've tried 'abd remount'

EDIT: This is not a .jar specific issue. I can't push any type of file to /system/framework

Thanks.

like image 722
CodingWithoutComments Avatar asked Jul 15 '10 18:07

CodingWithoutComments


2 Answers

Found the answer on the following thread:

As an android developer, if you use the following command like:

adb push file /system/..

and meet problems like “failed to copy file to /system/…”, such as:

failed to copy ‘file’ to ‘/system/…’: No space left on device
failed to copy ‘file’ to ‘/system/…’: Out of memory

The resolve method is not using the Eclipse or AVD Manager to start the Android emulator, but by use the command first:

$emulator –avd youravdname –partition-size 128

Then you can try the command “adb push file /system/…”, and the problem maybe resolved.

like image 186
CodingWithoutComments Avatar answered Sep 19 '22 13:09

CodingWithoutComments


Faced the same problem some little while ago. The problem is not because of low memory; it is because users do not have permission to write to the /system.

This issue can be solved by changing permissions to the /system partition using 'chmod' from the adb command line.

like image 39
knmanish Avatar answered Sep 17 '22 13:09

knmanish