我使用的是Android Studio 2.3.3,Android SDK工具v26.0.2和HAXM模拟器6.2.1。
编辑(更新2017/11/10):还尝试使用Android Studio 3.0,Android SDK工具27.0.1,HAXM模拟器6.2.1,x86 Google Play英特尔API 27图像修订版1。
我下载了Android 8.0(O,API级别26,修订版2)平台并创建了一个新的模拟器:
创建 - >电话 - >带Play商店支持的Nexus 5X->图片x86 API 26(Google Play),标准设置:
启动模拟器后,我在通知栏中收到一条消息,告诉我"不支持的虚拟SD卡。此设备不支持此虚拟SD卡。点击以支持的格式进行设置。"
我这样做,并选择内部或外部存储,然后我收到错误:
10-09 13:31:59.786 2984-2984 E/StorageSettings: Failed to partition
java.lang.IllegalStateException: command '10 volume partition disk:253,48 public' failed with '400 10 Command failed'
完整错误及其周围的一切:
10-09 13:31:58.397 1506-1594 E/TaskPersister: File error accessing recents directory (directory doesn't exist?).
10-09 13:31:58.566 2984-3021 D/EGL_emulation: eglMakeCurrent: 0xa1a99fe0: ver 2 0 (tinfo 0xa1d7f920)
10-09 13:31:58.608 1356-1356 D/gralloc_ranchu: gralloc_alloc: Creating ashmem region of size 4096
10-09 13:31:58.731 1506-2285 I/ActivityManager: START u0 {cmp=com.android.settings/.deviceinfo.StorageWizardFormatProgress (has extras)} from uid 1000
10-09 13:31:58.753 1506-1519 E/memtrack: Couldn't load memtrack module
10-09 13:31:58.753 1506-1519 W/android.os.Debug: failed to get memory consumption info: -1
10-09 13:31:58.775 1506-1655 D/VoldConnector: SND -> {10 volume partition disk:253,48 public}
10-09 13:31:58.775 1310-1314 V/vold: /system/bin/sgdisk
10-09 13:31:58.775 1310-1314 V/vold: --zap-all
10-09 13:31:58.775 1310-1314 V/vold: /dev/block/vold/disk:253,48
10-09 13:31:58.779 1310-1314 I/sgdisk: Creating new GPT entries.
10-09 13:31:58.790 1356-1356 D/gralloc_ranchu: gralloc_alloc: Creating ashmem region of size 4096
10-09 13:31:58.795 1356-1356 I/chatty: uid=1000(system) allocator@2.0-s identical 1 line
10-09 13:31:58.800 1356-1356 D/gralloc_ranchu: gralloc_alloc: Creating ashmem region of size 4096
[ 10-09 13:31:58.807 2984: 3021 D/ ]
SurfaceInterface::setAsyncMode: set async mode 1
10-09 13:31:58.812 2984-3021 D/EGL_emulation: eglMakeCurrent: 0xa1a99fe0: ver 2 0 (tinfo 0xa1d7f920)
10-09 13:31:58.819 1506-1527 I/ActivityManager: Displayed com.android.settings/.deviceinfo.StorageWizardFormatProgress: +67ms
10-09 13:31:58.821 2984-3021 D/EGL_emulation: eglMakeCurrent: 0xa1a99fe0: ver 2 0 (tinfo 0xa1d7f920)
10-09 13:31:58.829 2984-3021 D/EGL_emulation: eglMakeCurrent: 0xa1a99fe0: ver 2 0 (tinfo 0xa1d7f920)
10-09 13:31:58.839 2984-3021 D/OpenGLRenderer: endAllActiveAnimators on 0xa1d0da00 (RippleDrawable) with handle 0xa19fd2e0
10-09 13:31:59.784 1310-1314 I/sgdisk: GPT data structures destroyed! You may now partition the disk using fdisk or
10-09 13:31:59.785 1310-1314 I/sgdisk: other utilities.
10-09 13:31:59.785 1310-1314 E/config_mbr: Not enough space to add parttion 'android_sdcard'.
10-09 13:31:59.785 1310-1314 E/diskconfig: Configuration is invalid.
10-09 13:31:59.785 1310-1314 E/vold: Failed to apply disk configuration: 1
10-09 13:31:59.785 1506-1565 D/VoldConnector: RCV <- {400 10 Command failed}
10-09 13:31:59.785 1506-1655 E/VoldConnector: NDC Command {10 volume partition disk:253,48 public} took too long (1010ms)
10-09 13:31:59.786 2984-2984 E/StorageSettings: Failed to partition
java.lang.IllegalStateException: command '10 volume partition disk:253,48 public' failed with '400 10 Command failed'
at android.os.Parcel.readException(Parcel.java:1950)
at android.os.Parcel.readException(Parcel.java:1888)
at android.os.storage.IStorageManager$Stub$Proxy.partitionPublic(IStorageManager.java:1865)
at android.os.storage.StorageManager.partitionPublic(StorageManager.java:878)
at com.android.settings.deviceinfo.StorageWizardFormatProgress$PartitionTask.doInBackground(StorageWizardFormatProgress.java:118)
at com.android.settings.deviceinfo.StorageWizardFormatProgress$PartitionTask.doInBackground(StorageWizardFormatProgress.java:93)
at android.os.AsyncTask$2.call(AsyncTask.java:333)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at android.os.AsyncTask$SerialExecutor$1.run(AsyncTask.java:245)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1162)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:636)
at java.lang.Thread.run(Thread.java:764)
我尝试删除并重新创建此图片,更新Android Studio,更新Android工具以及更新SDK。这适用于API 23和24仿真器。有没有人见过这个或者对我可以尝试的事情有任何想法?