Synology SPK for DVR Record Engine

Downloads & Instructions
Post Reply
calavera24
Posts: 12
Joined: Mon Jan 04, 2021 11:51 am
x 2

Re: Synology SPK for DVR Record Engine

Post by calavera24 »

Indeed, for whatever weird reason, the hdhomerun.conf file was not present at the designated path. I don't know how it got deleted, but anyway, I reinstalled/reconfigured it, and now it seems to work. Thanks for the hint!
PS: how did you know about what the logs indicate, including date etc.?
jasonl wrote: Tue Aug 23, 2022 4:21 pm The logs indicate that the last time the DVR was started on the NAS (2022-08-21 22:43:11 UTC), the DVR did not have a config path specified, which usually means that either it was executed from a different directory and the config file path was not specified, or the config file was missing. If you run it as like /path/to/hdhomerun_record, you should add ' --conf /path/to/hdhomerun.conf' (without the quotes) to explicitly tell it where to find the conf file.

jasonl
Silicondust
Posts: 16828
Joined: Sun Oct 28, 2007 9:23 pm
x 64

Re: Synology SPK for DVR Record Engine

Post by jasonl »

The DVR logs are sent to our server. I and the other support and engineering team members have access to review them for troubleshooting purposes.

MidwestDVRDude
Posts: 3
Joined: Tue Oct 11, 2022 6:41 pm

Re: Synology SPK for DVR Record Engine

Post by MidwestDVRDude »

I see why I've not been able to record anything over the past several months and I also see that SiliconDust appears to have given up on supporting Synology DiskStations which is a big drag.

So I'm trying the solution recommended by MNOiSY but I don't understand the steps fully. SSH into the Diskstation? What does that mean. I have SSH turned on. What else is needed? Then where do I place that code? Please explain what to do step by step so someone not familiar with the lingo can understand what to do. Thank you!

MidwestDVRDude
Posts: 3
Joined: Tue Oct 11, 2022 6:41 pm

Re: Synology SPK for DVR Record Engine

Post by MidwestDVRDude »

jasonl wrote: Thu Aug 25, 2022 4:34 pm The DVR logs are sent to our server. I and the other support and engineering team members have access to review them for troubleshooting purposes.
Jason, Please help a novice understand this issue. Will SiliconDust fix this issue with Synology or how good is the workaround. I'm not understanding the steps to work around this issue. And as a last resort, what is the most cost effective way to implement something other than Synology. Would something like a WD My Cloud Home system solve the issue? Thank you.

Online
signcarver
Expert
Posts: 11092
Joined: Wed Jan 24, 2007 1:04 am
Device ID: 10A05954 10802091 131B34B7 13231F92 1070A18E 1073ED6F 15300C36
x 38

Re: Synology SPK for DVR Record Engine

Post by signcarver »

A my cloud home won't work as the nas needs to be linux based rather than (headless) android based. Hopefully when they separate the android record engine from the app they will add such headless support

You will need to SSH into the box, thus requires you to have a "computer" that can do such (most windows users probably use putty as tge software to make the connection )

Then you basically type the commands in a terminal.

You may wish to check out
https://mariushosting.com/how-to-ssh-in ... ology-nas/
Which was the first thing that popped up from Google.

gunbunny
Posts: 12
Joined: Tue Jul 11, 2017 6:33 am

Re: Synology SPK for DVR Record Engine

Post by gunbunny »

Odd situation today. Running 1.1.0 on DSM 6. Haven't changed the config in a while, everything just ran like it should. Until today.

Football game was set to record and I had planned to timeshift it. Little red dot was showing up in the UI and everything normal. Sit down to watch it... no recording. So I log into my Synology, click the Package Center, hit the HDHR DVR Manager, click Open... and it 404's. Okay, that's odd. So I check here, then SSH into my box and there's no files in the www folder. So I re-download the SPK and reinstall it. Still 404s. Still nothing in the www folder. So I open the SPK and manually copy the files into www. Okay, now we're getting somewhere. The web interface comes up, and most of the config stuff is blank:
  • Version:TO BE SET
  • Record Engine Version: Unable to discover DVR version
  • Config File Location: /
  • RecordPath: Path not Set
  • Port: Path not Set
  • RecordStreamsMax: 16
  • StorageID: StorageID not Set
  • RunAs: not set
  • BetaEngine: 0
I check the config file with

Code: Select all

cat /volume1/@appstore/HDHomeRunDVR/etc/HDHomeRunDVR.conf
and I get:
  • RecordPath=/volume1/HDHomeRunDVR
  • Port=59090
  • RecordStreamsMax=16
  • BetaEngine=0
  • RunAs=hdhomerundvr
  • StorageID=8633275D-***********
So... what now?

demonrik
Posts: 1591
Joined: Mon May 04, 2015 10:03 am
Device ID: 108042A1, 10814D8E
x 38

Re: Synology SPK for DVR Record Engine

Post by demonrik »

gunbunny wrote: Sun Oct 16, 2022 2:30 pm Odd situation today. Running 1.1.0 on DSM 6. Haven't changed the config in a while, everything just ran like it should. Until today.

Football game was set to record and I had planned to timeshift it. Little red dot was showing up in the UI and everything normal. Sit down to watch it... no recording. So I log into my Synology, click the Package Center, hit the HDHR DVR Manager, click Open... and it 404's. Okay, that's odd. So I check here, then SSH into my box and there's no files in the www folder. So I re-download the SPK and reinstall it. Still 404s. Still nothing in the www folder. So I open the SPK and manually copy the files into www. Okay, now we're getting somewhere. The web interface comes up, and most of the config stuff is blank:
  • Version:TO BE SET
  • Record Engine Version: Unable to discover DVR version
  • Config File Location: /
  • RecordPath: Path not Set
  • Port: Path not Set
  • RecordStreamsMax: 16
  • StorageID: StorageID not Set
  • RunAs: not set
  • BetaEngine: 0
I check the config file with

Code: Select all

cat /volume1/@appstore/HDHomeRunDVR/etc/HDHomeRunDVR.conf
and I get:
  • RecordPath=/volume1/HDHomeRunDVR
  • Port=59090
  • RecordStreamsMax=16
  • BetaEngine=0
  • RunAs=hdhomerundvr
  • StorageID=8633275D-***********
So... what now?
Permissions issue.
the web interface user is ran as user which is in the group 'http'
As part of the install the permissions of the .conf file are changed to be owned by the dvr user and the 'http' group.
If for some reason an update or something else gets those permissions screwed up then the DVR Manager can't read the .conf file or get the status of the engine.

However - the fact that you had to copy the www pages over means something else is probably go on
But it reminded me of something and I found my old post here viewtopic.php?p=376952#p376952
Which was in response to another user installing 1.1.0 on DSM6 and it not creating the web folder.
For DSM6 1.0.2 and 1.1.0 are functionally the same - might be worth just running 1.0.2

As to suddenly why it might change - sounds like an update was made and/or a restart and on the boot the new policies kicked in.

And finally - just reminder - the SPKs are EOL for the last year - so I've no idea if the 2022 updates to DSM6 introduced something

gunbunny
Posts: 12
Joined: Tue Jul 11, 2017 6:33 am

Re: Synology SPK for DVR Record Engine

Post by gunbunny »

And finally - just reminder - the SPKs are EOL for the last year - so I've no idea if the 2022 updates to DSM6 introduced something
So would your recommendation be to go with the Docker image instead?

demonrik
Posts: 1591
Joined: Mon May 04, 2015 10:03 am
Device ID: 108042A1, 10814D8E
x 38

Re: Synology SPK for DVR Record Engine

Post by demonrik »

gunbunny wrote: Mon Oct 17, 2022 8:37 am
And finally - just reminder - the SPKs are EOL for the last year - so I've no idea if the 2022 updates to DSM6 introduced something
So would your recommendation be to go with the Docker image instead?
If you have an x86 Synology - absolutely recommended.. Docker is fully supported by Synology and have a little guide here https://github.com/demonrik/HDHR-DVR-do ... -Container to help transition.. Anyone doing for first time can use same instructions.

If ARM Synology - Synology doesn't support but there may be methods out there just a search away to get docker on your NAS. In reading many of these solutions, it can be a bit of trial and error to get right version of docker, etc. :(
Some good instructions here https://stackoverflow.com/questions/525 ... nology-nas
Look up your CPU type for your NAS https://kb.synology.com/en-us/DSM/tutor ... y_NAS_have
Check out https://linuxhint.com/about-arm64-armel-armhf/ for hints on how to check which ARM you have
Then get your docker from https://download.docker.com/linux/static/stable/
Once up and running - I recommend installing Portainer https://www.portainer.io/ as your docker manager.

rrussis82
Posts: 507
Joined: Tue Jul 10, 2018 12:46 pm
Location: Western MA

Re: Synology SPK for DVR Record Engine

Post by rrussis82 »

MNOiSY wrote: Wed Mar 23, 2022 7:11 pm After speaking with SD, I was able to get it working on the 1.1.1 package! The problem was actually MUCH simpler than we all thought.

The first good news is that a new package is already being developed by SD and will be an installable APK for Synology. I will excitedly hold my breath. They also shared the cause...
-------------------
The Synology 7.1 update disables running executable code from the /tmp/ directory, which is how the HDHomeRun DVR works. The HDHomeRun DVR binary is actually a combination of the DVR for all platforms, and the processor-specific version is extracted and launched from the tmp directory. This breaks how we package the DVR, but it is a good idea from a security perspective. We are in the process of creating a new 7.1-friendly package, that will also install like a normal Synology app and be much easier to update and control, and we hope to have that out soon.
----------------
In the meantime, you can temporarily change the tmp directory back to being executable, which will allow the DVR to run again. This isn't a long-term solution, as it will get reset when the Synology reboots.

SSH into your Diskstation and:

Code: Select all

sudo -i
mount -o remount,exec /tmp
cd /volume1/HDHomeRun/
./hdhomerun_record stop
./hdhomerun_record start
And voilà, DVR along with demoniks app is working again.
I updated last night to DSM 7.1.1-42962 update 1. I wish i had come here first to see if this update breaks my DVR. and it did. These commands did not help. I have DemonRiks package installed. None of my clients will see anything recorded on the NAS

I may try to attempt the docker install when i have time. It is unfortunate that i have to wait a few days to try and just wish it would just work. at least the Servio i have will record for now, but will it try to re-record everything i had on the NAS? will i end up with duplicate recordings when this is all said and done?

just the other day i was thinking about getting a second NAS to add an additional record engine instead of increasing the HDs incrementally when i get close to filling it. looks like i may stay away from Synology if i do


EDIT... it was a permissions issue. I went in and gave user HDHOMERUNDVR read/write access to more folders.

nickk
Silicondust
Posts: 20195
Joined: Tue Jan 13, 2004 9:39 am
x 384

Re: Synology SPK for DVR Record Engine

Post by nickk »

We have just released an official Silicondust package for Synology:
https://download.silicondust.com/hdhome ... y_beta.spk

Update steps:
1) Uninstall the old package.
2) Install the Silicondust package.
3) Copy recordings from the old share to the new HDHomeRun share.
4) Delete the old share.

Beerman
Posts: 1642
Joined: Thu May 21, 2015 7:05 pm
x 5

Re: Synology SPK for DVR Record Engine

Post by Beerman »

Thanks much for putting this out there for us Synology users!

Should there be a problem with copy protected channels recording?

Recording: starting new file Live channel 38 14dace6f
20221107-01:07:25 Recording: no tuners available to record Live channel 38 14dace6f
20221107-01:07:25 Playback: Live channel 38 failed to start: 811 Content Protection Required
20221107-01:07:35 Recording: stop Live channel 38 14dace6f (result = 0x0000)
20221107-01:08:22 Status: Resource: nbk=0 dmk=329
20221107-01:10:22 Status: Resource: nbk=0 dmk=329
20221107-01:11:05 Recording: starting new file Live channel 38 9970b17a
20221107-01:11:05 Recording: no tuners available to record Live channel 38 9970b17a
20221107-01:11:05 Playback: Live channel 38 failed to start: 811 Content Protection Required
20221107-01:11:15 Recording: stop Live channel 38 9970b17a (result = 0x0000)

Online
signcarver
Expert
Posts: 11092
Joined: Wed Jan 24, 2007 1:04 am
Device ID: 10A05954 10802091 131B34B7 13231F92 1070A18E 1073ED6F 15300C36
x 38

Re: Synology SPK for DVR Record Engine

Post by signcarver »

Why wouldn't there be? Nothing but wmc ( as far as devices covered in this forum go) currently supports drm recording.

The way the engine/client works for drm is thar it attempts, then notifies client of failure, then client tunes directly.

Beerman
Posts: 1642
Joined: Thu May 21, 2015 7:05 pm
x 5

Re: Synology SPK for DVR Record Engine

Post by Beerman »

Sorry, chalk up another senior moment for me. I don't know what I was thinking except maybe I was back in 2017.
Thanks for the reality check. :lol:
Houston, we're good for now.

SpiceWare
Posts: 46
Joined: Thu Nov 16, 2017 5:04 pm
x 1

Re: Synology SPK for DVR Record Engine

Post by SpiceWare »

nickk wrote: Sun Nov 06, 2022 5:47 pm We have just released an official Silicondust package for Synology:
Nice!

I've done a new install on my Synology DS1821+, it's never been used as a DVR before. Was simple to install, and appears to be working - in File Station I see HDHomeRun, configuration file, log file, Live TV directory, and a recording that I just triggered via the HDHomeRun application on my Mac Pro.

Currently I have the DVR software running on a Mac mini that's connected to my TV. I was going to uninstall the recording software from the mini, but see a big warning that all of my recordings would be erased during the uninstall process.

So I'd like to stop the DVR on the mini from recording, migrate my recordings from the mini's drive to the Synology, then uninstall from the mini. I've tried using Activity Monitor to stop the hdhomerun_record task, but it just restarts - is there a way to do that? Or would renaming the directories allow me to uninstall without the recordings getting deleted?

Thanks!

Post Reply