PS3 not listing pictures

Help
cdeguise
2007-07-05
2013-05-30
  • cdeguise
    cdeguise
    2007-07-05

    Hi All,

    I have hit a wall with trying to figure out what might be wrong. I had Mediatomb and my PS3 working fine about 2 weeks ago with fireware 1.81. I can't pinpoint the problem because the server I was serving from had a system drive failure soon after. While I was in mid process of rebuilding that box my PS3 needed to be updated so I could play online. So I am stuck with a new server/install of Mediatomb and a new update so I can't tell which end broke which.

    Problem:
    PS3 shows all hierarchy information, 'PC Directory', 'All Pictures', and 'Date'. I can browse the directory hierarchy but when ever a directory listing is required I get 'No Images found.' message from the PS3. 'All Pictures' and 'Date' return the same result.

    Investigation:
    * I turned on media sharing in WMP 11 and the PS3 works fine with it.
    * I am running 0.9.1 compiled with --enable-tombdebug --enable-upnpdebug on gentoo.
    * I do have extended protocol info enabled.
    * I started the server and ran a simple test. A couple directories down and attempted to get the listing of the three files that exist. I can run the same test on the web interface and I can see the files and view.
    * * The upnp error log is empty.
    * * The information upnp log actually shows the Mediatomb server returning the directory listing for my tests. It appears that data is going over the network and the PS3 is just dropping it.

    I have all the logs files stored so I could send them out if anyone thinks them might help (thinking of developers here). Any thoughts anyone? Its my understanding that WMP11 should be able to see Mediatomb but I can't figure that out. Vista's "Network" applet detects my MediaTomb and gives me the option to open the web ui or media player. The open media player option doesn't buy me anything and the only traffic I see in the logs revolves around "UpnpSendAdvertisement" from WMP.

    Thanks,
    Chris

     
    • Jin
      Jin
      2007-07-05

      OK, let me see if I understand that correctly: you updated your PS3 firmware to a newer version?

      Of course it is possible, that something has changed there, and that we need to add a couple of things.

      I assume that MP3 and video still works?

      I'd be interested to hear from other PS3 users who have upgraded the firmware, if the problem is indeed with some changes in the fw, others should have the same issue.

      One more question, did you compile MT with libmagic support? Are you sure that the mimetype of the photos is set correctly? You can easily check that in the web UI, just pick one of the photos and click the Edit icon, what does the mimetype field say? If it's "application/octet-stream" - then the problem is found :>

      I'm sure we can figure this out.

      Kind regards,
      Jin

       
    • cdeguise
      cdeguise
      2007-07-05

      As is usually the case hours after my post I found the problem. It is user error but the user (me) doesn't quite understand the ramifications of the problem.

      At some point moving from the default config to my tailored config I had removed the following:

        <mappings>
            <extension-mimetype ignore-unknown="no">
              <map from="mp3" to="audio/mpeg"/>
              <map from="ogg" to="application/ogg"/>
              <map from="asf" to="video/x-ms-asf"/>
              <map from="asx" to="video/x-ms-asf"/>
              <map from="wma" to="audio/x-ms-wma"/>
              <map from="wax" to="audio/x-ms-wax"/>
              <map from="wmv" to="video/x-ms-wmv"/>
              <map from="wvx" to="video/x-ms-wvx"/>
              <map from="wm" to="video/x-ms-wm"/>
              <map from="wmx" to="video/x-ms-wmx"/>
              <map from="wmx" to="video/x-ms-wmx"/>
            </extension-mimetype>
            <mimetype-upnpclass>
              <map from="audio/*" to="object.item.audioItem.musicTrack"/>
              <map from="application/ogg" to="object.item.audioItem.musicTrack"/>
              <map from="video/*" to="object.item.videoItem"/>
              <map from="image/*" to="object.item.imageItem"/>
            </mimetype-upnpclass>
            <mimetype-contenttype>
              <treat mimetype="audio/mpeg" as="mp3"/>
              <treat mimetype="application/ogg" as="ogg"/>
              <treat mimetype="audio/x-flac" as="flac"/>
              <treat mimetype="image/jpeg" as="jpg"/>
            </mimetype-contenttype>
          </mappings>

      When debugging I validated that the mime type image/jpeg was being sent in the upnp responses so I assumed everything would be ok. The only item that looks like it could impact me is the "<treat mimetype="image/jpeg" as="jpg"/>" but I would assume that the PS3 only cares about mime types. I also validated that adding these configurations to an already built database has no effect. I needed to rebuild my database with these settings in place to server them to the PS3.

      Anyway, I do have it severing up pictures again. Thanks for the quick response.

      Thanks,
      Chris

       
    • Eray Ozkural
      Eray Ozkural
      2007-08-22

      I have those configs in place, and I know that the file -i command works  but somehow all images are added as unknown octet stream. :( I just removed the Pictures folder and I'm going to try again.

       
    • Jin
      Jin
      2007-08-22

      Did you compile MediaTomb yourself? Did you compile with libmagic support? Probably not... else the mimetype would be set correctly; make sure that file-devel is installed on your system and recompile.

      You could also add an extention to mimetype mapping in your config.xml, but I strongly recommend compiling with libmagic support - it solves a lot of mimetype related problems.

      ...of course if you are using the precompiled binaries - then we'd have to do more investigation :>

       
      • Eray Ozkural
        Eray Ozkural
        2007-08-22

        Hello Jin,

        Yes, I compiled it on OSX and it uses libmagic. It recognizes video and audio correctly now. My only trouble is with JPG. I am going to delete my Pictures folder and readd it, I am waiting for the current scan to finish first. I just changed Music to rescan and it's a little big. I'll let you know what happens right after I try.

        Cheers,
        Eray

         
    • Eray Ozkural
      Eray Ozkural
      2007-08-22

      Okay, I removed the Pictures dir, and then I added it back. Still it shows the mime types as octet stream. I assume libmagic support works because it can recognize the video files all right. I am on OSX and I am trying to play the stuff on PS3. Can you show me how to debug my problem? My config file is very close to the default, I didn't change it much except adding PS3 support

       
    • Jin
      Jin
      2007-08-22

      So you can confirm, that at the end of the ./configure run, in the summary, you could see the "libmagic: yes" line? Are you absolutely sure?

      Did you add any extension to mimetype mappings that might override the libmagic settings?

       
    • Eray Ozkural
      Eray Ozkural
      2007-08-23

      It's been a long time since I compiled it Jin, but here is what I'll do: I'll remove the fink version and compile the new version and see if there is still a problem, and I'll also check if libmagic is configured. Then, I'll paste my entire config file should the problem persist...

       
    • Jin
      Jin
      2007-08-23

      Ahh... Fink, well yes, I have the feeling that Fink does not pull in libmagic as a dependency. I tried contacting the Fink devs to update the package, but they were very short on time, I'll talk to them again. So chances are high that your version is compiled without libmagic support.

      Anyway, I think you should be able to easily compile your own version using MacPorts, all dependencies are available there.

       
    • Eray Ozkural
      Eray Ozkural
      2007-08-23

      I just compiled 0.9.1 using fink, and libmagic is there:

      CONFIGURATION SUMMARY ----

      sqlite3       : yes
      mysql         : disabled
      libjs         : yes
      libmagic      : yes
      libexif       : yes
      id3lib        : yes
      taglib        : disabled
      libextractor  : disabled

      I checked that the error recurs, it thinks jpg files are octet-stream. Perhaps magic support is not working due to some misconfiguration? Perhaps I thought, I'm getting mp4's because of some config that I added later on? Could you please take a look at this?

      and here is what it says on startup:
      Centauri:~ malfunct$ mediatomb

      MediaTomb UPnP Server version 0.9.1 - http://mediatomb.cc/

      ===============================================================================
      Copyright 2005-2007 Gena Batsyan, Sergey Bostandzhyan, Leonhard Wimmer.
      MediaTomb is free software, covered by the GNU General Public License version 2

      2007-08-23 21:07:45    INFO: Loading configuration from: /Users/malfunct/.mediatomb/config.xml
      2007-08-23 21:07:45    INFO: Checking configuration...
      2007-08-23 21:07:45    INFO: Config: option not found: /server/servedir using default value:
      2007-08-23 21:07:45    INFO: Config: option not found: /server/ui/attribute::poll-when-idle using default value: no
      2007-08-23 21:07:45    INFO: Config: option not found: /server/ui/attribute::poll-interval using default value: 2
      2007-08-23 21:07:45    INFO: Config: option not found: /server/ui/items-per-page/attribute::default using default value: 25
      2007-08-23 21:07:45    INFO: Config: option not found: /import/filesystem-charset using default value: US-ASCII
      2007-08-23 21:07:45    INFO: Setting filesystem import charset to US-ASCII
      2007-08-23 21:07:45    INFO: Config: option not found: /import/metadata-charset using default value: US-ASCII
      2007-08-23 21:07:45    INFO: Setting metadata import charset to US-ASCII
      2007-08-23 21:07:45    INFO: Config: option not found: /server/ip using default value:
      2007-08-23 21:07:45    INFO: Config: option not found: /server/bookmark using default value: mediatomb.html
      2007-08-23 21:07:45    INFO: Config: option not found: /server/modelName using default value: MediaTomb
      2007-08-23 21:07:45    INFO: Config: option not found: /server/modelDescription using default value: Free UPnP AV MediaServer, GNU GPL
      2007-08-23 21:07:45    INFO: Config: option not found: /server/modelNumber using default value: 0.9.1
      2007-08-23 21:07:45    INFO: Config: option not found: /server/serialNumber using default value: 1
      2007-08-23 21:07:45    INFO: Config: option not found: /server/manufacturerURL using default value: http://mediatomb.cc/
      2007-08-23 21:07:45    INFO: Config: option not found: /server/presentationURL using default value:
      2007-08-23 21:07:45    INFO: Config: option not found: /server/presentationURL/attribute::append-to using default value: none
      2007-08-23 21:07:45    INFO: Config: option not found: /server/upnp-string-limit using default value: -1
      2007-08-23 21:07:45    INFO: Config: option not found: /import/virtual-layout/script/attribute::charset using default value: UTF-8
      2007-08-23 21:07:45    INFO: Config: option not found: /server/port using default value: 0
      2007-08-23 21:07:45    INFO: Config: option not found: /server/alive using default value: 180
      2007-08-23 21:07:45    INFO: Config: option not found: /import/autoscan using default value:
      2007-08-23 21:07:45    INFO: Config: option not found: /server/custom-http-headers using default value:
      2007-08-23 21:07:45    INFO: Config: option not found: /import/library-options/libexif/auxdata using default value:
      2007-08-23 21:07:45    INFO: Config: option not found: /import/magic-file using default value:
      2007-08-23 21:07:45    INFO: Configuration check succeeded.
      2007-08-23 21:07:45    INFO: Config: option not found: /server/ip using default value:
      2007-08-23 21:07:45    INFO: Initialized port: 49152
      2007-08-23 21:07:45    INFO: Server bound to: 10.0.0.3
      2007-08-23 21:07:46 WARNING: magic_load: could not find any magic files!
      2007-08-23 21:07:46    INFO: MediaTomb Web UI can be reached by following this link:
      2007-08-23 21:07:46    INFO: http://10.0.0.3:49152/

      and here is my config file:
      <?xml version="1.0" encoding="UTF-8"?>
      <config xmlns="http://mediatomb.cc/0.9.1/config" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://mediatomb.cc/0.9.1/config http://mediatomb.cc/0.9.1/config.xsd">
        <server>
          <protocolInfo extend="yes"/>
          <ui enabled="yes">
            <accounts enabled="no" session-timeout="30"/>
          </ui>
          <name>MediaTomb</name>
          <udn>uuid:22e82bbb-250e-4309-b1aa-da258769bab2</udn>
          <home>/Users/malfunct/.mediatomb</home>
          <webroot>/sw/share/mediatomb/web</webroot>
          <storage driver="sqlite3">
            <database-file>mediatomb.db</database-file>
          </storage>
        </server>
        <import hidden-files="no">
          <virtual-layout type="builtin">
            <script>/sw/share/mediatomb/js/import.js</script>
          </virtual-layout>
          <mappings>
            <extension-mimetype ignore-unknown="no">
              <map from="mp3" to="audio/mpeg"/>
              <map from="ogg" to="application/ogg"/>
              <map from="mpg" to="video/mpeg"/>
              <map from="mp4" to="video/mp4"/>
              <map from="asf" to="video/x-ms-asf"/>
              <map from="asx" to="video/x-ms-asf"/>
              <map from="wma" to="audio/x-ms-wma"/>
              <map from="wax" to="audio/x-ms-wax"/>
              <map from="wmv" to="video/x-ms-wmv"/>
              <map from="wvx" to="video/x-ms-wvx"/>
              <map from="wm" to="video/x-ms-wm"/>
              <map from="wmx" to="video/x-ms-wmx"/>
              <map from="wmx" to="video/x-ms-wmx"/>
            </extension-mimetype>
            <mimetype-upnpclass>
              <map from="audio/*" to="object.item.audioItem.musicTrack"/>
              <map from="application/ogg" to="object.item.audioItem.musicTrack"/>
              <map from="video/*" to="object.item.videoItem"/>
              <map from="image/*" to="object.item.imageItem"/>
            </mimetype-upnpclass>
            <mimetype-contenttype>
              <treat mimetype="audio/mpeg" as="mp3"/>
              <treat mimetype="application/ogg" as="ogg"/>
              <treat mimetype="audio/x-flac" as="flac"/>
              <treat mimetype="image/jpeg" as="jpg"/>
            </mimetype-contenttype>
          </mappings>
        </import>
      </config>

       
    • Jin
      Jin
      2007-08-23

      2007-08-23 21:07:46 WARNING: magic_load: could not find any magic files!

      Thats the problem, libmagic is not properly installed! it uses the so called magic files, some kind of a database where it looks up the information. If that is missing or can not be found - magic will not work. So either fix the libmagic installation or provide an alternative magic file via the config.xml (we have an option for that).

      Of course you can add an extension to mimtype mapping, if you don't want to fix magic:
      <map from="jpg" to="image/jpeg"/>

      But I suggest that you get magic working since it does not care about file extensions etc, it really looks at the data to determine the mimetype.