So I'm getting a really frustrating issue happening with my phone wherein any .mp3 files stored on my external SD card are removed from their playlists whenever I restart my phone. Any music stored on the internal phone storage still remains in the playlists but everything else gets cleared out of them. I've taken a look into the Media Store's SQL logs and found this:
Basically, I cleared the Media Store's data to reset the Android media database, then I rebooted. On the first reboot, all my playlists displayed perfectly (external SD music AND internal SD music). This produced the 3 log lines above the highlighted line in the image. Then I restarted my phone again and once again all the music on the external SD card was erased from my playlists. Restarting gave the log lines below and including the highlighted line. What seems to be happening is Android is removing any reference to files stored on my external SD from the Media Store database at reboot, then it rescans when the phone starts, but it generates the playlists BEFORE it scans the external SD for media, so it just thinks there's loads of missing media in the playlists and removes any reference to external SD music. Then it scans the external SD for music and finds all my media there.
So in the end I can still access all the music stored on my external SD and my phone sees it just fine, it's just that it's never maintained in any playlists. If anyone has any method of fixing this or any advice at all, I'd really appreciate it! I don't have enough room on my internal SD to store all my music.
Thanks!
(I'm on a Google Play Edition Galaxy S4 running Android 5.1)