Plex Media Server DLNA wrong mime type for apple lossless music - m4a files show as video mp4 files




hope someone can help - am trying to use plex as a media server with the WHAALE app . My itunes music library appears but when i navigate to an album in the app there is no music. I've asked the app provider who's looked at the logs and says res protocol info shows as video/mp4 for these files from plex, hence it wont show them as it's a music app. No music appears in the itunes channel either

Files play on plex on the server PC itself, and the same files can be accessed and played in the WHAALE app using Universal Media Server pointing at the same library, same files copied onto USB play fine from my router usb server function but i would like to standardise on PLex as it shows album art within WHAALE that the others don't

Are there some settings in plex i can access to change this ?

Plex Server is running on windows 10 , WHAALE app is running on iphone 6 on iOS 10.3, and get same on ipad mini 2


sorry should have added the WHAALE app is expecting audio/m4a for these files


and here’s an extract of the app logs showing video/mp4 values


and here's an extract from the logs showing video/mp4 values

Response from media server dc:titleAll I Really Want/dc:titleupnp:artistAlanis Morissette/upnp:artistupnp:albumJagged Little Pill/upnp:albumhttp:// Oughta Know/dc:titleupnp:artistAlanis Morissette/upnp:artistupnp:albumJagged Little Pill/upnp:albumhttp:// Morissette/upnp:artistupnp:albumJagged Little Pill/upnp:albumhttp:// in My Pocket/dc:titleupnp:artistAlanis Morissette/upnp:artistupnp:albumJagged Little Pill/upnp:albumhttp:// Through You/dc:titleupnp:artistAlanis Morissette/upnp:artistupnp:albumJagged Little Pill/upnp:albumhttp:// Morissette/upnp:artistupnp:albumJagged Little Pill/upnp:album<upnp:albumArtURI


I've tried adding "http-get::audio/m4a:" to the DLNA default protocol info, also deleting video/mp4 etc. Does the order matter - I put audio/m4a first, tried it after audio/mp3 etc. with save and restart each time

I've also tried deleting PMS, the registry and files and done a fresh install -- all to no avail


I never found a fix for this - the app i’m using now supports flac and that works, though i’ll have to tidy up my libraries.
I have re-installed PMS recently and re-imported the itunes songs - all apple lossless are imported with a container value of MP4, not m4a, so the issue appears to be a bug in the library import function. From a quick google it seems that other devices/apps struggle with plex m4a/AAC songs, so it may depend on how strict the app is on what container it gets back from plex as to whether it plays - example below you can see the incorrect container value from the plex “get info” screen

D:\iTunes\Music\Compilations\NOW That’s What I Call Music! 98\1-01 Havana (Radio Edit).m4a
Duration 2:57
Bitrate 895 kbps
Container MP4
Web Optimized Yes
Has 64bit Offsets 0
Duration 2:57
File 1-01 Havana (Radio Edit).m4a
Size 18.98 MB
Container MP4
Has 64bit Offsets 0
Web Optimized Yes
Codec ALAC
Channels Stereo
Bitrate 895 kbps
Audio Channel Layout stereo
Bit Depth 16
Sampling Rate 44100 Hz
Stream Identifier 1


Also here’s the media info data for the same file - not sure if plex devs access these forums as there doesn’t appear to be a way to report a bug as the contact us states that support items will be ignored

omplete name : D:\iTunes\Music\Compilations\NOW That’s What I Call Music! 98\1-01 Havana (Radio Edit).m4a
Format : MPEG-4
Format profile : Apple audio with iTunes info
Codec ID : M4A (M4A /mp42/isom)
File size : 19.0 MiB
Duration : 2 min 57 s
Overall bit rate mode : Variable
Overall bit rate : 895 kb/s
Album : NOW That’s What I Call Music! 98
Part/Position : 1
Part/Total : 2
Track name : Havana (Radio Edit)
Track name/Position : 1
Track name/Total : 23
Compilation : Yes
Performer : Camila Cabello
Genre : Pop
Recorded date : 2017
Encoded date : UTC 2017-12-21 18:41:46
Tagged date : UTC 2017-12-21 18:42:15
Writing application : iTunes
Encoding Params : (Binary)
UFID : 䌳㍄ㅍ㜰㝑㌵㘸〵㔴㉕㠷㌷ㄸ䌲㙅䐸䄳㜱䐳あ䑄㙅㈹䈴䅁䕃䑁㕐


I managed to solve the issue with ALAC playing by creation of a custom profile with explicit rule which tags the mp4 audio as audio/m4a. Please see the attached file for details. I hope it can help!


thanks for this - great news as that looks like its the answer I need. Unfortunately had a play and can’t actually get it to work right now as my client device never appears in the logs so not sure if it’s using some generic profile for dlna or one of the iphone ones. I edited the iphone 3,1 profile (they look way out of date as it talks about iOS file type limitations that I dont think exist anymore, and there appear to be several redirect versions), however it still wont recognise the mp4 individual music files and play them from the whaale app. It will play some mp3 files I have in the itunes library - but still not the mp4 ones. Have attached the updated profile in case that gives some clues, but I guess it may not be using that profile and am not sure how to figure that out but will keep trying


just edited the iOS profile which is probably the right one from the description but still no joy…now saved this with name changed to generic and all works fine !


OK finally fixed thanks to photolux and some digging in the logs. There wasn’t much to go on but finally figured out the WHAALE app was using the “generic” profile - so I added a custom version of the “generic” profile with the mime type override and the apple itunes music finally plays. Not sure what issues the custom profile will give with other devices using “generic”, but for now this is my main use of plex so is OK

In the course of investigating this i found numerous other threads of DLNA failures for apple music, including the Yamaha one where photolux had created a custom profile to set the correct mime type for m4a.

For me this really is poor coding in plex - other DLNA media servers work with itunes music through WHAALE, and this seemed the same in the Yamaha thread, so the others must set the correct mime type, but plex doesn’t differentiate correctly for m4a ALAC files, and it seems potluck as to how the client is coded as to whether it works - with music clients the worst off

Once again photolux - big big thanks as this has been so frustrating