Reply
Thread Tools
Posts: 889 | Thanked: 537 times | Joined on Mar 2010 @ scotland
#1
in my alternate life as an international man of mystery i may at some point have to wipe all my data in an emergency, i know there is a short xterm code to completely erase everything, but i want the phone to still be usable, i was just wondering if there is a xterm code that will wipe all user data but leave the os intact? then i can queen beecon it and if the commies catch me i can hit the button and nobody has to die. yet.

p.s. this post will self destruct in 3hours.
__________________
sarcasm may be the lowest form of wit, but its the only wit i have.

its a sad day when i can't slip at least one hitchhiker reference in somewhere.

Last edited by festivalnut; 2011-02-09 at 01:49.
 

The Following User Says Thank You to festivalnut For This Useful Post:
Captwheeto's Avatar
Posts: 302 | Thanked: 193 times | Joined on Oct 2008 @ England
#2
What kind of things did you want deleting? I don't think there's a one-stop-delete-everything-in-a-usable-way command, but it's certainly scriptable.
 

The Following User Says Thank You to Captwheeto For This Useful Post:
Posts: 889 | Thanked: 537 times | Joined on Mar 2010 @ scotland
#3
basically everything i've put on there, call records, texts, images and videos, im, gps history. if its scriptable it may be good to not delete my apps and saves etc, but definately anything that could lead the enemy to my secret volcano safehouse... oops, i've said too much already!
__________________
sarcasm may be the lowest form of wit, but its the only wit i have.

its a sad day when i can't slip at least one hitchhiker reference in somewhere.
 
Posts: 235 | Thanked: 339 times | Joined on Nov 2010
#4
Start with the "Clear device" function already found in Settings. It runs a script: /usr/sbin/osso-app-killer-cud.sh

It doesn't clear everything (esp. settings in ~ by applications created by a 3rd-party, for instance) but it just runs a bunch of scripts in /etc/osso-cud-scripts/
 

The Following 2 Users Say Thank You to jstokes For This Useful Post:
Posts: 889 | Thanked: 537 times | Joined on Mar 2010 @ scotland
#5
Originally Posted by jstokes View Post
Start with the "Clear device" function already found in Settings. It runs a script: /usr/sbin/osso-app-killer-cud.sh

It doesn't clear everything (esp. settings in ~ by applications created by a 3rd-party, for instance) but it just runs a bunch of scripts in /etc/osso-cud-scripts/
thanks, i'm guessing i'd want to edit this to my own settings, so it clears what i want it to, but obviously i'm a bit dubious about how to safely open and edit it, i dont want to accidentally run it prematurely! any tips for playing with this particular fire safely?

ps would a rm /home/user/MyDocs/ command work as root or is it somehow protected? again, testing isn't really an option!
__________________
sarcasm may be the lowest form of wit, but its the only wit i have.

its a sad day when i can't slip at least one hitchhiker reference in somewhere.
 
Captwheeto's Avatar
Posts: 302 | Thanked: 193 times | Joined on Oct 2008 @ England
#6
Should work... you should definitely test it though to make sure
 
Posts: 235 | Thanked: 339 times | Joined on Nov 2010
#7
Originally Posted by festivalnut View Post
thanks, i'm guessing i'd want to edit this to my own settings, so it clears what i want it to, but obviously i'm a bit dubious about how to safely open and edit it, i dont want to accidentally run it prematurely! any tips for playing with this particular fire safely?
No?

I guess you'd have to go through the scripts and try and figure out what's being deleted. If you have the time, you could use RobbieThe1st's BackupMenu to create a clone of your rootfs and see what gets deleted...

ps would a rm /home/user/MyDocs/ command work as root or is it somehow protected? again, testing isn't really an option!
It should work as anyone: MyDocs is just a FAT32 partition with no understanding of UNIX permissions. Though you'd want to make sure that it's error-free so that it's not mounted as read-only! You'd also want to add a "-r" (maybe an "-f" also?) to your rm command so that it deletes subdirectories too
 

The Following User Says Thank You to jstokes For This Useful Post:
Posts: 889 | Thanked: 537 times | Joined on Mar 2010 @ scotland
#8
Originally Posted by Captwheeto View Post
Should work... you should definitely test it though to make sure
no thanks for you this time captain wheeto! if it wasn't so recently that i had to repopulate my n900 after i got it back from nokia i may be willing to go through all the hassle, but not again so soon!

would this remove the contents of MyDocs, or the actual MyDocs folder itself? and would the n900 create a new MyDocs folder or is it reflash time if that goes?
__________________
sarcasm may be the lowest form of wit, but its the only wit i have.

its a sad day when i can't slip at least one hitchhiker reference in somewhere.
 
Posts: 889 | Thanked: 537 times | Joined on Mar 2010 @ scotland
#9
i think what i'll do is try writing a little script and then bring it back for you all to have a look and either approve or show me the error of my ways, is there a command to delete all sub directories like you mentioned but leave the parent folder alone?

and just to save me some homework does anyone know off the top of their heads the locations of:

saved texts
saved im
call records
fmms images
web bookmarks
web history
cache
saved passwords etc.
__________________
sarcasm may be the lowest form of wit, but its the only wit i have.

its a sad day when i can't slip at least one hitchhiker reference in somewhere.
 
Captwheeto's Avatar
Posts: 302 | Thanked: 193 times | Joined on Oct 2008 @ England
#10
Bwaahaaha.

Anyway, that would delete the directory + everything in it (if it was rm -r).
If you wanted to keep the folder but delete the contents you'd do

rm -r /home/user/MyDocs/*

But why make it easy for them to get your super secret volcano hideout? (Ps. I know where it is)

#!/bin/bash
for ((a=0;a<3;a++))
dd if=/dev/zero of=/home/user/MyDocs
done
 

The Following User Says Thank You to Captwheeto For This Useful Post:
Reply


 
Forum Jump


All times are GMT. The time now is 15:58.