An Android Enthusiast’s Apple iPhone 6 Challenge – XDA TV

The media has gone batty again over Apple “revolutionizing” … more

Sony to Extend its AOSP Program to Other Devices

Sony will be offering its users the possibility to use AOSP ROMs as an alternative to the … more

Project Ara Smartphone Will Run Modified Android L with Hot Swapping

Project Ara is a very exciting topic–both for hardware and … more

Streamline Android Theme Customization with Graphic Porter

I dont have a custom theme on my Android phone, and the reason for this is because … more
Post Reply

Clear Cache and Data from Stock Recovery

11th April 2011, 03:09 PM   |  #1  
OP Senior Member
Thanks Meter: 97
 
479 posts
Join Date:Joined: Jan 2011
I've seen a number of requests for this functionality and recently it became necessary for one user who had a disabled Home Key to clear cache and data without the use of ClockworkMod. I have reserached two methods to address this issue. These instructions require some familiarity of android, computer and tablet terminology and usage. Feel free to ask for clarifications in comments. Here we go...

Method I - Stock Recovery Command File

Technical: Stock Recovery command file can be used to perform a few additional functions as well as to alter the path to update files. These commands will execute with all privileges available to recovery mode.

Advantages: Very easy to use. Very little technical knowledge required. No third party software is required for use.

Prerequisites: You will need a MicroSD card formatted FAT32 and a method for transferring files from your computer to the MicroSD.

Usage:

1) Prepare a text file named "command" (no file extension) with one of the following commands on a single line. The wipe data command will wipe both data and cache. Wipe cache will wipe cache only.

--wipe_data
--wipe_cache

2) Place the file in a folder named "recovery" in the root directory of your MicroSD card.
3) From a powered down state, insert the MicroSD card into your tablet and boot into recovery by powering it on while holding down the Volume Up key.
4) Allow the command to execute completely then the tablet should reboot (this may not occur automatically depending on firmware installed).

Method II - Updater Script

Technical: The attached "Updater Scripts" perform delete commands (recursively if necessary) on the named directory or file(s). The directories are mounted automatically by the system before the script executes but it could be easily revised to include that step if necessary. The partitioning, formatting and directory structure are left untouched. Only files are deleted.

Advantages: No third party software is necessary for execution. Relatively easy to modify for more surgical precision (i.e. leaving installed apps but clearing possibly corrupted system data). Included example: "Clear Battery Stats"

Prerequisites: You will need a MicroSD card formatted FAT32 and a method for transferring files from your computer to the MicroSD.

Usage:

1) Download the attached archive (ClearData.zip) to your computer.
2) Extract the files to your computer. You should then have a folder named "recovery" (which contains a file named "command") and an additional archive named "update.zip"
3) Place the recovery folder and the update.zip in the root directory of the MicroSD card.
4) From a powered down state, insert the MicroSD card into your tablet and boot into recovery by powering it on while holding down the Volume Up key.
5) Allow the script to execute completely then reboot the tablet (this may occur automatically depending on firmware installed).
Attached Files
File Type: zip Clear Cache.zip - [Click for QR Code] (160.9 KB, 136 views)
File Type: zip Wipe Data.zip - [Click for QR Code] (160.9 KB, 136 views)
File Type: zip Clear Cache and Data.zip - [Click for QR Code] (161.0 KB, 202 views)
File Type: zip Clear Battery Stats.zip - [Click for QR Code] (161.0 KB, 70 views)
Last edited by K J Rad; 4th May 2011 at 02:44 PM. Reason: New Information
The Following 8 Users Say Thank You to K J Rad For This Useful Post: [ View ]
16th April 2011, 12:17 PM   |  #2  
mydave1's Avatar
Senior Member
Thanks Meter: 35
 
198 posts
Join Date:Joined: Mar 2011
This will become handy someday.
Thanks for sharing your knowledge.
16th April 2011, 03:00 PM   |  #3  
OP Senior Member
Thanks Meter: 97
 
479 posts
Join Date:Joined: Jan 2011
You're welcome. One quick note... the new stock recovery adds a menu simiilar to ClockworkMod. These methods will still work since the recovery folder/command file are checked first but it really isn't as necessary any more.
16th April 2011, 08:43 PM   |  #4  
Junior Member
Thanks Meter: 0
 
7 posts
Join Date:Joined: Apr 2011
Need Help
Tried both methods above but either way I get to the viewsonic splash with the message "Booting recovery kernel image" in the upper left and it just stays there, stuck there, I left it for a long time to see and it never leaves that screen.

Any ideas?
16th April 2011, 09:15 PM   |  #5  
Junior Member
Thanks Meter: 0
 
1 posts
Join Date:Joined: Apr 2011
Me too
I can't get into clockworkmod either. My machine is running faster. I almost hate to mess it more.
16th April 2011, 11:47 PM   |  #6  
OP Senior Member
Thanks Meter: 97
 
479 posts
Join Date:Joined: Jan 2011
Quote:
Originally Posted by lrgche

Tried both methods above but either way I get to the viewsonic splash with the message "Booting recovery kernel image" in the upper left and it just stays there, stuck there, I left it for a long time to see and it never leaves that screen.

Any ideas?

That's an indication that you may have more serious problems. nvflash will be required. http://forum.xda-developers.com/showthread.php?t=861950

Once done you will likely need to install ClockworkMod and repartition your internal storage.

Quote:
Originally Posted by Loukoebel

I can't get into clockworkmod either. My machine is running faster. I almost hate to mess it more.

If your tablet boots properly but you can't get into CWM then it probably isn't installed properly (or at all). http://forum.xda-developers.com/showthread.php?t=865245

Keep in mind that CWM is NOT compatible with all ROMs. Make sure the developer for your chosen ROM recommends it before installing it.
Last edited by K J Rad; 16th April 2011 at 11:51 PM.
17th April 2011, 05:30 AM   |  #7  
Senior Member
Thanks Meter: 6
 
150 posts
Join Date:Joined: Dec 2010
More
Does your method in opening post have to be run from external micro sdcard?
17th April 2011, 05:48 AM   |  #8  
OP Senior Member
Thanks Meter: 97
 
479 posts
Join Date:Joined: Jan 2011
Both methods are performed with an external MicroSD card. They will work from internal also but it is a little more difficult to get the files in place if your tablet is not booting properly.
17th April 2011, 03:14 PM   |  #9  
Senior Member
Thanks Meter: 6
 
150 posts
Join Date:Joined: Dec 2010
More
Quote:
Originally Posted by K J Rad

Both methods are performed with an external MicroSD card. They will work from internal also but it is a little more difficult to get the files in place if your tablet is not booting properly.

so your method is a simple way to replace one of the main uses of Clockword MOD?--Plus you stay stock more or less.
18th April 2011, 06:20 AM   |  #10  
OP Senior Member
Thanks Meter: 97
 
479 posts
Join Date:Joined: Jan 2011
That is correct. Method II can also be modified to be less intrusive (leave user apps installed) or embedded into update scripts to perform a wipe during new ROM installs.

Post Reply Subscribe to Thread
Previous Thread Next Thread
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes