1. 2015 is going to be a great year for Android! Why wait??
    Samsung Galaxy Note 5 | Samsung Galaxy S6 | HTC One M9
  2. New Forum Created: Samsung Gear VR!

What does wiping cache and dalvik cache do?


  1. Ph33zy

    Ph33zy Member

    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. 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

    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

    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

    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

    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

    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

    Are there any additional steps to get a cleaner environment for a ROM install?
  9. Wadester

    Wadester Well-Known Member

    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

    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

    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

    How would one go about doing this?
  13. Wadester

    Wadester Well-Known Member

    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

    When wiping battery stats does it matter if you are full charged or not?
  15. Wadester

    Wadester Well-Known Member

    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

    That what I figured.. I'm gonna give it a try later and see what happens
  17. akazabam

    akazabam Well-Known Member

    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

    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

    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

    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

    No, when you boot up after wiping cache and dalvik, the system will rebuild the cache.
    Calamachino likes this.
  22. Calamachino

    Calamachino Member

    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

    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

    Awesome, thanks.

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

    wrapkgb Well-Known Member

    LOL Thats funny! Whatever works right?
Loading...

Share This Page