#LyX 1.6.4 created this file. For more info see http://www.lyx.org/
\lyxformat 345
\begin_document
\begin_header
\textclass docbook
\use_default_options false
\language english
\inputencoding auto
\font_roman default
\font_sans default
\font_typewriter default
\font_default_family default
\font_sc false
\font_osf false
\font_sf_scale 100
\font_tt_scale 100

\graphics default
\paperfontsize default
\spacing single
\use_hyperref false
\papersize a4paper
\use_geometry true
\use_amsmath 0
\use_esint 0
\cite_engine basic
\use_bibtopic false
\paperorientation portrait
\leftmargin 1cm
\topmargin 1cm
\rightmargin 1cm
\bottommargin 1cm
\secnumdepth 3
\tocdepth 3
\paragraph_separation skip
\defskip medskip
\quotes_language swedish
\papercolumns 1
\papersides 1
\paperpagestyle plain
\tracking_changes false
\output_changes false
\author "" 
\author "" 
\end_header

\begin_body

\begin_layout Title
MediaTomb - UPnP MediaServer
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<copyright>
\end_layout

\begin_layout Plain Layout

  <year>2005</year>
\end_layout

\begin_layout Plain Layout

  <holder>Gena Batsyan</holder>
\end_layout

\begin_layout Plain Layout

  <holder>Sergey Bostandzhyan</holder>
\end_layout

\begin_layout Plain Layout

</copyright>
\end_layout

\begin_layout Plain Layout

<copyright>
\end_layout

\begin_layout Plain Layout

  <year>2006-2008</year>
\end_layout

\begin_layout Plain Layout

  <holder>Gena Batsyan</holder>
\end_layout

\begin_layout Plain Layout

  <holder>Sergey Bostandzhyan</holder>
\end_layout

\begin_layout Plain Layout

  <holder>Leonhard Wimmer</holder>
\end_layout

\begin_layout Plain Layout

</copyright>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<releaseinfo>This documentation is valid for MediaTomb version 0.12.0.</releaseinfo
>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<legalnotice>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
THIS SOFTWARE COMES WITH ABSOLUTELY NO WARRANTY! USE AT YOUR OWN RISK!
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</legalnotice>
\end_layout

\end_inset


\end_layout

\begin_layout Section
Introduction
\end_layout

\begin_layout Standard
MediaTomb is an open source (GPL) UPnP MediaServer with a nice web user
 interface, it allows you to stream your digital media through your home
 network and listen to/watch it on a variety of UPnP compatible devices.
\end_layout

\begin_layout Standard
MediaTomb implements the UPnP MediaServer V 1.0 specification that can be
 found on 
\begin_inset CommandInset href
LatexCommand href
name "http://www.upnp.org/"
target "http://www.upnp.org/"

\end_inset

.
 The current implementation focuses on parts that are required by the specificat
ion, however we look into extending the functionality to cover the optional
 parts of the spec as well.
\end_layout

\begin_layout Standard
MediaTomb should work with any UPnP compliant MediaRenderer, please tell
 us if you experience difficulties with particular models, also take a look
 at the Supported Devices list for more information.
\end_layout

\begin_layout Paragraph*
WARNING! 
\end_layout

\begin_layout Standard
The server has an integrated file system browser in the UI, that means that
 anyone who has access to the UI can browse your file system (with user
 permissions under which the server is running) and also download your data!
 If you want maximum security - disable the UI completely! Account authenticatio
n offers simple protection that might hold back your kids, but it is not
 secure enough for use in an untrusted environment!
\end_layout

\begin_layout Description
Note: since the server is meant to be used in a home LAN environment the
 UI is enabled by default and accounts are deactivated, thus allowing anyone
 on your network to connect to the user interface.
\end_layout

\begin_layout Subsection
Currently Supported Features
\end_layout

\begin_layout Itemize
browse and playback your media via UPnP
\end_layout

\begin_layout Itemize
metadata extraction from mp3, ogg, flac, jpeg, etc.
 files.
\end_layout

\begin_layout Itemize
Exif thumbnail support
\end_layout

\begin_layout Itemize
user defined server layout based on extracted metadata (scriptable virtual
 containers)
\end_layout

\begin_layout Itemize
automatic directory rescans
\end_layout

\begin_layout Itemize
sophisticated web UI with a tree view of the database and the file system,
 allowing to add/remove/edit/browse your media
\end_layout

\begin_layout Itemize
highly flexible media format transcoding via plugins / scripts
\end_layout

\begin_layout Itemize
allows to watch YouTube(tm) videos on your UPnP player device
\end_layout

\begin_layout Itemize
support for external URLs (create links to internet content and serve them
 via UPnP to your renderer)
\end_layout

\begin_layout Itemize
support for ContentDirectoryService container updates
\end_layout

\begin_layout Itemize
Active Items (experimental feature), allows execution of server side scripts
 upon HTTP GET requests to certain items
\end_layout

\begin_layout Itemize
highly flexible configuration, allowing you to control the behavior of various
 features of the server
\end_layout

\begin_layout Itemize
support for Linux, FreeBSD, Mac OS X
\end_layout

\begin_layout Itemize
runs on x86, Alpha, ARM, MIPS, Sparc, PowerPC
\end_layout

\begin_layout Section
\noindent
Requirements
\end_layout

\begin_layout Description
\noindent
\align left
Note: remember to install associated development packages, because development
 headers are needed for compilation!
\end_layout

\begin_layout Description
\noindent
\align left
Note: libupnp is now a part of MediaTomb and does not have to be installed
 separately.
 We base our heavily patched version on libupnp 1.4.1 from http://pupnp.sf.net/
\end_layout

\begin_layout Description
\noindent
\align left
Note: you need at least one database in order to compile and run MediaTomb
 - either sqlite or mysql.
\end_layout

\begin_layout Standard
\noindent
In order to compile MediaTomb you will have to install the following packages.:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
sqlite (version > 3.x) 
\begin_inset CommandInset href
LatexCommand href
name "http://www.sqlite.org/"
target "http://www.sqlite.org/"

\end_inset

 
\emph on
REQUIRED (if mysql is not available)
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
mysql client library (version > 4.0.x) 
\begin_inset CommandInset href
LatexCommand href
name "http://mysql.org/"
target "http://mysql.org/"

\end_inset

 
\emph on
REQUIRED (if sqlite is not available)
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
expat 
\begin_inset CommandInset href
LatexCommand href
name "http://expat.sourceforge.net/"
target "http://expat.sourceforge.net/"

\end_inset

 
\emph on
REQUIRED
\end_layout

\begin_layout Standard
Expat is a very good and robust XML parser, since most of UPnP is based
 on XML this package is a requirement.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
zlib 
\begin_inset CommandInset href
LatexCommand href
name "http://www.zlib.net/"
target "http://www.zlib.net/"

\end_inset

 
\emph on
OPTIONAL, HIGHLY RECOMMENDED
\end_layout

\begin_layout Standard
Zlib is a compression library that is available on most systems, we need
 it for the database autocreation functionality.
 Make sure to install the zlib development package providing zlib.h, if it
 is not available you will need to create the MediaTomb sqlite3/MySQL database
 manually.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
libmagic 
\emph on
OPTIONAL, RECOMMENDED
\end_layout

\begin_layout Standard
This is the 'file' package, it is used to determine the mime type of the
 media.
 If you don't have this you will have to enter file extension to mime type
 mappings manually in your config file.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
js - SpiderMonkey JavaScript Engine 
\begin_inset CommandInset href
LatexCommand href
name "http://www.mozilla.org/js/spidermonkey/"
target "http://www.mozilla.org/js/spidermonkey/"

\end_inset


\shape italic
 
\shape default
\emph on
OPTIONAL, RECOMMENDED, REQUIRED FOR PLAYLIST SUPPORT
\end_layout

\begin_layout Standard
This package is necessary to allow the user defined creation of virtual
 containers.
 The import.js script defines the layout of your media, the default import
 script will create a structure sorted by Audio/Photo/Video, it will make
 use of the gathered metadata (like ID3 tags) to sort your music by Artist/Album
/Genre/Year , etc.
 The import script can be adjusted and modified - it allows you to create
 the layout that you want.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
taglib 
\begin_inset CommandInset href
LatexCommand href
name "http://developer.kde.org/~wheeler/taglib.html"
target "http://developer.kde.org/~wheeler/taglib.html"

\end_inset

 
\emph on
OPTIONAL, RECOMMENDED
\end_layout

\begin_layout Standard
This library retrieves metadata from mp3, ogg and flac files.
 You will need it if you want to have virtual objects for those files (i.e.
 nice content layout).
 
\end_layout

\begin_layout Description

\series bold
Note: 
\series default
It makes no sense to use taglib and id3lib at the same time, the configure
 script will first look for TagLib, if TagLib detection fails it will search
 for id3lib.
 You can also force the configure script to take the library of your choice,
 overriding the default setting.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
id3lib 
\begin_inset CommandInset href
LatexCommand href
name "http://id3lib.sourceforge.net/"
target "http://id3lib.sourceforge.net/"

\end_inset

 (at least version 3.8.3)
\shape italic
 
\shape default
\emph on
OPTIONAL, RECOMMENDED (if TagLib is not available)
\end_layout

\begin_layout Standard
This library retrieves id3 tags from mp3 files.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
libexif 
\begin_inset CommandInset href
LatexCommand href
name "http://libexif.sourceforge.net/"
target "http://libexif.sourceforge.net/"

\end_inset

 
\emph on
OPTIONAL, RECOMMENDED
\end_layout

\begin_layout Standard
You will need this library if you want to extract metadata from images,
 this will allow you to have virtual containers for your Photos, sorted
 by various attributes like Date, etc.
 It also enables thumbnail support: if EXIF thumbnails are present in your
 images they will also be offered via UPnP.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
curl 
\begin_inset CommandInset href
LatexCommand href
name "http://curl.haxx.se/"
target "http://curl.haxx.se/"

\end_inset

 
\emph on
OPTIONAL, REQUIRED FOR YOUTUBE AND SOPCAST SUPPORT
\end_layout

\begin_layout Standard
curl is a library that allows to easily fetch content from the web, if you
 want to compile MediaTomb with YouTube and/or SopCast support then curl
 is required.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
libextractor 
\begin_inset CommandInset href
LatexCommand href
name "http://gnunet.org/libextractor/"
target "http://gnunet.org/libextractor/"

\end_inset

 
\emph on
OPTIONAL
\end_layout

\begin_layout Standard
This library tries to gather metadata from all kinds of files (also .avi
 and .asf).
 The drawback is, that it can be very slow at scanning video files.
 We also noticed that it uses a lot of memory when reading files, the result
 is, that media import becomes extremely slow.
 It is up to you if you want to use it or not, you may try the 'extract'
 utility that is provided with the library to check if there is any metadata
 that can be extracted from your media prior to enabling this feature in
 MediaTomb.
 By default libextractor is disabled, use ./configure --enable-libextractor
 to activate it.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
ffmpeg 
\begin_inset CommandInset href
LatexCommand href
name "http://ffmpeg.mplayerhq.hu/"
target "http://ffmpeg.mplayerhq.hu/"

\end_inset

 
\emph on
OPTIONAL
\end_layout

\begin_layout Standard
Currently ffmpeg is used to gather additional metadata from audio and video
 files.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
libffmpegthumbnailer 
\begin_inset CommandInset href
LatexCommand href
name "http://code.google.com/p/ffmpegthumbnailer/"
target "http://code.google.com/p/ffmpegthumbnailer/"

\end_inset

 
\emph on
OPTIONAL
\end_layout

\begin_layout Standard
ffmpegthumbnailer is used to generate video thumbnails on the fly.
 If your device (like DSM-510 or PlayStation 3) supports video thumbnails
 it would be worth to compile MediaTomb with this library.
\end_layout

\begin_layout Description
Note: ffmpegthumbnailer support is only provided if MediaTomb is compiled
 with ffmpeg support.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
In order to use the web UI you will need to have javascript enabled in your
 web browser.
\end_layout

\begin_layout Standard
The UI has been tested and works with the recent versions of :
\end_layout

\begin_layout Itemize
Firefox/Mozilla
\end_layout

\begin_layout Itemize
Opera 
\end_layout

\begin_layout Standard
Tested and does not work with the recent versions of:
\end_layout

\begin_layout Itemize
Konqueror 
\end_layout

\begin_layout Itemize
Safari 
\end_layout

\begin_layout Standard
Limited functionality with:
\end_layout

\begin_layout Itemize
Internet Explorer 6 and 7
\end_layout

\begin_layout Section
Compiling From Source
\end_layout

\begin_layout Subsection
Standard Method
\end_layout

\begin_layout Standard
If you don't care about the details - make sure you have installed the required
 packages and the appropriate development headers and simply run
\end_layout

\begin_layout Code
$ ./configure
\end_layout

\begin_layout Code
$ make
\end_layout

\begin_layout Code
$ make install
\end_layout

\begin_layout Standard
This should compile and install MediaTomb, the resulting binary is ready
 to run.
\end_layout

\begin_layout Description
Note: if you checked out the sources from SVN the configure script will
 not be available, you will have to create it with the following command:
\end_layout

\begin_layout Code
autoreconf -i
\end_layout

\begin_layout Subsection
Configure Options
\end_layout

\begin_layout Standard
The MediaTomb configure script provides a large variety of options, allowing
 you to specify the additional libraries that will be used, features that
 will be compiled or disabled, workarounds for known bugs in some distributions
 and so on.
 Some options are straightforward, some require deeper knowledge - make
 sure you know what you are doing :)
\end_layout

\begin_layout Subsubsection
Install Location Of Architecture Independent Files
\end_layout

\begin_layout Code
--prefix=PREFIX
\end_layout

\begin_layout Description
Default: /usr/local/
\end_layout

\begin_layout Standard
Install all architecture independent files - all .js files and .png images
 for the Web UI, the import.js script, the service description XML files
 - in the directory of your choice.
 This is especially useful if you do not want to perform a system-wide installat
ion, but want to install MediaTomb only for your user.
\end_layout

\begin_layout Description
Important: the prefix path will be compiled into the binary; the binary
 will still be relocatable, but you move those files you will have to point
 MediaTomb to the proper location by specifying it in the server configuration
 file.
 
\end_layout

\begin_layout Subsubsection
Static Build
\end_layout

\begin_layout Code
--enable-static
\end_layout

\begin_layout Description
Default: disabled
\end_layout

\begin_layout Standard
Build a static binary.
 This may be useful if you plan to install a precompiled MediaTomb binary
 on a system that does not have all the required libraries and where installatio
n of those libraries is not possible due to reasons beyond your control.
\end_layout

\begin_layout Description
Note: if you enable this option, make sure that you have all static versions
 of the appropriate libraries installed on your system.
 The configure script may not detect that those are missing - in this case
 you will get linker errors.
 Some distributions, for example Fedora Core, do not ship static library
 versions.
\end_layout

\begin_layout Subsubsection
Automatically Create Database
\end_layout

\begin_layout Code
--enable-db-autocreate
\end_layout

\begin_layout Description
Default: enabled
\end_layout

\begin_layout Standard
Automatically create the database if it is missing (for example upon a first
 time launch).
 Disabling this will make the resulting binary a little smaller, however
 you will have to take care of the database creation yourself by invoking
 the appropriate .sql scripts that are provided with the package.
 
\end_layout

\begin_layout Description
Note: the server configuration file has to be setup correctly.
 Either sqlite or MySQL has to be chosen in the storage section, for sqlite
 the database file has to point to a writable location, for MySQL the user
 has to be setup with a valid password and permissions and the database
 
\begin_inset Quotes sld
\end_inset

mediatomb
\begin_inset Quotes srd
\end_inset

 has to exist.
\end_layout

\begin_layout Subsubsection
Debug Malloc/Realloc Of Zero bytes
\end_layout

\begin_layout Code
--enable-debug-malloc0
\end_layout

\begin_layout Description
Default: disabled
\end_layout

\begin_layout Standard
This feature is only for debugging purposes, whenever a malloc or realloc
 with a value of zero bytes is encountered, the server will terminate with
 abort()
\end_layout

\begin_layout Subsubsection
Force Linking With The Pthread Library
\end_layout

\begin_layout Code
--enable-pthread-lib
\end_layout

\begin_layout Description
Default: disabled
\end_layout

\begin_layout Standard
We use the ACX_PTHREAD macro from the autoconf archive to determine the
 way how to link against the pthread library.
 Usually it works fine, but it can fail when cross compiling.
 This configure option tells us to use -lpthread when linking, it seems
 to be needed when building MediaTomb under Optware.
 Note, that using --disable-pthread-lib will not prevent automatic checks
 against the pthread library.
\end_layout

\begin_layout Subsubsection
Force Linking With The Iconv Library
\end_layout

\begin_layout Code
--enable-iconv-lib
\end_layout

\begin_layout Description
Default: disabled
\end_layout

\begin_layout Standard
By default we will attempt to use iconv functionality provided with glibc,
 however under some circumstances it may make sense to link against a separate
 iconv library.
 This option will attempt to do that.
 Note, that using --disable-iconv-lib will not prevent automatic attempts
 to link ageinst the iconv library in the case where builtin glibc iconv
 functionality is not available.
\end_layout

\begin_layout Subsubsection
Use Atomic Assembler Code For x86 Single CPU systems
\end_layout

\begin_layout Code
--enable-atomic-x86-single
\end_layout

\begin_layout Description
Default: disabled
\end_layout

\begin_layout Standard
Use assembler code suited for single CPU x86 machines.
 This may improve performance, but your binary will not function properly
 on SMP systems.
 If you specify this for a non x86 architecture the binary will not run
 at all.
 If you wonder about the purpose of assembler code in a mediaserver application:
 we need it for atomic operations that are required for reference counting.
 The pthread library will be used as a fallback for other architectures,
 but can also be forced by a designated configure option.
 This however, will have the worst performance.
 
\end_layout

\begin_layout Standard
By default x86 SMP code will be used on x86 systems - it will reliably work
 on both SMP and single CPU systems, but will not be as fast as the atomic-x86-s
ingle option on uniprocessor machines.
\end_layout

\begin_layout Subsubsection
Use Pthread Code For Atomic Operations
\end_layout

\begin_layout Code
--enable-atomic-pthread
\end_layout

\begin_layout Description
Default: auto detect
\end_layout

\begin_layout Standard
This is the default setting for non x86 architectures, we may add assembler
 optimizations for other architectures as well, but currently only x86 optimizat
ions are available.
 This option may also be safely used on x86 machines - the drawback is poor
 performance, compared to assembler optimized code.
\end_layout

\begin_layout Subsubsection
Enable SIGHUP Handling
\end_layout

\begin_layout Code
--enable-sighup
\end_layout

\begin_layout Standard
This option turns on SIGHUP handling, every time a SIGHUP is caught we will
 attempt to restart the server and reread the configuration file.
 By default this feature is enabled for x86 platforms, but is disabled for
 others.
 We discovered that MediaTomb will not cleanly restart on ARM based systems,
 investigations revealed that this is somehow related to an unclean libupnp
 shutdown.
 This will be fixed in a later release.
\end_layout

\begin_layout Description
Default: auto detect
\end_layout

\begin_layout Subsubsection
X_MS_MediaReceiverRegistrar Support
\end_layout

\begin_layout Code
--enable-mrreg-service
\end_layout

\begin_layout Description
Default: disabled
\end_layout

\begin_layout Standard
This option will enable the compilation and support of the X_MS_MediaReceiverReg
istrar UPnP service, this was implemented for future Xbox 360 support.
 If you have a renderer that requires this service, you can safely enable
 it.
 It will always return true to IsValidated and IsAuthorized requests.
\end_layout

\begin_layout Description
Note: eventhough this service is implemented there is still no Xbox 360
 support in MediaTomb, more work needs to be done.
\end_layout

\begin_layout Subsubsection
Playstation 3 Support
\end_layout

\begin_layout Code
--enable-protocolinfo-extension
\end_layout

\begin_layout Description
Default: enabled
\end_layout

\begin_layout Standard
This option allows to send additional information in the protocolInfo attribute,
 this will enable MP3 and MPEG4 playback for the Playstation 3, but may
 also be useful to some other renderers.
\end_layout

\begin_layout Description
Note: allthough compiled in, this feature is disabled in configuration by
 default.
\end_layout

\begin_layout Subsubsection
Fseeko Check
\end_layout

\begin_layout Code
--disable-fseeko-check
\end_layout

\begin_layout Description
Default: enabled
\end_layout

\begin_layout Standard
This is a workaround for a bug in some Debian distributions, disable this
 check if you know that your system has large file support, but configure
 fails to detect it.
 
\end_layout

\begin_layout Subsubsection
Largefile Support
\end_layout

\begin_layout Code
--disable-largefile
\end_layout

\begin_layout Description
Default: auto
\end_layout

\begin_layout Standard
By default largefile support will be auto detected by configure, however
 you can disable it if you do not want it or if you experience problems
 with it on your system.
\end_layout

\begin_layout Subsubsection
Redefinition Of Malloc And Realloc
\end_layout

\begin_layout Code
--disable-rpl-malloc
\end_layout

\begin_layout Description
Default: enabled
\end_layout

\begin_layout Standard
Autoconf may redefine malloc and realloc functions to rpl_malloc and rpl_realloc
, usually this will happen if the autotools think that you are compiling
 against a non GNU C library.
 Since malloc and realloc may behave different on other systems, this gives
 us the opportunity to write wrapper functions to handle special cases.
 However, this redefinition may get triggered when cross compiling, even
 if you are compiling against the GNU C lib.
 If this is the case, you can use this option to disable the redefinition.
\end_layout

\begin_layout Subsubsection
SQLite Support
\end_layout

\begin_layout Code
--enable-sqlite3
\end_layout

\begin_layout Description
Default: enabled
\end_layout

\begin_layout Standard
The SQLite database is very easy in installation and use, you do not have
 to setup any users, permissions, etc.
 A database file will be simply created as specified in the MediaTomb configurat
ion.
 At least SQLite version 3 is required.
\end_layout

\begin_layout Subsubsection
MySQL Support
\end_layout

\begin_layout Code
--enable-mysql
\end_layout

\begin_layout Description
Default: enabled
\end_layout

\begin_layout Standard
MySQL is a very powerful database, however it requires some additional setup.
 You will find information on how to setup MediaTomb with MySQL in the Installat
ion section.
\end_layout

\begin_layout Subsubsection
SpiderMonkey LibJS Support
\end_layout

\begin_layout Code
--enable-libjs
\end_layout

\begin_layout Description
Default: enabled
\end_layout

\begin_layout Standard
SpiderMonkey is Mozilla's JavaScript engine, it plays a very important role
 in MediaTomb.
 We use it to create a nice virtual container layout based on the metadata
 that is extracted from your media.
 We also allow the user to create custom import scripts, so everyone has
 the possibility to adapt the layout to ones personal needs.
 Read more about this in the installation section.
\end_layout

\begin_layout Standard
The main problem with this library is, that it is called differently on
 various distributions and that it is installed in different locations.
 For example, it is called js on Fedora, but is available under the name
 of smjs on Debian.
 If configure fails to find your js headers and libraries you can point
 it to the desired locations (see options below).
\end_layout

\begin_layout Subsubsection
Filemagic Support
\end_layout

\begin_layout Code
--enable-libmagic
\end_layout

\begin_layout Description
Default: enabled
\end_layout

\begin_layout Standard
This library determines the file type and provides us with the appropriate
 mime type information.
 It is very important to correctly determine the mime type of your media
 - this information will be sent to your renderer.
 Based on the mime type information, the renderer will decide if it can
 play/display the particular file or not.
 If auto detection returns strange mime types, you may want to do a check
 using the 'file' command (the 'file' package must be installed on your
 system).
 Assuming that you want to check somefile.avi enter the following in your
 terminal:
\end_layout

\begin_layout Code
$ file -i somefile.avi
\end_layout

\begin_layout Standard
This will print the detected mime type, this is exactly the information
 that we use in MediaTomb.
 You can override auto detection by defining appropriate file extension
 to mime type mappings in your configuration file.
 You can also edit the mime type information of an imported object manually
 via the web UI.
\end_layout

\begin_layout Subsubsection
Id3lib Support
\end_layout

\begin_layout Code
--enable-id3lib
\end_layout

\begin_layout Description
Default: disabled, used if taglib is not available
\end_layout

\begin_layout Standard
This library will parse id3 tags of your MP3 files, the gathered information
 will be saved in the database and provided via UPnP.
 Further, the gathered metadata will be used by the import script to create
 a nice container layout (Audio/Artist/Album, etc.)
\end_layout

\begin_layout Subsubsection
Taglib Support
\end_layout

\begin_layout Code
--enable-taglib
\end_layout

\begin_layout Description
Default: enabled, preffered over id3lib
\end_layout

\begin_layout Standard
This library will parse id3 tags of your MP3 files as well as information
 provided with flac files.
 It claims to be faster than id3lib, but it also seems to have some drawbacks.
 We had some cases where it crashed when trying to parse tags of certain
 MP3 files on embedded systems, we had reports and observed that it had
 problems parsing the sample rates.
 We also did some valgrinding and detected memory leaks.
 Our feeling is, that you will have more stable results with id3lib, however
 it is up to you to enable or disable this library.
 By default id3lib will be taken if both libraries are present on the system.
\end_layout

\begin_layout Subsubsection
Libexif Support
\end_layout

\begin_layout Code
--enable-libexif
\end_layout

\begin_layout Description
Default: enabled
\end_layout

\begin_layout Standard
The exif library will gather metadata from your photos, it will also find
 exif thumbnails which are created automatically by most digital camera
 models.
 The gathered data will be used by the import script, the thumbnails will
 be offered as additional resources via UPnP.
\end_layout

\begin_layout Subsubsection
Libextractor Support
\end_layout

\begin_layout Code
--enable-libextractor
\end_layout

\begin_layout Description
Default: disabled
\end_layout

\begin_layout Standard
Libextractor is a library that attempts to parse all sorts of files, this
 includes exif data, id3 tags and much more.
 It can also deal with .AVI and .ASF files which is useful when your video
 files have the appropriate metadata.
 The drawback is - it is slow, especially slow on scanning big video files,
 so it slows down the import process considerably.
 For this reason this library is disabled by default.
\end_layout

\begin_layout Subsubsection
Inotify Support
\end_layout

\begin_layout Code
--enable-inotify
\end_layout

\begin_layout Description
Default: auto
\end_layout

\begin_layout Standard
Inotify is a kernel mechanism that allows monitoring of filesystem events.
 You need this if you want to use the Inotify Autoscan mode, contrary to
 the Timed mode which recsans given directories in specified intervals,
 Inotify mode will immedeately propagate changes in monitored directories
 on the filesystem to the database.
 
\end_layout

\begin_layout Standard
If you do not specify this option configure will check if inotify works
 on the build system and compile it in only if the check succeeds.
 If you specify this option, the functionality will be compiled in even
 if the build system does not support inotify - the availability of inotify
 will then be checked at server runtime.
\end_layout

\begin_layout Subsubsection
YouTube Service Support
\end_layout

\begin_layout Code
--enable-youtube
\end_layout

\begin_layout Description
Default: enabled
\end_layout

\begin_layout Standard
This option enabled support of the YouTube service, it allows to gather
 information about content on the YouTube site and offers the content via
 UPnP, thus enabling you to watch your favorite YouTube videos on your UPnP
 player device.
 The feature only makes sense in combination with transcoding, since most
 devices do not support playback of flv files natively.
\end_layout

\begin_layout Subsubsection
External Transcoding
\end_layout

\begin_layout Code
--enable-external-transcoding
\end_layout

\begin_layout Description
Default: enabled
\end_layout

\begin_layout Subsubsection
Sqlite Backup Defaults
\end_layout

\begin_layout Code
--enable-sqlite-backup-defaults
\end_layout

\begin_layout Description
Default: disabled
\end_layout

\begin_layout Standard
Enables backup option for sqlite as the default setting, might be useful
 for NAS builds.
\end_layout

\begin_layout Subsubsection
Curl
\end_layout

\begin_layout Code
--enable-curl
\end_layout

\begin_layout Description
Default: enabled if external transcoding or YouTube features are turned
 on
\end_layout

\begin_layout Standard
It only makes sense to enable the curl library if YouTube and External Transcodi
ng are turned on.
 YouTube requires curl, but it's optional for External Transcoding.
\end_layout

\begin_layout Subsubsection
Ffmpeg Support
\end_layout

\begin_layout Code
--enable-ffmpeg
\end_layout

\begin_layout Description
Default: enabled
\end_layout

\begin_layout Standard
Currently the ffmpeg library is used to extract additional information from
 audio and video files.
 It is also capable of reading out the tag information from theora content.
 It is not yet used for transcoding, so this feature only gathers additional
 metadata.
\end_layout

\begin_layout Subsubsection
Ffmpeg Thumbnailer Support
\end_layout

\begin_layout Code
--enable-ffmpegthumbnailer
\end_layout

\begin_layout Description
Default: enabled
\end_layout

\begin_layout Standard
Compiling with ffmpegthumbnailer support is only possible if you also compile
 with ffmpeg support.
 The library allows to generate thumbnails for the videos on the fly.
\end_layout

\begin_layout Subsubsection
MediaTomb Debug Output
\end_layout

\begin_layout Code
--enable-tombdebug
\end_layout

\begin_layout Description
Default: disabled
\end_layout

\begin_layout Standard
This option enables debug output, the server will print out a lot of information
 which is mainly interesting to developers.
 Use this if you are trying to trace down a bug or a problem, the additional
 output may give you some clues.
\end_layout

\begin_layout Subsubsection
UPnP Library Debug Output
\end_layout

\begin_layout Code
--enable-upnpdebug
\end_layout

\begin_layout Description
Default: disabled
\end_layout

\begin_layout Standard
This option enables debug output of the UPnP SDK.
 You should not need it under normal circumstances.
\end_layout

\begin_layout Subsubsection
Log Output
\end_layout

\begin_layout Code
--disable-log
\end_layout

\begin_layout Description
Default: enabled
\end_layout

\begin_layout Standard
This option allows you to suppress all log output from the server.
\end_layout

\begin_layout Subsubsection
Debug Log Output
\end_layout

\begin_layout Description
Default: enabled
\end_layout

\begin_layout Standard
This option allows you to compile the server with debug messages.
 If enabled, switching between verbose and normal output during runtime
 becomes possible.
\end_layout

\begin_layout Subsubsection
Package Search Directory
\end_layout

\begin_layout Code
--with-search=DIR
\end_layout

\begin_layout Description
Default: /opt/local/ on Darwin, /usr/local/ on all other systems
\end_layout

\begin_layout Standard
Some systems may have whole sets of packages installed in an alternative
 location, for example Darwinports on OSX get installed to /opt/local/.
 This option tells the configure script to additionally search for headers
 and libraries of various packages in DIR/include and DIR/lib.
\end_layout

\begin_layout Subsubsection
Specifying Header And Library Locations Of Various Packages
\end_layout

\begin_layout Standard
You can specify the exact location of particular headers and libraries.
 Some packages use extra programs that tell us the appropriate flags that
 are needed for compilation - like mysql_config.
 You can also specify the exact location of those programs.
 The parameters are self explanatory, in case of headers and libraries the
 DIR parameter is the directory where those headers and libraries are located.
\end_layout

\begin_layout Code
--with-sqlite3-h=DIR               search for sqlite3 headers only in DIR
\end_layout

\begin_layout Code
--with-sqlite3-libs=DIR            search for sqlite3 libraries only in
 DIR
\end_layout

\begin_layout Code
--with-mysql-cfg=mysql_config      absolute path/name of mysql_config
\end_layout

\begin_layout Code
--with-js-h=DIR                    search for js (spidermonkey) headers
 in DIR
\end_layout

\begin_layout Code
--with-js-libs=DIR                 search for js (spidermonkey) libraries
 in DIR
\end_layout

\begin_layout Code
--with-libmagic-h=DIR              search for filemagic headers in DIR
\end_layout

\begin_layout Code
--with-libmagic-libs=DIR           search for filemagic headers in DIR
\end_layout

\begin_layout Code
--with-libexif-h=DIR               search for libexif headers in DIR
\end_layout

\begin_layout Code
--with-libexif-libs=DIR            search for libexif libraries in DIR
\end_layout

\begin_layout Code
--with-expat-h=DIR                 search for expat headers in DIR
\end_layout

\begin_layout Code
--with-expat-libs=DIR              search for expat libraries in DIR 
\end_layout

\begin_layout Code
--with-taglib-cfg=taglib-config    absolute path/name of taglib-config
\end_layout

\begin_layout Code
--with-id3lib-h=DIR                search for id3lib headers in DIR
\end_layout

\begin_layout Code
--with-id3lib-libs=DIR             search for id3lib libraries in DIR
\end_layout

\begin_layout Code
--with-zlib-h=DIR                  search for zlib headers in DIR
\end_layout

\begin_layout Code
--with-zlib-libs=DIR               search for zlib libraries in DIR
\end_layout

\begin_layout Code
--with-inotify-h=DIR               search for inotify header in DIR
\end_layout

\begin_layout Code
--with-iconv-h=DIR                 search for iconv headers in DIR/sys
\end_layout

\begin_layout Code
--with-iconv-libs=DIR              search for iconv libraries in DIR
\end_layout

\begin_layout Code
--with-libextractor-h=DIR          search for extractor headers in DIR
\end_layout

\begin_layout Code
--with-libextractor-libs=DIR       search for extractor libraries in DIR
\end_layout

\begin_layout Code
--with-ffmpeg-h=DIR                search for ffmpeg headers in DIR
\end_layout

\begin_layout Code
--with-ffmpeg-libs=DIR             search for ffmpeg libraries in DIR  --with-ff
mpegthumbnailer-h=DIR     search for ffmpegthumbnailer headers in DIR
\end_layout

\begin_layout Code
--with-ffmpegthumbnailer-libs=DIR  search for ffmpegthumbnailer libraries
 in DIR
\end_layout

\begin_layout Code
--with-curl-cfg=curl-config        absolute path/name of curl-config script
\end_layout

\begin_layout Code
--with-libmp4v2-h=DIR              search for libmp4v2 headers in DIR
\end_layout

\begin_layout Code
--with-libmp4v2-libs=DIR           search for libmp4v2 libraries in DIR
\end_layout

\begin_layout Code
--with-rt-libs=DIR                 search for rt libraries in DIR
\end_layout

\begin_layout Code
--with-pthread-libs=DIR            search for pthread libraries in DIR 
\end_layout

\begin_layout Code

\end_layout

\begin_layout Subsubsection
The devconf Script
\end_layout

\begin_layout Standard
If you are doing some development work and some debugging, you will probably
 want to compile with the -g flag and also disable optimization.
 The devconf script does exactly that.
 In addition, it accepts command line parameters that are passed to the
 configure script.
\end_layout

\begin_layout Section
Initial Installation
\end_layout

\begin_layout Subsection
Network Setup
\end_layout

\begin_layout Standard
Some systems require a special setup on the network interface.
 If MediaTomb exits with UPnP Error -117, or if it does not respond to M-SEARCH
 requests from the renderer (i.e.
 MediaTomb is running, but your renderer device does not show it) you should
 try the following settings (the lines below assume that MediaTomb is running
 on a Linux machine, on network interface eth1):
\end_layout

\begin_layout Code
# route add -net 239.0.0.0 netmask 255.0.0.0 eth1
\end_layout

\begin_layout Code
# ifconfig eth1 allmulti
\end_layout

\begin_layout Standard
Those settings will be applied automatically by the init.d startup script.
\end_layout

\begin_layout Standard
You should also make sure that your firewall is not blocking port UDP port
 1900 (required for SSDP) and UDP/TCP port of MediaTomb.
 By default MediaTomb will select a free port starting with 49152, however
 you can specify a port of your choice in the configuration file.
\end_layout

\begin_layout Subsection
First Time Launch
\end_layout

\begin_layout Standard
When starting MediaTomb for the first time, a .mediatomb directory will be
 created in your home.
 Further, a default server configuration file, called config.xml will be
 generated in that directory.
\end_layout

\begin_layout Subsubsection
Using Sqlite Database
\end_layout

\begin_layout Standard
If you are using sqlite - you are ready to go, the database file will be
 created automatically and will be located ~/.mediatomb/mediatomb.db If needed
 you can adjust the database file name and location in the server configuration
 file.
\end_layout

\begin_layout Subsubsection
Using MySQL Database
\end_layout

\begin_layout Standard
If MediaTomb was compiled with support for both databases, sqlite will be
 chosen as default because the initial database can be created and used
 without any user interaction.
 If MediaTomb was compiled only with MySQL support, the appropriate config.xml
 file will be created in the ~/.mediatomb directory, but the server will
 then terminate, because user interaction is required.
\end_layout

\begin_layout Standard
MediaTomb has to be able to connect to the MySQL server and at least the
 (empty) database has to exist.
 To create the database and provide MediaTomb with the ability to connect
 to the MySQL server you need to have the appropriate permissions.
 Note that user names and passwords in MySQL have nothing to do with UNIX
 accounts, MySQL has it's own user names/passwords.
 Connect to the MySQL database as 
\begin_inset Quotes sld
\end_inset

root
\begin_inset Quotes srd
\end_inset

 or any other user with the appropriate permissions:
\end_layout

\begin_layout Code
$ mysql [-u <username>] [-p]
\end_layout

\begin_layout Standard
(You'll probably need to use 
\begin_inset Quotes sld
\end_inset

-u
\begin_inset Quotes srd
\end_inset

 to specify a different MySQL user and 
\begin_inset Quotes sld
\end_inset

-p
\begin_inset Quotes srd
\end_inset

 to specify a password.)
\end_layout

\begin_layout Standard
Create a new database for MediaTomb: (substitute 
\begin_inset Quotes sld
\end_inset

<database name>
\begin_inset Quotes srd
\end_inset

 with the name of the database)
\end_layout

\begin_layout Code
mysql> CREATE DATABASE <database name>;
\end_layout

\begin_layout Standard
(You can also use 
\begin_inset Quotes sld
\end_inset

mysqladmin
\begin_inset Quotes srd
\end_inset

 instead.)
\end_layout

\begin_layout Standard
Give MediaTomb the permissions to access the database:
\end_layout

\begin_layout Code
mysql> GRANT ALL ON <database name>.*
\end_layout

\begin_layout Code
       TO '<user name>'@'<hostname>'
\end_layout

\begin_layout Code
       IDENTIFIED BY '<password>';
\end_layout

\begin_layout Standard
If you don't want to set a password, omit 
\begin_inset Quotes sld
\end_inset

IDENTIFIED BY ..
\begin_inset Quotes srd
\end_inset

 completely.
 You could also use the MySQL 
\begin_inset Quotes sld
\end_inset

root
\begin_inset Quotes srd
\end_inset

 user with MediaTomb directly, but this is not recommended.
\end_layout

\begin_layout Standard
To create a database and a user named 
\begin_inset Quotes sld
\end_inset

mediatomb
\begin_inset Quotes srd
\end_inset

 (who is only able to connect via 
\begin_inset Quotes sld
\end_inset

localhost
\begin_inset Quotes srd
\end_inset

) without a password (the defaults) use:
\end_layout

\begin_layout Code
mysql> CREATE DATABASE mediatomb;
\end_layout

\begin_layout Code
mysql> GRANT ALL ON mediatomb.* TO 'mediatomb'@'localhost';
\end_layout

\begin_layout Standard
If MediaTomb was compiled with database auto creation the tables will be
 created automatically during the first startup.
 All table names have a 
\begin_inset Quotes sld
\end_inset

mt_
\begin_inset Quotes srd
\end_inset

 prefix, so you can theoretically share the database with a different applicatio
n.
 However, this is not recommended.
\end_layout

\begin_layout Standard
If database auto creation wasn't compiled in (configure was run with the
 
\begin_inset Quotes sld
\end_inset

--disable-db-autocreate
\begin_inset Quotes srd
\end_inset

 or zlib.h was not available) you have to create the tables manually:
\end_layout

\begin_layout Code
$ mysql [-u <username>] [-p] 
\backslash

\end_layout

\begin_layout Code
  <database name> < 
\backslash

\end_layout

\begin_layout Code
  <install prefix>/share/mediatomb/mysql.sql
\end_layout

\begin_layout Standard
After creating the database and making the appropriate changes in your MediaTomb
 config file you are ready to go - launch the server, and everything should
 work.
\end_layout

\begin_layout Section
Command Line Options
\end_layout

\begin_layout Standard
There is a number of options that can be passed via command line upon server
 start up, for a short summary you can invoke MediaTomb with the following
 parameter:
\end_layout

\begin_layout Code
$ mediatomb --help
\end_layout

\begin_layout Description
Note: the command line options override settings in the configuration file!
\end_layout

\begin_layout Subsection
IP Address
\end_layout

\begin_layout Code
--ip or -i
\end_layout

\begin_layout Standard
The server will bind to the given IP address, currently we can not bind
 to multiple interfaces so binding to 0.0.0.0 will not be possible.
\end_layout

\begin_layout Subsection
Interface
\end_layout

\begin_layout Code
--interface or -e
\end_layout

\begin_layout Standard
Interface to bind to, for example eth0, this can be specified instead of
 the ip address.
\end_layout

\begin_layout Subsection
Port
\end_layout

\begin_layout Code
--port or -p
\end_layout

\begin_layout Standard
Specify the server port that will be used for the web user interface, for
 serving media and for UPnP requests, minimum allowed value is 49152.
 If this option is omitted a default port will be chosen, however, in this
 case it is possible that the port will change upon server restart.
\end_layout

\begin_layout Subsection
Configuration File
\end_layout

\begin_layout Code
 --config or -c
\end_layout

\begin_layout Standard
By default MediaTomb will search for a file named 
\begin_inset Quotes sld
\end_inset

config.xml
\begin_inset Quotes srd
\end_inset

 in the ~/.mediatomb directory.
 This option allows you to specify a config file by the name and location
 of your choice.
 The file name must be absolute.
\end_layout

\begin_layout Subsection
Daemon Mode
\end_layout

\begin_layout Code
--daemon or -d
\end_layout

\begin_layout Standard
Run the server in background, MediaTomb will shutdown on SIGTERM, SIGINT
 and restart on SIGHUP.
\end_layout

\begin_layout Subsection
Home Directory
\end_layout

\begin_layout Code
--home or -m
\end_layout

\begin_layout Standard
Specify an alternative home directory.
 By default MediaTomb will try to retrieve the users home directory from
 the environment, then it will look for a .mediatomb directory in users home.
 If .mediatomb was found we will try to find the default configuration file
 (config.xml), if not found we will create both, the .mediatomb directory
 and the default config file.
\end_layout

\begin_layout Standard
This option is useful in two cases: when the home directory can not be retrieved
 from the environment (in this case you could also use -c to point MediaTomb
 to your configuration file or when you want to create a new configuration
 in a non standard location (for example, when setting up daemon mode).
 In the latter case you can combine this parameter with the parameter described
 in 
\begin_inset CommandInset ref
LatexCommand ref
reference "sec:Config-Directory"

\end_inset


\end_layout

\begin_layout Subsection
\begin_inset CommandInset label
LatexCommand label
name "sec:Config-Directory"

\end_inset

Config Directory
\end_layout

\begin_layout Code
--cfgdir or -f
\end_layout

\begin_layout Standard
The default configuration directory is combined out of the users home and
 the default that equals to .mediatomb, this option allows you to override
 the default directory naming.
 This is useful when you want to setup the server in a nonstandard location,
 but want that the default configuration to be written by the server.
\end_layout

\begin_layout Subsection
Write PID File
\end_layout

\begin_layout Code
--pidfile or -P
\end_layout

\begin_layout Standard
Specify a file that will hold the server process ID, the filename must be
 absolute.
\end_layout

\begin_layout Subsection
Run Under Different User Name
\end_layout

\begin_layout Code
--user or -u
\end_layout

\begin_layout Standard
Run MediaTomb under the specified user name, this is especially useful in
 combination with the daemon mode.
\end_layout

\begin_layout Subsection
Run Under Different Group
\end_layout

\begin_layout Code
--group or -g
\end_layout

\begin_layout Standard
Run MediaTomb under the specified group, this is especially useful in combinatio
n with the daemon mode.
\end_layout

\begin_layout Subsection
Add Content
\end_layout

\begin_layout Code
--add or -a
\end_layout

\begin_layout Standard
Add the specified directory or file name to the database without UI interaction.
 The path must be absolute, if path is a directory then it will be added
 recursively.
 If path is a file, then only the given file will be imported.
\end_layout

\begin_layout Subsection
Log To File
\end_layout

\begin_layout Code
--logfile or -l
\end_layout

\begin_layout Standard
Do not output log messages to stdout, but redirect everything to a specified
 file.
\end_layout

\begin_layout Subsection
Debug Output
\end_layout

\begin_layout Code
--debug or -D
\end_layout

\begin_layout Standard
Enable debug log output.
\end_layout

\begin_layout Subsection
Compile Info
\end_layout

\begin_layout Code
--compile-info
\end_layout

\begin_layout Standard
Print the configuration summary (used libraries and enabled features) and
 exit.
\end_layout

\begin_layout Subsection
Version Information
\end_layout

\begin_layout Code
--version
\end_layout

\begin_layout Standard
Print version information and exit.
\end_layout

\begin_layout Subsection
Display Command Line Summary
\end_layout

\begin_layout Code
--help or -h
\end_layout

\begin_layout Standard
Print a summary about the available command line options.
\end_layout

\begin_layout Section
Configuration File
\end_layout

\begin_layout Standard
MediaTomb is highly configurable and allows the user to set various options
 and preferences that define the servers behavior.
 Rather than enforcing certain features upon the user, we prefer to offer
 a number of choices where possible.
 The heart of MediaTomb configuration is the config.xml file, which is located
 in the ~/.mediatomb directory.
 If the configuration file is not found in the default location and no configura
tion was specified on the command line, MediaTomb will generate a default
 config.xml file in the ~/.mediatomb directory.
 The file is in the XML format and can be edited by a simple text editor,
 here is the list of all available options:
\end_layout

\begin_layout Itemize
"
\series bold
\emph on
Required
\series default
\emph default
" means that the server will not start if the tag is missing in the configuratio
n.
\end_layout

\begin_layout Itemize
"
\series bold
\emph on
Optional
\series default
\emph default
" means that the tag can be left out of the configuration file.
\end_layout

\begin_layout Standard
The root tag of MediaTomb configuration is:
\end_layout

\begin_layout Code
<config>
\end_layout

\begin_layout Subsection
Server Settings
\end_layout

\begin_layout Standard
These settings define the server configuration, this includes UPnP behavior,
 selection of database, accounts for the UI as well as installation locations
 of shared data.
\end_layout

\begin_layout Code
<server>
\end_layout

\begin_layout Standard

\emph on
Required
\end_layout

\begin_layout Standard
This section defines the server configuration parameters.
\end_layout

\begin_layout Standard
Child tags:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<port>0</port>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default
\emph default
:
\emph on
 0 (automatic)
\end_layout

\begin_layout Standard
Specifies the port where the server will be listening for HTTP requests.
 Note, that because of the implementation in the UPnP SDK only ports above
 49152 are supported.
 The value of zero means, that a port will be automatically selected by
 the SDK.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<ip>192.168.0.23</ip> 
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default
\emph default
:
\emph on
 ip of the first available interface.
\end_layout

\begin_layout Standard
Specifies the IP address to bind to, by default one of the available interfaces
 will be selected.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<interface>eth0</interface> 
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default
\emph default
:
\emph on
 first available interface.
\end_layout

\begin_layout Standard
Specifies the interface to bind to, by default one of the available interfaces
 will be selected.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<name>MediaTomb</name> 
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default
\emph default
:
\emph on
 MediaTomb
\end_layout

\begin_layout Standard
Server friendly name, you will see this on your devices that you use to
 access the server.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<manufacturerURL>http://mediatomb.org/</manufacturerURL>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default
\emph default
:
\emph on
 http://mediatomb.cc/
\end_layout

\begin_layout Standard
This tag sets the manufacturer URL of a UPnP device, a custom setting may
 be necessary to trick some renderers in order to enable special features
 that otherwise are only active with the vendor implemented server.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<modelName>MediaTomb</modelName>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: MediaTomb
\end_layout

\begin_layout Standard
This tag sets the model name of a UPnP device, a custom setting may be necessary
 to trick some renderers in order to enable special features that otherwise
 are only active with the vendor implemented server.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<modelNumber>0.9.0</modelNumber>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: MediaTomb version
\end_layout

\begin_layout Standard
This tag sets the model number of a UPnP device, a custom setting may be
 necessary to trick some renderers in order to enable special features that
 otherwise are only active with the vendor implemented server.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<serialNumber>1</serialNumber>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: 1
\end_layout

\begin_layout Standard
This tag sets the serial number of a UPnP device.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<presentationURL append-to="ip">80/index.html</presentationURL>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default
\emph default
:
\emph on
 
\begin_inset Quotes sld
\end_inset

/
\begin_inset Quotes srd
\end_inset


\end_layout

\begin_layout Standard
The presentation URL defines the location of the servers user interface,
 usually you do not need to change this however, vendors who want to ship
 our server along with their NAS devices may want to point to the main configura
tion page of the device.
\end_layout

\begin_layout Standard
Attributes:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
append-to=...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: 
\begin_inset Quotes sld
\end_inset

none
\begin_inset Quotes srd
\end_inset


\end_layout

\begin_layout Standard
The append-to attribute defines how the text in the presentationURL tag
 should be treated.
\end_layout

\begin_layout Standard
The allowed values are:
\end_layout

\begin_layout Code
append-to="none"
\end_layout

\begin_layout Standard
Use the string exactly as it appears in the presentationURL tag.
 
\end_layout

\begin_layout Code
append-to="ip"
\end_layout

\begin_layout Standard
Append the string specified in the presentationURL tag to the ip address
 of the server, this is useful in a dynamic ip environment where you do
 not know the ip but want to point the URL to the port of your web server.
         
\end_layout

\begin_layout Code
append-to="port"
\end_layout

\begin_layout Standard
Append the string specified in the presentationURL tag to the server ip
 and port, this may be useful if you want to serve some static pages using
 the built in web server.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<udn/> 
\end_layout

\begin_layout Standard

\emph on
Required
\end_layout

\begin_layout Standard

\emph on
Default
\emph default
:
\emph on
 automatically generated if the tag is empty
\end_layout

\begin_layout Standard
Unique Device Name, according to the UPnP spec it must be consistent throughout
 reboots.
 You can fill in something yourself, but we suggest that you leave this
 tag empty - it will be filled out and saved automatically after the first
 launch of the server.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<home>/home/your_user_name/.mediatomb</home> 
\end_layout

\begin_layout Standard

\emph on
Required
\end_layout

\begin_layout Standard

\emph on
Default: ~/.mediatomb
\end_layout

\begin_layout Standard
Server home - the server will search for the data that it needs relative
 to this directory - basically for the sqlite database file.
 The mediatomb.html bookmark file will also be generated in that directory.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<webroot>/usr/share/mediatomb/web</webroot>
\end_layout

\begin_layout Standard

\emph on
Required
\end_layout

\begin_layout Standard

\emph on
Default: depends on the installation prefix that is passed to the configure
 script.
\end_layout

\begin_layout Standard
Root directory for the web server, this is the location where device description
 documents, UI html and js files, icons, etc.
 are stored.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<servedir>/home/myuser/mystuff</servedir>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: empty (disabled)
\end_layout

\begin_layout Standard
Files from this directory will be served as from a regular web server.
 They do not need to be added to the database, but they are also not served
 via UPnP browse requests.
 Directory listing is not supported, you have to specify full paths.
\end_layout

\begin_layout Description
Example: the file something.jar is located in /home/myuser/mystuff/javasubdir/som
ething.jar on your filesystem.
 Your ip address is 192.168.0.23, the server is running on port 50500.
 Assuming the above configuration you could download it by entering this
 link in your web browser: http://192.168.0.23:50500/content/serve/javasubdir/somet
hing.jar
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<alive>180</alive>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default:
\emph default
 
\emph on
180, this is according to the UPnP specification.
\end_layout

\begin_layout Standard
Interval for broadcasting SSDP:alive messages
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<protocolInfo extend="no"/>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default:
\emph default
 
\emph on
no
\end_layout

\begin_layout Standard
Adds specific tags to the protocolInfo attribute, this is required to enable
 MP3 and MPEG4 playback on Playstation 3.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<pc-directory upnp-hide="no"/>
\end_layout

\begin_layout Standard

\family typewriter
\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: no
\end_layout

\begin_layout Standard
Enabling this option will make the PC-Directory container invisible for
 UPnP devices.
\end_layout

\begin_layout Description
Note: independent of the above setting the container will be always visible
 in the web UI!
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<tmpdir>/tmp/</tmpdir>
\end_layout

\begin_layout Standard

\family typewriter
\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: /tmp/
\end_layout

\begin_layout Standard
Selects the temporary directory that will be used by the server.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<bookmark>mediatomb.html</bookmark>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: mediatomb.html
\end_layout

\begin_layout Standard
The bookmark file offers an easy way to access the user interface, it is
 especially helpful when the server is not configured to run on a fixed
 port.
 Each time the server is started, the bookmark file will be filled in with
 a redirect to the servers current IP address and port.
 To use it, simply bookmark this file in your browser, the default location
 is ~/.mediatomb/mediatomb.html
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<custom-http-headers>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
This section holds the user defined HTTP headers that will be added to all
 HTTP responses that come from the server.
\end_layout

\begin_layout Standard
Child tags:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<add header="..."/>
\end_layout

\begin_layout Code
<add header="..."/>
\end_layout

\begin_layout Code
...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
Specify a header to be added to the response.
 If you have a DSM-320 use <add header="X-User-Agent: redsonic"/> to fix
 the .AVI playback problem.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<upnp-string-limit>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default:
\emph default
 
\emph on
disabled
\end_layout

\begin_layout Standard
This will limit title and description length of containers and items in
 UPnP browse replies, this feature was added a s workaround for the TG100
 bug which can only handle titles no longer than 100 characters.
 A negative value will disable this feature, the minimum allowed value is
 "4" because three dots will be appended to the string if it has been cut
 off to indicate that limiting took place.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<ui enabled="yes" poll-interval="2" poll-when-idle="no"/>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
This section defines various user interface settings.
\end_layout

\begin_layout Paragraph*
WARNING! 
\end_layout

\begin_layout Standard
The server has an integrated filesystem browser, that means that anyone
 who has access to the UI can browse your filesystem (with user permissions
 under which the server is running) and also download your data! If you
 want maximum security - disable the UI completely! Account authentication
 offers simple protection that might hold back your kids, but it is not
 secure enough for use in an untrusted environment!
\end_layout

\begin_layout Description
Note: since the server is meant to be used in a home LAN environment the
 UI is enabled by default and accounts are deactivated, thus allowing anyone
 on your network to connect to the user interface.
\end_layout

\begin_layout Standard
Attributes:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
enabled=...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: yes
\end_layout

\begin_layout Standard
Enables (
\begin_inset Quotes sld
\end_inset

yes
\begin_inset Quotes srd
\end_inset

) or disables (
\begin_inset Quotes sld
\end_inset

no
\begin_inset Quotes srd
\end_inset

) the web user interface.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
show-tooltips=...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: yes
\end_layout

\begin_layout Standard
This setting specifies if icon tooltips should be shown in the web UI.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
poll-interval=...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: 2
\end_layout

\begin_layout Standard
The poll-interval is an integer value which specifies how often the UI will
 poll for tasks.
 The interval is specified in seconds, only values greater than zero are
 allowed.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
poll-when-idle=...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: no
\end_layout

\begin_layout Standard
The poll-when-idle attribute influences the behavior of displaying current
 tasks: - when the user does something in the UI (i.e.
 clicks around) we always poll for the current task and will display it
 - if a task is active, we will continue polling in the background and update
 the current task view accordingly - when there is no active task (i.e.
 the server is currently idle) we will stop the background polling and only
 request updates upon user actions, but not when the user is idle (i.e.
 does not click around in the UI)
\end_layout

\begin_layout Standard
Setting poll-when-idle to "yes" will do background polling even when there
 are no current tasks; this may be useful if you defined multiple users
 and want to see the tasks the other user is queuing on the server while
 you are actually idle.
\end_layout

\begin_layout Standard
The tasks that are monitored are:
\end_layout

\begin_layout Itemize
adding files or directories
\end_layout

\begin_layout Itemize
removing items or containers
\end_layout

\begin_layout Itemize
automatic rescans 
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
Child tags:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<accounts enabled="yes" session-timeout="30"/>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
This section holds various account settings.
\end_layout

\begin_layout Standard
Attributes:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
enabled=...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: yes
\end_layout

\begin_layout Standard
Specifies if accounts are enabled (
\begin_inset Quotes sld
\end_inset

yes
\begin_inset Quotes srd
\end_inset

) or disabled (
\begin_inset Quotes sld
\end_inset

no
\begin_inset Quotes srd
\end_inset

).
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
session-timeout=...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: 30
\end_layout

\begin_layout Standard
The session-timeout attribute specifies the timeout interval in minutes.
 The server checks every five minutes for sessions that have timed out,
 therefore in the worst case the session times out after session-timeout
 + 5 minutes.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
Accounts can be defined as shown below:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<account user="name" password="password"/>
\end_layout

\begin_layout Code
<account user="name" password="password"/>
\end_layout

\begin_layout Code
....
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
There can be multiple users, however this is mainly a feature for the future.
 Right now there are no per-user permissions.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<items-per-page default="25"> 
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: 25
\end_layout

\begin_layout Standard
This sets the default number of items per page that will be shown when browsing
 the database in the web UI.
\end_layout

\begin_layout Standard
The values for the items per page drop down menu can be defined in the following
 manner:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<option>10</option>
\end_layout

\begin_layout Code
<option>25</option>
\end_layout

\begin_layout Code
<option>50</option>
\end_layout

\begin_layout Code
<option>100</option>
\end_layout

\begin_layout Standard

\emph on
Default: 10, 25, 50, 100
\end_layout

\begin_layout Description
Note: this list must contain the default value, i.e.
 if you define a default value of 25, then one of the <option> tags must
 also list this value.
 
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<storage caching="yes"> 
\end_layout

\begin_layout Standard

\emph on
Required
\end_layout

\begin_layout Standard
Defines the storage section - database selection is done here.
 Currently sqlite3 and mysql are supported.
 Each storage driver has it's own configuration parameters.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
caching="yes"
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: yes
\end_layout

\begin_layout Standard
Enables caching, this feature should improve the overall import speed.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<sqlite enabled="yes>
\end_layout

\begin_layout Standard

\emph on
Required if MySQL is not defined
\end_layout

\begin_layout Standard
Allowed values are 
\begin_inset Quotes sld
\end_inset

sqlite3
\begin_inset Quotes srd
\end_inset

 or 
\begin_inset Quotes sld
\end_inset

mysql
\begin_inset Quotes srd
\end_inset

, the available options depend on the selected driver.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
enabled="yes"
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: yes
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
Below are the sqlite driver options:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<database-file>mediatomb.db</database-file>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default:
\emph default
 
\emph on
mediatomb.db
\end_layout

\begin_layout Standard
The database location is relative to the server's home, if the sqlite database
 does not exist it will be created automatically.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<synchronous>off</synchronous>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: off
\end_layout

\begin_layout Standard
Possible values are 
\begin_inset Quotes sld
\end_inset

off
\begin_inset Quotes srd
\end_inset

, 
\begin_inset Quotes sld
\end_inset

normal
\begin_inset Quotes srd
\end_inset

 and 
\begin_inset Quotes srd
\end_inset

full
\begin_inset Quotes srd
\end_inset

.
\end_layout

\begin_layout Standard
This option sets the SQLite pragma 
\begin_inset Quotes sld
\end_inset

synchronous
\begin_inset Quotes srd
\end_inset

.
 This setting will affect the performance of the database write operations.
 For more information about this option see the SQLite documentation: 
\begin_inset CommandInset href
LatexCommand href
name "http://www.sqlite.org/pragma.html#pragma_synchronous"
target "http://www.sqlite.org/pragma.html#pragma_synchronous"

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<on-error>restore</on-error>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: restore
\end_layout

\begin_layout Standard
Possible values are 
\begin_inset Quotes sld
\end_inset

restore
\begin_inset Quotes srd
\end_inset

 and 
\begin_inset Quotes sld
\end_inset

fail
\begin_inset Quotes srd
\end_inset

.
\end_layout

\begin_layout Standard
This option tells MediaTomb what to do if an SQLite error occurs (no database
 or a corrupt database).
 If it is set to 
\begin_inset Quotes sld
\end_inset

restore
\begin_inset Quotes srd
\end_inset

 it will try to restore the database from a backup file (if one exists)
 or try to recreate a new database from scratch.
\end_layout

\begin_layout Standard
If the option is set to 
\begin_inset Quotes sld
\end_inset

fail
\begin_inset Quotes srd
\end_inset

, MediaTomb will abort on an SQLite error.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<backup enabled="no" interval="6000"/>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
Backup parameters:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
enabled=...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: no
\end_layout

\begin_layout Standard
Enables or disables database backup.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
interval=...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: 600
\end_layout

\begin_layout Standard
Defines the backup interval in seconds.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<mysql enabled="no"/>
\end_layout

\begin_layout Standard
Defines the MySQL storage driver section.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
enabled=...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: yes
\end_layout

\begin_layout Standard
Enables or disables the MySQL driver.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset CommandInset label
LatexCommand label
name "config-mysql"

\end_inset

Below are the child tags for MySQL:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<host>localhost</host>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: "localhost"
\end_layout

\begin_layout Standard
This specifies the host where your MySQL database is running.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<port>0</port>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: 0
\end_layout

\begin_layout Standard
This specifies the port where your MySQL database is running.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<username>root</username>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: "mediatomb"
\end_layout

\begin_layout Standard
This option sets the user name that will be used to connect to the database.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<password></password>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: no password
\end_layout

\begin_layout Standard
Defines the password for the MySQL user.
 If the tag doesn't exist MediaTomb will use no password, if the tag exists,
 but is empty MediaTomb will use an empty password.
 MySQL has a distinction between no password and an empty password.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<database>mediatomb</database>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: "mediatomb"
\end_layout

\begin_layout Standard
Name of the database that will be used by MediaTomb.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Subsubsection
Extended Runtime Options
\end_layout

\begin_layout Code
<extended-runtime-options>
\end_layout

\begin_layout Standard
These options reside under the server tag and allow to additinally control
 the so called "runtime options".
 The difference to the import options is:
\end_layout

\begin_layout Standard
Import options are only triggered when data is being imported into the database,
 this means that if you want new settings to be applied to already imported
 data, you will have to reimport it.
 Runtime options can be switched on and off without the need to reimport
 any media.
 Unfortunately you still need to restart the server so that these options
 take effect, however after that they are immediately active.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<ffmpegthumbnailer enabled="no">
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: no
\end_layout

\begin_layout Standard
Ffmpegthumbnailer is a nice, easy to use library that allows to generate
 thumbnails from video files.
 Some DLNA compliant devices support video thumbnails, if you think that
 your device may be one of those you can try enabling this option.
 It would also make sense to enable the protocolInfo option, since it will
 add specific DLNA tags to tell your device that a video thumbnail is being
 offered by the server.
\end_layout

\begin_layout Description
Note: thumbnails are not cached and not stored anywhere, they will be generated
 on the fly in memory and released afterwards.
 If your device supports video thumbnails and requests them from the server
 in large amounts, the performance when browsing video containers will depend
 on the speed of your machine.
 A feature to allow caching of thumbnails is planned for future releases.
\end_layout

\begin_layout Standard
The following options allow to control the ffmpegthumbnailer library (these
 are basically the same options as the ones offered by the ffmpegthumbnailer
 command line application).
 All tags below are optional and have sane default values.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<thumbnail-size>128</thumbnail-size>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: 128
\end_layout

\begin_layout Standard
The thumbnail size should not exceed 160x160 pixels, higher values can be
 used but will mostprobably not be supported by DLNA devices.
 The value of zero or less is not allowed.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<seek-percentage>5</seek-percentage>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: 5
\end_layout

\begin_layout Standard
Time to seek to in the movie (percentage), values less than zero are not
 allowed.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<filmstrip-overlay>yes</filmstrip-overlay>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: yes
\end_layout

\begin_layout Standard
Creates a filmstrip like border around the image, turn this option off if
 you want pure images.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<image-quality>8<image-quality>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: 8
\end_layout

\begin_layout Standard
Sets the image quality of the generated thumbnails.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<workaround-bugs>no</workaround-bugs>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: no
\end_layout

\begin_layout Standard
Accodring to ffmpegthumbnailer documentation, this option will enable workaround
s for bugs in older ffmpeg versions.
 You can try enabling it if you experience unexpected behaviour, like hangups
 during thumbnail generation, crashes and alike.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<mark-played-items enabled="no" suppress-cds-updates="yes">
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
The attributes of the tag have the following meaning:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
enabled=...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: no
\end_layout

\begin_layout Standard
Enables or disables the marking of played items, seto to "yes" to enable
 the feature.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
suppress-cds-updates=...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: yes
\end_layout

\begin_layout Standard
This is an advanced feature, leave the default setting if unsure.
 Usually, when items are modified we send out container updates as specified
 in the Content Directory Service.
 This notifies the player that data in a particular container has changed,
 players that support CDS updates will rebrowse the container and refresh
 the view.
 However, in this case we probably do not want it (this actually depends
 on the particular player implementation).
 For example, if we update the list of currently playing items, the player
 could interrupt playback and rebrowse the current container - clearly an
 unwatned behaviour.
 Because of this, we provide an option to suppress and not send out container
 updates - only for the case where the item is marked as "played".
 In order to see the changes you will have to get out of the current container
 and enter it again - then the view on your player should get updated.
\end_layout

\begin_layout Description
Note: some players (i.e.
 PS3) cache a lot of data and do not react to container updates, for those
 players it may be necessary to leave the server view or restart the player
 in order to update content (same as when adding new data).
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
The following tag defines how played items should be marked:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<string mode="prepend">* </string>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: * 
\end_layout

\begin_layout Standard
Specifies what string should be appended or prepended to the title of the
 object that will be marked as "played".
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
mode=...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: prepend
\end_layout

\begin_layout Standard
Specifies how a string should be added to the object's title, allowed values
 are "append" and "prepend".
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Subsection
Import Settings
\end_layout

\begin_layout Standard
The import settings define various options on how to aggregate the content.
\end_layout

\begin_layout Code
<import hidden-files="no">
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
This tag defines the import section.
\end_layout

\begin_layout Standard
Attributes:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
hidden-files=...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: no
\end_layout

\begin_layout Standard
This attribute defines if files starting with a dot will be imported into
 the database (
\begin_inset Quotes sld
\end_inset

yes
\begin_inset Quotes srd
\end_inset

).
 Autoscan can override this attribute on a per directory basis.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
Child tags:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<filesystem-charset>ISO-8859-1</filesystem-charset>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default:
\emph default
 
\emph on
if nl_langinfo() function is present, this setting will be auto detected
 based on your system locale, else set to ISO-8859-1
\end_layout

\begin_layout Standard
Defines the charset of the filesystem.
 For example, if you have file names in Cyrillic KOI8-R encoding, then you
 should specify that here.
 The server uses UTF-8 internally, this import parameter will help you to
 correctly import your data.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<metadata-charset>ISO-8859-1</metadata-charset>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default:
\emph default
 
\emph on
if nl_langinfo() function is present, this setting will be auto detected
 based on your system locale, else set to ISO-8859-1
\end_layout

\begin_layout Standard
Same as above, but defines the charset of the metadata (i.e.
 id3 tags, Exif information, etc.)
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<scripting script-charset="UTF-8">
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
Defines the scripting section.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
script-charset=...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: UTF-8
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
Below are the available scripting options:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<virtual-layout type="builtin">
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
Defines options for the virtual container layout; the so called 
\begin_inset Quotes sld
\end_inset

virtual container layout
\begin_inset Quotes srd
\end_inset

 is the way how the server organizes the media according to the extracted
 metadata.
 For example, it allows sorting audio files by Album, Artist, Year and so
 on.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
type=...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: builtin
\end_layout

\begin_layout Standard
Specifies what will be used to create the virtual layout, possible values
 are:
\end_layout

\begin_layout Itemize
builtin: a default layout will be created by the server
\end_layout

\begin_layout Itemize
js: a user customizable javascript will be used (MediaTomb must be compiled
 with js support)
\end_layout

\begin_layout Itemize
disabled: only PC-Directory structure will be created, i.e.
 no virtual layout
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
The virtual layout can be adjusted using an import script which is defined
 as follows:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<import-script>/path/to/my/import-script.js</import-script>
\end_layout

\begin_layout Standard

\emph on
Required if virtual layout type is 
\begin_inset Quotes sld
\end_inset

js
\emph default

\begin_inset Quotes srd
\end_inset


\end_layout

\begin_layout Standard

\emph on
Default:
\emph default
 
\emph on
${prefix}/share/mediatomb/js/import.js, where ${prefix} is your installation
 prefix directory.
\end_layout

\begin_layout Standard
Points to the script invoked upon media import.
 For more details read doc/scripting.txt
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<dvd-script>/path/to/my/import-dvd.js</dvd-script>
\end_layout

\begin_layout Standard

\emph on
Optional, only has effect when layout type is 
\begin_inset Quotes sld
\end_inset

js
\emph default

\begin_inset Quotes srd
\end_inset


\emph on
 and if MediaTomb was compiled with libdvdread support.
\end_layout

\begin_layout Standard

\emph on
Default:
\emph default
 
\emph on
${prefix}/share/mediatomb/js/import-dvd.js, where ${prefix} is your installation
 prefix directory.
\end_layout

\begin_layout Standard
Points to the script invoked upon import of DVD iso images.
 For more details read doc/scripting.txt
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<common-script>/path/to/my/common-script.js</common-script>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default:
\emph default
 
\emph on
${prefix}/share/mediatomb/js/common.js, where ${prefix} is your installation
 prefix directory.
\end_layout

\begin_layout Standard
Points to the so called common script - think of it as a custom library
 of js helper functions, functions added there can be used in your import
 and in your playlist scripts.
 For more details read doc/scripting.txt
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<playlist-script create-link="yes">/path/to/my/playlist-script.js</playlist-scrip
t>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default:
\emph default
 
\emph on
${prefix}/share/mediatomb/js/playlists.js, where ${prefix} is your installation
 prefix directory.
\end_layout

\begin_layout Standard
Points to the script that is parsing various playlists, by default parsing
 of pls and m3u playlists is implemented, however the script can be adapted
 to parse almost any kind of text based playlist.
 For more details read doc/scripting.txt
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
create-link=...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: yes
\end_layout

\begin_layout Standard
Links the playlist to the virtual container which contains the expanded
 playlist items.
 This means, that if the actual playlist file is removed from the database,
 the virtual container corresponding to the playlist will also be removed.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<magic-file>/path/to/my/magic-file</magic-file>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: System default
\end_layout

\begin_layout Standard
Specifies an alternative file for filemagic, containing mime type information.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<autoscan use-inotify="auto">
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
Specifies a list of default autoscan directories.
\end_layout

\begin_layout Standard
This section defines persistent autoscan directories.
 It is also possible to define autoscan directories in the UI, the difference
 is that autoscan directories that are defined via the config file can not
 be removed in the UI.
 Even if the directory gets removed on disk, the server will try to monitor
 the specified location and will re add the removed directory if it becomes
 available/gets created again.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
use-inotify=...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: auto
\end_layout

\begin_layout Standard
Specifies if the inotify autoscan feature should be enabled.
 The default value is "auto", which means that availability of inotify support
 on the system will be detected automatically, it will then be used if available.
 Setting the option to 'no' will disable inotify even if it is available.
 Allowed values: "yes", "no", "auto"
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
Child tags:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<directory location="/media" mode="timed" interval="3600"
\end_layout

\begin_layout Code
    level="full" recursive="no" hidden-files="no"/>
\end_layout

\begin_layout Code
<directory location="/audio" mode="inotify" 
\end_layout

\begin_layout Code
    recursive="yes" hidden-files="no"/>
\end_layout

\begin_layout Code
...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
Defines an autoscan directory and it's parameters.
\end_layout

\begin_layout Standard
The attributes specify various autoscan options:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
location=...
\end_layout

\begin_layout Standard

\emph on
Required
\end_layout

\begin_layout Standard
Absolute path to the directory that shall be monitored.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
mode=...
\end_layout

\begin_layout Standard

\emph on
Required
\end_layout

\begin_layout Standard
Scan mode, currently "inotify" and "timed" are supported.
 Timed mode rescans the given directory in specified intervals, inotify
 mode uses the kernel inotify mechanism to watch for filesystem events.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
interval=...
\end_layout

\begin_layout Standard

\emph on
Required for 
\begin_inset Quotes sld
\end_inset

timed
\begin_inset Quotes srd
\end_inset

 mode
\end_layout

\begin_layout Standard
Scan interval in seconds.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
level=...
\end_layout

\begin_layout Standard

\emph on
Required for 
\begin_inset Quotes sld
\end_inset

timed
\begin_inset Quotes srd
\end_inset

 mode
\end_layout

\begin_layout Standard
Either "full" or "basic".
 Basic mode will only check if any files have been added or were deleted
 from the monitored directory, full mode will remember the last modification
 time and re add the media that has changed.
 Full mode might be useful when you want to monitor changes in the media,
 like id3 tags and alike.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
recursive=...
\end_layout

\begin_layout Standard

\emph on
Required
\end_layout

\begin_layout Standard
Values of "yes" or "no" are allowed, specifies if autoscan shall monitor
 the given directory including all sub directories.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
hidden-files=...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default:
\emph default
 
\emph on
value specified in <import hidden-files=
\begin_inset Quotes srd
\end_inset


\begin_inset Quotes srd
\end_inset

/>
\end_layout

\begin_layout Standard
Allowed values: "yes" or "no", process hidden files, overrides the hidden-files
 value in the <import/> tag.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<mappings>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
Defines various mapping options for importing media, currently two subsections
 are supported.
\end_layout

\begin_layout Standard
This section defines mime type and upnp:class mappings, it is vital if filemagic
 is not available - in this case media type auto detection will fail and
 you will have to set the mime types manually by matching the file extension.
 It is also helpful if you want to override auto detected mime types or
 simply skip filemagic processing for known file types.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<extension-mimetype ignore-unknown="no" case-sensitive="no"> 
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
This section holds the file name extension to mime type mappings.
\end_layout

\begin_layout Standard
Attributes:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
ignore-unknown=...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default:
\emph default
 
\emph on
no
\end_layout

\begin_layout Standard
If ignore-unknown is set to "yes", then only the extensions that are listed
 in this section are imported.
 
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
case-sensitive=...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: no
\end_layout

\begin_layout Standard
Specifies if extensions listed in this section are case sensitive, allowed
 values are "yes" or "no".
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
Child tags:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<map from="mp3" to="audio/mpeg"/>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
Specifies a mapping from a certain file name extension (everything after
 the last dot ".") to mime type.
\end_layout

\begin_layout Description
Note: this improves the import speed, because invoking libmagic to discover
 the right mime type of a file is omitted for files with extensions listed
 here.
\end_layout

\begin_layout Description
Note: extension is case sensitive, this will probably need to be fixed.
 
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<mimetype-upnpclass> 
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
This section holds the mime type to upnp:class mappings.
 
\end_layout

\begin_layout Standard
Child tags:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<map from="audio/*" to="object.item.audioItem.musicTrack"/>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
Specifies a mapping from a certain mime type to upnp:class in the Content
 Directory.
 The mime type can either be entered explicitly "audio/mpeg" or using a
 wildcard after the slash "audio/*".
 The values of "from" and "to" attributes are case sensitive.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<mimetype-contenttype>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
This section makes sure that the server knows about remapped mimetypes and
 still extracts the metadata correctly.
 For example, we know that id3lib can only handle mp3 files, the default
 mimetype of mp3 content is audio/mpeg.
 If the user remaps mp3 files to a different mimetype, we must know about
 it so we can still pass this item to id3lib for metadata extraction.
\end_layout

\begin_layout Description
Note: if this section is not present in your config file, the defaults will
 be filled in automatically.
 However, if you add an empty tag, without defining the following <treat>
 tags, the server will assume that you want to have an empty list and no
 files will be process by the metadata handler.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<treat mimetype="audio/mpeg" as="mp3"/>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
Tells the server what content the specified mimetype actually is.
\end_layout

\begin_layout Description
Note: it makes no sense to define 'as' values that are not below, the server
 only needs to know the content type of the ones specified, otherwise it
 does not matter.
\end_layout

\begin_layout Standard
The 'as' attribute can have following values:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
mp3
\end_layout

\begin_layout Standard

\emph on
Default mimetype: audio/mpeg
\end_layout

\begin_layout Standard
The content is an mp3 file and should be processed by either id3lib or taglib
 (if available).
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
ogg
\end_layout

\begin_layout Standard

\emph on
Default mimetype: application/ogg
\end_layout

\begin_layout Standard
The content is an ogg file and should be processed by taglib (if available).
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
flac
\end_layout

\begin_layout Standard

\emph on
Default mimetype: audio/x-flac
\end_layout

\begin_layout Standard
The content is a flac file and should be processed by taglib (if available).
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
jpg
\end_layout

\begin_layout Standard

\emph on
Default mimetype: image/jpeg
\end_layout

\begin_layout Standard
The content is a jpeg image and should be processed by libexif (if available).
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
playlist
\end_layout

\begin_layout Standard

\emph on
Default mimetype: audio/x-mpegurl or audio/x-scpls
\end_layout

\begin_layout Standard
The content is a playlist and should be processed by the playlist parser
 script.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
pcm
\end_layout

\begin_layout Standard

\emph on
Default mimetype: audio/L16 or audio/x-wav
\end_layout

\begin_layout Standard
The content is a PCM file.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
avi
\end_layout

\begin_layout Standard

\emph on
Default mimetype: video/x-msvideo
\end_layout

\begin_layout Standard
The content is an AVI container, FourCC extraction will be attempted.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<library-options>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
This section holds options for the various supported import libraries, it
 is useful in conjunction with virtual container scripting, but also allows
 to tune some other features as well.
\end_layout

\begin_layout Standard
Currently the library-options allow additional extraction of the so called
 auxilary data (explained below) and provide control over the video thumbnail
 generation.
\end_layout

\begin_layout Standard
Here is some information on the auxdata: UPnP defines certain tags to pass
 along metadata of the media (like title, artist, year, etc.), however some
 media provides more metadata and exceeds the scope of UPnP.
 This additional metadata can be used to fine tune the server layout, it
 allows the user to create a more complex container structure using a customized
 import script.
 The metadata that can be extracted depends on the library, currently we
 support libebexif and libextractor, the libraries provide a default set
 of keys that can be passed in the options below.
 The data according to those keys will the be extracted from the media and
 imported into the database along with the item.
 When processing the item, the import script will have full access to the
 gathered metadata, thus allowing the user to organize the data with the
 use of the extracted information.
 A practical example would be: if have more than one digital camera in your
 family you could extract the camera model from the Exif tags and sort your
 photos in a structure of your choice, like:
\end_layout

\begin_layout Standard
Photos/MyCamera1/All Photos
\end_layout

\begin_layout Standard
Photos/MyCamera1/Date
\end_layout

\begin_layout Standard
Photos/MyCamera2/All Photos
\end_layout

\begin_layout Standard
Photos/MyCamera2/Date
\end_layout

\begin_layout Standard
etc.
\end_layout

\begin_layout Standard
Child tags:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<libexif>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
Options for the exif library.
\end_layout

\begin_layout Standard
Child tags:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<auxdata>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
Currently only adding keywords to auxdata is supported.
 For a list of keywords/tags see the libexif documentation.
 Auxdata can be read by the import java script to gain more control over
 the media structure.
\end_layout

\begin_layout Standard
Child tags:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<add-data tag="keyword1"/>
\end_layout

\begin_layout Code
<add-data tag="keyword2"/>
\end_layout

\begin_layout Code
...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
If the library was able to extract the data according to the given keyword,
 it will be added to auxdata.
 You can then use that data in your import scripts.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
A sample configuration for the example described above would be:
\end_layout

\begin_layout Code
<libexif>
\end_layout

\begin_layout Code
    <auxdata>
\end_layout

\begin_layout Code
        <add-data tag="EXIF_TAG_MODEL"/>
\end_layout

\begin_layout Code
    </auxdata>
\end_layout

\begin_layout Code
</libexif> 
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<id3>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
These options apply to id3lib or taglib libraries.
\end_layout

\begin_layout Standard
Child tags:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<auxdata>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
Currently only adding keywords to auxdata is supported.
 The keywords are those defined in the id3 specification, we do not perform
 any extra checking, so you could try to use any string as a keyword - if
 it does not exist in the tag nothing bad will happen.
 
\end_layout

\begin_layout Standard
Here is a list of possible keywords:
\end_layout

\begin_layout Standard
TALB, TBPM, TCOM, TCON, TCOP, TDAT, TDLY, TENC, TEXT, TFLT, TIME, TIT1,
 TIT2, TIT3, TKEY, TLAN, TLEN, TMED, TOAL, TOFN, TOLY, TOPE, TORY, TOWN,
 TPE1, TPE2, TPE3, TPE4, TPOS, TPUB, TRCK, TRDA, TRSN, TRSO, TSIZ, TSRC,
 TSSE, TYER, TXXX 
\end_layout

\begin_layout Standard
Child tags:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<add-data tag="TCOM"/>
\end_layout

\begin_layout Code
<add-data tag="TENC"/>
\end_layout

\begin_layout Code
...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
If the library was able to extract the data according to the given keyword,
 it will be added to auxdata.
 You can then use that data in your import scripts.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
A sample configuration for the example described above would be:
\end_layout

\begin_layout Code
<id3>
\end_layout

\begin_layout Code
    <auxdata>
\end_layout

\begin_layout Code
        <add-data tag="TENC"/>
\end_layout

\begin_layout Code
    </auxdata>
\end_layout

\begin_layout Code
</id3> 
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<libextractor>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
Options for the extractor library.
\end_layout

\begin_layout Standard
Child tags:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<auxdata>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
Currently only adding keywords to auxdata is supported.
 For a list of keywords/tags see the libextractor documentation.
\end_layout

\begin_layout Standard
Child tags:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<add-data tag="keyword1"/>
\end_layout

\begin_layout Code
<add-data tag="keyword2"/>
\end_layout

\begin_layout Code
...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
If the library was able to extract the data according to the given keyword,
 it will be added to auxdata.
 You can then use that data in your import scripts.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Subsubsection
Online Content Settings
\end_layout

\begin_layout Standard
This section resides under import and defines options for various supported
 online services.
\end_layout

\begin_layout Code
<online-content fetch-buffer-size="262144" fetch-buffer-fill-size="0">
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
This tag defines the online content section.
\end_layout

\begin_layout Standard
Attributes:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
fetch-buffer-size=...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: 262144
\end_layout

\begin_layout Standard
Often, online content can be directly accessed by the player - we will just
 give it the URL.
 However, sometimes it may be necessary to proxy the content through MediaTomb.
 This setting defines the buffer size in bytes, that will be used when fetching
 content from the web.
 The value must not be less than allowed by the curl library (usually 16384
 bytes).
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
fetch-buffer-fill-size=...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: 0 (disabled)
\end_layout

\begin_layout Standard
This setting allows to prebuffer a certain amount of data, given in bytes,
 before sending it to the player, this should ensure a constant data flow
 in case of slow connections.
 Usually this setting is not needed, because most players will anyway have
 some kind of buffering, however if the connection is particularly slow
 you may want to try enable this setting.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
Below are the settings for supported services.
\end_layout

\begin_layout Subsubsection
YouTube Service
\end_layout

\begin_layout Standard
MediaTomb allows you to watch YouTube videos using your UPnP device, you
 can specify what content you are interested in, we will import the meta
 data and present it in the database, so you can browse the content on your
 player just like you do it with your local data.
 
\end_layout

\begin_layout Description
WANING: by using this feature you may be violating the YouTube service terms
 and conditions: 
\begin_inset CommandInset href
LatexCommand href
target "http://www.youtube.com/t/terms"

\end_inset


\end_layout

\begin_layout Description
Note: we do not download/mirror the actual videos, we only get description
 of the content and present it in the database.
 The actual video is only streamed when you press play on your device.
 So, when we use the term 
\begin_inset Quotes sld
\end_inset

retrieve videos
\begin_inset Quotes srd
\end_inset

 we actually mean retrieving the video name, description and associated
 meta data, not the actual flv file.
\end_layout

\begin_layout Description
Note: so far we have not yet seen many devices that will natively support
 the .flv format, you will need to setup appropriate transcoding profiles
 to make use of the YouTube feature.
\end_layout

\begin_layout Code
<YouTube enabled="no" refresh="12600" update-at-start="yes" purge-after="1200000
" racy-content="exclude">
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
Options and setting for YouTube service support, the attributes are:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
enabled=...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: no
\end_layout

\begin_layout Standard
Enables or disables the service, allowed values are 
\begin_inset Quotes sld
\end_inset

yes
\begin_inset Quotes srd
\end_inset

 or 
\begin_inset Quotes sld
\end_inset

no
\begin_inset Quotes srd
\end_inset

.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
refresh=...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: 28800
\end_layout

\begin_layout Standard
Refresh interval in seconds, each time the interval elapses we will contact
 the YouTube server and fetch new meta data, presenting the changes in the
 database view.
 This allows you to stay up to date with what is available on YouTube, you
 probably should not need to update more than once per day, so specify a
 reasonably high value here.
 Setting the option to 0 (zero) disables automatic refreshing.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
purge-after=...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: 0 (disabled)
\end_layout

\begin_layout Standard
Time amount in seconds when data that has not been updated is considered
 old and can be purged from the database.
 This setting helps to prevent an endless filling of the database with YouTube
 meta data, the idea is the following: each video has a unique ID, during
 a refresh cycle the video meta data will be imported into the database
 and a time stamp will be added.
 Each refresh cycle we may encounter same content (i.e.
 nothing changed on the YouTube site), we will update the time stamp.
 However, if a particular video is no longer available on YouTube it will
 not be refreshed, once the time stamp exceeds the purge-after value we
 will remove the meta data for this particular video from the database.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
update-at-start=...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: no
\end_layout

\begin_layout Standard
This option defines if we will contact the service right after MediaTomb
 was started (about 10 seconds after start up) or if data should be fetched
 when the first refresh cycle kicks in.
 It may be useful if you frequently restart the server and do not want the
 content to be updated each time.
 Allowed values are 
\begin_inset Quotes sld
\end_inset

yes
\begin_inset Quotes srd
\end_inset

 or 
\begin_inset Quotes sld
\end_inset

no
\begin_inset Quotes srd
\end_inset

.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
racy-content=...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: exclude
\end_layout

\begin_layout Standard
Specifies if restricted content should be inclueded in the search results.
 The option will automatically be used with YouTube requests that support.
 By default restricted content is not included.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
Below are various options that allow you to define what content you are
 interested in.
\end_layout

\begin_layout Description
Note: all tags are optional and can occur more then once.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<standardfeed feed="top_rated" region-id="ru" time-range="today" start-index="1"
 amount="all"/>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
This tag tells us to retrieve one of the standard video feeds.
 It can appear more than once with different options (i.e.
 different feed and region settings).
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
feed=...
\end_layout

\begin_layout Standard

\emph on
Required
\end_layout

\begin_layout Standard
Definition of the standard feed that you are interested in, the allowed
 values are:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
top_rated
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
top_favorites
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
most_viewed
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
most_recent
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
most_discussed
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
most_linked
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
most_responded
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
recently_featured
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
watch_on_mobile
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
region-id=...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
Allows to get a standard feed for a specific region, the option is ignored
 for the watch_on_mobile standard feed.
\end_layout

\begin_layout Standard
Currently, the following region id's are supported:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
au
\end_layout

\begin_layout Standard
Australia
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
br
\end_layout

\begin_layout Standard
Brazil
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
ca
\end_layout

\begin_layout Standard
Canada
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
fr
\end_layout

\begin_layout Standard
France
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
de
\end_layout

\begin_layout Standard
Germany
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
gb
\end_layout

\begin_layout Standard
Great Britain
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
nl
\end_layout

\begin_layout Standard
The Netherlands
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
hk
\end_layout

\begin_layout Standard
Hong Kong
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
ie
\end_layout

\begin_layout Standard
Ireland
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
it
\end_layout

\begin_layout Standard
Italy
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
jp
\end_layout

\begin_layout Standard
Japan
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
mx
\end_layout

\begin_layout Standard
Mexico
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
nz
\end_layout

\begin_layout Standard
New Zealand
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
pl
\end_layout

\begin_layout Standard
Poland
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
ru
\end_layout

\begin_layout Standard
Russia
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
kr
\end_layout

\begin_layout Standard
South Korea
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
es
\end_layout

\begin_layout Standard
Spain
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
tw
\end_layout

\begin_layout Standard
Taiwan
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
us
\end_layout

\begin_layout Standard
United States
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
time-range=...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
Allows to specify a certain time range when retrieving the feed content.
 The time-range option is only supported for the following standard feeds:
 top_rated, top_favorites, most_viewed, most_discussed, most_linked and
 most_responded.
\end_layout

\begin_layout Standard
Following values are supported:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
all_time
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
today
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
this_week
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
this_month
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
start-index=...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
Starting index of the item in the list, useful if you want to skip the first
 xxx results, must be an integer value >= 1.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
amount=...
\end_layout

\begin_layout Standard
Amount of items to fetch, can be either an integer value or the keyword
 "all".
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<favorites user="mediatomb"/>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
Retrieves all favorites of the given user.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
user=...
\end_layout

\begin_layout Standard

\emph on
Required
\end_layout

\begin_layout Standard
Name of the YouTube user whose favorites should be fetched.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<subscriptions user="mediatomb"/>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
Retrieves all subscriptions of the given user.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
user=...
\end_layout

\begin_layout Standard

\emph on
Required
\end_layout

\begin_layout Standard
Name of the YouTube user whose subscriptions should be fetched.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<playlists user="mediatomb"/>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
Retrieve all playlists of the given user.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
user=...
\end_layout

\begin_layout Standard

\emph on
Required
\end_layout

\begin_layout Standard
Name of the YouTube user whose playlists should be fetched.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<uploads user="mediatomb" start-index="1" amount="all"/>
\end_layout

\begin_layout Standard

\emph on
Required
\end_layout

\begin_layout Standard
Retrieves videos that were uploaded by a specified user.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
user=...
\end_layout

\begin_layout Standard

\emph on
Required
\end_layout

\begin_layout Standard
Name of the YouTube user whose playlists should be fetched.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
start-index=...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
Starting index of the item in the list, useful if you want to skip the first
 xxx results, must be an integer value >= 1.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
amount=...
\end_layout

\begin_layout Standard
Amount of items to fetch, can be either an integer value or the keyword
 "all".
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Subsubsection
Weborama Service
\end_layout

\begin_layout Standard
MediaTomb allows you to access Weborama content and to play it on your device.
\end_layout

\begin_layout Description
Note: we do not download/mirror the actual audio files, we only get description
 of the content and present it in the database.
 The actual media is only streamed when you press play on your device.
 So, when we use the term "retrieve media" we actually mean retrieving the
 song name, description and associated meta data, not the actual audio file.
\end_layout

\begin_layout Code
<Weborama enabled="no" refresh="12600" update-at-start="no">
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
Options and settings for Weborama service support:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
enabled=...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: no
\end_layout

\begin_layout Standard
Enables or disables the service, allowed values are "yes" or "no".
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
refresh=...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: 28800
\end_layout

\begin_layout Standard
Refresh interval in seconds, each time the interval elapses we will contact
 the Weborama server and fetch new meta data, presenting the changes in
 the database view.
 This allows you to get new playlists and update the content that you want
 to play from Weborama.
 Setting the option to 0 (zero) disables automatic refreshing.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
update-at-start=...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: no
\end_layout

\begin_layout Standard
This option defines if we will contact the service right after MediaTomb
 was started (about 10 seconds after start up) or if data should be fetched
 when the first refresh cycle kicks in.
 It may be useful if you frequently restart the server and do not want the
 content to be updated each time.
 Allowed values are "yes" or "no".
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
The request for fetching particular content is described using the following
 tag:
\end_layout

\begin_layout Code
<playlist name="Dark" mood="dark" amount="5">
\end_layout

\begin_layout Standard
The attributes have the following meaning:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
name=...
\end_layout

\begin_layout Standard

\emph on
Required
\end_layout

\begin_layout Standard
Name of the request, this name will be used in the virtual layout when presentin
g the content.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
mood=...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
Defines the mood of the user, the returned content is filtered accordingly.
 Possible values are:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
calm-positive
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
positive
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
energetic-positive
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
calm
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
neutral
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
energetic
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
calm-dark
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
dark
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
energetic-dark
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
amount=...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: 200
\end_layout

\begin_layout Standard
Integer value, defining the number of songs that should be fetched for this
 request.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<type id="0">playlist</type>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
Type of the generated content.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
id=
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: 0
\end_layout

\begin_layout Standard
The value of the 
\emph on
id
\emph default
 parameter is tightly coupled to the 
\emph on
type
\emph default
 parameter which is described above.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<type id="0">playlist</type>
\end_layout

\begin_layout Standard
Id value of zero generates a random playlist.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<type id="playlist id">playlist</type>
\end_layout

\begin_layout Standard
Requests a playlist wich is identified by the playlist id which is passed
 via the 
\emph on
id
\emph default
 parameter.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<type id="song hash">audio</type>
\end_layout

\begin_layout Standard
Requests a particular song which is identified by the hash which is passed
 via the 
\emph on
id
\emph default
 parameter.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<type id="album id">album</type>
\end_layout

\begin_layout Standard
Requests a particular album which is identified by the album id which is
 passed via the 
\emph on
id
\emph default
 parameter.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
The allowed type values are:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
audio
\end_layout

\begin_layout Standard
The request delivers only one song, identified by the 
\emph on
id
\emph default
 parameter.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
playlist
\end_layout

\begin_layout Standard
The request delivers a users playlist, identified by the 
\emph on
id
\emph default
 parameter.
 If 
\emph on
id
\emph default
 is zero, then the request delivers content which is specified using the
 
\emph on
mood
\emph default
 and filter 
\emph on
parameters
\emph default
.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
album
\end_layout

\begin_layout Standard
The request delivers songs from a particular album, identified by the 
\emph on
id
\emph default
 parameter.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<filter>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
Allows to filter the returned content, this is especially useful when generating
 random playlists.
 Allowed subtags are:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<genres>genre1,genre2,genre3</genres>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
Allows to filter by one or more genres, multiple genres are separated by
 a comma.
 The list of supported genres is:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
electronic
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
alternative
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
jazz
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
metal
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
pop
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
punk
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
rhytm-and-blues
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
rap
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
reggae
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
rock
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
classic
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
soundtrack
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
retro
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
russian-rock
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
russian-pop
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
chanson
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
folk
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<sort user-id="username">all</sort>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
Additional criteria for content selection which is valued for a given user
 id.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
user-id=...
\end_layout

\begin_layout Standard
Weborama user id.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
The allowed sort parameters are:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
all
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
favorite
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
friends
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
uploaded
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
used_last
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Subsubsection
Apple Trailers Service
\end_layout

\begin_layout Standard
MediaTomb allows you to access Apple trailers content, depending on your
 device you may also need to enable transcoding - the trailers are provided
 as h264 in a quicktime container.
\end_layout

\begin_layout Description
Note: we do not download/mirror the actual video files, we only get description
 of the content and present it in the database.
 The actual media is only streamed when you press play on your device.
 So, when we use the term "retrieve media" we actually mean retrieving the
 media name, description and associated meta data, not the actual file.
\end_layout

\begin_layout Code
<AppleTrailers enabled="no" refresh="43200" update-at-start="no">
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
Options and settings for Apple Trailers support:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
enabled=...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: no
\end_layout

\begin_layout Standard
Enables or disables the service, allowed values are "yes" or "no".
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
refresh=...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: 43200 (every 12 hours)
\end_layout

\begin_layout Standard
Refresh interval in seconds, each time the interval elapses we will contact
 the Apple trailers server and fetch new meta data, presenting the changes
 in the database view.
 This allows you to update the content that you want to play from this service.
 Setting the option to 0 (zero) disables automatic refreshing.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
update-at-start=...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: no
\end_layout

\begin_layout Standard
This option defines if we will contact the service right after MediaTomb
 was started (about 10 seconds after start up) or if data should be fetched
 when the first refresh cycle kicks in.
 It may be useful if you frequently restart the server and do not want the
 content to be updated each time.
 Allowed values are "yes" or "no".
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Subsection
Transcoding Settings
\end_layout

\begin_layout Standard
The transcoding section allows to define ways on how to transcode content.
\end_layout

\begin_layout Code
<transcoding enabled="yes" fetch-buffer-size="262144" fetch-buffer-fill-size="0"
>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
This tag defines the transcoding section.
\end_layout

\begin_layout Standard
Attributes:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
enabled=...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: yes
\end_layout

\begin_layout Standard
This attribute defines if transcoding is enabled as a whole, possible values
 are 
\begin_inset Quotes sld
\end_inset

yes
\begin_inset Quotes srd
\end_inset

 or 
\begin_inset Quotes sld
\end_inset

no
\begin_inset Quotes srd
\end_inset

.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
fetch-buffer-size=...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: 262144
\end_layout

\begin_layout Standard
In case you have transcoders that can not handle online content directly
 (see the accept-url parameter below), it is possible to put the transcoder
 between two FIFOs, in this case MediaTomb will fetch the online content.
 This setting defines the buffer size in bytes, that will be used when fetching
 content from the web.
 The value must not be less than allowed by the curl library (usually 16384
 bytes).
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
fetch-buffer-fill-size=...
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: 0 (disabled)
\end_layout

\begin_layout Standard
This setting allows to prebuffer a certain amount of data before sending
 it to the transcoder, this should ensure a constant data flow in case of
 slow connections.
 Usually this setting is not needed, because most transcoders will just
 patiently wait for data and we anyway buffer on the output end.
 However, we observed that ffmpeg will fail to transcode flv files if it
 encounters buffer underruns - this setting helps to avoid this situation.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
Child tags:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<mimetype-profile-mappings>
\end_layout

\begin_layout Standard
The mime type to profile mappings define which mime type is handled by which
 profile.
 
\end_layout

\begin_layout Standard
Different mime types can map to the same profile in case that the transcoder
 in use supports various input formats.
 The same mime type can also map to several profiles, in this case multiple
 resources in the XML will be generated, allowing the player to decide which
 one to take.
\end_layout

\begin_layout Standard
The mappings under mimetype-profile are defined in the following manner:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<transcode mimetype="audio/x-flac" using="oggflac-pcm"/>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
In this example we want to transcode our flac audio files (they have the
 mimetype audio/x-flac) using the 
\begin_inset Quotes sld
\end_inset

oggflac-pcm
\begin_inset Quotes srd
\end_inset

 profile which is defined below.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
mimetype=...
\end_layout

\begin_layout Standard
Selects the mime type of the source media that should be transcoded.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
using=...
\end_layout

\begin_layout Standard
Selects the transcoding profile that will handle the mime type above.
 Information on how to define transcoding profiles can be found below.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<profiles>
\end_layout

\begin_layout Standard
This section defines the various transcoding profiles.
 
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<profile name="oggflag-pcm" enabled="yes" type="external">
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard
Definition of a transcoding profile.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
name=...
\end_layout

\begin_layout Standard

\emph on
Required
\end_layout

\begin_layout Standard
Name of the transcoding profile, this is the name that is specified in the
 mime type to profile mappings.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
enabled=...
\end_layout

\begin_layout Standard

\emph on
Required
\end_layout

\begin_layout Standard
Enables or disables the profile, allowed values are 
\begin_inset Quotes sld
\end_inset

yes
\begin_inset Quotes srd
\end_inset

 or 
\begin_inset Quotes sld
\end_inset

no
\begin_inset Quotes srd
\end_inset

.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
type=...
\end_layout

\begin_layout Standard

\emph on
Required
\end_layout

\begin_layout Standard
Defines the profile type, currently only 
\begin_inset Quotes sld
\end_inset

external
\begin_inset Quotes srd
\end_inset

 is supported, this will change in the future.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<mimetype>audio/x-wav</mimetype>
\end_layout

\begin_layout Standard

\emph on
Required
\end_layout

\begin_layout Standard
Defines the mime type of the transcoding result (i.e.
 of the transcoded stream).
 In the above example we transcode to PCM.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<accept-url>yes</accept-url>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: yes
\end_layout

\begin_layout Standard
Some transcoders are able to handle non local content, i.e.
 instead giving a local file name you can pass an URL to the transcoder.
 However, some transcoders can only deal with local files, for this case
 set the value to 
\begin_inset Quotes sld
\end_inset

no
\begin_inset Quotes srd
\end_inset

.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<first-resource>no</first-resource>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: no
\end_layout

\begin_layout Standard
It is possible to offer more than one resource in the browse result, a good
 player implementation will go through all resources and pick the one that
 it can handle best.
 Unfortunately most players only look at the first resource and ignore the
 rest.
 When you add a transcoding profile for a particular media type it will
 show up as an additional resource in the browse result, using this parameter
 you can make sure that the transcoded resource appears first in the list.
\end_layout

\begin_layout Description
Note: if more than one transcoding profile is applied on one source media
 type (i.e.
 you transcode an OGG file to MP3 and to PCM), and the first-resource parameter
 is specified in both profiles, then the resource positions are undefined.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<hide-original-resource>no</hide-original-resource>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: no
\end_layout

\begin_layout Standard
This parameter will hide the resource of the original media when sending
 the browse result to the player, this can be useful if your device gets
 confused by multiple resources and allows you to send only the transcoded
 one.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<accept-ogg-theora>no</accept-org-theora>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: no
\end_layout

\begin_layout Standard
As you may know, OGG is just a container, the content could be Vorbis or
 Theora while the mime type is 
\begin_inset Quotes sld
\end_inset

application/ogg
\begin_inset Quotes srd
\end_inset

.
 For transcoding we need to identify if we are dealing with audio or video
 content, specifying yes in this tag in the profile will make sure that
 only OGG files containing Theora will be processed.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<dvd-only>no<dvd-only>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: no
\end_layout

\begin_layout Standard
This is a special option which is related to DVD image support that is offered
 via libdvdnav.
 We encountered a problem that some devices fail to play the stream that
 we get from libdvdnav, for those devices remuxing to TS may be required.
 
\end_layout

\begin_layout Standard
This option allows to setup a transcoding profile that will only transcode
 streams coming from the DVD image.
 The option is needed to prevent transcoding of normal mpeg streams, without
 it those streams would also get transcoded because the settings are based
 on the mime type.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<avi-fourcc-list mode="ignore">
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: disabled
\end_layout

\begin_layout Standard
This option allows to specify a particular list of AVI fourcc strings that
 can be either set to be ignored or processed by the profile.
\end_layout

\begin_layout Description
Note: this option has no effect on non AVI content.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
mode=...
\end_layout

\begin_layout Standard

\emph on
Required
\end_layout

\begin_layout Standard
Specifies how the list should be handled by the transcoding engine, possible
 values are:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
"disabled"
\end_layout

\begin_layout Standard
The option is completely disabled, fourcc list is not being processed.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
"process"
\end_layout

\begin_layout Standard
Only the fourcc strings that are listed will be processed by the transcoding
 profile, AVI files with other fourcc strings will be ignored.
 Setting this is useful if you want to transcode only some specific fourcc's
 and not transcode the rest.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
"ignore"
\end_layout

\begin_layout Standard
The fourcc strings listed will not be transcoded, all other codecs will
 be transcoded.
 Setting this might be useful if you want to prevent a limited number of
 codecs from being transcoded, but want to apply transcoding on the rest
 (i.e.
 - do not transcode divx and xvid, but want to transcode mjpg and whatever
 else might be in the AVI container).
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
The list of fourcc strings is enclosed in the avi-fourcc-list section:
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<fourcc>XVID</fourcc>
\end_layout

\begin_layout Code
<fourcc>DX50</fourcc>
\end_layout

\begin_layout Standard
etc...
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<agent command="ogg123" arguments="-d wav -f %out %in/>
\end_layout

\begin_layout Standard

\emph on
Required
\end_layout

\begin_layout Standard
Defines the transcoding agent and the parameters, in the example above we
 use ogg123 to convert ogg or flac to wav.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
command=...
\end_layout

\begin_layout Standard

\emph on
Required
\end_layout

\begin_layout Standard
Defines the transcoder binary that will be executed by MediaTomb upon a
 transcode request, the binary must be in $PATH.
 It is very important that the transcoder is capable of writing the output
 to a FIFO, some applications, for example ffmpeg, have problems with that.
 The command line arguments are specified separately (see below).
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
arguments=...
\end_layout

\begin_layout Standard

\emph on
Required
\end_layout

\begin_layout Standard
Specifies the command line arguments that will be given to the transcoder
 application upon execution.
 There are two special tokens:
\end_layout

\begin_layout Code
%in
\end_layout

\begin_layout Code
%out
\end_layout

\begin_layout Standard
Those tokens get substituted by the input file name and the output FIFO
 name before execution.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<buffer size="1048576" chunk-size="131072" fill-size="262144"/>
\end_layout

\begin_layout Standard

\emph on
Required
\end_layout

\begin_layout Standard
These settings help you to achieve a smooth playback of transcoded media.
 The actual values need to be tuned and depend on the speed of your system.
 The general idea is to buffer the data before sending it out to the player,
 it is also possible to delay first playback until the buffer is filled
 to a certain amount.
 The prefill should give you enough space to overcome some high bitrate
 scenes in case your system can not transcode them in real time.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<itemizedlist><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
size=...
\end_layout

\begin_layout Standard

\emph on
Required
\end_layout

\begin_layout Standard
Size of the buffer in bytes.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
chunk-size=...
\end_layout

\begin_layout Standard

\emph on
Required
\end_layout

\begin_layout Standard
Size of chunks in bytes, that are read by the buffer from the transcoder.
 Smaller chunks will produce a more constant buffer fill ratio, however
 too small chunks may slow things down.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
fill-size=...
\end_layout

\begin_layout Standard

\emph on
Required
\end_layout

\begin_layout Standard
Initial fill size - number of bytes that have to be in the buffer before
 the first read (i.e.
 before sending the data to the player for the first time).
 Set this to 0 (zero) if you want to disable prefilling.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<resolution>320x240</resolution>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: not specified
\end_layout

\begin_layout Standard
Allows you to tell the resolution of the transcoded media to your player.
 This may be helpful if you want to generate thumbnails for your photos,
 or if your player has the ability to pick video streams in a particular
 resolution.
 Of course the setting should match the real resolution of the transcoded
 media.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<use-chunked-encoding>yes</use-chunked-encoding>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: yes
\end_layout

\begin_layout Standard
Specifies that the content should be sent out using chunked HTTP encoding,
 this is the default setting for transcoded streams, because the content
 length of the data is not known.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<sample-frequency>source</sample-frequency>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: source
\end_layout

\begin_layout Standard
Specifies the sample frequency of the transcoded media, this information
 is passed to the player and is particularly important when streaming PCM
 data.
 Possible values are: 
\emph on
source 
\emph default
(automatically set the same frequency as the frequency of the source content,
 which is useful if you are not doing any resampling)
\emph on
, off 
\emph default
(do not provide this information to the player)
\emph on
, frequency 
\emph default
(specify a fixed value, where 
\emph on
frequency
\emph default
 is a numeric value > 0)
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<audio-channels>source</audio-channels>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: source
\end_layout

\begin_layout Standard
Specifies the number of audio channels in the transcoded media, this information
 is passed to the player and is particularly important when streaming PCM
 data.
 Possible values are: 
\emph on
source 
\emph default
(automatically set the same number of audio channels as in the source content)
\emph on
, off 
\emph default
(do not provide this information to the player)
\emph on
, number 
\emph default
(specify a fixed value, where 
\emph on
number
\emph default
 is a numeric value > 0)
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem><listitem>
\end_layout

\end_inset


\end_layout

\begin_layout Code
<thumbnail>yes</thumbnail>
\end_layout

\begin_layout Standard

\emph on
Optional
\end_layout

\begin_layout Standard

\emph on
Default: no
\end_layout

\begin_layout Description
Note: this is an experimental option, the implementation will be refined
 in the future releases.
\end_layout

\begin_layout Standard
This is a special option which was added for the PS3 users.
 If the resolution option (see above) was set, then, depending on the resolution
 an special DLNA tag will be added, marking the resource as a thumbnail.
 This is useful if you have a transcoding script that extracts an image
 out of the video and presents it as a thumbnail.
\end_layout

\begin_layout Standard
Use the option with caution, no extra checking is being done if the resulting
 mimetype represents an image, also, it is will only work if the output
 of the profile is a JPG image.
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

</listitem></itemizedlist>
\end_layout

\end_inset


\end_layout

\begin_layout Section
Supported Devices
\end_layout

\begin_layout Paragraph*
Attention Hardware Manufacturers:
\end_layout

\begin_layout Standard
If you want to improve compatibility between MediaTomb and your renderer
 device or if you are interested in a port of MediaTomb for your NAS device
 please e-mail to: <contact at mediatomb dot cc>
\end_layout

\begin_layout Subsection
MediaRenderers
\end_layout

\begin_layout Standard
MediaTomb supports all UPnP compliant MediaRenderers, however there can
 always be various problems that depend on the particular device implementation.
 We always try to implement workarounds to compensate for failures and limitatio
ns of various renderers.
\end_layout

\begin_layout Standard
This is the list of client devices that MediaTomb has been tested with and
 that are known to work.
 Please drop us a mail if you are using MediaTomb with a device that is
 not in the list, report any success and failure.
 We will try to fix the issues and will add the device to the list.
\end_layout

\begin_layout Subsubsection
Acer
\end_layout

\begin_layout Itemize
AT3705-MGW
\end_layout

\begin_layout Subsubsection
Conceptronic
\end_layout

\begin_layout Itemize
C54WMP
\end_layout

\begin_layout Subsubsection
Denon
\end_layout

\begin_layout Itemize
AVR 4306
\end_layout

\begin_layout Subsubsection
D-Link
\end_layout

\begin_layout Itemize
DSM-320
\end_layout

\begin_layout Itemize
DSM-320RD
\end_layout

\begin_layout Itemize
DSM-510
\end_layout

\begin_layout Itemize
DSM-520
\end_layout

\begin_layout Standard
Some additional settings in MediaTomb configuration are required to enable
 special features for the DSM renderers.
 If you have a DSM-320 and are experiencing problems during AVI playback,
 add the following to the server section of your config.xml:
\end_layout

\begin_layout Code
<custom-http-headers>
\end_layout

\begin_layout Code
    <add header="X-User-Agent: redsonic"/>
\end_layout

\begin_layout Code
</custom-http-headers>
\end_layout

\begin_layout Standard
Further, the DSM-320 behaves differently if it thinks that it is dealing
 with the D-Link server.
 Add the following to the server section of your configuration to enable
 srt subtitle support:
\end_layout

\begin_layout Code
<manufacturerURL>redsonic.com</manufacturerURL>
\end_layout

\begin_layout Code
<modelNumber>105</modelNumber>
\end_layout

\begin_layout Standard
It is still being investigated, but we were able to get subtitles working
 with a U.S.
 DSM-320 unit running firmware version 1.09
\end_layout

\begin_layout Standard
Also, the DSM-510 (probably also valid for other models) will only play
 avi files if the mimetype is set to video/avi, you may want to add a mapping
 for that to the extension-mimetype section in your config.xml:
\end_layout

\begin_layout Code
<map from="avi" to="video/avi"/>
\end_layout

\begin_layout Subsubsection
Freecom
\end_layout

\begin_layout Itemize
MusicPal
\end_layout

\begin_layout Subsubsection
Häger
\end_layout

\begin_layout Itemize
OnAir (also known as BT Internet Radio)
\end_layout

\begin_layout Subsubsection
HP
\end_layout

\begin_layout Itemize
MediaSmart TV
\end_layout

\begin_layout Standard
Users reported that after a firmwre upgrade the device stopped working properly.
 It seems that it does not sue the UPnP Browse action anymore, but now uses
 the optional Search action which is not implemented in MediaTomb.
\end_layout

\begin_layout Subsubsection
I-O Data
\end_layout

\begin_layout Itemize
AVeL LinkPlayer2 AVLP2/DVDLA
\end_layout

\begin_layout Subsubsection
Linksys
\end_layout

\begin_layout Itemize
WMLS11B (Wireless-B Music System)
\end_layout

\begin_layout Itemize
KiSS 1600
\end_layout

\begin_layout Subsubsection
NeoDigits
\end_layout

\begin_layout Itemize
HELIOS X3000
\end_layout

\begin_layout Subsubsection
Netgear
\end_layout

\begin_layout Itemize
EVA700
\end_layout

\begin_layout Subsubsection
Philips
\end_layout

\begin_layout Itemize
Streamium SL-300i
\end_layout

\begin_layout Itemize
Streamium SL-400i
\end_layout

\begin_layout Itemize
Streamium MX-6000i
\end_layout

\begin_layout Itemize
SLA-5500
\end_layout

\begin_layout Itemize
SLA-5520
\end_layout

\begin_layout Subsubsection
Pinnacle
\end_layout

\begin_layout Itemize
ShowCenter 200
\end_layout

\begin_layout Itemize
SoundBridge
\end_layout

\begin_layout Subsubsection
Pioneer
\end_layout

\begin_layout Itemize
BDP-HD50-K
\end_layout

\begin_layout Itemize
BDP-94HD
\end_layout

\begin_layout Subsubsection
Roberts
\end_layout

\begin_layout Itemize
WM201 WiFi Radio
\end_layout

\begin_layout Standard
Playing OGG audio files requres a custom mimetype, add the following to
 the <extension-mimetype> section and reimport your OGGs:
\end_layout

\begin_layout Code
<map from="ogg" to="audio/ogg"/>
\end_layout

\begin_layout Standard
Also, add this to the <mimetype-contenttype> section:
\end_layout

\begin_layout Code
<treat mimetype="audio/ogg" as="ogg"/>
\end_layout

\begin_layout Subsubsection
Roku
\end_layout

\begin_layout Itemize
SoundBridge M1001
\end_layout

\begin_layout Itemize
SoundBridge M2000 
\end_layout

\begin_layout Subsubsection
Siemens
\end_layout

\begin_layout Itemize
Gigaset M740AV
\end_layout

\begin_layout Subsubsection
Sony
\end_layout

\begin_layout Itemize
Playstation 3
\end_layout

\begin_layout Standard
Firmware 1.80 introduces UPnP/DLNA support, add the following to the <server>
 section of your configuration file to enable MediaTomb PS3 compatibility:
\end_layout

\begin_layout Code
<protocolInfo extend="yes"/>
\end_layout

\begin_layout Subsubsection
T+A
\end_layout

\begin_layout Itemize
T+A Music Player
\end_layout

\begin_layout Subsubsection
Telegent
\end_layout

\begin_layout Itemize
TG100
\end_layout

\begin_layout Standard
The TG100 client has a problem browsing containers, where item titles exceed
 101 characters.
 We implemented a server-side workaround which allows you to limit the lengths
 of all titles and descriptions.
 Use the following settings in the <server> section of your configuration
 file:
\end_layout

\begin_layout Code
<upnp-string-limit>101</upnp-string-limit>
\end_layout

\begin_layout Subsubsection
TerraTec
\end_layout

\begin_layout Itemize
NOXON iRadio 
\end_layout

\begin_layout Itemize
NOXON 2 Audio 
\end_layout

\begin_layout Subsubsection
ZyXEL
\end_layout

\begin_layout Itemize
DMA-1000
\end_layout

\begin_layout Standard
Some users reported problems where the DMA will show an error 
\begin_inset Quotes sld
\end_inset

Failed to retrieve list
\begin_inset Quotes srd
\end_inset

 and the DMA disconnecting from the server.
 Incresing the alive interval seems to solve the problem - add the following
 option to the <server> section of your configuration file:
\end_layout

\begin_layout Code
<alive>600</alive>
\end_layout

\begin_layout Standard
Additionally, the DMA expects that avi files are serverd with the mime type
 of video/avi, so add the following to the <extensoin-mimetype> section
 in your configuration file:
\end_layout

\begin_layout Code
<map from="avi" to="video/avi"/>
\end_layout

\begin_layout Standard
Also, add this to the <mimetype-contenttype> section:
\end_layout

\begin_layout Code
<treat mimetype="video/avi" as="avi"/>
\end_layout

\begin_layout Subsection
Network Attached Storage Devices
\end_layout

\begin_layout Standard
We provide a bitbake metadata file for the OpenEmbedded environment, it
 allows to easily cross compile MediaTomb for various platforms.
 We have successfully tested MediaTomb on ARM and MIPSel based devices,
 so it should be possible to install and run the server on various Linux
 based NAS products that are available on the market.
\end_layout

\begin_layout Standard
So far two devices are shipped with a preinstalled version of MediaTomb,
 community firmware versions are available for the rest.
\end_layout

\begin_layout Subsubsection
Asus
\end_layout

\begin_layout Itemize
WL500g
\end_layout

\begin_layout Standard
Use the statically linked mips32el binary package that is provided on our
 download site.
\end_layout

\begin_layout Subsubsection
Buffalo
\end_layout

\begin_layout Itemize
KuroBox-HG
\end_layout

\begin_layout Itemize
LinkStation
\end_layout

\begin_layout Subsubsection
Excito
\end_layout

\begin_layout Itemize
Bubba Mini Server (preinstalled)
\end_layout

\begin_layout Subsubsection
Iomega
\end_layout

\begin_layout Itemize
StorCenter (preinstalled)
\end_layout

\begin_layout Subsubsection
Linksys
\end_layout

\begin_layout Itemize
NSLU2
\end_layout

\begin_layout Standard
Available via Optware.
\end_layout

\begin_layout Subsubsection
Maxtor
\end_layout

\begin_layout Itemize
MSS-I
\end_layout

\begin_layout Standard
Either use the Optware feeds or the statically linked mips2el binary package
 that is provided on our download site.
\end_layout

\begin_layout Subsubsection
Raidsonic
\end_layout

\begin_layout Itemize
IB-NAS4200-B
\end_layout

\begin_layout Standard
Use the statically linked binary armv4 package that is provided on our download
 site.
\end_layout

\begin_layout Subsubsection
Western Digital
\end_layout

\begin_layout Itemize
MyBook
\end_layout

\begin_layout Section
Running The Server
\end_layout

\begin_layout Standard
When you run MediaTomb for the first time a default configuration will be
 created in the ~/.mediatomb directory.
 If you are using the sqlite database no further intervention is necessary,
 if you are using MySQL you will have to make some adjustments (see Configuratio
n section for more details).
 To start the server simply run "mediatomb" from the console, to shutdown
 cleanly press Ctrl-C.
 At start up MediaTomb will print a link to the web UI.
\end_layout

\begin_layout Description
Note: Internet Explorer support is limited and not yet finished.
 It is very difficult to support this browser because of a huge number of
 bugs in its javascript implementation.
 If you don't believe us - just visit 
\begin_inset CommandInset href
LatexCommand href
name "http://selfhtml.org/"
target "http://selfhtml.org/"

\end_inset

 and see how often IE is mentioned in not following the specs or simply
 not working with certain functions and features.
 We recommend Firefox.
\end_layout

\begin_layout Standard
If you want to run a second server from the same PC, make sure to use a
 different configuration file with a different udn and a different database.
\end_layout

\begin_layout Standard
After server launch the bookmark file is created in the ~/.mediatomb directory.
 You now can manually add the bookmark ~/.mediatomb/mediatomb.html in your
 browser.
 This will redirect you to the UI if the server is running.
\end_layout

\begin_layout Standard
Assuming that you enabled the UI, you should now be able to get around quite
 easily.
\end_layout

\begin_layout Standard
We also support the daemon mode which allows to start the server in background,
 the --user and --group parameters should be used to run the server under
 an unprivileged account.
 A script for starting/stopping the server is provided.
 
\end_layout

\begin_layout Section
Legal
\end_layout

\begin_layout Paragraph*
THIS SOFTWARE COMES WITH ABSOLUTELY NO WARRANTY! USE AT YOUR OWN RISK! 
\end_layout

\begin_layout Subsection
Copyright
\end_layout

\begin_layout Paragraph*
Copyright (C) 2005 
\end_layout

\begin_layout Standard
Gena Batyan <bgeradz at mediatomb dot cc>
\end_layout

\begin_layout Standard
Sergey Bostandzhyan <jin at mediatomb dot cc> 
\end_layout

\begin_layout Paragraph*
Copyright (C) 2006-2008
\end_layout

\begin_layout Standard
Gena Batyan <bgeradz at mediatomb dot cc>
\end_layout

\begin_layout Standard
Sergey Bostandzhyan <jin at mediatomb dot cc>
\end_layout

\begin_layout Standard
Leonhard Wimmer <leo at mediatomb dot cc>
\end_layout

\begin_layout Subsection
License
\end_layout

\begin_layout Standard
MediaTomb is free software; you can redistribute it and/or modify it under
 the terms of the GNU General Public License version 2 as published by the
 Free Software Foundation.
 MediaTomb is distributed in the hope that it will be useful, but WITHOUT
 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
 FOR A PARTICULAR PURPOSE.
 See the GNU General Public License for more details.
 You should have received a copy of the GNU General Public License version
 2 along with MediaTomb; if not, write to the Free Software Foundation,
 Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.
\end_layout

\begin_layout Section
Acknowledgments
\end_layout

\begin_layout Standard
We are using the following code in our tree:
\end_layout

\begin_layout Itemize
uuid from E2fsprogs 1.35 under GNU GPL, Copyright (C) 1996, 1997, 1998 Theodore
 Ts'o.
 <tytso at mit dot edu> Some functions from the UPnP SDK were conflicting
 with libuuid, so we had to take the sources in and do some renaming.
\end_layout

\begin_layout Itemize
md5 implementation by L.
 Peter Deutsch <ghost at aladdin dot com>, Copyright (c) 1999 Aladdin Enterprise
s.
 All rights reserved.
 (See source headers for further details)
\end_layout

\begin_layout Itemize
md5 javascript implementation distributed under BSD License, Copyright (c)
 Paul Johnston 1999 - 2002.
 http://pajhome.org.uk/crypt/md5
\end_layout

\begin_layout Itemize
Prototype JavaScript Framework http://www.prototypejs.org/ (c) 2005-2007 Sam
 Stephenson, MIT-style license.
\end_layout

\begin_layout Itemize
(heavily modified version of) NanoTree http://nanotree.sourceforge.net/ (c)
 2003 (?) Martin Mouritzen <martin at nano dot dk>; LGPL
\end_layout

\begin_layout Itemize
IE PNG fix from http://webfx.eae.net/dhtml/pngbehavior/pngbehavior.html
\end_layout

\begin_layout Itemize
tombupnp is based on pupnp (http://pupnp.sf.net) which is based on libupnp
 (http://upnp.sf.net), originally distributed under the BSD license, Copyright
 (c) 2000-2003 Intel Corporation.
 Note that all changes to libupnp/pupnp code that were made by the MediaTomb
 team are covered by the LGPL license.
 
\end_layout

\begin_layout Itemize
ACX_PTHREAD autoconf script http://autoconf-archive.cryp.to/acx_pthread.html
 (c) 2006 Steven G.
 Johnson <stevenj at alum dot mit dot edu>
\end_layout

\begin_layout Itemize
The the Inotify::nextEvent() function is based on code from the inotify
 tools package, http://inotify-tools.sf.net/, distributed under GPL v2, (c)
 Rohan McGovern <rohan at mcgovern dot id dot au>
\end_layout

\begin_layout Section
Contributions
\end_layout

\begin_layout Itemize
Initial version of the MediaTomb start up script was contributed by Iain
 Lea <iain at bricbrac dot de> 
\end_layout

\begin_layout Itemize
TagLib support patch was contributed by Benhur Stein <benhur.stein at gmail
 dot com>
\end_layout

\begin_layout Itemize
ffmpeg metadata handler was contributed by Ingo Preiml <ipreiml at edu dot
 uni-klu dot ac dot at>
\end_layout

\begin_layout Itemize
ID3 keyword extraction patch was contributed by Gabriel Burca <gburca-mediatomb
 at ebixio dot com>
\end_layout

\begin_layout Itemize
tombupnp is kept in sync with the latest pupnp (http://pupnp.sf.net/) patches,
 see documentation in the tombupnp directory
\end_layout

\end_body
\end_document
