redroid-doc icon indicating copy to clipboard operation
redroid-doc copied to clipboard

Android10无法保存屏幕截图?

Open zengerlin opened this issue 2 years ago • 11 comments

QQ20230112-010754 QQ20230112-010826

zengerlin avatar Jan 11 '23 17:01 zengerlin

seems something wrong with the emulated storage. is fuse enabled in your system? try modprobe fuse if not.

And collect the debug logs if still not work.

zhouziyang avatar Jan 12 '23 04:01 zhouziyang

image

Android8.1

docker run -itd --privileged
--memory-swappiness=0
--pull always
-v ~/data8:/data
-p 8000:5555
redroid/redroid:8.1.0-arm64
ro.secure=0
redroid.gpu.mode=guest
androidboot.redroid_width=1080
androidboot.redroid_height=1920

Android10.0

docker run -itd --privileged
--memory-swappiness=0
--pull always
-v ~/data10:/data
-p 10000:5555
redroid/redroid:10.0.0-arm64
ro.secure=0
redroid.gpu.mode=guest
androidboot.redroid_width=1080
androidboot.redroid_height=1920

image

01-12 05:25:06.867 3165 3165 D AndroidRuntime: Calling main entry com.genymobile.scrcpy.CleanUp 01-12 05:25:15.084 162 281 V InputDispatcher: Asynchronous input event injection succeeded. 01-12 05:25:19.922 162 281 I chatty : uid=1000(system) InputDispatcher identical 4 lines 01-12 05:25:20.294 162 281 V InputDispatcher: Asynchronous input event injection succeeded. 01-12 05:25:20.397 162 228 E memtrack: Couldn't load memtrack module 01-12 05:25:20.397 162 228 W android.os.Debug: failed to get memory consumption info: -1 01-12 05:25:20.399 596 596 I LatinIME: Starting input. Cursor position = 0,0 01-12 05:25:20.445 162 228 E memtrack: Couldn't load memtrack module 01-12 05:25:20.445 162 228 W android.os.Debug: failed to get memory consumption info: -1 01-12 05:25:20.448 162 228 E memtrack: Couldn't load memtrack module 01-12 05:25:20.448 162 228 W android.os.Debug: failed to get memory consumption info: -1 01-12 05:25:20.450 162 228 E memtrack: Couldn't load memtrack module 01-12 05:25:20.450 162 228 W android.os.Debug: failed to get memory consumption info: -1 01-12 05:25:20.452 162 228 E memtrack: Couldn't load memtrack module 01-12 05:25:20.452 162 228 W android.os.Debug: failed to get memory consumption info: -1 01-12 05:25:20.454 162 228 E memtrack: Couldn't load memtrack module 01-12 05:25:20.454 162 228 W android.os.Debug: failed to get memory consumption info: -1 01-12 05:25:20.456 162 228 E memtrack: Couldn't load memtrack module 01-12 05:25:20.456 162 228 W android.os.Debug: failed to get memory consumption info: -1 01-12 05:25:20.458 162 228 E memtrack: Couldn't load memtrack module 01-12 05:25:20.458 162 228 W android.os.Debug: failed to get memory consumption info: -1 01-12 05:25:20.461 162 228 E memtrack: Couldn't load memtrack module 01-12 05:25:20.461 162 228 W android.os.Debug: failed to get memory consumption info: -1 01-12 05:25:20.462 162 228 E memtrack: Couldn't load memtrack module 01-12 05:25:20.462 162 228 W android.os.Debug: failed to get memory consumption info: -1 01-12 05:25:20.464 162 228 E memtrack: Couldn't load memtrack module 01-12 05:25:20.464 162 228 W android.os.Debug: failed to get memory consumption info: -1 01-12 05:25:20.466 162 228 E memtrack: Couldn't load memtrack module 01-12 05:25:20.466 162 228 W android.os.Debug: failed to get memory consumption info: -1 01-12 05:25:20.468 162 228 E memtrack: Couldn't load memtrack module 01-12 05:25:20.468 162 228 W android.os.Debug: failed to get memory consumption info: -1 01-12 05:25:20.470 162 228 E memtrack: Couldn't load memtrack module 01-12 05:25:20.470 162 228 W android.os.Debug: failed to get memory consumption info: -1 01-12 05:25:20.501 162 228 E memtrack: Couldn't load memtrack module 01-12 05:25:20.501 162 228 W android.os.Debug: failed to get memory consumption info: -1 01-12 05:25:20.503 162 228 E memtrack: Couldn't load memtrack module 01-12 05:25:20.503 162 228 W android.os.Debug: failed to get memory consumption info: -1 01-12 05:25:20.515 162 228 E memtrack: Couldn't load memtrack module 01-12 05:25:20.515 162 228 W android.os.Debug: failed to get memory consumption info: -1 01-12 05:25:20.572 76 76 E HWComposer: Invalid layer type change: SolidColor --> Device 01-12 05:25:33.053 76 76 I chatty : uid=1000(system) /system/bin/surfaceflinger identical 39 lines 01-12 05:25:33.586 76 76 E HWComposer: Invalid layer type change: SolidColor --> Device 01-12 05:25:34.053 162 281 V InputDispatcher: Asynchronous input event injection succeeded. 01-12 05:25:34.053 76 76 E HWComposer: Invalid layer type change: SolidColor --> Device 01-12 05:25:36.119 76 76 I chatty : uid=1000(system) /system/bin/surfaceflinger identical 11 lines 01-12 05:25:36.584 76 76 E HWComposer: Invalid layer type change: SolidColor --> Device 01-12 05:25:36.591 162 281 V InputDispatcher: Asynchronous input event injection succeeded. 01-12 05:25:36.596 1486 1486 D TextClassifierService: No configured system TextClassifierService 01-12 05:25:36.600 162 281 I chatty : uid=1000(system) InputDispatcher identical 3 lines 01-12 05:25:36.602 162 281 V InputDispatcher: Asynchronous input event injection succeeded. 01-12 05:25:36.603 162 228 E memtrack: Couldn't load memtrack module 01-12 05:25:36.603 162 228 W android.os.Debug: failed to get memory consumption info: -1 01-12 05:25:36.605 162 538 E InputDispatcher: Window handle Window{38dbec3 u0 PopupWindow:175d1e2} has no registered input channel 01-12 05:25:36.650 76 76 E HWComposer: Invalid layer type change: SolidColor --> Device 01-12 05:25:36.671 162 228 E memtrack: Couldn't load memtrack module 01-12 05:25:36.671 162 228 W android.os.Debug: failed to get memory consumption info: -1 01-12 05:25:36.718 76 76 E HWComposer: Invalid layer type change: SolidColor --> Device 01-12 05:25:36.854 76 76 I chatty : uid=1000(system) /system/bin/surfaceflinger identical 2 lines 01-12 05:25:36.918 76 76 E HWComposer: Invalid layer type change: SolidColor --> Device 01-12 05:25:36.924 162 228 E memtrack: Couldn't load memtrack module 01-12 05:25:36.924 162 228 W android.os.Debug: failed to get memory consumption info: -1 01-12 05:25:36.986 76 76 E HWComposer: Invalid layer type change: SolidColor --> Device 01-12 05:25:44.786 76 76 I chatty : uid=1000(system) /system/bin/surfaceflinger identical 17 lines 01-12 05:25:45.253 76 76 E HWComposer: Invalid layer type change: SolidColor --> Device 01-12 05:25:45.282 162 281 V InputDispatcher: Asynchronous input event injection succeeded. 01-12 05:25:45.519 76 76 E HWComposer: Invalid layer type change: SolidColor --> Device 01-12 05:25:47.319 76 76 I chatty : uid=1000(system) /system/bin/surfaceflinger identical 8 lines 01-12 05:25:47.786 76 76 E HWComposer: Invalid layer type change: SolidColor --> Device 01-12 05:25:47.875 162 281 V InputDispatcher: Asynchronous input event injection succeeded. 01-12 05:25:47.889 1046 1318 E DatabaseUtils: Writing exception to parcel 01-12 05:25:47.889 1046 1318 E DatabaseUtils: java.lang.IllegalArgumentException: Parent document isn't a directory 01-12 05:25:47.889 1046 1318 E DatabaseUtils: at com.android.internal.content.FileSystemProvider.createDocument(FileSystemProvider.java:239) 01-12 05:25:47.889 1046 1318 E DatabaseUtils: at com.android.providers.downloads.DownloadStorageProvider.createDocument(DownloadStorageProvider.java:205) 01-12 05:25:47.889 1046 1318 E DatabaseUtils: at android.provider.DocumentsProvider.callUnchecked(DocumentsProvider.java:1121) 01-12 05:25:47.889 1046 1318 E DatabaseUtils: at android.provider.DocumentsProvider.call(DocumentsProvider.java:1067) 01-12 05:25:47.889 1046 1318 E DatabaseUtils: at android.content.ContentProvider.call(ContentProvider.java:2152) 01-12 05:25:47.889 1046 1318 E DatabaseUtils: at android.content.ContentProvider$Transport.call(ContentProvider.java:477) 01-12 05:25:47.889 1046 1318 E DatabaseUtils: at android.content.ContentProviderNative.onTransact(ContentProviderNative.java:277) 01-12 05:25:47.889 1046 1318 E DatabaseUtils: at android.os.Binder.execTransactInternal(Binder.java:1021) 01-12 05:25:47.889 1046 1318 E DatabaseUtils: at android.os.Binder.execTransact(Binder.java:994) 01-12 05:25:47.891 1486 1562 W DocumentsContract: Failed to create document 01-12 05:25:47.891 1486 1562 W DocumentsContract: java.lang.IllegalArgumentException: Parent document isn't a directory 01-12 05:25:47.891 1486 1562 W DocumentsContract: at android.database.DatabaseUtils.readExceptionFromParcel(DatabaseUtils.java:170) 01-12 05:25:47.891 1486 1562 W DocumentsContract: at android.database.DatabaseUtils.readExceptionFromParcel(DatabaseUtils.java:140) 01-12 05:25:47.891 1486 1562 W DocumentsContract: at android.content.ContentProviderProxy.call(ContentProviderNative.java:658) 01-12 05:25:47.891 1486 1562 W DocumentsContract: at android.content.ContentProviderClient.call(ContentProviderClient.java:558) 01-12 05:25:47.891 1486 1562 W DocumentsContract: at android.content.ContentResolver.call(ContentResolver.java:2032) 01-12 05:25:47.891 1486 1562 W DocumentsContract: at android.provider.DocumentsContract.createDocument(DocumentsContract.java:1327) 01-12 05:25:47.891 1486 1562 W DocumentsContract: at com.android.documentsui.CreateDirectoryFragment$CreateDirectoryTask.doInBackground(CreateDirectoryFragment.java:152) 01-12 05:25:47.891 1486 1562 W DocumentsContract: at com.android.documentsui.CreateDirectoryFragment$CreateDirectoryTask.doInBackground(CreateDirectoryFragment.java:128) 01-12 05:25:47.891 1486 1562 W DocumentsContract: at android.os.AsyncTask$3.call(AsyncTask.java:378) 01-12 05:25:47.891 1486 1562 W DocumentsContract: at java.util.concurrent.FutureTask.run(FutureTask.java:266) 01-12 05:25:47.891 1486 1562 W DocumentsContract: at com.android.documentsui.ProviderExecutor.run(ProviderExecutor.java:104) 01-12 05:25:47.891 1486 1562 W Documents: Failed to create directory 01-12 05:25:47.891 1486 1562 W Documents: java.lang.IllegalArgumentException: Parent document isn't a directory 01-12 05:25:47.891 1486 1562 W Documents: at android.database.DatabaseUtils.readExceptionFromParcel(DatabaseUtils.java:170) 01-12 05:25:47.891 1486 1562 W Documents: at android.database.DatabaseUtils.readExceptionFromParcel(DatabaseUtils.java:140) 01-12 05:25:47.891 1486 1562 W Documents: at android.content.ContentProviderProxy.call(ContentProviderNative.java:658) 01-12 05:25:47.891 1486 1562 W Documents: at android.content.ContentProviderClient.call(ContentProviderClient.java:558) 01-12 05:25:47.891 1486 1562 W Documents: at android.content.ContentResolver.call(ContentResolver.java:2032) 01-12 05:25:47.891 1486 1562 W Documents: at android.provider.DocumentsContract.createDocument(DocumentsContract.java:1327) 01-12 05:25:47.891 1486 1562 W Documents: at com.android.documentsui.CreateDirectoryFragment$CreateDirectoryTask.doInBackground(CreateDirectoryFragment.java:152) 01-12 05:25:47.891 1486 1562 W Documents: at com.android.documentsui.CreateDirectoryFragment$CreateDirectoryTask.doInBackground(CreateDirectoryFragment.java:128) 01-12 05:25:47.891 1486 1562 W Documents: at android.os.AsyncTask$3.call(AsyncTask.java:378) 01-12 05:25:47.891 1486 1562 W Documents: at java.util.concurrent.FutureTask.run(FutureTask.java:266) 01-12 05:25:47.891 1486 1562 W Documents: at com.android.documentsui.ProviderExecutor.run(ProviderExecutor.java:104) 01-12 05:25:47.938 162 185 E InputDispatcher: Window handle Window{6b5eff8 u0 com.android.documentsui/com.android.documentsui.files.FilesActivity} has no registered input channel 01-12 05:25:47.987 76 76 E HWComposer: Invalid layer type change: SolidColor --> Device 01-12 05:25:48.120 76 76 I chatty : uid=1000(system) /system/bin/surfaceflinger identical 2 lines 01-12 05:25:48.187 76 76 E HWComposer: Invalid layer type change: SolidColor --> Device 01-12 05:25:58.937 68 89 D hwcomposer: hw_composer sent 916 syncs in 61s 01-12 05:26:00.001 344 344 D KeyguardClockSwitch: Updating clock: 526

zengerlin avatar Jan 12 '23 05:01 zengerlin

please collect full debug logs.

collect debug logs curl -fsSL https://raw.githubusercontent.com/remote-android/redroid-doc/master/debug.sh | bash -s -- [CONTAINER] omit CONTAINER if not exist any more.

zhouziyang avatar Jan 12 '23 08:01 zhouziyang

please collect full debug logs.

collect debug logs curl -fsSL https://raw.githubusercontent.com/remote-android/redroid-doc/master/debug.sh | bash -s -- [CONTAINER] omit CONTAINER if not exist any more.

image tmp.22G4P0el64.tgz

zengerlin avatar Jan 12 '23 08:01 zengerlin

I can reproduce this issue. will look into this issue.

01-12 08:36:21.802  1298  1321 E DatabaseUtils: Writing exception to parcel
01-12 08:36:21.802  1298  1321 E DatabaseUtils: java.lang.IllegalArgumentException: Volume external_primary not found
01-12 08:36:21.802  1298  1321 E DatabaseUtils:         at com.android.providers.media.MediaProvider.queryInternal(MediaProvider.java:1735)
01-12 08:36:21.802  1298  1321 E DatabaseUtils:         at com.android.providers.media.MediaProvider.query(MediaProvider.java:1676)
01-12 08:36:21.802  1298  1321 E DatabaseUtils:         at android.content.ContentProvider$Transport.query(ContentProvider.java:267)
01-12 08:36:21.802  1298  1321 E DatabaseUtils:         at android.content.ContentResolver.query(ContentResolver.java:944)
01-12 08:36:21.802  1298  1321 E DatabaseUtils:         at android.content.ContentResolver.query(ContentResolver.java:880)
01-12 08:36:21.802  1298  1321 E DatabaseUtils:         at android.content.ContentResolver.query(ContentResolver.java:836)
01-12 08:36:21.802  1298  1321 E DatabaseUtils:         at com.android.providers.downloads.DownloadStorageProvider.includeDownloadsFromMediaStore(DownloadStorageProvider.java:883)
01-12 08:36:21.802  1298  1321 E DatabaseUtils:         at com.android.providers.downloads.DownloadStorageProvider.queryChildDocuments(DownloadStorageProvider.java:352)
01-12 08:36:21.802  1298  1321 E DatabaseUtils:         at com.android.providers.downloads.DownloadStorageProvider.queryChildDocumentsForManage(DownloadStorageProvider.java:316)
01-12 08:36:21.802  1298  1321 E DatabaseUtils:         at android.provider.DocumentsProvider.query(DocumentsProvider.java:919)
01-12 08:36:21.802  1298  1321 E DatabaseUtils:         at android.content.ContentProvider$Transport.query(ContentProvider.java:267)
01-12 08:36:21.802  1298  1321 E DatabaseUtils:         at android.content.ContentProviderNative.onTransact(ContentProviderNative.java:104)
01-12 08:36:21.802  1298  1321 E DatabaseUtils:         at android.os.Binder.execTransactInternal(Binder.java:1021)
01-12 08:36:21.802  1298  1321 E DatabaseUtils:         at android.os.Binder.execTransact(Binder.java:994)
01-12 08:36:21.802  2121  2207 W DirectoryLoader: Failed to query
01-12 08:36:21.802  2121  2207 W DirectoryLoader: java.lang.IllegalArgumentException: Volume external_primary not found
01-12 08:36:21.802  2121  2207 W DirectoryLoader:       at android.database.DatabaseUtils.readExceptionFromParcel(DatabaseUtils.java:170)
01-12 08:36:21.802  2121  2207 W DirectoryLoader:       at android.database.DatabaseUtils.readExceptionFromParcel(DatabaseUtils.java:140)
01-12 08:36:21.802  2121  2207 W DirectoryLoader:       at android.content.ContentProviderProxy.query(ContentProviderNative.java:423)
01-12 08:36:21.802  2121  2207 W DirectoryLoader:       at android.content.ContentProviderClient.query(ContentProviderClient.java:195)
01-12 08:36:21.802  2121  2207 W DirectoryLoader:       at com.android.documentsui.DirectoryLoader.loadInBackground(DirectoryLoader.java:141)
01-12 08:36:21.802  2121  2207 W DirectoryLoader:       at com.android.documentsui.DirectoryLoader.loadInBackground(DirectoryLoader.java:54)
01-12 08:36:21.802  2121  2207 W DirectoryLoader:       at androidx.loader.content.AsyncTaskLoader.onLoadInBackground(AsyncTaskLoader.java:287)
01-12 08:36:21.802  2121  2207 W DirectoryLoader:       at androidx.loader.content.AsyncTaskLoader$LoadTask.doInBackground(AsyncTaskLoader.java:56)
01-12 08:36:21.802  2121  2207 W DirectoryLoader:       at androidx.loader.content.ModernAsyncTask$1.call(ModernAsyncTask.java:96)
01-12 08:36:21.802  2121  2207 W DirectoryLoader:       at java.util.concurrent.FutureTask.run(FutureTask.java:266)
01-12 08:36:21.802  2121  2207 W DirectoryLoader:       at com.android.documentsui.ProviderExecutor.run(ProviderExecutor.java:104)

zhouziyang avatar Jan 12 '23 08:01 zhouziyang

I can reproduce this issue. will look into this issue.

01-12 08:36:21.802  1298  1321 E DatabaseUtils: Writing exception to parcel
01-12 08:36:21.802  1298  1321 E DatabaseUtils: java.lang.IllegalArgumentException: Volume external_primary not found
01-12 08:36:21.802  1298  1321 E DatabaseUtils:         at com.android.providers.media.MediaProvider.queryInternal(MediaProvider.java:1735)
01-12 08:36:21.802  1298  1321 E DatabaseUtils:         at com.android.providers.media.MediaProvider.query(MediaProvider.java:1676)
01-12 08:36:21.802  1298  1321 E DatabaseUtils:         at android.content.ContentProvider$Transport.query(ContentProvider.java:267)
01-12 08:36:21.802  1298  1321 E DatabaseUtils:         at android.content.ContentResolver.query(ContentResolver.java:944)
01-12 08:36:21.802  1298  1321 E DatabaseUtils:         at android.content.ContentResolver.query(ContentResolver.java:880)
01-12 08:36:21.802  1298  1321 E DatabaseUtils:         at android.content.ContentResolver.query(ContentResolver.java:836)
01-12 08:36:21.802  1298  1321 E DatabaseUtils:         at com.android.providers.downloads.DownloadStorageProvider.includeDownloadsFromMediaStore(DownloadStorageProvider.java:883)
01-12 08:36:21.802  1298  1321 E DatabaseUtils:         at com.android.providers.downloads.DownloadStorageProvider.queryChildDocuments(DownloadStorageProvider.java:352)
01-12 08:36:21.802  1298  1321 E DatabaseUtils:         at com.android.providers.downloads.DownloadStorageProvider.queryChildDocumentsForManage(DownloadStorageProvider.java:316)
01-12 08:36:21.802  1298  1321 E DatabaseUtils:         at android.provider.DocumentsProvider.query(DocumentsProvider.java:919)
01-12 08:36:21.802  1298  1321 E DatabaseUtils:         at android.content.ContentProvider$Transport.query(ContentProvider.java:267)
01-12 08:36:21.802  1298  1321 E DatabaseUtils:         at android.content.ContentProviderNative.onTransact(ContentProviderNative.java:104)
01-12 08:36:21.802  1298  1321 E DatabaseUtils:         at android.os.Binder.execTransactInternal(Binder.java:1021)
01-12 08:36:21.802  1298  1321 E DatabaseUtils:         at android.os.Binder.execTransact(Binder.java:994)
01-12 08:36:21.802  2121  2207 W DirectoryLoader: Failed to query
01-12 08:36:21.802  2121  2207 W DirectoryLoader: java.lang.IllegalArgumentException: Volume external_primary not found
01-12 08:36:21.802  2121  2207 W DirectoryLoader:       at android.database.DatabaseUtils.readExceptionFromParcel(DatabaseUtils.java:170)
01-12 08:36:21.802  2121  2207 W DirectoryLoader:       at android.database.DatabaseUtils.readExceptionFromParcel(DatabaseUtils.java:140)
01-12 08:36:21.802  2121  2207 W DirectoryLoader:       at android.content.ContentProviderProxy.query(ContentProviderNative.java:423)
01-12 08:36:21.802  2121  2207 W DirectoryLoader:       at android.content.ContentProviderClient.query(ContentProviderClient.java:195)
01-12 08:36:21.802  2121  2207 W DirectoryLoader:       at com.android.documentsui.DirectoryLoader.loadInBackground(DirectoryLoader.java:141)
01-12 08:36:21.802  2121  2207 W DirectoryLoader:       at com.android.documentsui.DirectoryLoader.loadInBackground(DirectoryLoader.java:54)
01-12 08:36:21.802  2121  2207 W DirectoryLoader:       at androidx.loader.content.AsyncTaskLoader.onLoadInBackground(AsyncTaskLoader.java:287)
01-12 08:36:21.802  2121  2207 W DirectoryLoader:       at androidx.loader.content.AsyncTaskLoader$LoadTask.doInBackground(AsyncTaskLoader.java:56)
01-12 08:36:21.802  2121  2207 W DirectoryLoader:       at androidx.loader.content.ModernAsyncTask$1.call(ModernAsyncTask.java:96)
01-12 08:36:21.802  2121  2207 W DirectoryLoader:       at java.util.concurrent.FutureTask.run(FutureTask.java:266)
01-12 08:36:21.802  2121  2207 W DirectoryLoader:       at com.android.documentsui.ProviderExecutor.run(ProviderExecutor.java:104)

Waiting for the good news, thank you very much!!

zengerlin avatar Jan 12 '23 08:01 zengerlin

The /mnt/runtime/full/xxx bind mount is missing;

zhouziyang avatar May 19 '23 09:05 zhouziyang

I have known the issue root cause, the fuse mode related code in /system/core/sdcard/sdcard.cpp don't mount /mnt/runtime/full/ dir,but vold daemon process judge whether fuse is ready through /mnt/runtime/full/ dir states variety and redroid10 ams/pms framework code using /mnt/runtime/full/. I have added /mnt/runtime/full/ fuse mode related logic code as default/read/write, the /sdcard dir can be mounted but system_server is crashed occasionally

xufuhai avatar May 19 '23 10:05 xufuhai

Seems some ops not implemented in fuse daemon. Android moves to libfuse since Android 11.

zhouziyang avatar May 22 '23 08:05 zhouziyang

I have known the issue root cause, the fuse mode related code in /system/core/sdcard/sdcard.cpp don't mount /mnt/runtime/full/ dir,but vold daemon process judge whether fuse is ready through /mnt/runtime/full/ dir states variety and redroid10 ams/pms framework code using /mnt/runtime/full/. I have added /mnt/runtime/full/ fuse mode related logic code as default/read/write, the /sdcard dir can be mounted but system_server is crashed occasionally

Hello, I may have the same problem. Have you solved the screenshot problem? ask for advice

liukeqqs avatar Sep 07 '23 09:09 liukeqqs

Is there any solution for this?

MrXLR8 avatar Dec 26 '23 22:12 MrXLR8