Monday, February 16, 2009

playing with mediatomb

I'm going to run mediatomb on a linux machine i use as my router its an old Athlon 1ghz. It will hopefully share my media archive that is stored on a network attached storage so it can be played on my ps3

First install it

panthro ~ # emerge mediatomb

Then check the configs and start the service

panthro ~ # nano /etc/conf.d/mediatomb
panthro ~ # nano /etc/mediatomb/config.xml
panthro ~ # /etc/init.d/mediatomb start
* Starting MediaTomb ... [ ok ]
panthro ~ #


looking in the /etc/conf.d/mediatomb config file i see;

MEDIATOMB_PORT=49152

that its running on port 49152.

Put http://panthro:49152/ in a browser.


Appart from the fact it worrys me that it can access everything this looks promising. (a iptables rule will keep the naughty ppl out)

I mount my NAS in to the unix file system

panthro ~ # mkdir /mnt/nas
panthro ~ # mount -t cifs -o username=djc,password=foobar //192.168.200.201/nas1 /mnt/nas/
panthro ~ #

Check the mounted

panthro ~ # ls /mnt/nas/Videos/
Films Music Video TV Yoga base.mpeg
panthro ~ #

Going back to http://panthro:49152/ i add the video folder


Unfortunately when i go back to the database it has put all the videos that are neatly sored in the file system into one big lump in the database.



It will be quite easy to organise but for now it doesn't matter as i'm just testing thing out. [if you use the 'pc directory' folder it keeps the directory stucture]

The ps3 found the media server immediately and i was able to play most of the videos.

A few that didn't play gave me a "corrupt data message" or the icon was "unsupported data"

One format which i was interested to see if it worked was some HD content in a mkv wrapper.

The mkv does not appear on the list in the ps3 menu. Looking on the media tomb webserver it seems to identify the file as octol stream and not a video file.

When the mkv file is placed on a usb storage device it cannot be seen by the PS3 either

http://hoschie.org/b2evolution/index.php/2008/03/23/upnp_server_mediatomb_for_divx_xvid_and_

It looks like mkv will need transcoding (the computer [panthro] will read the file and re-encode the file before passing to the ps3)

Before i start messing with transcoding i've decided to do a little bench mark

"top" a unix command to and will allow me to see how much cpu media tomb is using.

Mediatomb scanning my music directory is using about 80% cpu.
Playing MP3 0.3% cpu 0.6%mem
Playing movie 8.7%cpu 6.1%mem with spikes of 20% cpu

Another annoyance is the flac format gives a data type not supported message

I will play with transcoding another day

2 comments:

Unknown said...

Did you ever play with transcoding on mediatomb? I have been spending more time than is healthy trying to stream iplayer through it via the cgi interface of getiplayer. I wondered if you had had any success with a similar hack.

Thanks,


Richard

Anonymous said...

All the games have been played in good spirit for the completion of the inner goals of the soul. The chapter of the games has been highlighted for the full use of the norms and all captions for the individuals.