3

I'm interested in making a thorough backup of all my customizations to my android phone. Perhaps not so far as to "image" the phone, because the phone itself is locked to a carrier and I would like to be able to restore the backed up customizations to a phone that has different service and a different phone number (but maybe the method that folks propose would restrict restoration to devices of the same make and model, which would be fine with me - it seems hard to conceive of a method that would allow a backup of a motorola to be restored to a Samsung). In other words, I would like to have my apps, the data saved by my apps, my system configuration preferences, and the files I've manually littered around the filesystem such as in the "Alarm" and "Ringtone" directories. Again, I'd like to be as thorough and low-level as possible without getting into the realm of carrier locks, carrier bloat, or phone number and carrier service account.

Any ideas? I'm a knowledgeable technology user new to the world of Android. The device in question is an ATT Moto E, and in the upcoming future, I might try to restore it to a Sprint or FreedomPop or Republic Wireless Moto E, that latter two of which make modifications to firmware. Further, ATT is GSM while all three of the other mentioned networks are CDMA, so I definitely wouldn't want to backup the "baseband," if that is the correct term, for my particular imagined use case, but maybe this is best framed as two questions that may be combinable into one to some degree. How would one go about doing this in my particular usecase, and how would one go about it in case it was the exact same (sub-)model? Maybe the answer is the same, which would be great.

Thanks

1
  • This is kind of broad, but as a first step please check our backup tag-wiki. After that, you should be able to narrow down what you're trying to achieve and either close your own question as a duplicate or make it a bit more focused.
    – Dan Hulme
    Commented Apr 1, 2016 at 12:20

1 Answer 1

1

If you have a good enough backup program, why not just backup the entire file system on the device? Under Ubuntu 15.10, my Android-based phone gets mounted at /run/user/1000/gvfs/. I back all those files up with borg-backup.

A lot of the customization might also get backed up to your Google profile (I haven't switched Android phones yet). My approach is very low-level and there might even be slicker ways to do it.

#!/bin/bash

# exit immediately on errors
set -e
# error out if uninitialized variable is used
set -u

REPOPATH=ssh://backups.example.com/backup/device/borg
ARCHIVENAME=tgh-usbdevice
if [ $# -ge 1 ]; then
  ARCHIVENAME+="-"${1}
fi
ARCHIVENAME+="-"$(date +'%Y%m%d-%H%M')

echo "Creating: ${REPOPATH}::${ARCHIVENAME}"
borg create --progress --stats ${REPOPATH}::${ARCHIVENAME} \
  /run/user/1000/gvfs/

borg check --archives-only --last 10 ${REPOPATH}

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .