Editing Manual backup and restore
Warning: You are not logged in.
Your IP address will be recorded in this page's edit history.
The edit can be undone.
Please check the comparison below to verify that this is what you want to do, and then save the changes below to finish undoing the edit.
Latest revision | Your text | ||
Line 1: | Line 1: | ||
- | There are several scenarios where you might want to manually backup and restore your | + | There are several scenarios where you might want to manually backup and restore your phone. Using manual methods (as opposed to using osso-backup) is convenient for advanced users (to have more control over their phone), scheduling backups with fcron and the like, starting from scratch (if you want to wipe the phone and restore file-by-file) - because osso-backup can backup also problematic files. |
- | This was discussed at [http://talk.maemo.org/showthread.php?t=35037 | + | This was discussed at [http://talk.maemo.org/showthread.php?t=35037 talk.maemo.org]. |
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
==Backup methods== | ==Backup methods== | ||
Line 27: | Line 7: | ||
===Copying=== | ===Copying=== | ||
- | This script backs up contacts | + | This script backs up contacts, conversations, calendar, bookmarks, repository and packages list to external memory card's directory Backup which then contains subdirectories named with date and time when the backup was performed. For example: "Memory_card/Backup/2010-03-03 00-00". It also displays notification during backup, because it was made to be used with fcron. |
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | run-standalone.sh dbus-send --type=method_call --dest=org.freedesktop.Notifications /org/freedesktop/Notifications org.freedesktop.Notifications.SystemNoteInfoprint string:"Backup | + | #!/bin/sh |
- | + | run-standalone.sh dbus-send --type=method_call --dest=org.freedesktop.Notifications /org/freedesktop/Notifications org.freedesktop.Notifications.SystemNoteInfoprint string:"Making backup..." | |
+ | date=`date +"%F %H-%M"` | ||
+ | mkdir -p /media/mmc1/Backup/"$date"/home/user/.bookmarks | ||
+ | mkdir /media/mmc1/Backup/"$date"/home/user/.calendar | ||
+ | mkdir /media/mmc1/Backup/"$date"/home/user/.osso-abook | ||
+ | mkdir /media/mmc1/Backup/"$date"/home/user/.osso-abook-backup | ||
+ | mkdir -p /media/mmc1/Backup/"$date"/var/lib/hildon-application-manager | ||
+ | cp /home/user/.bookmarks/MyBookmarks.xml* /media/mmc1/Backup/"$date"/home/user/.bookmarks | ||
+ | cp /home/user/.calendar/calendardb /media/mmc1/Backup/"$date"/home/user/.calendar | ||
+ | cp -r /home/user/.osso-abook/db /media/mmc1/Backup/"$date"/home/user/.osso-abook | ||
+ | cp -r /home/user/.osso-abook-backup/db /media/mmc1/Backup/"$date"/home/user/.osso-abook-backup | ||
+ | cp -r /home/user/.rtcom-eventlogger /media/mmc1/Backup/"$date"/home/user | ||
+ | cp /var/lib/hildon-application-manager/catalogues* /media/mmc1/Backup/"$date"/var/lib/hildon-application-manager | ||
+ | cp /var/lib/hildon-application-manager/packages.backup /media/mmc1/Backup/"$date"/var/lib/hildon-application-manager | ||
+ | run-standalone.sh dbus-send --type=method_call --dest=org.freedesktop.Notifications /org/freedesktop/Notifications org.freedesktop.Notifications.SystemNoteInfoprint string:"Backup created" | ||
===osso-backup (what is backed up by it)=== | ===osso-backup (what is backed up by it)=== | ||
[[Documentation/Maemo 5 Developer Guide/Generic Platform Components/Using Backup Application|osso-backup]] is the default Backup application on the phone. You can use it for "manual" backup, because it produces standard .zip compressed files which can be opened on any system. The list of files that osso-backup backs up can be obtained by making a backup with it and opening these zip files (the list is too long for this wiki page). | [[Documentation/Maemo 5 Developer Guide/Generic Platform Components/Using Backup Application|osso-backup]] is the default Backup application on the phone. You can use it for "manual" backup, because it produces standard .zip compressed files which can be opened on any system. The list of files that osso-backup backs up can be obtained by making a backup with it and opening these zip files (the list is too long for this wiki page). | ||
- | |||
- | |||
- | |||
- | |||
- | |||
- | |||
- | |||
- | |||
- | |||
- | |||
===rsync=== | ===rsync=== | ||
Line 77: | Line 34: | ||
rsync is standard Linux/Unix file and directory synchronization tool. It is in extras repository. An example backup script is shown here: | rsync is standard Linux/Unix file and directory synchronization tool. It is in extras repository. An example backup script is shown here: | ||
- | ==== | + | #!/bin/sh |
+ | |||
+ | dpkg -l > /root/dpkg.txt | ||
+ | |||
+ | gconftool-2 -R /system/osso/connectivity/IAP > /root/iap.txt | ||
+ | |||
+ | rsync -avz \ | ||
+ | --exclude=/dev \ | ||
+ | --exclude=/media \ | ||
+ | --exclude=/mnt/initfs \ | ||
+ | --exclude=/proc \ | ||
+ | --exclude=/sys \ | ||
+ | / \ | ||
+ | mypc.example.com:/home/archive/mytablet/ | ||
- | + | Change "mypc.example.com" to the IP/hostname of your computer and the target directory to whatever suits you. Don't forget to make the script executable and it must be run as root of course. | |
- | + | ||
- | + | The "dpkg -l" command makes a list of installed packages and gconftool-2 lists all internet access points (Wi-Fi and GPRS), so you can copypaste details back later. | |
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | dpkg -l | + | |
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
- | + | ||
==Automatic/periodic/scheduled backups== | ==Automatic/periodic/scheduled backups== | ||
Line 115: | Line 59: | ||
==Wipe methods== | ==Wipe methods== | ||
- | Wiping the device clean is achieved with reflashing. This is covered in | + | Wiping the device clean is achieved with reflashing. This is covered in [[Updating_the_tablet_firmware]] wiki page and similar. |
==Restore methods== | ==Restore methods== | ||
Line 125: | Line 69: | ||
===Contacts=== | ===Contacts=== | ||
- | You need to create a dummy entry before restoring contacts. Run the contacts application first and create a contact, anything will do. Then exit the contacts application and restore the files in | + | You need to create a dummy entry before restoring contacts. Run the contacts application first and create a contact, anything will do. Then exit the contacts application and restore the files in '''/home/user/.osso-abook/db''' and '''/home/user/.osso-abook-backup/db'''. |
===Bookmarks=== | ===Bookmarks=== | ||
- | Close the browser first, then simply copy the files from your archive to the phone to | + | Close the browser first, then simply copy the files from your archive to the phone to '''/home/user/.bookmarks'''. The bookmarks should appear immediately. |
- | The bookmarks are saved in | + | The bookmarks are saved in '''MyBookmarks.xml''' file, so this is the one that you really need, other files are thumbnails and the like. |
===Calendar=== | ===Calendar=== | ||
- | The calendar entries are in the file | + | The calendar entries are in the file '''/home/user/.calendar/calendardb'''. |
- | + | ||
- | + | ||
- | + | ||
===Repository and packages list=== | ===Repository and packages list=== | ||
- | These are located in | + | These are located in '''/var/lib/hildon-application-manager''', files '''catalogues.backup''', '''catalogues2.backup''' and '''packages.backup'''. These can't be just copied back, because osso-backup uses them in its own way (asks which applications should be reinstalled), but you can use them as list of what you had installed. |
===IM/Chat/SIP accounts=== | ===IM/Chat/SIP accounts=== | ||
- | These accounts are stored in | + | These accounts are stored in /var/lib/gconf/apps/telepathy/mc/accounts. It's probably a good idea to set your presence to "off" before trying to restore. |
===E-mail (Modest)=== | ===E-mail (Modest)=== | ||
- | Restoring | + | Restoring /home/users/.modest and /var/lib/gconf/apps/modest doesn't work properly. I had to create the email server settings, but at least the old email did come back. Actually, I think it might have worked, but the mailbox didn't appear. I discovered that the old mailboxes were there when I looked for them in Menu->View and chose one of the mailboxes. |
- | The rabbit hole goes deeper. I didn't notice there was a problem after restoring, as I use a special email address for my tablet and it didn't get any email for a while, so I was quite happy accessing my recovered emails. When a new email arrived, it killed modest, and I was unable to restart it - the UI would show up briefly before modest died. The only way I could make modest run without crashing was to rename | + | The rabbit hole goes deeper. I didn't notice there was a problem after restoring, as I use a special email address for my tablet and it didn't get any email for a while, so I was quite happy accessing my recovered emails. When a new email arrived, it killed modest, and I was unable to restart it - the UI would show up briefly before modest died. The only way I could make modest run without crashing was to rename /home/user/.modest to /home/user/.modest.xxx. |
- | === | + | ===gPodder=== |
- | Close | + | Close gPodder and copy its config directory to /home/user/.config/gpodder. |
- | === | + | ===OpenVPN Applet=== |
- | + | If you use the OpenVPN Applet the configuration files are stored in /etc/openvpn. After you copy them be sure to have them owned by user "root", group "root", and protected so that user (root) has rw privileges, and no one else has anything. | |
- | === | + | ===RSS Feeds=== |
- | + | Close RSS application and copy files to /home/user/.osso_rss_feed_reader. | |
- | + | ===Wi-Fi and GPRS access points=== | |
- | + | You'll have to manually re-enter them, but you can copypaste details from the file created with rsync backup script (iap.txt). | |
- | + | ||
- | + | ||
[[Category:Power users]] | [[Category:Power users]] | ||
- |
Learn more about Contributing to the wiki.