Serviio 1.4.1.2 package for Synology NAS

Serviio 1.4 in DSM Package Center

Many people are using the Synology packages I created for Serviio and Java, and most of them will have installed from my package repository making the upgrade possible with just one click.

This new version updates Serviio to version 1.4.1.2 (release notes). The Media Browser has been redesigned (Pro version feature), and is designed to allow direct playback of media on tablet devices without the need for dedicated apps. Please note that Apple iOS devices require video in H.264 and audio in stereo AAC format when streaming. Most Synology NAS models lack the CPU power to transcode video into H.264 and furthermore, licensing restrictions prevent distribution of an FFmpeg binary with libfdk_aac support. As a result, realtime AAC audio transcoding on older ARMv5 NAS models (which lack an FPU) is also out of reach, even if the source video is already H.264.

Renderers that do not natively support subtitles via DLNA can have them burned into the video during transcoding, but in general a NAS lacks the CPU power to do this (more info here). Please comment if this works nicely on the Intel or ARMv7 models. ARMv5 and PowerPC are confirmed to be too slow. If you absolutely need hard subs for a particular film, you could start playback on your device then stop it and Serviio will continue transcoding. Then you will be able to try again in a few hours since it will play from the transcode cache folder.

For burning subtitles into video streams the package downloads the free DejaVu font family from SourceForge during installation, since DSM does not include any fonts. Non-Latin character encodings should be supported as long as fonts with support are provided. The DejaVu font does not include support for Chinese glyphs for instance. You will need to copy new fonts to the folder /volume1/@appstore/Serviio/lib/dejavu-fonts-ttf-2.33/ttf.

I was able to compile FFmpeg 2.1 for all four supported architectures with libx264 and libass support (and dependent libraries) while using the libs included within DSM as far as possible. Only the Intel CPU will be of any practical use transcoding to H.264, since the other CPUs lack vector support (no AltiVec in QorIQ/PowerQUICC, and no NEON in Armada 370/XP).

As with the last few versions of the package, there is no Web UI included so I recommend that you manage Serviio using Serviio 1.4 Console installed on another computer. Integrating a Web UI into the package can be tricky because they do introduce problems of their own (bugs, browser incompatibilities), their development tends to lag behind the Serviio releases which can significantly delay my releases, and this also means I have to re-package as they get updated. Maintaining the CSS was also a lot of work. For the relatively small benefit the WebUI brings, it doesn’t really justify the effort. It only takes a few minutes to set up a remote console.

 

Instructions

The package can be installed on an unmodified NAS – no hacking is required.

  • Firstly, in the DSM User control panel enable the User Home service.
  • Open the DSM Package Center. In Settings -> Package Sources add my package repository URL which is http://packages.pcloadletter.co.uk
  • Install either one of my Java SE Embedded Synology packages (Java 6 or Java 7). Only Marvell Kirkwood, Marvell Armada 370/XP, Intel, and Freescale QorIQ PowerPC CPUs are supported, or PowerQUICC running DSM 5.0 or later, so please check which CPU your NAS has.
  • Install Serviio using DSM’s Package Center.
  • Download any Serviio online content plugins that you require and leave the .groovy files in your NAS’s /volume1/public/serviio/plugins folder (where /volume1 is you primary storage volume). This folder is created automatically by the package installer.
  • Download and install Serviio on another computer (selecting only the Console when prompted) and configure it to connect to your NAS:
    For Mac OS find Serviio-Console, right-click, then Show Package Contents. Use TextEdit to open Contents/info.plist and add this towards the end of the file after the last key and string entries (Properties section):
    <key>serviio.remoteHost</key>
    <string>192.168.1.100</string>

    ..replacing that IP with the IP of your NAS obviously. Then save, navigate back the Serviio folder and launch Serviio-Console again.
    On Windows, use Notepad to open ServiioConsole.exe.vmoptions (in the Serviio/bin folder) and add the line:
    -Dserviio.remoteHost=192.168.1.100
    On a Linux client, add this same parameter to the JAVA_OPTS in Serviio/bin/serviio-console.sh
    Do not make this change on the NAS – only on the computer that runs the console.
  • Since this console binding uses a static address you should reserve this particular IP address for your NAS (most home broadband routers will let you do this in the DHCP options), or use a static IP address. This will also prevent Serviio appearing multiple times in the menus of your renderer devices.
  • Once the remote console is connected be aware that everything it indicates relates to the NAS, *not* to the Serviio installation on your computer.
 

Notes

  • In the console disable ‘Generate thumbnails for local videos’ in the Metadata tab. Failure to do this will make adding videos to your library very slow. With this disabled Serviio will still fetch thumbnail images automatically from the online databases.
  • Don’t alter the transcoded files location on the Transcoding tab, it’s already set to a sensible location. This particular folder is deleted each time your NAS restarts, and Serviio cleans up its temp files automatically in any case.
  • When adding folders to the media library use the Add Path button (not Add Local). You will need to specify the folder path in the NAS’s Linux notation, for example /volume1/public/videos
  • Don’t forget to use the Users control panel in DSM to grant permission for the Serviio user to read your files (if they’re not in the public share).
  • When closing the Console, notice that ‘Exit Serviio’ quits the Console and also stops Serviio running on the NAS. To only quit the Console, be sure to select ‘Exit Serviio Console’ instead.
  • The package will allow future upgrades while preserving the media database, as long as Serviio itself is ok with that.
  • If you’re upgrading from a previous Serviio version you should update your online content plugins.
  • You can see Serviio’s log by clicking More in the Package Center.
  • The URL of the MediaBrowser is also displayed there (http://IPofYourNAS:23424/mediabrowser). If you want to use the MediaBrowser from a remote location you would need to either port forward 23424 on your router, or use SSH tunnelling. You can also manage Serviio remotely by SSH tunnelling port 23423 which the console uses.
  • If you have upgraded your DSM version and have lost unicode character support in Serviio, you will need to remove and reinstall the Java package which will fix the system locale support (DSM updates break this unfortunately).
  • Package Center installs the application to /volume1/@appstore/Serviio though from what I understand, on multi-volume systems the user is prompted for a destination volume. If you need to edit device profiles or enable debug logging then that’s where you’ll find the files. You will need to use an SSH session to access this folder – it’s not browsable in DSM’s File Station. The simplest way to edit these files if you’re not really confident with Linux is to install Merty’s Config File Editor package, which requires the official Synology Perl package to be installed too (since DSM 4.2). Load Config File Editor, then in the dropdown menu edit Config File Editor’s own config (it’s the last in the list) and add the lines:
    /volume1/@appstore/Serviio/config/profiles.xml,Serviio-profiles
    /volume1/@appstore/Serviio/config/log4j.xml,Serviio-logging

    Make sure to add an extra blank line underneath, save, then relaunch CFE and you’ll have an entry for Serviio in the dropdown. You’ll need to restart the Serviio package for any changes to take effect.
  • Bear in mind that a NAS, even an Intel Atom powered one, is unlikely to have sufficient CPU power to manage realtime video transcoding (e.g. from DivX to MPEG2), though it will manage remuxing MKV to M2TS and realtime audio transcoding. If you have a DLNA renderer with good format support then this isn’t an issue.
  • Unfortunately for this same reason the MediaBrowser is probably of limited value if you run Serviio on a NAS, since it uses realtime video transcoding, but I have nonetheless taken several steps to mitigate this. I have modified the FlowPlayer application profile to play AAC audio natively (you will only get the L+R channels from a multichannel file), and I have been able to integrate the integer maths libshine MP3 encoder into my build of FFmpeg for ARM CPUs, which allows you to listen to FLAC music transcoded to MP3 in realtime (useful for wifi music players for instance). I used a wrapper script to force libshine’s encoding bitrate to 320Kbps at all times since it didn’t increase the load, and it hides this simple encoder’s slight lack of quality. Source code for libshine is available here.
  • I have left the FFmpeg wrapper script in the package even when not in use (in the Serviio/bin folder), because it’s still useful for people trying to test a particular workaround or encoder setting. The wrapper was a really tricky script to get working due to variable expansion precedence issues and quote handling. If you need it, just change the ffmpeg.location system property in /volume1/@appstore/Serviio/bin/serviio.sh (changing the location to /volume1/@appstore/Serviio/bin/ffmpeg-wrapper.sh).
 

Package scripts

For information, here are the package scripts so you can see what it’s going to do. You can get more information about how packages work by reading the Synology Package wiki.

installer.sh

#!/bin/sh

#--------SERVIIO installer script
#--------package maintained at pcloadletter.co.uk

DOWNLOAD_PATH="http://download.serviio.org/releases"
DOWNLOAD_FILE="serviio-1.4.1.2-linux.tar.gz"
EXTRACTED_FOLDER="serviio-1.4.1.2"
DOWNLOAD_URL="${DOWNLOAD_PATH}/${DOWNLOAD_FILE}"
DAEMON_USER="`echo ${SYNOPKG_PKGNAME} | awk {'print tolower($_)'}`"
DAEMON_PASS="`openssl rand 12 -base64 2>/dev/null`"
DAEMON_ID="${SYNOPKG_PKGNAME} daemon user"
SYNO_CPU_ARCH="`uname -m`"
[ "${SYNO_CPU_ARCH}" == "x86_64" ] && SYNO_CPU_ARCH="i686"
NATIVE_BINS_URL="http://packages.pcloadletter.co.uk/downloads/serviio1.4-native-${SYNO_CPU_ARCH}.tgz"   
NATIVE_BINS_FILE="`echo ${NATIVE_BINS_URL} | sed -r "s%^.*/(.*)%\1%"`"
FONTS_URL="http://sourceforge.net/projects/dejavu/files/dejavu/2.33/dejavu-fonts-ttf-2.33.tar.bz2"
FONTS_FILE="`echo ${FONTS_URL} | sed -r "s%^.*/(.*)%\1%"`"
INSTALL_FILES="${DOWNLOAD_URL} ${NATIVE_BINS_URL} ${FONTS_URL}"

source /etc/profile
TEMP_FOLDER="`find / -maxdepth 2 -name '@tmp' | head -n 1`"
PUBLIC_FOLDER="`cat /usr/syno/etc/smb.conf | sed -r '/\/public$/!d;s/^.*path=(\/volume[0-9]{1,4}\/public).*$/\1/'`"
PLUGINS_PATH="/`echo $TEMP_FOLDER | cut -f2 -d'/'`/public/serviio"



preinst ()
{
  if [ -z ${JAVA_HOME} ]; then
    echo "Java is not installed or not properly configured. JAVA_HOME is not defined. "
    echo "Download and install the Java Synology package from http://wp.me/pVshC-z5"
    exit 1
  fi
  
  if [ ! -f ${JAVA_HOME}/bin/java ]; then
    echo "Java is not installed or not properly configured. The Java binary could not be located. "
    echo "Download and install the Java Synology package from http://wp.me/pVshC-z5"
    exit 1
  fi
  
  #is the User Home service enabled?
  UH_SERVICE=maybe
  synouser --add userhometest Testing123 "User Home test user" 0 "" ""
  UHT_HOMEDIR=`cat /etc/passwd | sed -r '/User Home test user/!d;s/^.*:User Home test user:(.*):.*$/\1/'`
  if echo $UHT_HOMEDIR | grep '/var/services/homes/' > /dev/null; then
    if [ ! -d $UHT_HOMEDIR ]; then
      UH_SERVICE=false
    fi
  fi
  synouser --del userhometest
  #remove home directory (needed since DSM 4.1)
  [ -e /var/services/homes/userhometest ] && rm -r /var/services/homes/userhometest
  if [ ${UH_SERVICE} == "false" ]; then
    echo "The User Home service is not enabled. Please enable this feature in the User control panel in DSM."
    exit 1
  fi
    
  cd ${TEMP_FOLDER}
  for WGET_URL in ${INSTALL_FILES}
  do
    WGET_FILENAME="`echo ${WGET_URL} | sed -r "s%^.*/(.*)%\1%"`"
    [ -f ${TEMP_FOLDER}/${WGET_FILENAME} ] && rm ${TEMP_FOLDER}/${WGET_FILENAME}
    wget ${WGET_URL}
    if [[ $? != 0 ]]; then
      if [ -d ${PUBLIC_FOLDER} ] && [ -f ${PUBLIC_FOLDER}/${WGET_FILENAME} ]; then
        cp ${PUBLIC_FOLDER}/${WGET_FILENAME} ${TEMP_FOLDER}
      else     
        echo "There was a problem downloading ${WGET_FILENAME} from the official download link, "
        echo "which was \"${WGET_URL}\" "
        echo "Alternatively, you may download this file manually and place it in the 'public' shared folder. "
        exit 1
      fi
    fi
  done

  exit 0
}


postinst ()
{
  #create serviio daemon user
  synouser --add ${DAEMON_USER} ${DAEMON_PASS} "${DAEMON_ID}" 0 "" ""
  
  #determine the serviio user homedir and save that variable in the user's profile
  #this is needed because librtmp needs to write a file called ~/.swfinfo
  #and new users seem to inherit a HOME value of /root which they have no permissions for
  DAEMON_HOME="`cat /etc/passwd | grep "${DAEMON_ID}" | cut -f6 -d':'`"
  su - ${DAEMON_USER} -s /bin/sh -c "echo export HOME=\'${DAEMON_HOME}\' >> .profile"
  
  #fontconfig configuration which is needed for libass subtitles
  su - ${DAEMON_USER} -s /bin/sh -c "echo export FONTCONFIG_FILE=fonts.conf >> .profile"
  su - ${DAEMON_USER} -s /bin/sh -c "echo export FONTCONFIG_PATH=${SYNOPKG_PKGDEST}/config/fonts >> .profile"

  #extract the downloaded Serviio archive
  cd ${TEMP_FOLDER}
  tar xzf ${TEMP_FOLDER}/${DOWNLOAD_FILE}
  rm ${TEMP_FOLDER}/${DOWNLOAD_FILE}
  cp -R ${TEMP_FOLDER}/${EXTRACTED_FOLDER}/* ${SYNOPKG_PKGDEST}
  if [ ! -z "${EXTRACTED_FOLDER}" ]; then
    rm -r ${TEMP_FOLDER}/${EXTRACTED_FOLDER}
  fi
  if [ ! -d "${PLUGINS_PATH}/plugins" ]; then
    mkdir -p ${PLUGINS_PATH}/plugins
  fi
  
  #extract CPU-specific additional binaries
  cd ${SYNOPKG_PKGDEST}/lib
  tar xzf ${TEMP_FOLDER}/${NATIVE_BINS_FILE} && rm ${TEMP_FOLDER}/${NATIVE_BINS_FILE}
  mv ${SYNOPKG_PKGDEST}/lib/ffmpeg ${SYNOPKG_PKGDEST}/bin
  ${SYNOPKG_PKGDEST}/bin/ffmpeg -version > /dev/null 2>&1 || (
    #this system is running an older DSM with missing dependencies, fetch more libs
    NATIVE_BINS_URL=`echo ${NATIVE_BINS_URL} | sed -e "s/.tgz/-oldDSM.tgz/"`
    NATIVE_BINS_FILE="`echo ${NATIVE_BINS_URL} | sed -r "s%^.*/(.*)%\1%"`"
    wget ${NATIVE_BINS_URL}
    tar xzf ${NATIVE_BINS_FILE} && rm ${NATIVE_BINS_FILE}
  )
  
  #extract open source font package for subtitle support during transcoding
  tar xjf ${TEMP_FOLDER}/${FONTS_FILE} && rm ${TEMP_FOLDER}/${FONTS_FILE}
  sed -i "s|WINDOWSFONTDIR|${SYNOPKG_PKGDEST}/lib/dejavu-fonts-ttf-2.33/ttf|" ${SYNOPKG_PKGDEST}/config/fonts/fonts.conf
  sed -i "s|WINDOWSTEMPDIR_FONTCONFIG_CACHE|~/.fontconfig.cache|" ${SYNOPKG_PKGDEST}/config/fonts/fonts.conf
   
  #wrapper script can be useful for testing different encoder options
  if [ "${SYNO_CPU_ARCH}" == "armv5tel" ]; then
    #we need to use the wrapper to make FFmpeg use libshine instead of libmp3lame on ARM systems
    FFMPEG_PATH="\$SERVIIO_HOME/bin/ffmpeg-wrapper.sh"
  else
    FFMPEG_PATH="\$SERVIIO_HOME/bin/ffmpeg"
  fi

  #modification to natively play AAC audio in Media Browser, minimizing transcoding
  mv ${SYNOPKG_PKGDEST}/application-profiles.xml ${SYNOPKG_PKGDEST}/config
  
  #set some additional Serviio system properties (temp folder, FFmpeg path, plugins folder)
  #http://www.serviio.org/index.php?option=com_content&view=article&id=43
  EXTRA_OPTS="-Dserviio\.defaultTranscodeFolder=${TEMP_FOLDER} -Dffmpeg\.location=${FFMPEG_PATH} -Dplugins\.location=${PLUGINS_PATH}"
  #fix Java prefs checking which was preventing NAS hibernation http://forum.serviio.org/viewtopic.php?f=5&t=6878
  EXTRA_OPTS="${EXTRA_OPTS} -Djava.util.prefs.syncInterval=86400"
  if [ "${SYNO_CPU_ARCH}" == "armv5tel" ]; then
    #use integer math (not floating point) Dolby AC-3 encoder for better performance on ARM CPUs
    #http://ffmpeg.org/ffmpeg.html#ac3-and-ac3_005ffixed
    EXTRA_OPTS="${EXTRA_OPTS} -Dserviio\.fixedPointEncoders"
  fi
  sed -r -i "s%^(JAVA_OPTS=.*)\"$%\1 ${EXTRA_OPTS}\"%" ${SYNOPKG_PKGDEST}/bin/serviio.sh
  
  #change owner of Serviio folder tree
  chown -R ${DAEMON_USER} ${SYNOPKG_PKGDEST}
    
  #reset ownership on any pre-existing transcoding temp folder
  if [ -d ${TEMP_FOLDER}/Serviio ]; then
    chown -R ${DAEMON_USER} ${TEMP_FOLDER}/Serviio
  fi
  
  exit 0
}


preuninst ()
{
  #make sure that daemon is stopped
  su - ${DAEMON_USER} -s /bin/sh -c "${SYNOPKG_PKGDEST}/bin/serviio-wrapper.sh -stop"
  sleep 6
  
  exit 0
}


postuninst ()
{
  #remove daemon user
  synouser --del ${DAEMON_USER}
  
  #remove daemon user's home directory (needed since DSM 4.1)
  [ -e /var/services/homes/${DAEMON_USER} ] && rm -r /var/services/homes/${DAEMON_USER}
  
  exit 0
}


preupgrade ()
{
  #make sure that daemon is stopped
  su - ${DAEMON_USER} -s /bin/sh -c "${SYNOPKG_PKGDEST}/bin/serviio-wrapper.sh -stop"
  sleep 6
  
  #if a media database exists we need to preserve it
  if [ -d ${SYNOPKG_PKGDEST}/library/db ]; then
    mkdir ${SYNOPKG_PKGDEST}/../${DAEMON_USER}_db_migration
    mv ${SYNOPKG_PKGDEST}/library/db ${SYNOPKG_PKGDEST}/../${DAEMON_USER}_db_migration
  fi
  
  exit 0
}


postupgrade ()
{
  #use the backed up media database from the previous version
  if [ -d ${SYNOPKG_PKGDEST}/../${DAEMON_USER}_db_migration/db ]; then
    mv ${SYNOPKG_PKGDEST}/../${DAEMON_USER}_db_migration/db ${SYNOPKG_PKGDEST}/library
    rmdir ${SYNOPKG_PKGDEST}/../${DAEMON_USER}_db_migration
    
    #daemon user has been deleted and recreated so we need to reset ownership (new UID)
    chown -R ${DAEMON_USER} ${SYNOPKG_PKGDEST}/library/db
  fi
  	
  #reset ownership on transcoding temp folder
  if [ -d ${TEMP_FOLDER}/Serviio ]; then
    chown -R ${DAEMON_USER} ${TEMP_FOLDER}/Serviio
  fi
  
  exit 0
}
 

start-stop-status.sh

#!/bin/sh

#--------SERVIIO start-stop-status script
#--------package maintained at pcloadletter.co.uk

DAEMON_USER="`echo ${SYNOPKG_PKGNAME} | awk {'print tolower($_)'}`"
DAEMON_ID="${SYNOPKG_PKGNAME} daemon user"
ENGINE_CFG="serviio.sh"
ENGINE_SCRIPT="serviio.sh"


daemon_status ()
{
  ps | grep "^ *[0-9]* ${DAEMON_USER} .*java" > /dev/null
}


case $1 in
  start)
    DAEMON_HOME="`cat /etc/passwd | grep "${DAEMON_ID}" | cut -f6 -d':'`"
    
    #set the current timezone for Java so that log timestamps are accurate
    #we need to use the modern timezone names so that Java can figure out DST
    SYNO_TZ=`cat /etc/synoinfo.conf | grep timezone | cut -f2 -d'"'`
    SYNO_TZ=`grep "^${SYNO_TZ}" /usr/share/zoneinfo/Timezone/tzname | sed -e "s/^.*= //"`
    grep "^export TZ" ${DAEMON_HOME}/.profile > /dev/null \
     && sed -i "s%^export TZ=.*$%export TZ='${SYNO_TZ}'%" ${DAEMON_HOME}/.profile \
     || echo export TZ=\'${SYNO_TZ}\' >> ${DAEMON_HOME}/.profile
    
    #set appropriate Java max heap size
    RAM=$((`free | grep Mem: | sed -e "s/^ *Mem: *\([0-9]*\).*$/\1/"`/1024))
    if [ $RAM -le 128 ]; then
      JAVA_MAX_HEAP=80
    elif [ $RAM -le 256 ]; then
      JAVA_MAX_HEAP=192
    elif [ $RAM -le 512 ]; then
      JAVA_MAX_HEAP=384
    #Serviio's default max heap is 512MB
    elif [ $RAM -gt 512 ]; then
      JAVA_MAX_HEAP=512
    fi
    sed -i -r "s/(^..JAVA.) -Xmx[0-9]+[mM] (.*$)/\1 -Xmx${JAVA_MAX_HEAP}m \2/" "${SYNOPKG_PKGDEST}/bin/${ENGINE_CFG}"
    su - ${DAEMON_USER} -s /bin/sh -c "${SYNOPKG_PKGDEST}/bin/${ENGINE_SCRIPT} &"
    exit 0
  ;;

  stop)
    su - ${DAEMON_USER} -s /bin/sh -c "${SYNOPKG_PKGDEST}/bin/${ENGINE_SCRIPT} -stop"
    sleep 6
    exit 0
  ;;

  status)
    if daemon_status ; then
      exit 0
    else
      exit 1
    fi
  ;;

  log)
    echo "${SYNOPKG_PKGDEST}/log/serviio.log"
    exit 0
  ;;

esac
 

ffmpeg-wrapper.sh

#!/bin/sh

#FFmpeg wrapper script to use libshine fixed point maths MP3 encoder on ARM CPUs
#as originally posted here: http://forum.serviio.org/viewtopic.php?f=7&t=6458

PARAMS=""
FFMPEG_BIN="ffmpeg"
INPUT=0
for PARAM in "$@"; do
  if [ ${INPUT} = 1 ]; then
    #the FFmpeg input filename/URL needs quotes adding back on
    #because it may contain spaces, and the shell has removed them
    PARAMS="${PARAMS} \"${PARAM}\""    
    INPUT=0
  else
    PARAMS="${PARAMS} ${PARAM}"
  fi
  if [ "${PARAM}" == "-i" ]; then
    #this loop is the -i parameter, the next loop will be the input filename/URL
    INPUT=1
  fi
done

#make libshine encoder substitution, 320kbps since it's no more expensive
if [ "${PARAMS}" != "${PARAMS/libmp3lame/}" ] || [ "${PARAMS}" != "${PARAMS/-f mp3/}" ]; then
  PARAMS="`echo ${PARAMS} | sed -r "s|libmp3lame|libshine|;s|-b:a [0-9]+k|-b:a 320k|"`"
fi

#make libfdk_aac encoder substitution, 128Kbps since we're usually transcoding to AAC stereo only
#if [ "${PARAMS}" != "${PARAMS/-c:a aac/}" ]; then
#  PARAMS="`echo ${PARAMS} | sed -r "s| aac -strict experimental | libfdk_aac |;s|-b:a [0-9]+k|-b:a 128k|"`"
#fi

#invoke FFmpeg
FOLDER="`dirname $0`"
echo "${FOLDER}/${FFMPEG_BIN} ${PARAMS}" > ${FOLDER}/../log/ffmpeg-wrapper.log
#need to use eval here otherwise the quotes aren't handled properly
#http://fvue.nl/wiki/Bash:_Why_use_eval_with_variable_expansion%3F
eval ${FOLDER}/${FFMPEG_BIN} ${PARAMS}

#return FFmpeg status
exit $?
 

Changelog:

  • 1.4.1.2-0026 Updated to Serviio 1.4.1.2
  • 1.4.1.1-0025 Updated to Serviio 1.4.1.1
  • 1.4.0-0024 Updated to Serviio 1.4
  • 1.3.1-0023 Updated to FFmpeg 2.1 stable release
  • 1.3.1-0022 Added support for Intel Atom Evansport and Armada XP CPUs in new DSx14 products
  • 1.3.1-0021 Fixed zlib linking issue in QorIQ and Intel builds of FFmpeg
  • 1.3.1-0020 Updated to Serviio 1.3.1
  • 1.2.1-0019 Added support for Armada370 SoC used in DS213j (ARMv7 CPU with FPU)
  • 1.2.1-0018 Updated to Serviio 1.2.1, recompiled FFmpeg to use the libRTMP source code from serviio.org for consistency
  • 1.2.0-0017 Updated to Serviio 1.2
  • 1.1.0-0016 Fixes for DSM 4.2
  • 1.1.0-015 Updated to Serviio 1.1, fixed garbled ac3 encoding issue on ARM CPUs by compiling FFmpeg natively, rather than cross compiling. Remember to update your computer’s Serviio Console to 1.1 before connecting to manage.
  • 1.0-014 Added support for Freescale QorIQ PowerPC CPUs used in some Synology x13 series products, switched to shared library compile of FFmpeg with some minor changes, ARM build now uses libshine encoder which allows realtime audio transcoding to MP3, edited FlowPlayer config to play AAC audio natively to make Media Browser more usable with online feed items.
  • 1.0-013 fixed a bug in the plugins folder creation, fixed deletion of home directories after user deletion (DSM 4.1)
  • 1.0-012 reduced Java prefs checking interval to once every 24 hours to allow the NAS to hibernate (was 30 seconds by default – remember to increase the time between library refreshes if you want hibernation)
  • 1.0-011 updated Serviio to 1.0.1, slightly altered how the plugins folder path is determined
  • 1.0-010 updated to Serviio 1.0, removed WebUI, FFmpeg wrapper no longer needed on ARM, plugins folder moved to /volume1/public/serviio/plugins to make adding/updating plugins easier
  • 0.6.2-009 installation fails unless User Home service is enabled, unified the installer scripts, merged ARM and Intel packages into one which downloads the FFmpeg binary separately, used integer maths Dolby AC-3 encoder on ARM systems (no floating point)
  • 0.6.2-008 fixed DST timezone support, installer no longer assumes /volume1 is primary storage volume
  • 0.6.2-007 updated Serviio to 0.6.2, kairoh’s WebUI to 0.6.2c, changed package to download Serviio from the official website during installation, temp path is set by default to /volume1/@tmp on first run, and finally some CSS improvements
  • 0.6.1-006 switched to kairoh’s Java WebUI, added timezone support, removed DSM icon when Serviio is not running, adjusted Java max heap size for systems with low RAM, specified FFmpeg path directly rather than creating a symlink in /bin so as not to interfere with other packages which may use different versions of FFmpeg
  • 0.6.0.1-005 added Web Station dependency, EULA dialog, and links for Web UI and user forum in More Info
  • 0.6.0.1-004 test for package repo to allow update notification
  • 0.6.0.1 v3 hopefully fixed an issue with the Serviio DSM icon in DSM 3.2 on NAS units without Optware installed
  • 0.6.0.1 v2 inclusion of a modified version of the PHP Web UI
  • 0.6.0.1 v1 new minor Serviio release with some updated international translations – will upgrade 0.6 preserving the media library
  • 0.6 v1 first public release
  • 0.6b4 v2 fixed permissions on transcode temporary folder following upgrade, avoiding the need for a reboot
  • 0.6b4 v1 added upgrade scripts to allow media database migration (install future packages over the top of this one – database is preserved)
  • 0.6b3c v2 fixed HOME env var for serviio user (to fix librtmp issues with BBC iPlayer) and removed the need to edit the passwd file to change the shell (safer)
  • 0.6b3c v1 initial spk test release

 
 
About these ads

857 thoughts on “Serviio 1.4.1.2 package for Synology NAS

  1. Chewie

    Gotcha. Will give that a try. Also solved the TV show issue! I tried a different XBMC media manager to re-scrape my TV Shows and that seemed to do the trick. They are now showing up in the Series folder. (I was using Vimediamanager on the Mac, and tried Media Central on Windows instead). Thanks again for your help, and for getting Serviio onto Synology, it’s light years ahead of the stock media manager.

    Reply
  2. cyb

    Hi,

    i have a synology 412+ and i can`t install java 6 embedded.. The 412+ has a new cpu platform “Cedarview” and i think this is the problem.. The Cedarview has its own gcc compiler package..
    Can you update your Java Package or what can i do that i can install seviio ?

    Reply
    1. patters Post author

      All Intel synos use either Pineview, Bromolow, or Cedarview CPUs, but please follow my instructions nonetheless. All three are Intel CPUs which will run both i686 or x86_64 code. Their only differences are in their support for CPU extensions like Hyperthreading, or AES in hardware, etc. – which make no difference to this software since it’s already compiled. The only stuff that’s used from that toolchain is the locale data files and two small binaries (locale and localedef) which just set up the locales for the system. Running the 32bit ones in this case is completely fine.

      The Java 6 package works on Cedarview.

      Reply
      1. cyb

        Hi,

        The DSM Package Center says “This Package can not be installed”
        I have downloaded “ejre-1_6_0_30-fcs-b12-linux-i586-headless-10_nov_2011.tar.gz” and “gcc420_glibc236_pineview.tgz” to the public folder…

        Best regards
        cyb

      2. patters Post author

        Very strange, but I have no way to test. That error message is not one I wrote into my scripts so it’s coming from Package Center. However, I have at least one confirmed Cedarview user using Java 6.
        See the conversation about Cedarview (search for the word) in the comments on the Java package page. You ought to post on that page, to keep things on topic:

        http://pcloadletter.co.uk/2011/08/23/java-package-for-synology/

      3. cyb

        Hi,

        hm, when i install java 6 it says “This Package can not be installed” but when i look in the Package Center, there is a Java 6 Package installed but not running !? But when i try to install seviio it can`t find the java package. I have no idea what I’m doing wrong..

        Best regards
        cyb

      4. TheNymf

        @cyb

        for the record; i think this was due to a nonset JAVA_HOME variable which points to the installed Java location. This will indeed be autoset on next reboot.

        GL

  3. Max

    ds212J DSM4.0

    stuck with installing java 6 or 7
    downloaded toolchain 4.0
    installer asking me for 3.1

    should i download toolchain 3.1?

    Reply
    1. patters Post author

      Yes. This is mentioned in the Instructions section of my blog post for the Java package (linked to from this Serviio guide).

      Reply
  4. Ian

    Hi
    Synology Media Server has failed with DSM 4.0, so I have now installed Serviio. This was painful as neither Java or Toolchain would install via Package Centre. Followed the instructions to download/install manually – then Serviio seemed to install ok.
    I can now see Serviio on my Samsung TV, but none of the folders have any content. This was the issue with the Synology Media Server!
    Serviio seems to ‘see’ my TV under Renderer Profile Status (green dot against IP address), but there is a question mark under Profile.
    If try to add a new device – and click Save – I get red error message “Cannot connect to Serviio server, it does not seem to be running. Exiting…
    Rest error to “status” : Internal Server Error (500)”
    Also – Java SE for Embedded 6 is “stopped” in Package Centre, with no option to “run”…?

    Any ideas what I need to do?
    Thanks.

    Win7/DS210j

    Reply
    1. patters Post author

      Java does not run as a service. It’s meant to be stopped (notice there’s no start option). This is mentioned on the Java package instructions page, and in the Info screen in Package Center. Regarding the install not being completely automatic – that’s by design, for legal reasons.

      As for Serviio, are you giving it a few minutes to start up and read the profiles, etc?

      If you can’t see either media server, then perhaps you have another problem (firewall perhaps?).

      Reply
      1. Ian

        Hi Patters,

        Thanks for your reply & explaining. Info screen in Package Centre? Where’s this? Do you mean the Help pages (clicking on the “?”). I can’t see any mention of Java in there.

        One of the Serviio instructions says to download the Java Synology package from from this link which doesn’t work http://wp-me/pvshc-z5.

        To be honest – I’m so fed up of this product I may shelve it till another DSM comes out. I’ve spent all day messing about now.

        Thanks again.

  5. Mobes

    Hi Patters,

    Just wanted to say a big thankyou from down under. Your instructions (followed to the letter) are working beautifully with a DS1010+ serving to an Australian Sony EX700 running the latest 2012 firmware.

    One thing I’m curious about is what is the best format to store video files on the synology for serving using serviio and a Sony Bravia. I ask because I was going to use eyetv to record some programs from a tv tuner and then transcode and place onto the synology (and delete the original files).

    I note 720p mkvs are playing beautifully so wondered if that was good or perhaps the Apple TV2 preset from handbrake ?

    Thanks
    Mobes

    Reply
    1. patters Post author

      Thanks for the feedback. I don’t think it would really matter which format really (MP4 or MKV), since as I remember the Bravia profile will remux H.264 in whichever container to MPEG-TS anyway, which is light work (remuxing is just repackaging the streams, not transcoding them). I guess picking AC-3 audio would reduce audio transcoding (instead of AAC), if you wanted to keep the syno’s activity to a minimum.

      Reply
  6. Chris

    Any idea why the settings in the UI revert back when I click on Save (ex: nb of cores) ?
    By the way, I had to uninstall previous Java version removing the folder and print in the file Profile.

    Reply
  7. Tony

    Hi
    I’ve setup my Synology DS1812+ with 0.6.2 as directed and everything seems to work (I’m only wanting to use it for photos) with the exception of displaying the photo’s full screen if the originals are big (small res are fine). I’ve seen details about a switch to use to allow larger jpegs to be displayed (be reducing the size on the fly) but can’t work out where / how to set this. Please can you help?
    Btw, this is streaming via WDTV Live, and using the WDTV live profile.

    Thanks

    Reply
    1. patters Post author

      I haven’t got that working either. I was trying to get NASA’s image of the day working and had the same issue. I think from memory that Zip believes it ought to work, but it didn’t for me. I would suggest you report it on the Serviio forums. Most of the focus has tended to be on video issues, so it’s very possible that this has been overlooked.

      Reply
    1. Andy Twed

      Managed to download and install this now.

      I created a Shared Folder called “public” on my disk station, and have placed a .groovy file in there (Channel4od.groovy). Then i installed and ran Serviio as per the instructions on here.

      On my TV (Toshiba) I can see the server is running, and can browse all of the empty folders “video/movies, video/directors, videos/latest, videos/online”…. but can’t see anything to do with streaming media from Channel 4 OD.

      How do I know that Serviio has successfully picked up the .groovy file?
      How can I browse 4OD content from my TV, if possible?

      Reply
  8. Nicolas

    Hello,

    on a DS1511+ with DSM 4.0 I installed your serviio package.
    But it refuses to detect my PS3, neither is it detected by the PS3.

    When I open the serviio window in DSM it states the upnp server is stopped, and it refuses to start whan I click on “start”.

    There is a message on top of the window :
    Cannot connect to Serviio server, it does not seem to be running. Exiting…
    Rest error to “status” : Internal Server Error (500)

    Any idea?

    Reply
      1. patters Post author

        Not really – there’s no progress indicator even with the proper remote client (rather than the WebUI). As long as you have disabled the video thumbnailing, and as long as you’re not trying to add a huge load of photos it should be pretty fast (like half and hour or something for my video library).

      2. patters Post author

        Not sure – I don’t have a PS3. Take a look at the Serviio forum. PS3MS does allow subs to be ‘burned in’ to a stream which is being transcoded which is something Serviio cannot do since it only uses FFmpeg for all its conversion (PS3MS uses FFmpeg, TSMuxer and MEncoder for some tasks). However, it’s possible that the PS3 does have some native subtitle support.

      3. Nicolas

        Unfortunately it doesn’t.
        Too bad, it’s really nice to have subtitles for some foreign movies… I still got to struggle to install pms then…

  9. uncola

    Nicolas I had that error “serviio doesn’t seem to be running” it was because I didn’t wait long enough for serviio to start up after installing it.. I waited a few minutes and tried opening the web gui for it and then it worked. I’m also running a 1511+ with dsm 4.0

    Reply
    1. uncola

      Oh I saw you fixed it by reinstalling.. you know I also reinstalled it too but assumed waiting longer before opening the webgui fixed it.. maybe it was reinstalling it after all

      Reply
  10. Litten

    hello there, i love the serviio package, it works really well.. only problem is ffmpeg cannot pass the dts track to my receiver.. i heard that PS3MediaServer can do this. I also tried (and failed) at getting this solution to work: http://www.markinthedark.nl/news/ubuntu-linux-unix/88-install-playstation-media-server-pms-on-a-synology-nas.html

    my question, is there any way could possibly be working on a package install for PS3MediaServer? It would be oh so cool if you do. Please try it!

    Reply
  11. Harvey King

    I have successfully installed Java6. When I tried to install Serviio package itself, I got this following error:

    Failed to download “Serviio”

    when I look at the /var/log/message on my DS211, , I got the following error:

    PkgSynoMan.cgi: PkgSynoMan.cpp:333 Failed to curl perform, code=56, err=Failure when receiving data from the peer

    Questions:
    1. does this package require cloud station to be enabled?
    2. what might be wrong with this? I have encountered this “failed to download” error message quite frequently, actually. In fact, this is the reason why I couldn’t install Java 7 package, I had to switch to Java 6 instead.

    your help is greatly appreciated.

    Reply
      1. Harvey King

        Dear Patter:

        no, it didn’t work neither. It did gave out more message, though:
        Failed to Install the package.

        There was a problem downloading ffmpeg-serviio0.6.2-arm-tgz from the download link, which was “http://dl.dropbox.com/u/1188556/blog/ffmpeg-serviio0.6.2-arm.tgz”

        I guess it’s dropbox that got overwhelmed?

        Harv

  12. timeflake

    Hello.
    I have trouble with disconnects while I browse my serviio server on the TV. There is no trouble playing a video file, when I find it. Also the video directory does seem to update with new files.
    All the log says on these disconnects is:
    “WARN [ResourceTransportRequestHandler] Error while processing resource, sending back 404 error. Message: /volume/video/videofile.avi”

    and after that just alot of
    “OutputTextReader] Error reading output of an external command: Stream closed”

    Is it an error on my side!? I might have cut the update of the media library short when serviio was first installed. Because I got impatient. could that be part of the problem!?
    Do you have any recommendation on how I can correct this problem
    Thank you for a wonderful product
    Sincerly
    Jonas

    Reply
    1. patters Post author

      Interrupting the library update process won’t be a problem – it just carries on where it left off, or will rescan eventually.

      Reply
      1. timeflake

        man I suck.. I meant to write that the library does NOT update…
        Also I forgot to include that I installed your package on a DS410J… but since you didn’t comment on the errors … should I ask on the serviio forums? or just shut up!?

  13. Gerald

    Hi Patters,

    I have tried everything to install your java package and serviio onto my 1511+ but java just gives me the ‘Failed to install the package.’ error. It says that the Java binary bundle not found and it was expecting the file /ejre-1_6_0_32-fcs-b05-linux-i586-headless-05_apr_2012.tar.gz. I’m not sure what else I can try. I’ve successfully installed all serviio and java on my ds211j but this has been frustrating on my 1511+ to say the least. What am I doing wrong and is there a way to manually do this? Thanks for all your help, you are awesome.

    G

    Reply
      1. patters Post author

        Sorry, I found that there had been a bug with Pacific and Atlantic timezones (I updated the Java package to correct this), but not with Eastern – so I’m not sure what is preventing it installing on your system. Some people did report getting an error, but that Java did nonetheless get installed. Is it not managing to do that at all on yours?

  14. matt

    Is anyone else having problems since the latest update? with folder/files with a ‘ in them not displaying?

    they worked fine before the update. but now they don’t show.

    it might also be worth noting that the upgrade failed in dramatic fashion as I did the update via the inbuilt synology upgrade notification. so didnt check here and realise i didn’t to download the latest version of java, which caused the installation to fail and serviio to be uninstalled/removed from the NAS.

    so downloaded the latest version of java and reinstalled. turned on the home service. and it all installed fine. now as mentioned above any folder or file that has a ‘ in it doesn’t show up.

    Reply
    1. patters Post author

      I would guess that the issue with apostrophe characters is likely to be a bug with the WebUI. Do you still get this issue if you install the Serviio Remote Console and configure it to connect to your NAS (instructions on the Serviio website, in the FAQ section)?

      Reply
      1. mattm

        I haven’t tried to configure the remote console, i’ll give it a try when I get home.

        Just so I am clear though, I only ever add the default video dir “volume1\video” in the WebUi under “Library” / “shared folders” so I never actually look for any of the sub video folders using the WebUi.

        Where I am getting the problem is when serviio is doing its media refresh and then I am accessing serviio via with my ps3/xbox/ipad it doesn’t show any folders with a ‘ in the name.

        if I access my video folder via the DSM file explorer and navigate to a \\synology_nas\video\ if I have any folders in there with a ‘ like matt’s they don’t show. if I rename them in the DSM to matts and tell serviio to do a force refresh. the folder shows up. by all DLNA media players.

        this also effects files as well as I had file that started “death’s door” changed it manually in the DSM file explorer to “deaths door” waited for a refresh and it then appeared to all the DLNA attached media players.

      2. patters Post author

        Hi – I think I may know why there’s a problem with apostrophes in filenames. It’s related to my FFmpeg wrapper script for ARM systems to change the ac3 encoder to the more efficient fixed point one. You have an ARM CPU, right? That would cause the ffmpeg -i 'filename' to fail when Serviio is inspecting the file as it’s adding it to the library. I’ll have to escape the quote characters.

      3. mattm

        It’s also probably worth mentioning that I made sure that serviio had full read write access to the “video” folder as well.

      4. matt

        Yeah i’m running am arm processor inan ds212j,

        thanks for the quick response and keep up the great work, its very much appreciated.

      5. kingk

        Think i have a similar problem with the ds212j – some files and folders not displaying. Is there something i’m supposed to change to correct this issue?

      6. kingk

        I dont think my problem is just to do with apostraphies. under my Video shared folder I have folders a-e, f-g etc. and only one of those folders is showing. Within that there are films missing as well (on both bravia tv downstairs and ps3). How do i force a library update so i can test out what’s going on? the automatic rescan doesnt seem to be working.

      7. kingk

        Well i solved that, but in the end the ds212j just proved unable to transcode without stuttering (even wired directly). Shame, i guess its not powerful enough.

  15. Pingback: Subsonic 4.7 beta 1 Synology package | eg-blog

  16. Livin

    patters,
    Will you be (please) creating a package with version 1.0 beta3? This beta has the webapp Media Browser in it and can be controlled over the web. This would be NICE!

    Reply
    1. patters Post author

      I won’t distribute packages for closed betas. You’ll have to wait until Serviio 1.0 is released I’m afraid.

      Reply
  17. Antonio

    Hi,
    I’m running DSM 3.2 on my DS211+ and I had serviio installed but I uninstalled it an now I cannot find it anymore in the package center as an available package.

    How should I proceed to install it again? Java is still installed.

    Thanks,
    Antonio.

    Reply
  18. geert

    I am also missing the package in package center. but I do see Crashplan there along with several others.

    For me, it was an upgrade that caused the package to disapear from the installed packages as the installation failed on User Home service being disabled.

    Now I can’t install it again after enabling the User Home service. Is there another way to get the package installed again?

    Reply
  19. geert

    fixed for me now. I was still running DSM 3.2. after upgrade to DSM 4.0 I could see serviio as available package.

    Reply
  20. Ian

    Thanks for all your work. I managed to install software and it worked to a degree. I was able to stream photos and music to my LG TV but I never managed to get videos to work. Whenever I selected the video folder it was empty. All permissions were set correctly but I could just not get videos to show. One strange thing was that if I added a folder with with photos in – this folder would show in the video folder even though I did not tick the video box.

    In the end I uninstalled it as I wanted to mainly use it for video and online content which I also never got towork.

    Cheers

    Ian

    Reply
  21. Vette

    Hi,
    I used the previous version and was very happy with it (thanks for your work).
    I reinstalled completely my 710+ (intel cpu, DSM 4.0 2228), so I tried to install the last version 6.2.
    Ok for Java (6). Ok for Serviio installation, Serviio is running. But, when I double click on the serviio icon, I only got a blank window. After few minutes I only receive a msg :
    A communication error occurred: “Operation timed out”
    I try to reinstall it, same behavior.
    The log stops when it started to look for media updates.
    It seems alive, because it founds media renderer I connect on the network.
    Any idea ?

    Reply
  22. Chris

    Hi Patters,

    Excellent work getting Serviio up and running on our synology boxes! Having a small problem at the moment, looks like http://pcloadletter.comlu.com is having problems as I can’t install Serviio. Had it up and running a couple of days ago but decided to re-install Serviio and last night and can’t connect to your URL (I can ping it though).
    Any help much appreciated.

    Cheers,

    Chris.

    Reply
  23. Paul

    Sorry if this has been answered already, but when I install the Serviio package and try and open it in DSM, it opens the window but inside it is a Firefox error: “This address is restricted. This address uses a network port which is normally used for purposes other than Web browsing. Firefox has cancelled the request for your protection.”.

    I am using in DSM 4.0-2228 on a DS212. How do I fix this problem please?

    Reply
  24. X S Inattar

    Hi,

    Just wanted to request you to take a look at some changes I made to your ffmpeg-wrapper.sh to enable support for Refresh.groovy that allows users to refresh the web resources directly from the client.

    I have added the details to Serviio Wiki: http://wiki.serviio.org/doku.php?id=refresh_on_demand_linux

    It would be great if you could incorporate this in your next version.

    Thanks.

    X S Inattar

    Reply
    1. patters Post author

      Hi – that does look interesting. I’ll try and find some time to have a look. I’d say now that I probably won’t include that fix enabled in my release since I’m going to keep it as standardized as possible with the main Serviio release going forward. I have decided to remove the WebUI since it often causes issues of its own and the benefit is really quite small. The wrapper script I wrote is no longer required for the fixed point encoders (new Serviio parameter) but I have decided to leave the wrapper in my package (disabled by default), because it’s useful for people to troubleshoot and test different FFmpeg parameters. What I can do is include your mod in there commented out so it’s pretty easy to enable for those that need it. Incidentally by using my wrapper script you actually have a bug in there which will fail for filenames containing apostrophe characters. You need to change line 12 to:
      PARAMS="${PARAMS} \"${PARAM}\""

      I didn’t update the package to correct this yet because Serviio 1.0 will be out fairly soon (it’s in RC at the moment).

      Reply
  25. Dmitry

    Hi Patters,

    I’m trying to use serviio0.6.2-009 on ds212j.
    I have a big CPU load (about100%) due to many thumb’s creation on my photos by serviio.
    Is it possible to turn off this?
    Second thing is that ffmpeg will be active as well, even get out on dlna client (my tv sony ex720).
    So, initially raised ffmpeg will be active till end of media. Is there any timeout in the config?

    Reply
    1. patters Post author

      Hi Dmitry, for FFmpeg transcoding Serviio has no way to tell whether your renderer device has stopped watching the stream so it will carry on until it has finished the whole file, or you start another playback with the same renderer (I think).

      As for the photos, yes it does seem very inefficient at doing this. I haven’t added my photos for this reason. Most of the development and testing focus for Serviio has been on video, so if you would like to improve the image side of things please do join the Serviio forums and suggest or test improvements.

      Reply
  26. Taddeo

    Can you please help me? I’ve installed Serviio but when I tried to change any settings it saves it but then it always revert it back to what is was?? why is that?? :( :( :( :(

    Reply
    1. patters Post author

      I believe that’s a bug with the WebUI when using the Internet Explorer browser. Try Firefox, Chrome or Safari. It’s for this reason that when Serviio 1.0 is released I’ll be dropping the WebUI from the package. There are too many issues.

      Reply
      1. Dmitry

        I have the same, pls try to wait sometime after saving via WEBUI (15-20 min, maybe before), then open WEBUI again. Your settings will be showing correctly (with your previous changes)

  27. Taddeo

    I’m getting the same problem even after 15-20 min…. is there any other way to control servio without the web ui? thanks

    Reply
    1. patters Post author

      Yep. Install Serviio on another computer, selecting Serviio Console only. On Mac OS find Serviio-Console, right-click, then Show Package Contents. Use TextEdit open Contents/info.plist and add this towards the end of the file after the last key and string entries (Properties section):

      <key>serviio.remoteHost</key>
      <string>192.168.1.100</string>

      ..replacing that IP with the IP of your NAS obviously. Then save.
      On Windows, use Notepad to open ServiioConsole.exe.vmoptions (in the Serviio/bin folder) and add the line:
      -Dserviio.remoteHost=192.168.1.100
      On a Linux client, add this same parameter to the JAVA_OPTS in bin/serviio-console.sh

      When you next launch the Serviio Console on this computer it will connect to the Serviio instance running on the NAS. It’s a few minutes’ work to set up but much more reliable.

      Reply
      1. Taddeo

        Thank you so much! I will try!
        Could you also please explain something to me…?
        Why can I play the same video directly from usb from my panasonic blueray player but not when streaming it with serviio?? what is the difference? is serviio changind the format of the video when streaming it? THANKS!!!!

      2. patters Post author

        Possibly. Sometimes the players have different supported formats via DLNA than from USB. I have mostly been involved with Serviio’s Sony device profiles so I’m not familiar with the Panasonic ones but there could very well be room for improvement. Have a look at the Serviio forum, and there are some FAQ/wiki things explaining how the device profiles work.

      3. Taddeo

        Thanks so much for the info! I’ll try to read all that I can to gain more knowledge! So do you use your synology box as a media center with serviio?, what about the internal media server no good at all? And is serviio better than twonky? Can we install twonky on the synology?
        Thanks again

  28. winxi

    hi patters! inspired by your great packages i’m about to build synology packages for ‘bubbleupnp server’ and ‘MinimServer’. with the former i’m nearly done. i have adopted a lot of your Serviio- scripts and even copied some parts (e.g. the check for java installation, check for user home service, creation of the daemon user, passgen). It really works great. would you permit a distribution of these packages at the developer’s websites? of course, in the documentation and the scripts itself, i would point to you and your great blog.
    cheers, winxi

    Reply
    1. patters Post author

      Yes that’s absolutely fine, and thank you for asking. I would appreciate a comment and link in the code, as you already suggested. I’d advise that you look at my CrashPlan package perhaps more than the Serviio 0.6.2 one, because it represents my most ‘modern’ one. I’ve imitated the style of the SuperZebulon ones – i.e. the concatenation of most of the individual scripts into a single installer.sh since it’s way easier to maintain (variables defined at the top, etc.), and also the merging of the different CPU architectures into a single package. This also has the advantage that if one day you no longer want to maintain them, they can quite easily be turned over to the SynoCommunity repository which also uses this style.

      Reply
  29. jjLDN

    Simple tutorial about connecting using the console would be helpfull. I am lost and I don’t know what to do. Linked above thread is not really helpfull.
    As far as I am aware version 1.0 doesn’t come with any webui,l which for now makes the package useless for me.

    Reply
  30. batserra

    Hi thanks for new package ,but i can not install it, always i recive a error like java is not installed or properly configurated, JAVA_HOME is not defined and a link to wp.me/pVshC-z5.
    I tryed to uninstall serviio ,uninstall all java ,restart ,install again java, restart and try to install again serveiio but always the same error. How can i fix it?
    I’m with latest beta SM ,with a 110j nas.

    Thanks a lot….

    Reply
    1. batserra

      Fixed… i don’t know how… i think that after i installed java 7

      But now ,how i can enter to mediabrowser??? ,say that i need a passowrd from console ,but i can enter to console…thanks for your answer..

      Reply
  31. Mike

    Please integrate the console for the NAS as it was in Version 0.6.1. That was good. I dont like it all how it ist now.

    Reply
    1. patters Post author

      I have explained my reasons and I’m not going to do it I’m afraid. Besides, kairoh who made the Java WebUI hasn’t actually made one for Serviio 1.0.

      Reply
  32. batserra

    Very good,

    Excuse me but I’m not doing wrong, do not know how to enable the console.
    I entered my nas through the program WinSCP and Serviio I edited the file / bin / serviio-console.sh with the-Dserviio.remoteHost = “The ip of my nas”.
    I turned off the service and I Back home to raise. But do not know how to access the console because I do not see anywhere.
    I tried to enter through Ip: 23424/mediabrowser and I have put the administrator password, but it says you have to first enter the console and change it.

    What am I doing wrong? and excuse me …

    Thank you …

    Reply
    1. The Future will be to go staps back :)

      You have to that action where the console is installed. And the NAS will not have any console anymore. Sad but true.

      Reply
    2. patters Post author

      The serviio.remoteHost parameter is something you change on the PC or Mac that you run the Console on. Not the NAS. I have updated the instructions to make that clearer.

      Reply
      1. batserra

        Thanks !!! sorry about my english ,i didn’t know that i have to donwload any Serviio from http://www.serviio.org to configure it.

        Now another question ,now i have changed folders ,etc… ,when i star my nas ,always i have to have my computer on? Or all changes that i have done are saved to my nas?

        Thanks again….

      2. patters Post author

        No problem. I’ve made that a little clearer now in the instructions.

        The NAS remembers all the settings and carries on running Serviio. Be careful to exit the Console using “Exit Serviio Console”, and not “Exit Serviio” (which stops Serviio on the NAS too).

        You’re just using the console to make changes to the settings, but the NAS is doing all the work.

      3. batserra

        thanks…

        I have to enable transcode? ,and also in the Transcoding tab in to transcode files location i have to have c:\windows\temp or /volume1/@tmp ??

      4. patters Post author

        Yes you want transcoding enabled (though your NAS won’t be able to cope with video transcoding).
        And it should indeed be /volume1/@tmp

        Remember – everything you see in the console relates to the NAS (not your PC). So any folders you add to the library will need expressing in the NAS style e.g. /volume1/public/movies
        You’ll need to use the Add Path button, not Add Local.

        Your comments are useful feedback for me to improve the instructions, so do ask if you need any more help.

  33. jjLDN

    @patters
    Thank you for making the instructions clearer. Now, they are really helpfull. I found some sort of problem though. Even though I am sure I’ve got port TCP8895 and 1900 UDP opened in firewall, the console is not able to connect, but when I switch off the firewall in DSM the immediately console is connected to serviio server. I am using DSM 4.1 beta now, maybe that’s the problem? Or are there any other ports they need to be opened. One of those I know i 23424 for mediabrowser. Is there anything else?

    Reply
      1. jjLDN

        Ok. It works. So it means we should take care of ports 8895,23423,23424 TCP and 1900 UDP and make sure they are all open.
        Thank you :)

  34. apotts

    Patters,

    Very nice job. Just pressed update, got a couple of errors at the end so re-booted the NAS and all seems to be well (so far – it’ll take at least overnight to re-index).

    Good clear instructions too – thank you for all the work you put into this.

    Reply
  35. deadlyporpoise

    Hi,

    I’ve successfully got the console installed on my Windows 7 laptop, as I’m hoping that running the transcoding on another machine will improve performance (my DS212J just can’t cope with the higher quality files, lots of stuttering!)

    However, I’m struggling to work out how to grant user access to the Synology box. I’ve added the matching user account credentials to the User group in the DSM, but checking the log files returns the details as below.

    2012-07-29 12:00:43,536 INFO [RendererManager] Stored a new renderer: uuid=’f3f77ad9-a0b4-46d6-861a-793401f9a50a’, name = ‘Panasonic Viera (2010)’, ipAddress=’192.XXX.X.XX’, profile = ‘viera2010′
    2012-07-29 12:00:46,853 INFO [RendererManager] Stored a new renderer: uuid=’4d454930-0100-1000-8001-04209a691ee6′, name = ‘Panasonic VIErA’, ipAddress=’192.XXX.X.XX’, profile = ‘viera2011′
    2012-07-29 12:01:43,977 INFO [RendererManager] Stored a new renderer: uuid=’0e488a19-63d7-4290-9807-41de16834615′, name = ‘Panasonic Viera (2010)’, ipAddress=’192.XXX.X.XX’, profile = ‘viera2010′
    2012-07-29 12:03:29,164 WARN [LibraryAdditionsCheckerThread] Folder ‘\\DISKSTATION212J\movies’ is either not an existing directory or cannot be read due to access rights
    2012-07-29 12:08:07,556 INFO [DiscoveryAdvertisementNotifier] Leaving DiscoveryAdvertisementNotifier
    2012-07-29 12:08:07,574 INFO [WebServer] WebServer shutting down
    2012-07-29 12:08:07,575 INFO [DiscoverySSDPMessageListener] Leaving DiscoverySSDPMessageListener
    2012-07-29 12:08:07,577 INFO [EventDispatcher] Leaving EventDispatcher
    2012-07-29 12:08:07,586 INFO [EventSubscriptionExpirationChecker] Leaving EventSubscriptionExpirationChecker, removing all event subscriptions
    2012-07-29 12:08:09,702 INFO [WebServer] WebServer starting on port 8895
    2012-07-29 12:08:09,704 INFO [DiscoveryAdvertisementNotifier] Starting DiscoveryAdvertisementNotifier
    2012-07-29 12:08:09,704 INFO [RendererSearchSender] Searching for Renderer devices
    2012-07-29 12:08:09,704 INFO [EventSubscriptionExpirationChecker] Starting EventSubscriptionExpirationChecker
    2012-07-29 12:08:09,708 INFO [EventDispatcher] Starting EventDispatcher
    2012-07-29 12:08:09,809 INFO [DiscoverySSDPMessageListener] Starting DiscoverySSDPMessageListener using interface eth3 (Realtek RTL8101E Family PCI-E Fast Ethernet NIC (NDIS 6.20)) and address 192.168.2.11, timeout = 0
    2012-07-29 12:08:11,374 INFO [RendererManager] Stored a new renderer: uuid=’4d454930-0100-1000-8001-04209a691ee6′, name = ‘Panasonic VIErA’, ipAddress=’192.XXX.X.XX’, profile = ‘viera2011′
    2012-07-29 12:08:11,915 INFO [RendererExpirationChecker] Leaving RendererExpirationChecker
    2012-07-29 12:08:24,274 INFO [RendererManager] Stored a new renderer: uuid=’8749ca89-2fc4-4ac2-8dab-73b76ea075c4′, name = ‘Panasonic Viera (2010)’, ipAddress=’192.XXX.X.XX’, profile = ‘viera2010′
    2012-07-29 12:08:29,223 WARN [LibraryAdditionsCheckerThread] Folder ‘\\DISKSTATION212J\movies’ is either not an existing directory or cannot be read due to access rights
    2012-07-29 12:08:41,925 WARN [ServiioStatusService] AuthenticationException occured. Returning error code 401 to the REST layer. Message: Cannot log in with an empty password.
    2012-07-29 12:13:29,284 WARN [LibraryAdditionsCheckerThread] Folder ‘\\DISKSTATION212J\movies’ is either not an existing directory or cannot be read due to access rights

    If you could provide an idiots guide to how to grant a Windows User account remote access to the DSM, that would be awesome, as I’m sure there will be lots of people using a remote machine to handle the transcoding for files held remotely.

    Many thanks!

    Reply
  36. tomtom2000

    I have a DS212j and tried to install this. I have put the ejre-7u4-fcs-b20-linux-arm-sflt-headless-12_apr_2012.tar.gz file in public folder,but I keep getting told that java 6 or 7 can’t see it in their and needs it to run.

    I have downloaded a few versions from Java and other sites. The version I downloaded from the tinyurl is different from the one requested.

    I have DSM 4 and am not sure what else to try.

    Thanks
    TOm

    Reply
  37. Niels-e

    Hi, first of all thanks for this great package!

    Secondly, I’ve just upgraded to the 4.1 beta firmware and now it seems that the package doesn’t install the right way. It won’t make a shortcut in the menu and doesn’t make any servio folder in the public folder on volume1. The web interface works tho.

    Any thoughts?

    Reply
  38. Zorya

    Hello everyone and thank you for all your great stuff.

    I love Serviio 0.6.2 but I don’t want to upgade to the version 1.0 now (as my current release is very stable and I’m not interressed by new features). So I’m affraid to clic on the “update” button by mistake.
    In case of, is there a way to downgrade from 1.0 to 0.6.2?

    Also, can I download somewhere the syno package (spk release 0.6.2) for an offline installation?

    Zo.

    Reply
  39. Gonza

    Hi. I was wondering about the impact of running this DLNA server on a Synology DS212j. The NAS for itself have a very limited amount of memory so I was wondering if leaving serviio running in the background makes the NAS slower or unresponsive. Can somebody answer this simple question? Would you recommend to install serviio on my NAS or it’s better to leave that to a computer? Thanks!

    Reply
    1. patters Post author

      It will be fine. Linux is very good at swapping out memory that isn’t actively being used to disk. I leave mine running Serviio continuously. Serviio runs very well on a NAS provided your renderer device has good format support. If it needs videos to be transcoded then unfortunately the NAS won’t have enough CPU power to do that in realtime.

      Reply
      1. Gonza

        Ok thank you for the answer and for your work!!
        One last question: Do you know what versions of serviio and java are the most lightweight?

      2. patters Post author

        I believe that I read somewhere at Oracle.com that Java 6 is slightly leaner and more highly optimised (Java 7 is still improving with each revision), and since Serviio doesn’t use any of the new Java 7 functionality yet (Macs lack Java 7) maybe you should use Java 6. As for Serviio I think newer is better. There have been significant improvements with the library additions threads and adjustments to how online resources are scanned.

  40. Mender

    Ahoj patters ;-)

    I have installed the Serviio 1.0 on my Synology DS212j with DSM 4.0 and it is working without problems.

    To my pleasure, Finally I am able see my NIKON DSLR photos on my Samsung TV. On Synology built in Media server I saw only thumbnails.

    But I see one problem. My DS212j is not going to sleep mode with Serviio running.

    What can I do???

    Reply
    1. patters Post author

      Hi, unfortunately I haven’t figured this out yet. It seems to me that all the Java apps I have run seem to stop the NAS hibernating (CrashPlan included), so I just accept this. I did once try to create a ramdisk and symlink the Serviio log folder to that but it didn’t seem to help. If anyone figures a solution out, please let me know.

      Reply
      1. Gonza

        Wasn’t that supposed to be a filesystem constant scanning problem?? And that the use of inotify would fix it sometime? At least that’s what I’ve read on Serviio forums.

    2. tomtom2000

      How did you get the Java installed on the NAS. I have the same model and as I posted before when I try to install Java it tells me that the file it is expecting is not in the right folder.
      I have tried a few versions, but still nothing.

      Any suggestions please??

      Reply
      1. tomtom2000

        I set all users to read/write and put both types in the folder public and still get this

        test

        This is why I am unsure what to do next. When I download the packages they miss the .tar and only display the .gz so I have added them in manually as others here have.

        Thanks
        Tom

        (The public folder was auto created, do I need a new one?)

      2. tomtom2000

        Nope, its not being extracted first (did try that as well)….oh well, I guess I can’t use it.

        Thanks for the help

        Tom

      3. patters Post author

        Check that ‘public’ appears in the Shared Folder DSM Control Panel. Also check that Windows File Service is enabled in the Win/Mac/NFS DSM Control Panel. My script uses the Windows File Service’s smb.conf to locate the actual folder path of the Public share (it might not be on volume1). Can you report back if that fixes it for you.

        EDIT – I think the problem might be that you called your folder ‘Public’ and not ‘public’. This being Linux, it is case sensitive.

      4. tomtom2000

        I think the problem is more between the chair and the keyboard. I love my tech, but I have no idea how to use the finer points of it most of the time! Thanks to every one here. Much appreciated.

      5. patters Post author

        :) I’ve updated the notes on the Java page. I had answered certain questions quite frequently in the comments and so I hadn’t realized that the actual blog post didn’t adequately stress these.

  41. Bob

    I have had numerous issues and just want to go back to what was working. Where can get the 0.6.2 package to reinstall until I figure this out?. – Thank you.

    Reply
      1. Chewie

        I, too, am having issues. I get DLNA errors on my PS3 that I never had before while using the new Serviio version. No matter where I place the online plugins in the public folder, Serviio won’t load them. And Serviio won’t restart after my NAS shuts down and starts up (as it does everyday).

        How do I go about reinstalling 0.6.2 after I’ve downloaded it from the above link?

  42. Bo

    Why was the console removed from synology with the upgrade? Can I reinstall it on the synology nas server like it used to be. It was an all encompassing install before and now you expect us to use two computers. If not, how do I revert to the old version?

    Reply
    1. patters Post author

      The reasons are explained in the text of the blog post. Look a few posts back in these comments for a download link to the 0.6.2 package if you really want.

      Reply
  43. François

    hello, excuse me for my english i am french people

    I have a DS712+ DSM 4.0-2228 and as I tried to install serviio.
    I put in the public directory files:
    ejre-1_6_0_32-fcs-b05-linux-i586-headless-05_apr_2012.tar.gz
    and
    gcc420_glibc236_x64-LPG-1.tgz

    after installing the java status shows: stop.
    and in the log :

    /var/packages/java6/scripts/postinst: line28: not found
    Systeme installed locales:
    C
    en_US.utf8
    POSIX

    JAVA_HOME=/volume1/@appstore/java6/jre
    TZ=Azia/Magadan

    when I install serviio package I get the message:

    java is not installed or not properly configured. The Java binary could not be located. Download and install the java package from http://wp.me/pVshC-z5

    Can you help me? and tell me how to fix this? for information I use the DS712 + with mac os X, but I do not think that’s the problem
    I started with the use of the DS712 + i am novice

    thank you in advance for your help

    François

    Reply
    1. patters Post author

      You’re using a Mac, so perhaps your Synology has the Windows File Sharing Service disabled. You will need this to be enabled just for the time you install the package. This is because I use its config file to locate the ‘public’ shared folder.

      Reply
      1. François

        hello,
        thank you for your answer but windows sharing is enabled.
        I do not understand why I can not install a package.
        if you have a solution?
        thank you
        François

      2. François

        hello,
        I just download the file with IE and java is ok over the error message.
        but during the installation of serviio I get the message:

        The User Home service is not enabled. Please enable this feature in the User control panel.

        thank you for your help.

        François

      3. François

        hello,
        thank you for your help, I managed to walk serviio.
        for information I used IE9 to download files and configure the NAS, maybe that’s it.
        thank you again.
        François

  44. alf

    Hi :d

    I upgrade my Serviio package on my ds411, and now when I want to acces webui, serviio ask me a password.
    I try my admin password and I have this anwser :

    You did not create a password for the web user. Enter it in the Serviio console.

    So I must enter in the servio consol, Okay but how ???
    I try whit Putty to acces on my Nas on the 23424 but nothing… I’m sure it’s a easy thing !! but not for me ! :)

    THX ;)

    Reply
    1. patters Post author

      Look at the updated Notes section of the blog post. You need to install Serviio Console on your computer then edit the settings so it connects to the NAS’s instance of Serviio.

      Reply
  45. similian

    No java expert but loved previous version, can no longer get to console to configure. please a newbie guide will help

    Reply

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s