Synology SPK for DVR Record Engine

Downloads & Instructions
Post Reply
gtb
Expert
Posts: 4222
Joined: Thu Oct 06, 2011 1:00 pm
Location: Sunnyvale, CA USA
x 15

Re: Synology SPK for DVR Record Engine

Post by gtb »

demonrik wrote: Sun Jan 02, 2022 10:58 pm Final release
Thank you for the support of the various NAS packages over the years.

While I never used your various NAS packages, they clearly were useful to many, and your efforts should be applauded. Thank you.

DornoDios
Posts: 76
Joined: Sat Dec 12, 2020 9:33 pm
Device ID: 107C3D26
x 3

Re: Synology SPK for DVR Record Engine

Post by DornoDios »

My original question was about updating from 1.02, but after some digging I found it's functionally equivalent to the newer releases unless you are using DSM7 which I have decided not to update to just yet.

I was sad to see this is no longer supported, until I found you released a Docker image. I wouldn't say I'm an expert, but I managed to setup the geoIP database and rtorrent/rutorrent from the recommended images on my DS220+ w/ $25 4GB Ram module.

So I will transition to your docker image at some point in the future. Thanks SO much for your continued work and support!

mrfreeze1963
Posts: 22
Joined: Thu Nov 15, 2018 8:18 am

Re: Synology SPK for DVR Record Engine

Post by mrfreeze1963 »

demonrik wrote: Sun Jan 02, 2022 10:58 pm Final release
1.1.1
Pick up from usual places (Google Drive, DropBox, OneDrive)
Fixes the Icons - everything else as is.

Again - no longer really supported ;)
@demonrik

Just downloaded the package over the weekend. Thank you again for all of your hard work. Have you planned your official retirement party, or are you keeping it a quiet closure?

Oh..., one more question: The DVRUI that you created for the Synology versions of the DVR package? How difficult is it to replicate it and make it work for other OSes, like Ubuntu, Windows, Fedora, Linux Mint, etc.? I'm still working on my project to migrate from Synology to Fedora. And, I just realized that I won't have that feature anymore.

CockneyBoy
Posts: 26
Joined: Tue Oct 01, 2019 2:14 pm
Location: Hamburg, Germany

Re: Synology SPK for DVR Record Engine

Post by CockneyBoy »

This is the first time I have visited this thread in 2 years.
A bit of a shock to see that the support will end, but I can (from my own experience) understand the decision.

I run Libreelec on Raspi 3's. use a HDHR Expand and a DS 116 dedicated for this purpose.
I am still on DSM 6.2 and intend to keep it, as I see no benefit in going to 7 on this machine.
The SPK is 1.0.2 - I understand that 1.1.0 is for DSM 7.0.
Everything works fine.

My problem is I have read that this package is dependant on PHP 7.2 and further
that Synology will remove PHP 7.2 in March this year.

The question is what happens to my current setup then and of course what do I need to prepare?

DornoDios
Posts: 76
Joined: Sat Dec 12, 2020 9:33 pm
Device ID: 107C3D26
x 3

Re: Synology SPK for DVR Record Engine

Post by DornoDios »

CockneyBoy wrote: Wed Feb 02, 2022 1:31 pm My problem is I have read that this package is dependant on PHP 7.2 and further
that Synology will remove PHP 7.2 in March this year.

The question is what happens to my current setup then and of course what do I need to prepare?
I'm in the same situation. I'm planning to switch to the Docker container version of the record engine eventually.

Is Synology actually going to remove the PHP 7.2 package that you installed? I could see them removing it from the available packages, but uninstalling something that is on the NAS seems a bit heavy handed.

CockneyBoy
Posts: 26
Joined: Tue Oct 01, 2019 2:14 pm
Location: Hamburg, Germany

Re: Synology SPK for DVR Record Engine

Post by CockneyBoy »

@DornoDios

Your question is exactly my problem, I do not know what happens when the package is removed.
A deinstallation is very unlikely, but will everything continue to work as normal?

Docker is no option for me as my NAS is based on ARM.

I will seek advice in Synology forum and revert.

DornoDios
Posts: 76
Joined: Sat Dec 12, 2020 9:33 pm
Device ID: 107C3D26
x 3

Re: Synology SPK for DVR Record Engine

Post by DornoDios »

CockneyBoy wrote: Sun Feb 06, 2022 12:24 am @DornoDios

Your question is exactly my problem, I do not know what happens when the package is removed.
A deinstallation is very unlikely, but will everything continue to work as normal?

Docker is no option for me as my NAS is based on ARM.

I will seek advice in Synology forum and revert.
Silicon Dust offers an official guide to setup storage on your NAS from a Windows PC here. They list demonrik's package as an alternative. I think that's mainly because installing an SPK is easier than following their instructions.

That being said using the default SD NAS installer seems like your best/only alternative IF Demonrik's SPK stops working in March due to PHP 7.2 changes. My personal guess is that it will continue to work unless you have to reinstall DSM and PHP 7.2 is no longer available to install.

Even then there's a very good chance you will still be able to find PHP 7.2 in a different package repository than the one Synology uses by default. I forget the name, but there are several trusted alternate repositories that offer additional packages and I imagine you won't be the only person who wants PHP 7.2 after March. If they are just removing the package from their official repository I wouldn't worry about it.

I should've posted this originally, but I configured all this stuff a year ago and I forgot a lot of it, so I had to refresh my brain. Thankfully I keep notes!

CockneyBoy
Posts: 26
Joined: Tue Oct 01, 2019 2:14 pm
Location: Hamburg, Germany

Re: Synology SPK for DVR Record Engine

Post by CockneyBoy »

DornoDios wrote: Sun Feb 06, 2022 1:35 am
CockneyBoy wrote: Sun Feb 06, 2022 12:24 am @DornoDios

Your question is exactly my problem, I do not know what happens when the package is removed.
A deinstallation is very unlikely, but will everything continue to work as normal?

Docker is no option for me as my NAS is based on ARM.

I will seek advice in Synology forum and revert.
Silicon Dust offers an official guide to setup storage on your NAS from a Windows PC here. They list demonrik's package as an alternative. I think that's mainly because installing an SPK is easier than following their instructions.

That being said using the default SD NAS installer seems like your best/only alternative IF Demonrik's SPK stops working in March due to PHP 7.2 changes. My personal guess is that it will continue to work unless you have to reinstall DSM and PHP 7.2 is no longer available to install.

Even then there's a very good chance you will still be able to find PHP 7.2 in a different package repository than the one Synology uses by default. I forget the name, but there are several trusted alternate repositories.
Thanks for this.
I forgot that demonik's package is actually a (better) alternative.
Then I have fallback if the worst case comes.
SD have anyway said they would revisit their installer.

I will simple wait and see. I have accrued a lot of patience during 2 years of covid.

MNOiSY
Posts: 90
Joined: Sun Oct 16, 2016 6:17 pm

Re: Synology SPK for DVR Record Engine

Post by MNOiSY »

Updated one of my DS to 7.1 beta today and it looks like this breaks the recording engine.

Tried all the standard steps of open base path, permissions, http group, config resets, etc. with no success. I know there are some changes in webstation in the new beta that are probably affecting this.

Anyone have ideas on how to fix?

Getting the Unable to discover dvr status/version. Storage ID not set.

I had to enable the curl extension manually after the webstation update. Are there any others required?

PHP debug shows:

Code: Select all

Notice: Undefined index: DeviceAuth in /volume1/web_packages/HDHomeRunDVR/includes/dvrui_hdhrjson.php on line 127

Notice: Trying to access array offset on value of type null in /volume1/web_packages/HDHomeRunDVR/includes/dvrui_hdhrjson.php on line 58
and

Code: Select all

Warning: Declaration of TabAlert::getBehavior($data) should be compatible with Tab::getBehavior() in /volume1/web_packages/HDHomeRunDVR/TinyAjaxBehavior.php on line 110 Warning: Declaration of TabSetValue::getBehavior($form_id, $data) should be compatible with Tab::getBehavior() in /volume1/web_packages/HDHomeRunDVR/TinyAjaxBehavior.php on line 125 Warning: Declaration of TabInnerHtml::getBehavior($form_id, $data) should be compatible with Tab::getBehavior() in /volume1/web_packages/HDHomeRunDVR/TinyAjaxBehavior.php on line 138 Warning: Declaration of TabInnerHtmlPrepend::getBehavior($form_id, $data) should be compatible with Tab::getBehavior() in /volume1/web_packages/HDHomeRunDVR/TinyAjaxBehavior.php on line 151 Warning: Declaration of TabInnerHtmlAppend::getBehavior($form_id, $data) should be compatible with Tab::getBehavior() in /volume1/web_packages/HDHomeRunDVR/TinyAjaxBehavior.php on line 163 Warning: Declaration of TabAddOption::getBehavior($element_id, $id, $value, $select_it = 0) should be compatible with Tab::getBehavior() in /volume1/web_packages/HDHomeRunDVR/TinyAjaxBehavior.php on line 179 Warning: Declaration of TabClearOptions::getBehavior($element_id) should be compatible with Tab::getBehavior() in /volume1/web_packages/HDHomeRunDVR/TinyAjaxBehavior.php on line 195 Warning: Declaration of TabRemoveSelectedOption::getBehavior($element_id) should be compatible with Tab::getBehavior() in /volume1/web_packages/HDHomeRunDVR/TinyAjaxBehavior.php on line 213 Warning: Declaration of TabSetBackgroundColor::getBehavior($element_id, $color) should be compatible with Tab::getBehavior() in /volume1/web_packages/HDHomeRunDVR/TinyAjaxBehavior.php on line 245 Warning: Declaration of TabRedirect::getBehavior($location) should be compatible with Tab::getBehavior() in /volume1/web_packages/HDHomeRunDVR/TinyAjaxBehavior.php on line 258 Warning: Declaration of TabEval::getBehavior($scriptName) should be compatible with Tab::getBehavior() in /volume1/web_packages/HDHomeRunDVR/TinyAjaxBehavior.php on line 273

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 »

MNOiSY wrote: Wed Feb 23, 2022 4:28 pm Updated one of my DS to 7.1 beta today and it looks like this breaks the recording engine.

Tried all the standard steps of open base path, permissions, http group, config resets, etc. with no success. I know there are some changes in webstation in the new beta that are probably affecting this.

Anyone have ideas on how to fix?

Getting the Unable to discover dvr status/version. Storage ID not set.

I had to enable the curl extension manually after the webstation update. Are there any others required?

PHP debug shows:

Code: Select all

Notice: Undefined index: DeviceAuth in /volume1/web_packages/HDHomeRunDVR/includes/dvrui_hdhrjson.php on line 127

Notice: Trying to access array offset on value of type null in /volume1/web_packages/HDHomeRunDVR/includes/dvrui_hdhrjson.php on line 58
Something in the PHP is not happy with the JSON processing from the request to the SD APIs.
Could be the XML packages are missing in the PHP Install.
Line 127 is where the constructor for the discover tries to store the device. the fact it's complaining that DeviceAuth doesn't exist is either the request never made it out but it thinks it did and got nothing back, or the getting back it failed.
You can set the const DVRUI_DEBUG to 'true' instead of 'false' in /volume1/web_packages/HDHomeRunDVR/vars.php to get more debug information pushed to /tmp/php-hdhomerundvr-ui.log
It might help identify where exactly stuff is going wrong.
I suspect the json_decode() of the returned JSON is failing, or curl_exec() since you said you enabled curl extension - hence I really think it's a json_decode missing issue - so probably need php_json and php_xml and I'd recommend curl and dom packages.
and

Code: Select all

Warning: Declaration of TabAlert::getBehavior($data) should be compatible with Tab::getBehavior() in /volume1/web_packages/HDHomeRunDVR/TinyAjaxBehavior.php on line 110 Warning: Declaration of TabSetValue::getBehavior($form_id, $data) should be compatible with Tab::getBehavior() in /volume1/web_packages/HDHomeRunDVR/TinyAjaxBehavior.php on line 125 Warning: Declaration of TabInnerHtml::getBehavior($form_id, $data) should be compatible with Tab::getBehavior() in /volume1/web_packages/HDHomeRunDVR/TinyAjaxBehavior.php on line 138 Warning: Declaration of TabInnerHtmlPrepend::getBehavior($form_id, $data) should be compatible with Tab::getBehavior() in /volume1/web_packages/HDHomeRunDVR/TinyAjaxBehavior.php on line 151 Warning: Declaration of TabInnerHtmlAppend::getBehavior($form_id, $data) should be compatible with Tab::getBehavior() in /volume1/web_packages/HDHomeRunDVR/TinyAjaxBehavior.php on line 163 Warning: Declaration of TabAddOption::getBehavior($element_id, $id, $value, $select_it = 0) should be compatible with Tab::getBehavior() in /volume1/web_packages/HDHomeRunDVR/TinyAjaxBehavior.php on line 179 Warning: Declaration of TabClearOptions::getBehavior($element_id) should be compatible with Tab::getBehavior() in /volume1/web_packages/HDHomeRunDVR/TinyAjaxBehavior.php on line 195 Warning: Declaration of TabRemoveSelectedOption::getBehavior($element_id) should be compatible with Tab::getBehavior() in /volume1/web_packages/HDHomeRunDVR/TinyAjaxBehavior.php on line 213 Warning: Declaration of TabSetBackgroundColor::getBehavior($element_id, $color) should be compatible with Tab::getBehavior() in /volume1/web_packages/HDHomeRunDVR/TinyAjaxBehavior.php on line 245 Warning: Declaration of TabRedirect::getBehavior($location) should be compatible with Tab::getBehavior() in /volume1/web_packages/HDHomeRunDVR/TinyAjaxBehavior.php on line 258 Warning: Declaration of TabEval::getBehavior($scriptName) should be compatible with Tab::getBehavior() in /volume1/web_packages/HDHomeRunDVR/TinyAjaxBehavior.php on line 273
ok - this is a PHP update saying all this stuff is about to be blown up with the next PHP release.
I had a catch all for PHP 7 which could be failing with any update synology does. The debug setting will log if the catch is working.

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

Re: Synology SPK for DVR Record Engine

Post by signcarver »

I will have to double check but most likely it is either an issue of https for http discovery (which nickk mentioned is probably going away soon but basically any communication to SD's servers need https now) or the device didn't connect to SD to get a DeviceAuth I also think there was some talk of the new php version not working with some things. (By the way, curl needs a location parameter for the redirect SD does if accessed by http rather than https.... note devices/engines are still http)

None of that should have been needed for the record engine to install and run. What it may be used for is the DVRUI which will probably need a lot of work.

MNOiSY
Posts: 90
Joined: Sun Oct 16, 2016 6:17 pm

Re: Synology SPK for DVR Record Engine

Post by MNOiSY »

demonrik wrote: Wed Feb 23, 2022 5:03 pm You can set the const DVRUI_DEBUG to 'true' instead of 'false' in /volume1/web_packages/HDHomeRunDVR/vars.php to get more debug information pushed to /tmp/php-hdhomerundvr-ui.log
It might help identify where exactly stuff is going wrong.
I suspect the json_decode() of the returned JSON is failing, or curl_exec() since you said you enabled curl extension - hence I really think it's a json_decode missing issue - so probably need php_json and php_xml and I'd recommend curl and dom packages.
Forgive my bad memory. It has been a WHILE since I had to mess with ssh and permissions for the DS. I have winscp setup and can log in, but I am unable to edit vars.php to change the flag to true.

Is there a way to sudo execute a permission command to be able to update or change permissions of the file, so I can edit it and get back to you with additional information?

I am way too tired at the moment to even try to remember this stuff!

Thanks for your help as always!

MNOiSY
Posts: 90
Joined: Sun Oct 16, 2016 6:17 pm

Re: Synology SPK for DVR Record Engine

Post by MNOiSY »

anyone :)

... Not sure if it helps but tried a normal install with the HDHomerun setup app and that also failed.

Service start failed

Unable to install

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 »

MNOiSY wrote: Wed Feb 23, 2022 5:51 pm
demonrik wrote: Wed Feb 23, 2022 5:03 pm You can set the const DVRUI_DEBUG to 'true' instead of 'false' in /volume1/web_packages/HDHomeRunDVR/vars.php to get more debug information pushed to /tmp/php-hdhomerundvr-ui.log
It might help identify where exactly stuff is going wrong.
I suspect the json_decode() of the returned JSON is failing, or curl_exec() since you said you enabled curl extension - hence I really think it's a json_decode missing issue - so probably need php_json and php_xml and I'd recommend curl and dom packages.
Forgive my bad memory. It has been a WHILE since I had to mess with ssh and permissions for the DS. I have winscp setup and can log in, but I am unable to edit vars.php to change the flag to true.

Is there a way to sudo execute a permission command to be able to update or change permissions of the file, so I can edit it and get back to you with additional information?

I am way too tired at the moment to even try to remember this stuff!

Thanks for your help as always!
apologies - unsupported does mean that I don't look here very often anymore
sudo does work on synology AFAIR
if you 'sudo -i' on the synology it should give you a root interactive shell and then you can execute any commands you want.
then you can CHMOD the permissions or simply edit as root with something like vi or nano.

NedS
Silicondust
Posts: 3146
Joined: Mon Dec 10, 2018 12:38 pm
x 163

Re: Synology SPK for DVR Record Engine

Post by NedS »

The DMS 7.1 beta seems to be mounting /tmp/ as noexec, so both the SPK package and the official HDHomeRun installer won't work at the moment. The Docker image should work. I'll throw up some temp-work-around instructions for non-Docker users at the moment, but if the Docker option is available to you, now would be a good time to migrate.

We hope to have a long-term option for people who don't want to use (or can't use) the Docker image, in the near future.

Post Reply