10

I'm unable to adb pull /data/anr/anr_xxx files on my Pixel Xl with Android 8.1.0.

My trials:

➜  Downloads adb shell ls -al /data/anr
total 1184
drwxrwxr-x  2 system system   4096 2018-06-24 13:57 .
drwxrwx--x 43 system system   4096 1970-02-11 19:30 ..
-rw-------  1 system system 503517 2018-06-24 01:41 anr_2018-06-24-01-41-39-700
-rw-------  1 system system 683519 2018-06-24 13:57 anr_2018-06-24-13-57-19-517
➜  Downloads adb pull /data/anr/anr_2018-06-24-01-41-39-700 .
adb: error: failed to copy '/data/anr/anr_2018-06-24-01-41-39-700' to './anr_2018-06-24-01-41-39-700': remote open failed: Permission denied

marlin:/data/anr $ ls -al
total 1184
drwxrwxr-x  2 system system   4096 2018-06-24 13:57 .
drwxrwx--x 43 system system   4096 1970-02-11 19:30 ..
-rw-------  1 system system 503517 2018-06-24 01:41 anr_2018-06-24-01-41-39-700
-rw-------  1 system system 683519 2018-06-24 13:57 anr_2018-06-24-13-57-19-517
marlin:/data/anr $ cp anr_2018-06-24-13-57-19-517 /sdcard/Download
cp: /sdcard/Download/anr_2018-06-24-13-57-19-517: Permission denied

I googled many times and didn't find a solution and i'm really going to be crazy. Any help or hint will be appreciated. Thank you!

Phantômaxx
  • 37,901
  • 21
  • 84
  • 115
Liu Tao
  • 2,063
  • 2
  • 10
  • 14

1 Answers1

14

You can use adb bugreport ./bugreport.zip, then unzip bugreport.zip, you will find a bugreporp-xxx.txt. from this txt, you can get /data/anr/anr_xxx file content by greping /data/anr/anr_

Chandler
  • 346
  • 3
  • 12
  • I try this idea, but still failed. `Error unlinking temporary trace path /data/anr/dumptrace_xNqWs7: Permission denied execvp on command 'parse_radio_log /proc/last_radio_log' failed (error: Permission denied)` – joe Aug 15 '19 at 04:23