[Galaxy S II Q&A, Help & Troubleshooting] Jokesy:
[SOLUTION] PHOTOS/MUSIC/MEDIA FILES MISSING AFTER FLASHING A NEW ROM (CM9 based ROMS/ CM10 based ROMS/ AOKP ROMS/Stock based ROMS)

Why open this thread?

-Many people have been reported this issues already and the worst thing is that new threads are opened asking for the same solution.

-Only yesterday, I fixed this same problem for about 5-6 people

-I believe having this kind of thread will prevent forum/android beginners from opening a new thread, asking for the same solution over and over again

Symptoms?

-Photos missing from gallery app after flashing new ROM

-Music files missing or unplayable after flashing new ROM

-All media files on internal SD, External SD or both are missing or unplayable

How will I know if this solution will work for me?

-Browse through your device using a file manager/browser, If you can see your photos (DCIM), music files in their respective locations, then this solution will work for you

-If you still can't see your media files after the above step, this solution will simply not work for you

What's the cause of this problem?

Personally I've never had this problem but the reason could be:

-Media scanner skipping your media files for some reason

-corrupt media scanner db

Some users I've helped have also attributed the cause of this problem to:

-Incompatibility/Issues with latest update of ROM manager

-ROM issues(I disagree)

-Unknown/other reasons

Ok....Enough of the stories, this thread was opened for the solution to the problem not the causes. Let's get to the real deal

REQUIREMENTS

-A good file manager/explorer

-A working brain (just kidding)

SOLUTIONS

STEP I

-If you have ROM manager installed or bundled with your ROM, then please freeze/uninstall it, for now.

STEP II

-Using file explorer/manager or similar apps e.g ES file explorer, Astro, Solid explorer or Root explorer, enable show hidden files and folders in the option of your preferred app. Some of these explorers enable hidden files by default.

STEP III (OPTIONAL)

-If your issue is with missing pictures alone, then you may download "Quickpic" from market as reference gallery app

SOLUTION 1.

we need to retrigger the media scanning process

Manually,

- Go to Setting > Apps> All > Media storage, clear data

- Reboot phoneSOLUTION I

OR

Using an APP

-Download Rescan Media Root from market

-Run the App for some minutes

If this solution does not work for you then try Solution 2.

SOLUTION 2

We need to delete any .nomedia file(s) found in the photo and/or music folder(s)

Manually,

-Use a file manager/explorer to browse through your files on your internal SD.

-Check the root of of internal and external SD, Delete any .nomedia file if present

-Open your picture and music folders e.g. DCIM

-Delete any .nomedia file present in those (above) folders.

-Reboot your device

-Check if problem is solved now

Using an APP

-Download StudioKUMA .nomedia Manager from market

-Open the app, browse through your folder

-Any folder containing .nomedia file will be marked x

-check if any of your picture or music folder as listed as x

-Long click on your desired media folders and select enable media scanning for all of them

-reboot phone

If this solution does not work, then try Solution 1. again

If after repeating Solution 1., things are still not working, try Solution 3.

SOLUTION 3.

You will need a PC. You can also use a file manager/explorer but a PC is recommended

We need force retrigger the media scanning process radically

- connect your device to your Pc

- move/cut your media files and folders to a location on your Pc (double check these folders on your Pc to ensure .nomedia files are not present in the folder)

- reboot your device

- Create new folders for your media files using any file manager on your internal SD card. Don't copy anything to them yet.

- Take a picture with your phone, check if it's showing in your gallery.

- reboot your device

- Check again if the pic you took the other time is still showing in your gallery

-connect your phone to your Pc

-copy back your media files (don't copy the folders) to the new folders you created on your internal SD card (in the first section of solution III).

-reboot your device.

If this solution does not work, then try Solution 1. again

If you find this Post useful, click on the THANKS button

If you have any suggestions in form of questions/ideas please do let me know

thanks to kilometers4 and budi5555 for their feedback