1

I have a non-gmail account with a cache of messages in my android gmail app. How can I make a backup of the emails and attachments? Accessing the mail server to make a backup is not possible. I tried the method in the answer here: Backup gmail emails offline However, the backup file is too small to realistically contain the emails and attachments. It's only coming out 549 bytes, even with trying a few different adb backup options.

  • The GMail app has android:allowBackup="true" therefore app backup via adb should be possible. Try to backup a different app to test if adb backup works at all on your device. – Robert Apr 09 '20 at 14:30
  • Confirmed using adb 1.0.41. – b4n4n4p4nd4 Apr 22 '20 at 00:55
  • Tried the methods in the above link, and was able to get a 141MB file, but it did not contain anything but manifests for most apps. gmail app database was not present. Per this link, it should be under /data/data/com.google.android.gm/databases/mailstore.* Am I correct in assuming gmail is blocking the including of the mail database from adb? Do I need to root to get around this, or is there another way? https://android.stackexchange.com/questions/27187/where-are-cached-email-messages-stored-in-the-gmail-app – b4n4n4p4nd4 Apr 22 '20 at 01:02

1 Answers1

0

You can copy these files and directories and paste into new device:

  1. /data/data/com.google.android.gm: for Gmail cache
  2. /data/system_de/0/accounts_de.db and /data/system_ce/0/accounts_ce.db: for Gmail accounts and some google authentication info

maybe this method solves your problem

Mohammad
  • 1
  • 1