[Q] Rules and Method to Restoring the msssms.db and the appstart folder? PLEAS HELP!! - Android Q&A, Help & Troubleshooting

Hello Friends and super expert Android devs and users,
I need some serious help with my SMS and MMS restores, moving from one ROM to another. The big reason for this? I currently have close to 47,000 messages in my SMS threads. Last time I restored these to a new ROM, via the XML insertion method using SMSBackup and Restore, for example it took me 48 hours to do so !!! All this being in Airplane mode to make sure nothing is corrupted or interrupted during the restore!
Titanium Backup is not an ideal solution for me either, because, it also takes a while, AND it will not work going from different UIs to UI, for example: Sense Backup to a CM10 restore of messages.
So I KNOW that the secret SHOULD lie in the msssms.db and the appstart folder, which seems to be the universal way Android stores its messages.
So far, the ONLY successful restore I have been able to pull off with the DBs has been this scenario:
1. Backup from a Sense ROM (Copy the providers.telephony folder into an SD)
2. Wipe and Install the SAME ROM
3. Copy the telephony folder using Root Explorer
4. Reboot into recovery, Fix Permissions, and Wipe Cache and Dalvik Cache
5. Reboot phone and then yes, the messages and MMS were there!
However, this process fails EPICALLY for going to other ROMs like:
Restoring this telephony folder OR JUST the mmssms.db and mmssms.journal files to a CM10 or a MIUI ROM, Rebooting in recovery, and then Fix Permissions, and Cache wipes. The outcome? Constant com.android.phone dying and the whole ROM being trashed ...
So... I need some education and desperate education here, guys. What exactly are the RULES and CORRECT (proven methods) of doing a mmssms.db restore? Can we move from OS version to OS? Like GB to JB? How about flavors of UI layers, like Sense to TouchWiz to MIUI and etc? If so, what is the REAL and the RIGHT way of pulling this off?
Other than that, if you experts thing of ANY OTHER way for me to restore 47K messages, while trying and using different ROMs on my phone, WITHOUT being in Airplane mode for 48 hours AND not, not restoring my whole 47K messages, then please feel free to share! I thank you in advance for your immense help!!!

*BUMP... one of you smart cats HAS TO know this ?

Related

[Q] What is lost during a ROM change? How to backup phone so I can play with ROMS

I'm running streakdroid 1.9 but I would like to do some experimentation with my streak. If I flash a new rom what will I lose? How do you backup your data so you can flash to your hearts content?
Thanks
if u flash stock roms, they do a factory reset during first start up.
So u end up loosing everything.
However if u flash .zip version of the stock roms using CWM or streak recovery , u will retain almost everything but may loose somethings like root and so on.
Remember stock roms will flash its default recovery everytime it boots up
Ok thanks. Is it wise to do a factory reset anyway?
What tools can I use to backup messages, apps, photos, etc?
I use titanium backup.
If you do a nandroid backup, when you restore it, everything will be just as it was before you flashed another ROM...
As far as using Titanium... it has never worked for me completely, nor has MyBackUp Pro, they cause me more headache than being useful...
I have gotten to the point to when I flash a new ROM, I just manually install everything, I know it sounds like some hassle, but you end up with a much smoother operating phone.
I even do a nandroid backup first, then go into my ROM and manually uninstall everything, so that when I boot up my new ROM and setup my market account, it doesn't try to install everything on its own and bog down my phone at first, I install everything manually in the order I want and set them up as I go.
I know this sounds cumbersome, but I have found it creates a cleaner environment and practically eliminated force closes
That is the way I like to do things also but what about the things that you can't just re-install e.g. sms, application specific data?
Advice
I was having a sim card and constant restart issue after updating to streakroid 2.4.4, and even after flashing dsc, the problem persisted. After I reviewed the steps I had taken I realized that I never did a factory resest (fearing I would forever lose my precious app data, which I did -_-). It turned out that was the fix, after doing the factory reset, my sim card was recognized immediately and a couple of the text I had missed showed up. However, I fixed one fixed problem and developed another.
Even though I restored a MyBackup and Titanium backup I did right before resetting I recovered my several apps without their precious data (setting, notes, bookmarks). I tried doing internal backups within the apps, some conveniently had syncs to a cloud yet I missed doing that with a few apps because I have over 100+ and I use more than half on a regular basis (even if for 5 minutes). All my apps are on my device, which is a good thing but I cant appreciate that given the missing data.
So my advice is:
Use apps that have can automatically backup or sync data -- there are enough apps with similiar utility that you can avoid ones without that function.
Do a manual backup within your important apps. -- Some apps backup files to locations that may be wiped during update, doesn't have auto backup or the last backup is months old.
Pics, texts, call logs are easily backed up -- Backup programs will explicitly state or ask what to back up in that regard.
Do a nandroid backup -- I believe this only restores rom and apps but someone can correct me.
Caveat
Through all the research done before actually need to restore a backup I missed the fact when restore apps depending on the restore program every app has to be reinstalled individually. If you have more than 25 apps then #$#@!, also for some reason when restoring with titanium if during a batch restore you come across an app if you hit cancel during one of the install prompts because you actually don't want to restore that app the batch will freeze and you'll have to force close titanium and start the restore all over. Go through the list of restore options and choose each app one by one, save yourself the time.
Lastly, to piggy back off what was said before, a factory reset( FR) after updating rom is always recommended but its not always needed. Most roms will update without causing you to lose any data but like I said previously I had sim card issues when I updated without a FR. YMMV
At this point I don't know if this helps the OP but maybe it will benefit someone else who reads this thread.
This guide by _n0p_ tells how to do an upgrade and minimize the re-installation of apps.
Key items:
Use the backup function of any apps that have it
Don't count on restoring data with TB or My Backup
Make a nandroid - just in case
I have found TB and My Backup to be useful for things like browser bookmarks.
The post linked to discussed going from Froyo to Gingerbread but the same techniques apply for moving to any other ROM.
Last time i changed roms, i used the Dell backup utility for evertyhing but the apps, which can be backed up together with their data with QtADB which creates a backup folder on your SD. After installing the new rom, i chose advanced recovery from the Dell Utility and set it to recover everything but the apps, which i recovered with QtADB. However, I also strongly recommend nandroid, in case the steak doesn't boot after the install.

[Q] Easy way to restore apps/user data after flashing ROM's?

I am new to HTC devices, coming from Motorola Droids. I have read a lot of the info here but still have a few noob questions. I am currently running RezROM 1.5 and like it a lot. But I would like to get the OTA update for the new radio and I would also like to check out some of the ICS ROM's.
So question is: Is there an easy way to restore user data and apps after flashing ROM's? Many of the ROM's I see suggest or require full wipe and often recommend not restoring anything. I have had problems restoring data (both on Motorola and HTC) with Titanium backup.
Thanks!
TahoeTexan said:
I am new to HTC devices, coming from Motorola Droids. I have read a lot of the info here but still have a few noob questions. I am currently running RezROM 1.5 and like it a lot. But I would like to get the OTA update for the new radio and I would also like to check out some of the ICS ROM's.
So question is: Is there an easy way to restore user data and apps after flashing ROM's? Many of the ROM's I see suggest or require full wipe and often recommend not restoring anything. I have had problems restoring data (both on Motorola and HTC) with Titanium backup.
Thanks!
Click to expand...
Click to collapse
The apps part is easy. Backup your /data/app/ somewhere before changing ROMs. Then drop it everything back in /data/app/ afterward. All you're backing up though is the installed application, not the data. Data is not recommended across many ROMs so I don't even think about it.
I've tried a few ways... but ultimately. I just deal with resetting everything up the way I want.
I've used MyBackup. It does alright. Takes forever if you have a lot of SMS messages. And it doesn't exactly get all of your system settings either. I also had a problem where I factory reset, re-installed all my apps. and then ran MyBackup restore to get the home screens back in order and while it did, none of the app buttons worked. So I had to replace everything, but at least I knew where things belonged I guess...
Eitherway, haven't been that impressed with any of the backup/restore things as of yet. I'm feeling bold enough to say there isn't a SlamDunk solution out there that'll work for everyone, but the ones that do exist might do enough for you to be happy.
The best way I have found by far is to use the app "App Monster Pro".
You can have that app made a BU copy of the APK for all your installed apps to a folder on your storage card. Then, after a ROM flash you just go to that folder & click on whatever APK's you want installed for the new ROM & you get a completely clean new install of everything in no time.
That way it a little slower than a TI batch recover, but the difference is it works 100% right 100% of the time (something TI & My BU Pro NEVER do)
It doesn't restore text messages, but I never had any desire to do that anyway (it always cracked me up when I had my TouchPro 2 & people would post I just restored 4200 text messages to my new ROM & now my phone is freezing constantly when texting, what do I do??)
I just use ES File Explorer to backup my apps, as for data, for me, my critical data are my contacts, so I just sync those up with my google account.
I second AppMonster Pro for just apps. I love that as soon as you download an app it makes a backup of it so you never have to think about it. And when restoring it's easy on the eyes, unlike TiBU which I find I have to search around a lot before I find what I'm trying to restore. Still I use three back up systems - AppMonster Pro, MyBackup Pro and Titanium Backup Pro - just in case so if one fails I have others to turn to.

Is there a bug in ICS for data .db restore?

Seasoned user here, def no noob. New to SGSII though. Anyway...here is my info.
I cannot no matter what I try get my phone to restore my Mms .db file, via recovery (I have tried, recovery, titanium, placing the files and setting the permissions manually).
If I delete the existing .db file and paste my Mms .db file there and it shows up in the data/data/com.android.providers.telephony/databases/mmssms.db
permissions
x x
x x
and then reboot
Go back and the old file is back there? Seriously WTF I want to smash this thing!
Someone assist me please?
Going to reply to my own thread with a solution in case anyone else has the same dramas? I kinda needed to do this because i got a chicks number the other day and she was hell cute and she had text me and I had saved her number but had not sync'ed my phone so the only way to get it back was from her SMS that was in the phone that someone had stolen. However I had the nandroid backup from the evening after i met this chick.
All previous hopes via recovery and titanium were fruitless
Anyway, I couldn't do a nandroid restore because it was saying that my device was not an MTD device....naturally its SGSII, and its not CM9 based firmware I have flashed either. So what I did was break the clockwork recovery backup down and pulled the data ext4 tar file out and re-hashed it (MD5sum)
I saw pulled an existing ICS nandroid backup form my SGSII fresh.
I exchanged the data tar and added the new hash value into the nandroid.md5 file and repackaged it.
It passed the check and installed the data but far out out it screwed my phone. android.process.android.acore was going nuts, I doubt there was even an app left that didn't force close.
I then did a titanium backup of the complete re-install with the Mms restored (although I wasn't certain because I couldn't open the messaging app at all! - nor could i get into settings to clear data cache without a bazillion force closes) I did this on total hope that it would work.
I then nandroid backuped my phone again just incase even though the data partition had a see of bugs in it. I then wiped the phone reflashed back to stock and then installed titanium and then restored just the SMS and couple of other things while i was at it! Bam perfect! All texts 100% restored including the drafts as if it was my old phone last I saw of it that is
I am still getting the odd few android.acore FCs but I know its a data cache related issue (I had this a while ago)....but no application FCs what so ever.
I hope this information helps someone out
James

[Q] Help with Installing New Criskelo Rom

Afternoon, I know this will cross over a load of threads so I don't want anyone to spend a lot of time replying just a few bullet points.
I had my phone all how I liked it and then a new ROM was released the other week...........so I backup all apps and data with Titanium backup. Then I backup SMS separately (as Titanium doesn't do it) and I manually move all my photos onto my ExtSDcard.
I had the JellyBean Criskelo ROM 8 and Kitchen on my internal memory card.
Then I booted into recovery, Factory Reset, Wipe Cache, Wipe Davlik.
I installed the ROM and reboot the phone and all good, I install the Kitchen all good.......this is where I have problems...........
Then I re sync to Google and get my contacts back, but then I don't have Titanium to restore my apps, so I spend ages scouring the internet for a copy with batch restore (I have now bought this app but I think the same will apply).........
So I finally find Titanium and recover all the apps, then recover the SMS's and I'm back to how it was prior to the new ROM yet on a new ROM version........i.e. non of the new features of the new ROM.
What am I doing wrong, please amend the above as neccessary and thank you for your patience.
Jamie
Can you specify what are the new features you are not getting.. Your method seems to be okay..
You have been zooo==>ted
Well the Jelly Bean specific bits are disappearing, the folder animations, the little eyes.........
zoot1 said:
Can you specify what are the new features you are not getting.. Your method seems to be okay..
You have been zooo==>ted
Click to expand...
Click to collapse

[REF][NEW-USER] A guide to switching between ROMs

One reason why I chose to buy this device (aside from official Google support) is the overwhelmingly large amount of developer enthusiasm for it. And with that enthusiasm comes a lot of custom ROMs.
I haven't had time to test all of them, but I will - and here's a guide I made that'll hopefully make testing different ROMs easier.
Prerequisites
Before continuing with this guide, make sure that you have:
a LOT of free time, depending on how many ROMs you want to test;
unlocked and rooted your device;
downloaded all the ROMs you want to test;
have installed a good recovery - I would recommend the latest version of TWRP;
common sense.
(OPTIONAL) a spare microSD card of at least 8GB. This'll make everything easier, as you won't have to delete stuff in order to fit all your ZIPs and backups.
Things to remember
Make sure you know how exactly to restore your device to how it was before following this guide.
You should know what you're doing. One small mistake can lead to your device being completely unusable!
You should know what features you're looking for in a ROM. It's never nice to have gone all the way to flash a different ROM, only to discover that feature X doesn't work. Ask questions in the ROM thread, if you like.
You can always ask help from others, should you have any trouble with your device.
When using custom ROMs (or any customization, for that matter), do NOT ask for ETAs. Our developers are doing their work at their own leisure and during their own time, and they don't get their pay from you.
Ready? Let's get going!
Getting started
A good Android user always backs up before doing anything radical to their phone, and that's precisely what we're going to do. There are three ways to go about this:
The easy way
The easy way is through making a Nandroid backup. This is particularly easy to do in TWRP, as all you need to do is reboot into recovery, press Backup, select the partitions you want to back up and whether to compress them, and start backing up. Simple as that.
Pros: Easy to restore your data once you're finished testing ROMs.
Cons: It's somewhat hard to restore individual pieces of data (such as messages and apps) instead of the whole thing.
The (slightly) more complicated way
This way deals with TitaniumBackup, an absolute must-have app for every Android user out there.
With TitaniumBackup, you can choose to back up individual apps (and even update their individual backups). TB isn't limited to backing up/restoring data, though; it can do so much more - remove bloatware, freeze apps you don't use, make a flashable ZIP out of your backups... the list goes on.
Pros: Finer control over what data gets backed up. Very powerful tool in migrating ROMs.
Cons: Somewhat outdated and intimidating interface; and features are reduced without buying the PRO version.
The Google way
This one is the simplest way of all three, though it only works if you have a) GApps and have signed in to your Google account, b) if you've agreed to let Google back your data up when you first set up your device, and c) if you have Settings > Backup & reset > Back up my data enabled.
Google automatically backs up almost all of your data to its servers, ready to be restored when you do a factory reset/switch to a new phone. A list of all data that are backed up can be seen by going to Settings > Accounts > Google > (your email address).
Notable exceptions to the data backed up are messages, which you have to back up yourself - I recommend SMS Backup & Restore for that.
Now that you have your data backed up, let's get flashing.
Flashing
Put your ROMs/kernels/GApps on your SD card, then reboot to recovery.
1. Wiping / factory resetting
This is why we back up your data in the first place. Different ROMs need different data, and data left over from one ROM can cause another ROM to get stuck in a bootloop.
Tip: If you're using TWRP, try enabling Use rm -rf instead of formatting in Advanced settings. Formatting doesn't really have any perceivable advantages over simply removing the contents of your data partition (unless you somehow corrupted it), and it actually causes higher wear on your storage chip. (Storage doesn't last forever - I've had my old Samsung bricked because I reformatted too much.)
Click to expand...
Click to collapse
In CWM, it's called wipe data/factory reset; in TWRP, it's simply called Wipe. Wipe your data, dalvik-cache, and cache partitions.
2. Flashing the ROM and other addons
In CWM, it's called install zip (from sdcard); in TWRP, it's simply called Install. Browse to your ROM zip and install.
Tip: If you're using TWRP, you can add ZIPs to the ZIP queue in this order: ROM > GApps (if any) > Kernel (if any) > Addons/Patches (if any).
Users of CWM must manually flash each ZIP, in the same order.
Click to expand...
Click to collapse
3. Finishing up
Now all that's left to do is pray for the best and reboot.
Testing
If you flashed GApps, do NOT let Google restore data yet. We'll do that later.
Click to expand...
Click to collapse
After initial setup completes and your newly-installed ROM settles down, it's time to get testing. It would be helpful if you listed down all the features you need and check/cross them out one by one if they work or not. For example, I need working screen cast and usable video recording, both of which do not work in all the CM-based ROMs I've tested.
Some ROMs, especially sprout4 ROMs, require patches when installing on sprout8 devices in order to provide the most optimal experience. Try flashing those to see if the ROM gets any better for you.
Rinse & repeat?
So, have you decided that this ROM is for you?
Yes, this ROM is awesome! I love it!
If you backed up earlier using Google, do another factory reset and this time, let Google restore your data.
If you used Titanium for backup, you can safely restore your data now.
If you made a Nandroid backup, you technically can restore your backup as-is since most of the ROMs available for sprout are CM-based; but I wouldn't recommend this as this can cause bootloops. Otherwise, you can manually restore your data one-by-one - but this is a time-consuming process.
I'm not quite sure I like this ROM yet.
Well that's okay, just repeat this guide from the start.
Finishing up
Now that you've decided on what ROM to use, you can safely delete your backups and ZIPs - though it would be better to keep them as they might come in handy if your device starts having problems.
Notes
If you're flashing a Marshmallow ROM, don't flash Xposed right after you flash your ROM as this may cause a bootloop.
Never ask for ETAs on ROM threads. That's rude.
That's it for this guide! Happy flashing! :fingers-crossed:​
Reserved 1
Reserved 2
Reserved 3
Awesome post. Enjoyed it!?
aureljared said:
Reserved 3
Click to expand...
Click to collapse
Sry for digging up this old thread. I was wondering if there is a tutorial for Titanium Backup specifically targeting a switch between custom roms, having different versions of android.
I'm in the midth of moving from cm 13 to lineageos 15 and just tried to backup apps+data in Titanium Backup and restore them and the new system is now somewhat buggy..I'm not sure if the restored backup is the reason for this or not....Maybe there are specific settings to be set..... I mean it's common sense for me not to backup and restore system data but maybe I am missing other important things to be set prior to a backup in Titanium Backup.
trohn_javolta said:
Sry for digging up this old thread. I was wondering if there is a tutorial for Titanium Backup specifically targeting a switch between custom roms, having different versions of android.
I'm in the midth of moving from cm 13 to lineageos 15 and just tried to backup apps+data in Titanium Backup and restore them and the new system is now somewhat buggy..I'm not sure if the restored backup is the reason for this or not....Maybe there are specific settings to be set..... I mean it's common sense for me not to backup and restore system data but maybe I am missing other important things to be set prior to a backup in Titanium Backup.
Click to expand...
Click to collapse
It's hard to say, some apps might work improperly or refuse to terminate in the background due to a mismatch in the restored data. I only backup/restore game data nowadays, as Google Backup takes care of my contacts, SMS, settings, and customization. No problems encountered so far.
The only setting I change in TiBkp is the compression method, as the default (gzip, I think) produces somewhat large backups. I use bzip2.
If you really need to restore everything, it might help for you to wipe /data and restore apps in TiBkp one by one until you find the culprit.
aureljared said:
It's hard to say, some apps might work improperly or refuse to terminate in the background due to a mismatch in the restored data. I only backup/restore game data nowadays, as Google Backup takes care of my contacts, SMS, settings, and customization. No problems encountered so far.
The only setting I change in TiBkp is the compression method, as the default (gzip, I think) produces somewhat large backups. I use bzip2.
If you really need to restore everything, it might help for you to wipe /data and restore apps in TiBkp one by one until you find the culprit.
Click to expand...
Click to collapse
Trying the Google Way was also my thought, unfortunately it does not work for me. I posted this today in the rom I used until now:
https://forum.xda-developers.com/showthread.php?p=76022005#post76022005
The initial setup was quite some time ago and now I cannot recall what I may have done to insult the google sync service
Thanks for this.
Can I ask something?
If I'm on stock rom and have magisk and modules installed. To switch rom, do I need to uninstall those first?
or when using nandroid backup... is its okey to backup with magisk+module on it?
watatara.102 said:
Can I ask something?
If I'm on stock rom and have magisk and modules installed. To switch rom, do I need to uninstall those first?
or when using nandroid backup... is its okey to backup with magisk+module on it?
Click to expand...
Click to collapse
You might want to uninstall your modules first to be safe, but if you're sure they're compatible with the ROM you're switching to, then you might be fine keeping them. As always, backup before trying anything dangerous. :good:
Nandroids are whole-device backups, so if you backup while Magisk is installed, Magisk and your modules will still be there when you restore the backup. If that's what you're aiming for, then go ahead and backup. Just make sure to backup the boot image too, since that's where Magisk is installed.
Sent from my starlte using XDA Labs
Can I install a nandroid backup of a totally different ROM to replace the current ROM I'm using with TWRP?

Categories

Resources