# ROMs and Android



## Civaus (Jun 4, 2012)

I looked around on Rootz & a internet search and couldn't find a good answer to my question.

When I flash a new ROM what gets wiped out and what stays between flashes?

I know some of this is not in the user accessible file system

Stays:
- ODIN
- Recovery
- SD Card (or it's equivalent) - i know this could be deleted manually
- radios
- bootloader?

Wiped / overwritten (I know some of these are user wiped rather automatic)
- /cache
- /data

The question is: If you download an app that just doesn't seem right does a ROM flash GUARANTEE that all traces will be wiped out? There seem to be files/data that exist even between [Factory Resets] + [fresh ROM] beyond the contents of the SDcard.

Also, could an app/virus/malware install files(s) in that portion of permanent storage?

I run CM10 on my phone (Galaxy Nexus).


----------



## TwinShadow (Oct 17, 2011)

/data remains intact through ROM flashing. /system is wiped through flashing, and /cache is sometimes too depending on the scripts the devs put in. But it usually never hurts to wipe cache anyway to make sure no issues come up.

An app that is a virus or malware can potentially get into a more permanent area of your phone if you allow it root permissions. But as long as you get apps from trusted sources, you should be fine from that.

The only way everything gets wiped (minus SD card) is from a factory reset. /system, /cache, /data.. all of that gets wiped. I think someone else could probably go into better detail than I can, but that should be the gist of it for ya.


----------

