Windoze
Windoze

Reputation: 331

How to run emulator64-arm in a Docker container?

I tried to run emulator64-arm in a Docker container but it reported:

$ emulator64-arm -avd t2 -no-window -no-accel -gpu off
qemu: could not open disk image /home/testuser/.android/avd/t2.avd/sdcard.img: Interrupted system cal

I think qemu-aarch64 should be a pure software emulator without any fancy things involved but I was wrong. I also tried to start the container with --privileged but still no luck.

In my case we need to run some smoke tests for our Android APK, speed doesn't really matter but Android-X86 is not an option.

Upvotes: 10

Views: 2508

Answers (1)

Windoze
Windoze

Reputation: 331

This is not about the root cause but a workaround.

AVD created under Linux will also create "qcow2" files for each image, with these qcow2 files, emulator can successfully start.

But these qcow2 files are not created under any other platforms, I was using an AVD created under Mac and got the error, then I recreated AVD under Linux and the error was gone.

Upvotes: 3

Related Questions