Salman
Salman

Reputation: 1024

Nativescript - native emulator error when run android --emulator

I receive the following error when I run android --emulator on my cmd;

Cannot run your app in the native emulator. Increase the timeout of the operation with the --timeout option or try to restart your adb server with 'adb kill-server' command. Alternatively, run the Android Virtual Device manager and increase the allocated RAM for the virtual device.

I've opened it with administrator rights and ran all the tutorials on the website.

I'm now stuck at this point and haven't been able to find the solution.

I've also tried tns run android --emulator --timeout -0 and waited for an hour without result.

What can i do to get the emulator running?

Upvotes: 0

Views: 1420

Answers (3)

Mr-K10
Mr-K10

Reputation: 345

tns run android

Runs the Emulator and then run the app on it.

Sometimes both process can't happen at once, admin access in Linux can be such case.

try starting the Emulator first then the app.

emulator -avd avd_name [ {-option [value]} … ]

for example:

sudo $ANDROID_HOME/emulator/emulator -avd test -netdelay none -netspeed full

'sudo' is important for Linux users.

then use this to start the app.

tns run android

Upvotes: 1

handiansom
handiansom

Reputation: 783

You just need to open your Android Virtual Device Manager and download the latest emulator. Then run your application again.It will work.

Upvotes: 1

MeanMan
MeanMan

Reputation: 1090

I had the same problem, I solved by opening avd manager and try starting the virtual device(emulator) you created. If the emulator doesnt launches, you will get an error in the console.

For me I had to install the intel HAXM, for launching the emulator

Upvotes: 2

Related Questions