soarlab / maline

Android Malware Detection Framework
GNU Affero General Public License v3.0
81 stars 31 forks source link

Failed to create virtual machine.Which version about android sdk? #20

Open zwj2017-NK opened 6 years ago

zwj2017-NK commented 6 years ago

Starting emulator... Waiting for the device: ........................................................ failed Failed to boot the emualtor. Exiting... Error: Missing platform-tools Deleting file /home/zhuwenjun/.android/avd/maline-avd.ini Deleting folder /home/zhuwenjun/.android/avd/maline-avd.avd

mdimjasevic commented 6 years ago

@zwj2017-NK , as stated in the documentation, we tested maline against Android 4.4.3 (API version 19). If you would like to reproduce this, you can find instructions for building the particular used SDK in docs/building-android.org.

zwj2017-NK commented 6 years ago

Thanks a lot. Firstly, I ran "vagrant up" command in the root of this project, all is well. Secondly, I have downloaded the custom SDK into my home directory, and set some environment variables. Thirdly, Creating virtual machine by running "avd-create.sh -a x86 -d maline-avd". I am very confused about the following error: zwj@zwj-Vostro-3668:~/projects/maline$ avd-create.sh -a x86 -d maline-avd Starting emulator... Waiting for the device: ........................................................ failed Failed to boot the emualtor. Exiting... Error: Missing platform-tools Deleting file /home/zwj/.android/avd/maline-avd.ini Deleting folder /home/zwj/.android/avd/maline-avd.avd

AVD 'maline-avd' deleted.

mdimjasevic commented 6 years ago

Your PATH variable is not set right. Try following the readme from the beginning.

zwj2017-NK commented 6 years ago

zhuwenjun@zhuwenjun-Vostro-3668:~/projects/maline$ echo $ANDROID_HOME ~/projects/custom-android-sdk zhuwenjun@zhuwenjun-Vostro-3668:~/projects/maline$ echo $MALINE /home/zhuwenjun/projects/maline zhuwenjun@zhuwenjun-Vostro-3668:~/projects/maline$ echo $PATH /home/zhuwenjun/projects/maline/bin:/home/zhuwenjun/projects/custom-android-sdk/tools:/home/zhuwenjun/projects/custom-android-sdk/platform-tools:/usr/lib/scala/scala-2.11.8/bin:/usr/lib/jvm/java-1.8.0-openjdk-amd64/bin:~/projects/maline/bin:~/projects/custom-android-sdk/tools:~/projects/custom-android-sdk/platform-tools:/home/zhuwenjun/anaconda2/bin:/usr/lib/scala/scala-2.11.8/bin:/usr/lib/jvm/java-1.8.0-openjdk-amd64/bin:~/projects/maline/bin:~/projects/custom-android-sdk/tools:~/projects/custom-android-sdk/platform-tools:/home/zhuwenjun/anaconda2/bin:/home/zhuwenjun/gopath/bin:/usr/local/go/bin:/home/zhuwenjun/Downloads/spark/spark-2.3.1-bin-hadoop2.7/bin:/usr/lib/jvm/java-1.8.0-openjdk-amd64/bin:/usr/lib/jvm/java-1.8.0-openjdk-amd64/jre/bin:/usr/lib/scala/scala-2.11.8/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/usr/local/hadoop/bin:/usr/local/hadoop/sbin:/snap/bin:/home/zhuwenjun/Downloads/spark/spark-2.3.1-bin-hadoop2.7/bin:/home/zhuwenjun/Downloads/spark/spark-2.3.1-bin-hadoop2.7/bin:/usr/local/hive/bin:/usr/local/hadoop$:~/projects/custom-android-sdk/tools/:~/projects/custom-android-sdk/platform-tools/:~/projects/custom-android-sdk/build-tools zhuwenjun@zhuwenjun-Vostro-3668:~/projects/maline$ +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ These are the information about my environment variables.

mdimjasevic commented 6 years ago

Sorry, I don't know how to help any further as you seem to have platform-tools in your path.

zwj2017-NK commented 6 years ago

Thanks again. I want to know the version number of custom-android-sdk, because I suspect that the platform-tool directory lacks essential files.

zwj2017-NK commented 6 years ago

I ran 'android update sdk -u' in the directory of '~/projects/custom-android-sdk/tools/'. Then, creating virtual machine by running 'avd-create.sh -a x86 -d maline-avd', but it was failed. zhuwenjun@zhuwenjun-Vostro-3668:~/projects/maline$ avd-create.sh -a x86 -d maline-avd Starting emulator... Waiting for the device: ......................................................... failed Failed to boot the emualtor. Exiting... Deleting file /home/zhuwenjun/.android/avd/maline-avd.ini Deleting folder /home/zhuwenjun/.android/avd/maline-avd.avd AVD 'maline-avd' deleted.