1. Introducing Channels - a new way to chat with other Android users!
    Dismiss Notice

What does wiping cache and dalvik cache do?


Last Updated:

  1. Ph33zy

    Ph33zy Member This Topic's Starter

    Joined:
    Oct 5, 2010
    Messages:
    11
    Likes Received:
    0
    I want to flash to a custom kernal and the instructions say to wipe the these two types of cache. From my understanding, it won't erase any data stored on phone right? In other words, I don't have to install all my apps or setup home pages again hopefully.
     

    Advertisement
  2. bvbull200

    bvbull200 Banned

    Joined:
    Jun 5, 2010
    Messages:
    999
    Likes Received:
    197
    Everytime I have flashed a ROM or kernel (via ROM Manager), I have backed up the current ROM and wiped all data/cache. As I understand it, starting from scratch lowers the chances that you will have any conflicts that either effect performance or screw up your phone. Titanium Backup restores all of your data and apps, so you are left with only the homescreens. That 5 minutes is worth the peace of mind, in my opinion.

    I know this doesn't directly answer your question, but it is food for thought.
     
  3. Ph33zy

    Ph33zy Member This Topic's Starter

    Joined:
    Oct 5, 2010
    Messages:
    11
    Likes Received:
    0
    I usually do a hard reset every time i do a ROM upgrade (from my WM6.5 days). Just wasn't sure if this is the case with a kernal upgrade as well...
     
  4. Lock-N-Load

    Lock-N-Load Well-Known Member

    Joined:
    Feb 8, 2010
    Messages:
    2,309
    Likes Received:
    195
    necropost I know

    but I just did my first Dalvik cache clean - via Recovery mode - and jumped from 86mb internal memory to 126mb down to 102. I was stunned at the gain. I suspect the drop was due to it remaking caches.
     
  5. akazabam

    akazabam Well-Known Member

    Joined:
    Jun 7, 2010
    Messages:
    4,418
    Likes Received:
    1,387
    You don't have to wipe data to flash a new kernel - just cache and dalvik cache. You won't lose any data. You can never hurt anything by wiping those two things. It will just take longer to boot.

    dalvik cache is stored in /data by default, so it makes sense that you would see internal memory do that. Some roms have dalvik moved to the cache partition to just keep that space on /data clear all the time.
     
  6. Wadester

    Wadester Well-Known Member

    Joined:
    Jun 14, 2010
    Messages:
    249
    Likes Received:
    21
    It's my understand the Dalvik cache is a place where the Android OS re-compiles the executable programs the first time to optimize them. It only needs to do it once which explains the "cache" part -- unless you make a major change like replace the kernel. If you do that, you want to manually clear the Dalvik cache to force Android to recompile the apps for the the new kernel.

    I also believe the main data Cache is used by the Android OS at runtime to write temporary files for specific reasons. You want to clear this out when you try a new ROM so it doesn't re-used that cached data.

    Manually clearning both caches out allows the new ROM to be installed in a "cleaner" environment.

    FYI - there is also a Battery "cache" of sorts where the OS keeps battery statistics. You want to clear this every once in a while -- especially if you're experiencing fast battery drains or change batteries.

    Anyone feel free to correct me if I'm wrong. :)
     
    BigBangAnarchy, ocnbrze and calvinrw like this.
  7. andygu3

    andygu3 Well-Known Member

    Joined:
    May 24, 2010
    Messages:
    4,699
    Likes Received:
    2,081
    Yes, you can wipe your battery stats, it may give you a better indication of battery life.
    I would always recommend wiping Davlik cache and cache when flashing a new kernel
     
  8. stevcha

    stevcha Well-Known Member

    Joined:
    Nov 6, 2009
    Messages:
    856
    Likes Received:
    274
    Are there any additional steps to get a cleaner environment for a ROM install?
     
  9. Wadester

    Wadester Well-Known Member

    Joined:
    Jun 14, 2010
    Messages:
    249
    Likes Received:
    21
    No, clearing the main Cache and Dalvik cache will do. Some people recommend doing it yourself in Recovery manually while others like myself just use the checkbox to automatically clear the cache in ROM Manager when you use it to load new ROMS.
     
  10. andygu3

    andygu3 Well-Known Member

    Joined:
    May 24, 2010
    Messages:
    4,699
    Likes Received:
    2,081
    I would always recommend wiping Davlik cache in clockworkmod recovery versus using the rom manager application to wipe cache and data, imo;)
     
  11. Wadester

    Wadester Well-Known Member

    Joined:
    Jun 14, 2010
    Messages:
    249
    Likes Received:
    21
    I've loaded about 12 different ROMS and never had a problem doing it from ROM Manager. Your mileage may vary. :)
     
  12. hortstu

    hortstu Well-Known Member

    Joined:
    Jun 29, 2010
    Messages:
    548
    Likes Received:
    32
    How would one go about doing this?
     
  13. Wadester

    Wadester Well-Known Member

    Joined:
    Jun 14, 2010
    Messages:
    249
    Likes Received:
    21
    I use ClockworkMOD Recovery... boot into it, then select advanced at the bottom in the main menu, then Wipe Battery Stats.
     
  14. wrapkgb

    wrapkgb Well-Known Member

    Joined:
    Jun 30, 2010
    Messages:
    924
    Likes Received:
    242
    When wiping battery stats does it matter if you are full charged or not?
     
  15. Wadester

    Wadester Well-Known Member

    Joined:
    Jun 14, 2010
    Messages:
    249
    Likes Received:
    21
    I'm not sure... it might be a good idea to do the wipe after you hit a full charge.
     
  16. wrapkgb

    wrapkgb Well-Known Member

    Joined:
    Jun 30, 2010
    Messages:
    924
    Likes Received:
    242
    That what I figured.. I'm gonna give it a try later and see what happens
     
  17. akazabam

    akazabam Well-Known Member

    Joined:
    Jun 7, 2010
    Messages:
    4,418
    Likes Received:
    1,387
    Typically, I charge it all the way up, unplug it, turn it off, charge it up until it turns green again, the boot straight into recovery to wipe stats. It's not going to make a difference unless you've just loaded a new rom or kernel.
     
  18. ronjcar

    ronjcar Well-Known Member

    Joined:
    Oct 21, 2009
    Messages:
    86
    Likes Received:
    2
    What are the steps to clear your dalvik cache? Can I clear the battery cache without a program?

    Thanks
    Ron
     
  19. wrapkgb

    wrapkgb Well-Known Member

    Joined:
    Jun 30, 2010
    Messages:
    924
    Likes Received:
    242
    To clear cache a dalvik, power your phone off. Then power back on holding power and volume down. Navigate to recovery. Select wipe. Select wipe cache. Press power to confirm. After thats done Select wipe dalvik (if you are using ClockworkMod it will be located in advanced, if you are using AMON RA it will be located below cache). Then to wipe battery states, in Clockwork it should be under advanced and in AMON it is under wipe.
     
    Mulan likes this.
  20. Calamachino

    Calamachino Member

    Joined:
    Oct 3, 2010
    Messages:
    21
    Likes Received:
    0
    If I want to clear both my cache and dalvik, do I have to wipe and reinstall my ROM?
     
  21. akazabam

    akazabam Well-Known Member

    Joined:
    Jun 7, 2010
    Messages:
    4,418
    Likes Received:
    1,387
    No, when you boot up after wiping cache and dalvik, the system will rebuild the cache.
     
    Calamachino likes this.
  22. Calamachino

    Calamachino Member

    Joined:
    Oct 3, 2010
    Messages:
    21
    Likes Received:
    0
    Thanks, I've been having battery issues so I installed a new kernal and hear its a good idea to wipe cache and dalvik.

    Another question. In clockwork, I didn't see wipe cache. I saw "wipe data/factory reset" and "wipe cache partition." I did not see a "Wipe" holder as stated above.

    It looks like this,
    [​IMG]

    I did find "Wipe dalvik cache" under advanced though.
     
  23. wrapkgb

    wrapkgb Well-Known Member

    Joined:
    Jun 30, 2010
    Messages:
    924
    Likes Received:
    242
    1. It is necessary to wipe cache and dalvik when ever flashing a new kernel.. Or else you will bootloop.
    2. Cache partition is cache so you are good there.

    Hope that helps!

    BTW; how did you capture a screen shot of recovery?
     
    Calamachino likes this.
  24. Calamachino

    Calamachino Member

    Joined:
    Oct 3, 2010
    Messages:
    21
    Likes Received:
    0
    Awesome, thanks.

    I found that on google image search. :D
     
  25. wrapkgb

    wrapkgb Well-Known Member

    Joined:
    Jun 30, 2010
    Messages:
    924
    Likes Received:
    242
    LOL Thats funny! Whatever works right?
     

Share This Page

Loading...