Building a TV Server on a Synology NAS (Updated)

Work Environment

NAS:  Synology DS216+II with DSM 6.1.7-15284

Before you begin:

Enable SSH.

If you have a battery backup unit then enable UPS.

You will need to donate $20 to to get a version of the software that will run on your Synology if it uses an ARM processor and won’t run the standard x86 version that you can download from the site. The DS216+II in this tutorial has an Intel x86 / x64 processor so the standard x86 version will work just fine.

You will also need a subscription to Schedules Direct.

Add SynoCommunity to your package sources. Install the latest version of Tvheadend. You might need to enable beta versions to get the latest version of the software.

Create a Windows Share folder on your Synology called “public” and make sure the “sc-media” user has read/write access to it.
Continue reading

Setting Up MythTV on an Odroid C2

passwd root
apt-get update
apt-get upgrade
apt-get dist-upgrade
apt autoremove
apt-get install nano mariadb-server apache2 open-iscsi
nano /etc/apt/sources.list.d/webmin.list

deb sarge contrib
deb sarge contrib

apt-key add jcameron-key.asc
apt-get update
apt-get install webmin
Continue reading

Launchpad Configuration

  1. Import your PGP Keys
  2. Install dput, dh-make, devscripts, & config-package-dev packages.
  3. Open /etc/ file and change Launchpad section to:
    fqdn            =
    method            = ftp
    incoming        = ~[LaunchpadID]/testppa/ubuntu
    login            = anonymous
    allow_unsigned_uploads  = 0
  4. The following are the commands used to build source and upload to Launchpad.
    cd test-x.x.x.x
    dh_make –single –native –copyright apache –email [LaunchpadEmail]
    rm debian/*.ex debian/*.EX
    debuild -S -k[LaunchpadEmail] –buildinfo-option=”-O”
    dput testppa ../test_x.x.x.x_source.changes

Moving/Copying your PGP Keys

Once you’re using PGP, you may want be able to sign email from more than location, or you may switch computers. There’s a few ways to accomplish this.

Copy All GnuPG Data

Your first choice is to copy all of your GnuPG data. This is a lot more data than just your key, but is still likely to be under 5MB. This method will copy all of your keys, everyone’s key you have, and your entire trust database. It’s ideal for backup, or for moving to a new computer. Simply copy all the contents of your GnuPG data directory, which would be as follows:

  • Windows: C:/Documents and Settings/username/application Data/GnuPG
  • Unix/Linux/Mac: ~/.gnupg

Where username is your windows username. Just simply copy the entire contents of that directory from one machine to the other and you will be set. There are many ways to move this data, which I won’t cover. Some examples might be zipping the data up and copying it to a disk.

This will also work between different operating systems.
Continue reading

Configuring Syncthing in Windows, Linux, and on a Synology NAS

Syncthing is a useful open source tool to keep all of your files in sync over multiple computers. It works like Dropbox, but it’s a peer-to-peer system instead of having a central repository to host all of your files.

Windows Set Up

  1. Download the windows client from the Syncthing website.
  2. Copy the EXE file to a folder on your Windows machine.
  3. Create a Batch file in the same folder with the following:
    • start “Syncthing” syncthing.exe -no-console -no-browser
  4. Create a shortcut to the batch file and copy it to the startup folder. The startup folder can be accessed by entering “shell:startup” in the run dialog box.
  5. Admin interface is located at

Update: SyncTrazor is a small stand-alone browser that automatically runs, restarts, updates etc. Syncthing for you.

Continue reading

Configuring Syncevolution to Sync via CalDAV/CardDAV

Open up a terminal window and enter the following replacing {hosturl}, {emailaddress}, and {password} with your own credentials:

$ syncevolution --configure --template webdav syncURL=https://{hosturl}:2080/ username={emailaddress} password={password} target-config@webdav
$ syncevolution --print-databases syncURL=https://{hosturl}:2080/ username={emailaddress} password={password}

The above command will show you the database URL’s. Since my addressbook wasn’t Continue reading

Setting Up Odroid C2 with Iceweasel and Flash

Setting Up Odroid C2 with Iceweasel and Flash

  • Download the latest Odrobian Vanilla image for the Odroid C2 here.
  • If you are running Linux, uncompress the image using the unxz command.
  • Flash the image to a microSD card using the dd command.
  • Insert the SD card into the slot on the Odroid C2 and boot the image. Login as root.
  • Change default root password:
    • passwd root
  • Grab all of the latest updates:
    • apt-get update && apt-get upgrade && apt-get dist-upgrade
  • Set Time Zone:
    • dpkg-reconfigure tzdata
  • Setup desktop environment:
    • tasksel
  • Add a user:
    • adduser Username –force-badname
  • Install all of the required dependencies for the Fresh Player plugin:
    • apt-get install libflashplayer build-essential git cmake pkg-config libglib2.0-dev libasound2-dev libx11-dev libgl1-mesa-dev liburiparser-dev libcairo2-dev libpango1.0-dev libpangocairo-1.0-0 libpangoft2-1.0-0 libfreetype6-dev libgtk2.0-dev libxinerama-dev libconfig-dev libevent-dev libegl1-mesa-dev libgles2-mesa-dev ragel libva-dev libvdpau-dev libv4l-dev libavcodec-dev libssl-dev
  • Build the Fresh Player plugin:
    • git clone
    • cd freshplayerplugin && mkdir build
    • cd build
    • cmake ..
    • make
  • Copy the created file to the Iceweasel plugins directory:
    • cp /usr/lib/mozilla/plugins
  • Reboot into desktop environment (reboot).

Raspberry Pi as Eye-Fi Server

February 26, 2016

Raspberry Pi as Eye-Fi Server

At the time of this writing, there still isn’t an eyefiserver package in the stable Debian repository.  Sure, I could have enabled the testing repository and added the package that way, but since the installation only consists of adding a few files in certain locations, I’ll document the steps that I took:

First, grab the source eyefiserver off of the Debian web site: Continue reading

Setting Up MythTV in Debian 8 (or Armbian Jessie)

  • Boot Debian 8 Network Install CD (or Armbian Jessie image. If running Armbian with a USB harddrive, now would be a good time to run ‘nand-sata-install’ to boot off the HDD.)
  • Select “Install”.
  • Create “myth” user.
  • Choose separate “home” partition.
  • When prompted for software packages to install, unselect everything except “SSH Server” and “Standard System Utilities”.
  • Log in as “root” and run “apt-get install sudo”.  Then add “myth    ALL=(ALL:ALL) ALL” to /etc/sudoers & log out.
  • Log in as “myth” and add the following to /etc/apt/sources.list:
    • #deb-multimedia
    • deb jessie main non-free
  • Add the following to /etc/apt/sources.list.d/webmin.list:
    • deb sarge contrib
  • Create the following directories:
    • mkdir /home/myth/recordings
    • chmod -R 777 /home/myth/recordings
    • mkdir /home/myth/recordings/banners
    • mkdir /home/myth/recordings/fanart
    • mkdir /home/myth/recordings/coverart
  • Run the following commands:
    • wget
    • sudo apt-key add jcameron-key.asc
    • sudo apt-get update
    • sudo apt-get install deb-multimedia-keyring
    • sudo apt-get update
    • sudo apt-get upgrade
    • sudo apt-get install xauth webmin

      (Set Time Zone in Webmin. Time server is
    • sudo apt-get install mythtv mythweb
    • sudo service ntp start
    • wget
    • chmod a+x
      (Use Webmin to copy MythTV database backup to root folder)
    • ./ –drop_database –create_database –directory /home/myth –filename mythconverg-1317-20170223222314.sql.gz
  • Edit /etc/php5/apache2/php.ini to fix a bug in mythweb:
    • max_input_vars = 100000
  • Add the IP address of the computer to /etc/mysql/my.cnf:
    • bind-address =
  • Restart Apache and MySQL. Also, start Myth Backend and run mythtv-setup from a remote computer:
    • sudo service apache2 restart
    • sudo service mysql restart
    • sudo service mythtv-backend start
    • (from remote computer) ssh myth@ -X
    • (from remote computer) sudo nano /etc/mythtv/config.xml (copy database password)
    • (from remote computer) mythtv-setup (change the IP address to the IP address running MythTV and paste the database password).  You should now be able to finish setting up MythTV.
    • mythmetadatalookup –refresh-all-rules
    • mythmetadatalookup –refresh-all
    • mythmetadatalookup –refresh-all-artwork