Guest Mushroom_Lord Posted June 27, 2011 Report Posted June 27, 2011 Okay: I will be gunned down because of this, but non-the-less... its about WIPING DATA. Now call me lazy etc but it is really annoying to wipe data between ROM's (when they need it ofc). Now obviously its all the data for system apps which is causing this, data for user apps should generally be okay (otherwise titanium backup wouldn't work, would it? :rolleyes:) So, why can't we JUST wipe system app data? (I don't see why not :)) - but I haven't got a clue on how to do this, and I thought CWM would be the best way: create a zip that deletes system app data, allowing the flashing of ROM's without needing to loose user app data. I know google I supposed to restore it and all, but to be honest wouldn't this be faster? If anyone who is good at scripting would be up to this, please let me know :rolleyes:
Guest ThermalDroid Posted June 27, 2011 Report Posted June 27, 2011 Okay: I will be gunned down because of this, but non-the-less... its about WIPING DATA. Now call me lazy etc but it is really annoying to wipe data between ROM's (when they need it ofc). Now obviously its all the data for system apps which is causing this, data for user apps should generally be okay (otherwise titanium backup wouldn't work, would it? :rolleyes:) So, why can't we JUST wipe system app data? (I don't see why not :)) - but I haven't got a clue on how to do this, and I thought CWM would be the best way: create a zip that deletes system app data, allowing the flashing of ROM's without needing to loose user app data. I know google I supposed to restore it and all, but to be honest wouldn't this be faster? If anyone who is good at scripting would be up to this, please let me know :rolleyes: Yeah I don't see why this hasn't been done o.0 maybe its not possible?
Guest hedgepigdaniel Posted June 27, 2011 Report Posted June 27, 2011 I don't think taht's a good idea. What if you want to reflash your ROM just to undo a patch? doing an automatic wipe removes your choice. For someone who can be bothered to install a ROM and wipe data, pressing a few more buttons does not seem an arduous task.
Guest t0mm13b Posted June 28, 2011 Report Posted June 28, 2011 (edited) Bad IDEA! Think about it - its more than just the directories - there's the cache as well which is the whole point in wiping cache/data first before flashing.... You'll be heading for disaster if you just do a partial wipe - that can cause havoc on apps (some will just die, others will FC like crazy), Another way of realizing this - do a flash without wipe of data/cache - come back to us and tell us... :) (That has been posted once too bloody often on this forum) P.S: If you knew you were going to get gunned down, then why did you post it in the first place? :rolleyes: Edited June 28, 2011 by t0mm13b
Guest Mushroom_Lord Posted June 28, 2011 Report Posted June 28, 2011 P.S: If you knew you were going to get gunned down, then why did you post it in the first place? :) It was worth a shot :L And can't you just wipe your cache partition in CWM anyway? I never said it would be automated but would just use it as an 'installable' zip for CWM so we have the choice to flash it before ROMs...
Guest Mushroom_Lord Posted June 28, 2011 Report Posted June 28, 2011 I don't think taht's a good idea. What if you want to reflash your ROM just to undo a patch? doing an automatic wipe removes your choice. For someone who can be bothered to install a ROM and wipe data, pressing a few more buttons does not seem an arduous task. You missed the point... I never said it would be atuomatic I just wanted it packaged into a separate zip so we have the choice to wipe. And Im not too lazy to wipe data... it just I'd rather not loose it all between flashes :)
Guest t0mm13b Posted June 28, 2011 Report Posted June 28, 2011 You missed the point... I never said it would be atuomatic I just wanted it packaged into a separate zip so we have the choice to wipe. And Im not too lazy to wipe data... it just I'd rather not loose it all between flashes :rolleyes: You young man, need to learn that you cannot have both slices of cake and eat it. You lose data ultimately when flashing to get the best out of the new rom - that is un-avoidable...simple! If you don't bother, and come on here to whine that the ROM is "unstable etc" due to the fact that no wipe took place..... :rolleyes: Some you win,some you lose... learn that :)
Guest wbaw Posted June 29, 2011 Report Posted June 29, 2011 (edited) Here it is... This will wipe your app data, but it'll leave your apps intact so there is no need to re-download them. It'd need a little bash script to tell the difference between system app data & user app data, I'll leave that as a project for you. Don't ever listen to people that tell you something is impossible or unavoidable, it just means that they don't know how to do it.wipe_data.zip Edited June 29, 2011 by wbaw
Guest Mushroom_Lord Posted June 29, 2011 Report Posted June 29, 2011 (edited) Here it is... This will wipe your app data, but it'll leave your apps intact so there is no need to re-download them. It'd need a little bash script to tell the difference between system app data & user app data, I'll leave that as a project for you. Don't ever listen to people that tell you something is impossible or unavoidable, it just means that they don't know how to do it. I sir, thankyou very much for this, and indeed will look into this further. Thankyou very much (: And thanks again for all the things you have done for this forum... Off the top of my head I can say: I'm running Stir fry, upgraded to gen2 with your tpt, changed my splash image/bootanimation via your clockwork mod method... May I quickly ask, if I wanted to change the script, would the binary also need changing? Thanks Edited June 29, 2011 by Mushroom_Lord
Guest wbaw Posted June 29, 2011 Report Posted June 29, 2011 (edited) I sir, thankyou very much for this, and indeed will look into this further. Thankyou very much (: And thanks again for all the things you have done for this forum... Off the top of my head I can say: I'm running Stir fry, upgraded to gen2 with your tpt, changed my splash image/bootanimation via your clockwork mod method... May I quickly ask, if I wanted to change the script, would the binary also need changing? Thanks The binary is standard, no need to change that. There is no way to differentiate between system & user app data using only edify though, you'll need to write a shell script to find out which apps are installed on /data/app & then just delete the other app data directories (under /data/data), then you'll need to remove the line which deletes all /data/data & replace it with a line to call your shell script. Tutorials here: http://tldp.org/HOWTO/Bash-Prog-Intro-HOWTO.html and http://tldp.org/LDP/abs/html/ Edited June 29, 2011 by wbaw
Guest k0zmic Posted June 29, 2011 Report Posted June 29, 2011 Thanks for this Wbaw, I can see it being useful.
Guest Mushroom_Lord Posted June 29, 2011 Report Posted June 29, 2011 The binary is standard, no need to change that. There is no way to differentiate between system & user app data using only edify though, you'll need to write a shell script to find out which apps are installed on /data/app & then just delete the other app data directories (under /data/data), then you'll need to remove the line which deletes all /data/data & replace it with a line to call your shell script. Tutorials here: http://tldp.org/HOWTO/Bash-Prog-Intro-HOWTO.html and http://tldp.org/LDP/abs/html/ Thanks again :) And I was just thinking of chaning delete data/data/ to deleting the system associated folders within it, as to preserve the user app data, but by manually lisiting all known system data folders. Eg delete the data/data/com.android.camera directory along with all the other system folders I can can find in my ROM (though I am sure other ROM's will have more/differently named system folders so I will have to include those too) It will be a long list but Imo it will be the easiest way for me to do it :rolleyes: (as I obviously have no programming experience)
Guest wbaw Posted June 29, 2011 Report Posted June 29, 2011 Thanks again :) And I was just thinking of chaning delete data/data/ to deleting the system associated folders within it, as to preserve the user app data, but by manually lisiting all known system data folders. Eg delete the data/data/com.android.camera directory along with all the other system folders I can can find in my ROM (though I am sure other ROM's will have more/differently named system folders so I will have to include those too) It will be a long list but Imo it will be the easiest way for me to do it :rolleyes: (as I obviously have no programming experience) You can't do it like that, because you don't (and can't possibly) know the name of every system app installed on every current or future rom. You need to do it the other way & find the names of apps installed on /data/app then delete all data, except data associated with those apps.
Guest Mushroom_Lord Posted June 29, 2011 Report Posted June 29, 2011 You can't do it like that, because you don't (and can't possibly) know the name of every system app installed on every current or future rom. You need to do it the other way & find the names of apps installed on /data/app then delete all data, except data associated with those apps. Good plan! ill look at those links tommorow, as for now I have to deal with a grumpy father because I accidentally installed Ubuntu over XP and lost all my files. (none of which I actually needed) then being the Linux hater he is he had to restore a dogey 5 month old XP backup what doesn't actually have anything on it, and needs a tonne of updates, wiping over my Ubuntu in the process. :@. I have serious issues if I can't install Ubuntu :) I spose it may be possible but it will require some hard work, (for me at least, it would probably be a doddle for someone like you :rolleyes:). anyway I need to learn for myself , and will try and continue from here :rolleyes:
Guest wbaw Posted June 29, 2011 Report Posted June 29, 2011 (edited) You shouldn't wipe & install a different os on your dad's computer without asking first. If you want to try ubuntu then use a virtual machine or livecd/usb. You'd need to test it out on your phone anyway, because busybox on the phone uses cut down versions of unix/linux commands which have options missing. I have it mostly working, but .android_secure (native apps on sd) is doing my head in. It might still save the data from any apps on sd card (not properly tested), but the apps themselves are stored encrypted. I thought I'd found the key for .android_secure in /data/misc/systemkeys but when I tried saving that it all broke. I also seem to lose the default home screen settings, I'd expect it to show the default icons & widgets from the rom, but it's just blank. So this should wipe cache, wipe .android_secure & save data from any apps installed on data or sd-extwipe_systemdata.zip Edited June 29, 2011 by wbaw
Guest Mushroom_Lord Posted June 30, 2011 Report Posted June 30, 2011 (edited) So this should wipe cache, wipe .android_secure & save data from any apps installed on data or sd-ext Cheers, you are the man :) And its okay its my machine and no-one else had any data on it (I've put Ubuntu etc on there before without him minding). He wasn't really mad he was just keen to get Xp back on it. (I don't think he likes linux :rolleyes:) Edited June 30, 2011 by Mushroom_Lord
Recommended Posts
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now