• Introducing XDA Computing: Discussion zones for Hardware, Software, and more!    Check it out!

[Tutorial] How to extract logs of an app in Galaxy M31

Search This thread


New member
Aug 4, 2021
This post explains how you can extract the logs of an app using the adb command line tool. Earlier, we could access the Android->data folder for each app but that is not possible now. But we can do it using the adb command line tool.
1. Step 1
a. Install and setup the adb command line tool for your computer. This article shows you how to do so.

2. Step 2
a. Now since your phone is connected to your computer via adb, open a command prompt and type in "adb shell". Now you can access your phone via the command line.
b. To access the data folder for a particular app, type in the following command "cd /sdcard/Android/data". Here you'll find the data folders for all the apps in your phone.
c. List all the apps using the "ls" command as shown below.

3.Step 3
a. Now get the complete name of your app and type in "cd <COMPLETE_APP_NAME>". Here you can access the logs/cache of your app.


b. Now to download this file to your pc, open another command prompt and type in command "adb pull /sdcard/Android/data/<APP_NAME>/<YOUR_PATH>"

c. This will fetch and download the files you need at the location where your command prompt is pointing to (D drive in this case)