Advice moving from Mythtv to TvHeadend

  Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Post Reply
se99paj Offline
Junior Member
Posts: 12
Joined: Mar 2015
Reputation: 0
Post: #1
So I currently have a Mythtv backend running on Ubuntu (Mythbuntu) and a Librelec frontend running on a Raspberry Pi 2.

I'm starting to get fed up with the noisy backend and looking for options, I'm a very big fan of the Raspberry Pi and quite interested in giving Tvheadend a try but thought I'd come here for advice.

My initial thoughts are to install Tvheadend via Librelec on my existing Raspberry Pi, I have a HDHomeRun so not expecting too many issues getting channels to work and record. I also have a NAS that I would use for storing the recordings. I think my concern is that it sounds far too simple.

Does Tvheadend add much overhead on performance or would I almost certainly need to run 2 Pi's? (To split the frontend and backend) - I do have the additional audio/video license on the Raspberry Pi so hoping that will help.

Can anyone see any issues recording to a NAS? My biggest headache is that by retiring mythtv I'm losing 2 HDD which is a large chunk of my storage, I could always add a USB enclosure and connect to the Pi.

I'm also interested to know how you access the recordings via Kodi, with the Mythtv add-on there is a recording menu, this is separate to the Movies/TV Shows menu in Kodi. Is there a way to make the Tvheadend recordings appear within the Movies/TV Shows menu?

Any help or advice is much appreciated.

Thanks
find quote
rpcameron Offline
Fan
Posts: 614
Joined: Nov 2015
Reputation: 27
Post: #2
You may have issues recording to NAS since the Pi is only 100Mbps, and this may limit incoming streams and outgoing streams; watching while recording means 3 concurrent streams for a single feed. NAS vs. USB isn't really an issue, because they share the same bus, although you may get slightly faster speeds over USB.

Also, TVH is not too friendly with the HDHR Prime; as long as you are not using that model, there shouldn't be too many issues.

(Personally I'd stay away from LibreELEC and the like, especially if you need a grabber for guide data and don't get it OTA via DVB, as third-party apps and scripts on LE can be hit or miss because it's a VERY minimal Linux install.)
find quote
se99paj Offline
Junior Member
Posts: 12
Joined: Mar 2015
Reputation: 0
Post: #3
Thanks for the heads-up on the data limit - It sounds like 2 Pi's splitting the work would be beneficial, although I'm just moving the limitation to the NAS instead of the Pi but hopefully that won't be an issue. I can always trial with 1 Pi first then upgrade to 2 later.

I'm based in the UK so using a HDHR Connect also when using Mythtv I've pulled the guide data OTA instead of using scripts - But saying that I'm always open to new suggestions, do you have any recommendations on another OS to use for the Pi? I did have a quick look at OSMC yesterday and it looked very nice (I know looks aren't the only factor I should be considering here)
find quote
xbmclinuxuser Offline
Fan
Posts: 339
Joined: Dec 2012
Reputation: 5
Post: #4
(2017-03-01 11:41)rpcameron Wrote:  (Personally I'd stay away from LibreELEC and the like, especially if you need a grabber for guide data and don't get it OTA via DVB, as third-party apps and scripts on LE can be hit or miss because it's a VERY minimal Linux install.)

HIGHLY agree with this. If you you think there is even the slightest possibility that you may want to run a script or program not part of OpenELEC or LibreELEC, I would avoid those two like the plague.

On a Raspberry Pi I'd just run Raspbian (Debian) Jessie Lite (no desktop, you don't need one since TVHeadend is configured via a web page. This assumes you will not be running Kodi or other software that requires a desktop on the same Raspberry Pi):

https://downloads.raspberrypi.org/raspbian_lite_latest

Use Etcher to save the image to your SD card (note it will overwrite all existing data on the card).

Prior to ejecting the SD card, create an empty file named ssh in the /boot/ directory. (In Linux or OS X you can type touch ssh, in Windows I think you would type NUL > ssh). If you don't do this the ssh service will not run (new security measure) and you will not be able to ssh into your Pi.

Insert the SD card and power up the Raspberry Pi. You may wish to plug in a display just long enough to see what IP address is assigned.

Using an SSH client (such as Terminal, iTerm, Putty, etc.), log in using pi:raspberry.

Run

sudo apt-get update
sudo apt-get dist-upgrade

To get the latest OS upgrades.

Run

raspi-config

and go through the screens to configure your Raspberry Pi (use the entire SD card, set Time Zone, etc. Each screen is pretty self explanatory).

Go to https://tvheadend.org/projects/tvheadend...Repository and https://tvheadend.org/boards/5/topics/21528?r=23476 for the software and install instructions for TVHeadend. I'd suggest using either the "Stable" or "Unstable" branch. Unstable is newer (4.1 with many of the 4.2 additions) but it is remotely possible to get a "broken" version. In my experience both work equally well for most situations. Unstable is not really all that unstable, but it is up to you. If I were setting up a new system right now I'd use Unstable, but that's just me. Also remember you are running Debian, not Ubuntu. If you could find a version of Ubuntu Server for the Raspberry Pi I'd run that instead, but there doesn't seem to be a build of that for the Pi and you really don't need the overhead of a desktop in most cases.

If you think the network might be an impediment you could try something like an Odroid-C2 which has a gigabit network connection. But I have no experience with those, so don't know what OS choices are available. Ubuntu is the most compatible with TVHeadend, and Debian/Raspbian the next most compatible. In theory you can build TVHeadend from source on any Linux box but unless you are a true Linux geek I would try to avoid that.

(Credit: Some of the Raspbian install instructions above were lifted or adapted from RonR's post on FreePBX for the Raspberry Pi.)

I am NOT a coder, in fact I am not very comfortable in Linux outside of a GUI. I am just a user of Linux and Kodi (formerly XBMC), as my user name implies.
(This post was last modified: 2017-03-01 19:50 by xbmclinuxuser.)
find quote
Prof Yaffle Offline
Team-Kodi Mumbler
Posts: 2,692
Joined: Mar 2011
Reputation: 78
Location: An increasingly isolated island off the north-west European coast.
Post: #5
Tvheadend is very flexible, and very lightweight as well - I've seen people run it on NASes, routers, Android boxes. Ultimately, your bottleneck is I/O (assuming you're not using any transcoding) - so I/O to the discs, or to the network port. That's where a Pi can struggle, as commented above, particularly as everything shares the same internal bus. That means you can really kill it if you're recording to an external disc while streaming something out of the LAN port to a different system.

I don't think your AV (MPEG2?) licence makes a difference unless you're *decoding* on the Pi. If all you're doing is taking an SD signal (e.g. Freeview) and dumping it to a .ts file, then the system never really knows what was in the stream.

The tvheadend PVR addon presents your recordings and channels in the same way as the MythTV addon, I believe (it's been several years since I've looked at MythTV). If you want recordings in the main library, you'd need to post-process them in some way to rename them according to a scraper, move them to the appropriate place on your NAS, and trigger a library refresh on Kodi. I guess you might be able to create a custom NFO in some way and then scrape that in, but that depends on what's available in the EPG entry for a recording and how easy it is to parse and re-write (e.g. translating the JSON recording record into the XML of the NFO file).

Please... search the forum, read the forum rules, post a debug log and useful system information if you've got a problem, and help everyone to help each other.
find quote
vmstek Offline
Senior Member
Posts: 112
Joined: Feb 2013
Reputation: 2
Post: #6
Use the "unstable" PPA as you will get the version that includes the setup wizard.
find quote
nickr Offline
Team-Kodi Member
Posts: 18,612
Joined: May 2009
Reputation: 381
Location: Christchurch NZ
Post: #7
(2017-03-03 13:08)Prof Yaffle Wrote:  Tvheadend is very flexible, and very lightweight as well - I've seen people run it on NASes, routers, Android boxes. Ultimately, your bottleneck is I/O (assuming you're not using any transcoding) - so I/O to the discs, or to the network port. That's where a Pi can struggle, as commented above, particularly as everything shares the same internal bus. That means you can really kill it if you're recording to an external disc while streaming something out of the LAN port to a different system.

I don't think your AV (MPEG2?) licence makes a difference unless you're *decoding* on the Pi. If all you're doing is taking an SD signal (e.g. Freeview) and dumping it to a .ts file, then the system never really knows what was in the stream.

The tvheadend PVR addon presents your recordings and channels in the same way as the MythTV addon, I believe (it's been several years since I've looked at MythTV). If you want recordings in the main library, you'd need to post-process them in some way to rename them according to a scraper, move them to the appropriate place on your NAS, and trigger a library refresh on Kodi. I guess you might be able to create a custom NFO in some way and then scrape that in, but that depends on what's available in the EPG entry for a recording and how easy it is to parse and re-write (e.g. translating the JSON recording record into the XML of the NFO file).
There should be no need for an nfo if the file is renamed properly.

If I have helped you or increased your knowledge, click the 'thank user' button to give thanks :) (People with less than 20 posts won't see the "Thank you" button.)
find quote
se99paj Offline
Junior Member
Posts: 12
Joined: Mar 2015
Reputation: 0
Post: #8
I'm testing this out at the moment and have a few snags that I'm working through. I'm trying to figure out the best way to do something so thought I'd ask.

My recordings I can access without an issue from kodi, but I also like to store some TV shows and movies for the long-term and store them in the tv shows / movie section. How do you migrate the recordings and delete from tvheadend?

I could just move the tvheadend recording files but I'm guessing tvheadend won't reflect the change
find quote
Prof Yaffle Offline
Team-Kodi Mumbler
Posts: 2,692
Joined: Mar 2011
Reputation: 78
Location: An increasingly isolated island off the north-west European coast.
Post: #9
tvh will spot that the file isn't there and flag it as "file missing" in the "removed recordings" tab (4.1.x/master branch).

[Image: bwQcW4.jpg]

Please... search the forum, read the forum rules, post a debug log and useful system information if you've got a problem, and help everyone to help each other.
find quote
mr_raider Offline
Senior Member
Posts: 113
Joined: Dec 2008
Reputation: 0
Post: #10
Sorry to thread jack, but I'm also moving from myth to tvheadend, mainly for the ability to remote administer with no GUI.

When playing myth recordings in Kodi the commercials would get skipped, although the raw file still contained them.

Is their similar functionality in tvheadend when using Kodi as the front end?
find quote
rpcameron Offline
Fan
Posts: 614
Joined: Nov 2015
Reputation: 27
Post: #11
(2017-04-30 22:10)mr_raider Wrote:  Sorry to thread jack, but I'm also moving from myth to tvheadend, mainly for the ability to remote administer with no GUI.

When playing myth recordings in Kodi the commercials would get skipped, although the raw file still contained them.

Is their similar functionality in tvheadend when using Kodi as the front end?
Tvheadend allows for post-processing scripts to be run. If you install and configure something like comskip, it can generate EDLs. When you play back a recorded file in Kodi via Tvheadend, if Tvheadend finds the EDL, it will send that information to Kodi as well, allowing for commercial skipping just as MythTV does.

The difference is that you must manage the commercial detection yourself via additional scripts; there is a "Skip commercials" setting in the recording profiles, but it doesn't realy do anything, you must use the post-processing script. (At least, I haven't found it to do anything.)
find quote
mr_raider Offline
Senior Member
Posts: 113
Joined: Dec 2008
Reputation: 0
Post: #12
Last question (I think). Myth TV would generate nice thumnails of each episode with a screen cap. Also, when viewing the series folder in kodi, I would get a logo of the series (i.e. DC Legends of Tomorrow). Is that a function from within mythtv or kodi? Can I still get that with TVH?
find quote
rpcameron Offline
Fan
Posts: 614
Joined: Nov 2015
Reputation: 27
Post: #13
That was a MythTV thing. And actually, MythTV wasn't generating it (other than the screencap), but instead pulled the info from IMDB or TVDB.
find quote
mr_raider Offline
Senior Member
Posts: 113
Joined: Dec 2008
Reputation: 0
Post: #14
(2017-05-01 19:11)rpcameron Wrote:  That was a MythTV thing. And actually, MythTV wasn't generating it (other than the screencap), but instead pulled the info from IMDB or TVDB.

That would explain why my Flash recordings had the icon from the 70s show with the guy in the fake muscle suit. Can Kodi do the same fro the TV recordings? I know it can for files in the "video" library.
find quote
rpcameron Offline
Fan
Posts: 614
Joined: Nov 2015
Reputation: 27
Post: #15
(2017-05-01 20:46)mr_raider Wrote:  
(2017-05-01 19:11)rpcameron Wrote:  That was a MythTV thing. And actually, MythTV wasn't generating it (other than the screencap), but instead pulled the info from IMDB or TVDB.

That would explain why my Flash recordings had the icon from the 70s show with the guy in the fake muscle suit. Can Kodi do the same fro the TV recordings? I know it can for files in the "video" library.

For MythTV, you could manually change the guessed-at IMDB or TVDB ID of a series, to correct current/remade shows having the original series' artwork and info.

For Tvheadend, this feature is not available.

For scraping purposes, such as for additional artwork and stuff, I suppose you could add your Tvheadend recordings folder as a "TV Shows" source in Kodi, but then you would watch your programs from the "TV Shows" entry in Kodi, instead of through the Recordings interface of the PVR Manager.
find quote