Can't load adb database even after chmod 777 on my device

I can not pull the database from the device even after changing the permission. I have a built-in phone. It worked. I could pull before. For some unknown reason, I cannot.

The error I get is remote object '/data/data/com.thuptencho.transitbus/databases/ttc.db' does not exist

Does anyone know why this is happening? The following is what I did in the command window.

 C:\users\thupten>adb shell shell@android :/ $ su su root@android :/ # cd /data/data/com.thuptencho.transitbus/databases/ cd /data/data/com.thuptencho.transitbus/databases/ root@android :/data/data/com.thuptencho.transitbus/databases # ls ls ttc.db ttc.db-journal webview.db webview.db-journal webviewCookiesChromium.db webviewCookiesChromiumPrivate.db root@android :/data/data/com.thuptencho.transitbus/databases # chmod 755 ttc.db 5 ttc.db < root@android :/data/data/com.thuptencho.transitbus/databases # chmod 777 ttc.db 7 ttc.db < root@android :/data/data/com.thuptencho.transitbus/databases # exit exit shell@android :/ $ exit exit C:\users\thupten>adb pull /data/data/com.thuptencho.transitbus/databases/ttc.db remote object '/data/data/com.thuptencho.transitbus/databases/ttc.db' does not exist 
+7
android adb
source share
5 answers

I get it. I also had to chmod the database folder and then the file.

+4
source share

I use these commands to retrieve data from data / data folders, without having to change the permission

 adb kill-server adb root 
+8
source share

The problem is that you need permission not only for the file, but also for its parent directories.

(This permission should not be 777!)

Instead of trying to change the resolution, what you probably want to do is get adb to work as root if it is supported (that is, if you have an engineering assembly and not the after-sales rooting of a secure device) or use your root access (or the application itself or the stock launch command, if you have debug apk) to copy the file of interest somewhere accessible, and then adb pull out a copy.

+2
source share

My preferred solution:

Install the adbd unecure Chainfire application Inside the adbd insecure application, select "Enable insecure adbd", adb pull / data / data / com.package.name / databases / database.db

Caution - adb insecure means that adb runs on your device with root privileges.

0
source share
 for i in `adb shell ls /data/ -1`;do adb pull /data/$i data; done 
0
source share

All Articles