1

Sometimes I start Android Emulator with the GUI, and sometimes I start with the CLI. If I keep using the same method, everything is fine, but if I switch between methods, it causes problems. For example if I start the emulator with the CLI, then shut down, then start again using the GUI, I get this:

Cold boot: snapshot failed to load

If I start with the GUI, then shut down and start with the CLI, I get this:

qemu-system-i386.exe: Failed to load virtio-blk:virtio

Here is the command I use with CLI:

adb start-server
emulator -writable-system -avd Pixel_2_API_24

Am I doing something wrong?

1 Answer 1

2

This isnt really an issue for me anymore, as I no longer use emulator -writable-system. I was previously using it, so that I could install a system certificate. However another method is available, that doesnt require an Emulator flag:

adb shell mkdir /data/local/tmp/cacerts/
adb shell cp /system/etc/security/cacerts/* /data/local/tmp/cacerts/
adb push c8750f0d.0 /data/local/tmp/cacerts/
adb root
adb shell mount -t tmpfs tmpfs /system/etc/security/cacerts
adb shell mv /data/local/tmp/cacerts/* /system/etc/security/cacerts/
adb shell chcon u:object_r:system_file:s0 /system/etc/security/cacerts/*

https://github.com/httptoolkit/httptoolkit-server/blob/master/src/interceptors/android/adb-commands.ts

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .