backup data for an app? - G1 Apps and Games

is it possible to backup data from on app before flashing?
i am running dudes cupcake and have bought workoutmanager from the market. i have taken a heap of time to install all my workouts and exercises and dont want to lose it next time i wipe and flash.... the app has an export function but no import.
i found the data for the app in: ls /system/intmem/data/com.wktmngr
inside was 2 files- MyWorkout and lib.
i figure i could just copy these to sd card using cp /system/intmem/data/com.wktmngr/MyWorkout /sdcard
and same for lib.
then cp this back in after flashing....
would this work?
is this the correct command or do i need cp -a /system/intmem/data/com.wktmngr/MyWorkout /sdcard ???
thx

I posted a similar question a little while ago in the main Dream forum. Worth I can't find the link now but if I remember correctly you will find the apps estate in data/data and you can web pull to your computer or copy to your decade.
If you search under my name, it should show up.

thanks mate- i figured it out myself on the weekend.... problem was finding the data folder with the new apps2sd- esp. with me being a linux nooob....
cp /system/intmem/data/com.wktmngr/MyWorkout /sdcard
i tested it by uninstalling app and checkin it had deleted all data- it had... then reinstalled, rm the new MyWorkout and cp old one in.
If anyone is wondering: Workout Manager is a great gym app. Best so far- not the best GUI but the fxns are exactly what is required....

Related

New recovery script "utility" / AUTO PARTITION!!!

MORE INFO IN POST 3 HERE
I am happy to announce the release of my new utility script. This script currently has 11 functions as noted below. It runs in recovery with the help of sdutility which is another script that procures the necessary permissions and file location for some of the features. Some of these options are copied from Cyanogen's various scripts located in his recovery image.
Option 11 will ask you what size to make the swap and ext partitions and then it will partition your sdcard for you using the remaining space for fat32.
The menu looks like this:
Code:
1) Enable SDcard to USB
2) Disable SDcard to USB
3) Upgrade ext2 > ext3
4) Upgrade ext3 > ext4
5) Fix Permissions
6) Repair Filesystem
7) Clear Dalvik-Cache
8) Clear ext partition
9) Backup APPS on ext to FAT32
10) Restore APPS from FAT32 to ext
11) Partition SDcard
Q) Quit Utiltity Menu
Enter Number> _
i am going to get you samuel jackson's wallet from pulp fiction because that is what you are with these scripts.
I think these scripts, along with miketaylor00's fix_rotate script, need to be included in every ROMs /system/bin folders.
Btw, why the . in "./sdcard/sdutility"? I'll probably just move these scripts over to the /system/bin folder on my phone for consistency.
That is an execute command and is required because /sdcard is not in $PATH. sdutility copies the utility script which is the actual script doing all the work to /sbin, setting permissions to 755, and launching it. The point of all of that is with the script on the sdcard it can't partition it without deleting itself.
Fingerlickin said:
That is an execute command and is required because /sdcard is not in $PATH. sdutility copies the utility script which is the actual script doing all the work to /sbin, setting permissions to 755, and launching it. The point of all of that is with the script on the sdcard it can't partition it without deleting itself.
Click to expand...
Click to collapse
I follow... guess I can just keep it on SDcard to run it from.
I looked at the files and figured that's how it worked... I did copy utility to my system/bin and ran it from recovery console. I even backed up my apps using option 9. It gave me an access denied error from line 173 (the fi command in the script). However, it seems it did back up the apps.
dude, this is awesome. im gunna try it out later... using my ubuntu partition.
anyways, when you backup your apps from the ext partition, does it copy over the google apps as well?
backing up the apps copies the /system/sd/app folder to /sdcard/appbackup.
To the best of my knowledge this is NOT a violation because you are backing up your OWN apps including any closed source apps. As long as you don't distribute these apps you are fine.
P.S. I bought a movie tonight and immediately put it in my computer and ripped it. My reason for this is my computer stores all my movies and my xbox streams them to my TV. Nothing wrong with this because I am not distributing the movie to other people.
Fingerlickin said:
backing up the apps copies the /system/sd/app folder to /sdcard/appbackup.
To the best of my knowledge this is NOT a violation because you are backing up your OWN apps including any closed source apps. As long as you don't distribute these apps you are fine.
P.S. I bought a movie tonight and immediately put it in my computer and ripped it. My reason for this is my computer stores all my movies and my xbox streams them to my TV. Nothing wrong with this because I am not distributing the movie to other people.
Click to expand...
Click to collapse
hey finger, let your xbox stream video to my tv as well.
Fingerlickin said:
backing up the apps copies the /system/sd/app folder to /sdcard/appbackup.
Click to expand...
Click to collapse
I feel the urge to clarify this.
mounts both ext and fat32
check to see if both folders exist and creates /sdcard/appbackup if it doesn't
THEN it copies the CONTENTS OF /system/sd/app to /sdcard/appbackup
but david, I'm a good law abiding citizen and that would be illegal.
catch me on gtalk
So has anyone else had the access denied error referencing line 173?
Fingerlickin... any chance you could work with Cyanogen to integrate this with his recovery? I'm thinking it's time for a Cyanogen Recovery v1.5.
Great work fingerlickin
Unasari, the orig plan for this was to make cyan's recovery more noob friendly, hopefully cyan will roll this into his new recovery and add trackball support to it for the mt3g users. Don't be surpised if you see a wrecking crew modified recovey image
Great work I see all of us got something to keep us busy now.
I am looking into the line 173 error now. We need MT3G support before cyan will touch it, working on that too.
I can't recreate the error at line 173. Lets see if others have the problem as well.
Updated to v1.1 see post 3 HERE for details.
This has a possible fix for your line 173 error. I didn't anticipate someone trying to backup apps when they don't have any apps installed on the ext or you try to backup apps after partitioning the card because there obviously isn't a /system/sd/app directory in this case. I have no idea if this will fix your problem or not.
I also included support for ADB (MT3G) YAY
Updated again.
v1.2
updated to fix_permissions v1.29
fix_permissions always has the -r option

About Deleting Stock apps. [g1]

Alright so It's always been an aim of mine to some day retire the G1 as a PMP and use the Emulators I have on it for fun and music and videos yadda yadda yadda.
Today I actually went through with giving it a try.
I nandroid backed up on my Soul Life build.
Swapped out the sd card with the stock one.
Wipe and flashed to a different build.
And ran the codes to remove stock apps.
Su
mount -o rw,remount -t yaffs2 /dev/block/mtdblock3 /system
rm /system/app/com.amazon.mp3.apk
rm /system/app/VoiceDialer.apk
Took out Amazon, and the Voice dialer application.
However I DID NOT get the following applications to be removed via terminal emulator.
I've deleted everything but
Alarm Clock
Gallery
Google Maps
Log Collector
PDF Viewer
Quickoffice
Spare Parts
Teeter
Youtube
Mind you on a soul life build Teeter and PDF Viwer can't be uninstalled via settings, [not do I have the settings .apk anymore.]
But I am flashing to a cyan build just to remove them but any help and knowledge will be appreciated.
I boot looped my phone after I rebooted it having deleted some stock applications and I'm curious to know which ones I need to keep?
Here's how I remove them...
Make a backup first (ALWAYS!)
Must have Root access.
I'm on Cyanogenmod V4.2.2
su
ls /system/app (find the app you want to remove and write down the code) Ex. com.amazon.mp3.apk
cd /system/app
rm -r com.amazon.mp3.apk
Click to expand...
Click to collapse
Thats all I had to do to remove them anyway. Someone correct me if I'm wrong.
*edit- Ok, so I tried the same method on the youtube.apk, and got permission denied. Looking into that now.
You guys could get the autosign tool setup and just delete the apps you don't want. Would be easier than using the terminal.
Double Post. My apologies. Here's what you do, if using Terminal Emulator.
mount -o remount,rw /system
rm /system/app/YouTube.apk
mount -o remount,r /system
Click to expand...
Click to collapse
Make sure to do the last part to make the folder read only again, or it may cause some accidents. Good luck.
What you need to do is mount system rw (like the op said) and from there you can rm -r all you want.
Here's what I remove right away
amazon.mp3
voice dialer
voice search (in the past, now it's global search so I keep it)
email
work email
vpn services
htc_ime
latin_ime (I use replacement vk)
From what I heard, you need to stay away from anything that has google in it (gmail, setup wizard, gtalk,) and from anything that has to do with IM.
Good luck.

[Q] i9000m + Froyo + Internal SD Card failure ?

Ok so there's alot of info. regarding Internal SD card failure and Froyo.
My question is will this occur with a natural Froyo update instead of a flash ?
I have a stock i9000m - never even rooted, no lag fix, nothing.
I heard Froyo will be coming soon (im guessing via Kies?)
Will the Froyo update mess up my Internal SD as appears to be happening with Froyo Flashs ?
Also, will I lose my apps when I update via Kies to Froyo ?
thanks guys.
From what I've seen on here there is no direct link to sd failure from flashing. I think just as many have failed that were not flashed. Always possible though that a botched flash could spell doom.
An official update should not damage your phone. If it does, you should return it to bell for repair or replacement.
Many on here recommend a factory reset after update, I'm planning to do that myself. Reinstalling apps is no big deal. Takes only minutes and because they are linked to your google account you don't have to buy paid apps again.
Sent from my GT-I9000M using XDA App
However, the linking to the Market account does not restore unpaid apps. These you will have to install again, and of course, you have to remember which ones these are. This could be time consuming.
In my case it took about 2 hours. I had many apps, and in some I could not remember the names: A fair amount of time was lost searching for the names.
Any easy solution to this is to back up this directory on your phone afore you reset:-
Directory: /data/app
It contains all the .apk of your apps.
use the ADB to get a shell on your phone - There are a few guides around on how to set this up. Once set-up, please use this command to get a shell:
adb shell, and then su to root:
adb shell
su
* How to backup.
Change into the directory
cd /data/app
Archive the files to a file on your SD card. In this case the archive tar file is called /sdcard/apps.tar. You can put it anywhere you want with any filename you like.
tar cvf /sdcard/apps.tar .
* Perform a factory reset.
* Restore the files.
Here you should extract the archive into a tempory directory and use a file manager like Astro to click on and then install the apk files:
Create a temp directory for the files:
mkdir /sdcard/apkrestore
Change to the directory:
cd /sdcard/apkrestore
Extract the files from the archive:
tar xvf /sdcard/apps.tar
List the file files in the dir - you will see many files with .apk extensions.
ls /sdcard/apkrestore
Install the apks
Start ASTRO file manager and navigate to /sdcard/apkrestore
Click on the apk you wish to install.
Its funny how people seem to omit this information: as if they think people only ever buy apps and never use the free ones ;P
forgetmyname said:
However, the linking to the Market account does not restore unpaid apps. These you will have to install again, and of course, you
Its funny how people seem to omit this information: as if they think people only ever buy apps and never use the free ones ;P
Click to expand...
Click to collapse
Awesome info. I guess I will try this.
Questions. I obviously have to have a root to use these ADB commands ? I haven't rooted phone yet.
Other question, is there an easier way to back up all apps? Like what if I root ? I can get Titanium Backup Pro -- will this work? would this back up apps to my sdcard ? I have a 32gb external card too -- can I back up apps to this or no ?
Final question,
has anyone in Canada been able to do a normal, official update via kies to froyo 2.2 ?? is it avail. yet ?

[Q] Increasing free memory on my Milestone

I've noticed that killing all the apps on my milestone doesn't provide me with a lot of free memory compared to other users.
When I tap the ATK widget, I end up with 35 - 40mb free. I've read that other users can get upwards of 100mb free when they clean-up their running apps.
I did some research and came across the following "fix":
Code:
How To: Free Extra Memory::
look under Settings>SD Card & phone storage> down at avalible space internal storage make note on how much is there.
step 1: download this file
attached at bottom of this thread
step 2: rename the file by deleting the .txt extention and leaving it blank! *should just be named "mot_boot_mode"*
step 3: place the file on the root of your SDcard
step 4: using terminal emulator or adb shell type these commands:
su
mount -o remount,rw /dev/block/mtdblock6 /system
cd /system/bin
cp mot_boot_mode mot_boot_mode.bin
rm mot_boot_mode
cp /sdcard/mot_boot_mode .
chown root.shell mot_boot_mode
chown root.shell mot_boot_mode.bin
chmod 755 mot_boot_mode
chmod 755 mot_boot_mode.bin
reboot
NOTE THE "." at the end of cp /sdcard/mot_boot_mode YOU HAVE TO INCLUDE THE "."
congrats you should have alot more free memory! now go back to Settings>SD card & phone storage> and see how much is avalible
i went from 45mb to 113mb
However there is not much explanation as to what exactly this does.
Also while reading up on the SGS, I've noticed a lot of information on converting the RFS partition to ext2 or 4. I don't think the Milestone suffers from the same i/o problem as the SGS, is there something similar that can be done for the milestone to improve it's performance?
Any input would be appreciated, I'm still a bit of a scrub!
drae52 said:
I've noticed that killing all the apps on my milestone doesn't provide me with a lot of free memory compared to other users.
When I tap the ATK widget, I end up with 35 - 40mb free. I've read that other users can get upwards of 100mb free when they clean-up their running apps.
I did some research and came across the following "fix":
Code:
How To: Free Extra Memory::
look under Settings>SD Card & phone storage> down at avalible space internal storage make note on how much is there.
step 1: download this file
attached at bottom of this thread
step 2: rename the file by deleting the .txt extention and leaving it blank! *should just be named "mot_boot_mode"*
step 3: place the file on the root of your SDcard
step 4: using terminal emulator or adb shell type these commands:
su
mount -o remount,rw /dev/block/mtdblock6 /system
cd /system/bin
cp mot_boot_mode mot_boot_mode.bin
rm mot_boot_mode
cp /sdcard/mot_boot_mode .
chown root.shell mot_boot_mode
chown root.shell mot_boot_mode.bin
chmod 755 mot_boot_mode
chmod 755 mot_boot_mode.bin
reboot
NOTE THE "." at the end of cp /sdcard/mot_boot_mode YOU HAVE TO INCLUDE THE "."
congrats you should have alot more free memory! now go back to Settings>SD card & phone storage> and see how much is avalible
i went from 45mb to 113mb
However there is not much explanation as to what exactly this does.
Also while reading up on the SGS, I've noticed a lot of information on converting the RFS partition to ext2 or 4. I don't think the Milestone suffers from the same i/o problem as the SGS, is there something similar that can be done for the milestone to improve it's performance?
Any input would be appreciated, I'm still a bit of a scrub!
Click to expand...
Click to collapse
Where did you get this .bin file?
What does it do?
I am all for improving free ram and development efforts, but running executables from unknown, untrested sources (no offense) is borderline silly...
I know you said you dont fully understand this, but a bit more detail is in order...no?
Sent from my Milestone using Tapatalk
drae52 said:
I've noticed that killing all the apps on my milestone doesn't provide me with a lot of free memory compared to other users.
When I tap the ATK widget, I end up with 35 - 40mb free. I've read that other users can get upwards of 100mb free when they clean-up their running apps.
I did some research and came across the following "fix":
Code:
How To: Free Extra Memory::
look under Settings>SD Card & phone storage> down at avalible space internal storage make note on how much is there.
step 1: download this file
attached at bottom of this thread
step 2: rename the file by deleting the .txt extention and leaving it blank! *should just be named "mot_boot_mode"*
step 3: place the file on the root of your SDcard
step 4: using terminal emulator or adb shell type these commands:
su
mount -o remount,rw /dev/block/mtdblock6 /system
cd /system/bin
cp mot_boot_mode mot_boot_mode.bin
rm mot_boot_mode
cp /sdcard/mot_boot_mode .
chown root.shell mot_boot_mode
chown root.shell mot_boot_mode.bin
chmod 755 mot_boot_mode
chmod 755 mot_boot_mode.bin
reboot
NOTE THE "." at the end of cp /sdcard/mot_boot_mode YOU HAVE TO INCLUDE THE "."
congrats you should have alot more free memory! now go back to Settings>SD card & phone storage> and see how much is avalible
i went from 45mb to 113mb
However there is not much explanation as to what exactly this does.
Also while reading up on the SGS, I've noticed a lot of information on converting the RFS partition to ext2 or 4. I don't think the Milestone suffers from the same i/o problem as the SGS, is there something similar that can be done for the milestone to improve it's performance?
Any input would be appreciated, I'm still a bit of a scrub!
Click to expand...
Click to collapse
Wow, this is meant for freeing internal memory, not RAM. I'm pretty sure this was meant for 2.1, so don't try it on any 2.2 roms. My milestone also has barely any RAM available.
Caz666 said:
Where did you get this .bin file?
What does it do?
I am all for improving free ram and development efforts, but running executables from unknown, untrested sources (no offense){non taken } is borderline silly...
I know you said you dont fully understand this, but a bit more detail is in order...no?
Sent from my Milestone using Tapatalk
Click to expand...
Click to collapse
It would be silly if I ran it without asking that's why I asked if anyone knows what it does. It's the simplest looking ram "fix" I found, but I'm not versed well enough to understand exactly what it's doing.
I found it on some android forum, (still open on my desktop, I should have posted the link, my bad, I'll get it up soon.) There isn't anymore detail then this unfortunately, which is why I asked here
@Mohitrocks - thanks it was listed as a way to free up ram, but after I read the last line again I tend to agree with you.
How about that file system fix for the sgs? I don't understand much about the milestone filesystem, if anyone could point me to some reading it would be greatly appreciated!
I know it's not what you had in mind but the best way is to uninstall apps that restart themselves when you don't want them to restart.
For example, I had this wallpaper app... it downloads wallpapers... nice app... but why did have to stay in memory ALL THE TIME? I disabled the option for it to rotate wallpapers etc but it wouldn't go away...
There were a couple of others that I don't recall but keep on eye on those persistant memory hogs that shouldn't be persistent.
I'll keep that in mind.
I'm regularly sitting at like 35mb free. How are some users reporting ~100mb? They must have done something; I've never seen mine that high. I've heard of memory booster, what exactly does that app do?
No clue how they have 100mb free ram unless they have 512 mb to start with.
The most I would see on a fresh install of CM612 would be 60 mb max.
I am using shadowmod b3 in which background processes would be auto-killed quickly.
In this way, I can have 7x mb ram at best
how to boost up the ram to 100mb???
I'm using ShadowModb6 and getting between 70 and 80mb free with regular use, and a task killer of course.
LuigiC6 said:
I'm using ShadowModb6 and getting between 70 and 80mb free with regular use, and a task killer of course.
Click to expand...
Click to collapse
how many apps did you install??
It seems to me that the more apps you install, the slower the phone function though there should be no relationship between no.of apps and ram.
And what task killer do you use??
what is your setting??
You can get about 90mb ram with Gingerbread in the best case with the beta 3, but with services killed constantly, so that is not a good comparison, there is no way you can get more than 50-60mb even with froyo, so who told you that they have 100mb free, they talk bull**** or they have a phone with 384MB or 512mb ram
or you are talking about the internal storage space that on the milestone is about 190MB with a clean froyo,
Sent from my A853 using XDA App
I noticed that some apps just get killed in the background when I have recently flashed to CM6 Froyo. However there were less app 'killed' when I was using stock 2.1
I thought Froyo was better in terms of memory management?
The custom ROM OC'ed the Milestone to 900Mhz, so the speed is quite decent. But I'm frustrated when for example, I turn on my GPS Ndrive, and then a call came.. I answered and after that I switched to Ndrive - it loads back from the beginning. This isn't happening with Eclair before.
Come on guys, what can I do?

[FIXED] [Q] XT860 - Broke my /system/app folder...

EDIT: Fixed! Procedure I used was to download Danifunker's system dump, move it to /sdcard/ via adb push, then run the following:
Code:
adb shell
su dd if=/sdcard/mmcblk1p21.img of=/dev/block/mmcblk1p21
This completely refreshed my /system folder. Original post below:
--------------------------------------------------------------
Hello XDA forumgoers, longtime reader first time poster here. I'm currently posting because I made a few mistakes. Several mistakes, actually.
1. In my quest to de-bloat my XT860, I accidentally removed one file too many, which caused my phone to mysteriously not have a cell signal. (com.motorola.service.main kept crashing.) So I hit the forum and grabbed a system dump from this thread (thanks Willis111):
http://forum.xda-developers.com/showthread.php?p=17501981
I had bought the phone with some version of Cyanogenmod Recovery installed by the previous owner, so I was able to use that and ADB to stick the .apks and .odex files in the /system/app folder, chmod 644 them, and even factory reset for good measure.
2. As I soon found out, I had somehow made things worse. The phone, when boot into, shows the "press android to begin" page, but com.motorola.service.main and some other apps keep FCing on me, and I can't progress past that screen. In my haste, I didn't backup any of my system folders at all, though, I still backed up my apps with Titanium.
Tl;dr:
presumably none of the /system/app apks boot, most notably com.motorola.service.main. How do I fix this? Can I?
Try to flash
http://forum.xda-developers.com/showthread.php?t=1288823
You also need to chown 0:0 both the apk and the odex
Have you tried using my original system dump? It was taken with dd, so things like symlinks and the other sort should be functional. The only caveat is that a number of apps were frozen at the time, so you may need to unfreeze them with titaniumbackup.
http://www.multiupload.com/SORQERFAYT
DoubleYouPee: Is this that chinese rom I've heard of? I heard that if I flash this, I can't root my phone. So I think I'll save this one as a last resort.
eww245: chown'd, no result.
daniflunker: how do I open this?
jonsicoli said:
DoubleYouPee: Is this that chinese rom I've heard of? I heard that if I flash this, I can't root my phone. So I think I'll save this one as a last resort.
eww245: chown'd, no result.
daniflunker: how do I open this?
Click to expand...
Click to collapse
What about rootkeeper?
DoubleYouPee said:
What about rootkeeper?
Click to expand...
Click to collapse
I can't get past the "click android" screen, so I probably can't install or run it. Any way to do it via adb or Cyanogenmod Recovery?
I really appreciate the help.
jonsicoli, if you want to restore your *entire* /system folder (not just apps) you would run a similar command-set as this.
1. Copy the file to the internal memory
adb push c:\path.to.folder\mmcblk1p21.img /sdcard
the file will be located in the root of the sdcard (or you could drag and drop the file in USB storage mode)
2. Do a full restore on system memory *I have not checked to ensure this is working... but a command similar to this should work
adb shell
su dd if=/sdcard/mmcblk1p21.img of=/dev/block/mmcblk1p21
- wait -
(it would have to write about 500mb and replace all of the contents of /system )
reboot
_______________________________________________________
Okay, if you just want to look at the files, you could use a linux machine to mount the filesystem (it is a standard ext3 FS) or you could do what I have done on my windows system:
Install EXT2FsD from http://sourceforge.net/projects/ext2fsd/files/latest/download?source=files
Then install OSFMount from http://www.osforensics.com/tools.html
Point the OSFMount program to the img file that you downloaded and assign it a drive then voilla!
I am pretty sure this is a bit of overkill, but this should completely restore your system close to factory (minus the APKs that were upgraded/disabled, plus the fact root was done)
Thanks Danifunker! I reset my entire /system folder, and restoring my user app backup. I'm just relieved to have my phone back. Now to mark this thread as solved.
Awesome!!!!!! Glad to hear my system dump works! Thanks for testing
My command lines were written correctly also I guess?
Sent from my XT860 using XDA App
searched for like 8 hours until i found this thread. Just what i needed, i had system image for 2.3.6 from your other post but no command.

Categories

Resources