# Music files being duplicated in any custom ROM



## bfleischman (Jun 18, 2012)

*Originally Posted by mbrian27 
Would there be any reason why it shows three of EACH song I have on my SD card in both Google Music and Apollo? And why in the gallery it says I have waaaaaaay more pictures and videos than I actually do and show up as blank tiles? I have never seen this happen and I have no idea where to even begin to try to fix it. So any suggestions would be MUCH appreciated.
I've seen that behavior on stock UCLE2 as well after flashing a rom or restoring nandroid backup.

Solution is to delete the db files in /data/data/com.android.providers.media/databases and then reboot. Media scanner will then rebuild the media indexes.*

After doing a lot of searching and reading, I found the above bold reply in another thread. This is the same problem I am having with my music files. I tried the fix mentioned, removing the db files and rebooting. This works great and rebuilds the database so only one instance of a file is displayed. Until the next time I reboot, when the duplication starts over again. Does any one know of a permanent fix to this issue.


----------



## sir nom (Sep 11, 2012)

bfleischman said:


> *Solution is to delete the db files in /data/data/com.android.providers.media/databases and then reboot. Media scanner will then rebuild the media indexes.*


An easier way is to go to Settings>Apps>All (For ICS: Swipe heading bar left) then search for Media Storage, Open it and press Clear Data Confirm in the next window and it will rebuild the whole library once you restart the phone and open up your music app.


----------

