NextPVR Forums
  • Home
  • New Posts
  • Wiki
  • Members
  • Help
  • Search
  • Register
  • Login
  • Home
  • Wiki
  • Members
  • Help
  • Search
NextPVR Forums Public NextPVR Support Linux v
« Previous 1 … 22 23 24 25 26 Next »
Script Files

 
  • 0 Vote(s) - 0 Average
Script Files
vintdiesel
Offline

Member

Posts: 105
Threads: 21
Joined: Jan 2012
#1
2019-07-24, 10:25 PM
For V4, I have a Postprocessing.bat file for compressing recordings to .mp4's using ffmpeg. By tweaking the settings, I have been able to store and archive shows to a 1/3 of the storage space without sacrificing noticeable quality.

With V5 under a Linux environment, I am guessing I will have to translate the .bat files to Bash script?
Win Server: ASRock P67 Pro3 B3, i5 2500K 4.0Ghz, 16GB, Nvidia GT430 HDMI, Win 10 Pro 64bit, Win-TV Quad HD, Win-TV Nova-T USB.
UnRaid NAS Server: Gigabyte i7 2600 3.4Ghz, 16GB, S3 Trio VGA PCI Video, DVB LibreElec for DVB-T tuner drivers, Hauppage Win-TV 2210 Dual DVB-T.
Win Client: Intel NUC i3 Broadwell, 4GB Ram, 128GB SSD, Win 10 Pro 64bit.
Linux Client: Raspberry Pi 3+, OSMC + Kodi
sub
Offline

Administrator

NextPVR HQ, New Zealand
Posts: 102,394
Threads: 741
Joined: Nov 2003
#2
2019-07-25, 01:08 AM
It'll look for a .NPVR-data/scripts/PostProcessing.sh file on Linux. You can add similar login in there.
vintdiesel
Offline

Member

Posts: 105
Threads: 21
Joined: Jan 2012
#3
2019-07-25, 02:49 AM
Thanks for the reply sub,

Is ffmpeg part of the NextPVR docker container installation, or will I have to install ffmpeg separately?
Damian
Win Server: ASRock P67 Pro3 B3, i5 2500K 4.0Ghz, 16GB, Nvidia GT430 HDMI, Win 10 Pro 64bit, Win-TV Quad HD, Win-TV Nova-T USB.
UnRaid NAS Server: Gigabyte i7 2600 3.4Ghz, 16GB, S3 Trio VGA PCI Video, DVB LibreElec for DVB-T tuner drivers, Hauppage Win-TV 2210 Dual DVB-T.
Win Client: Intel NUC i3 Broadwell, 4GB Ram, 128GB SSD, Win 10 Pro 64bit.
Linux Client: Raspberry Pi 3+, OSMC + Kodi
sub
Offline

Administrator

NextPVR HQ, New Zealand
Posts: 102,394
Threads: 741
Joined: Nov 2003
#4
2019-07-25, 05:18 AM
Yes, ffmpeg is included in the docker container.
vintdiesel
Offline

Member

Posts: 105
Threads: 21
Joined: Jan 2012
#5
2019-07-25, 08:33 AM
Cheers sub, I shall try writing a script then. Wink
Win Server: ASRock P67 Pro3 B3, i5 2500K 4.0Ghz, 16GB, Nvidia GT430 HDMI, Win 10 Pro 64bit, Win-TV Quad HD, Win-TV Nova-T USB.
UnRaid NAS Server: Gigabyte i7 2600 3.4Ghz, 16GB, S3 Trio VGA PCI Video, DVB LibreElec for DVB-T tuner drivers, Hauppage Win-TV 2210 Dual DVB-T.
Win Client: Intel NUC i3 Broadwell, 4GB Ram, 128GB SSD, Win 10 Pro 64bit.
Linux Client: Raspberry Pi 3+, OSMC + Kodi
vintdiesel
Offline

Member

Posts: 105
Threads: 21
Joined: Jan 2012
#6
2019-07-29, 10:36 AM
Quote:It'll look for a .NPVR-data/scripts/PostProcessing.sh file on Linux.

OK I tried writing some simple echo statement to write to a processing.log file but I can't seem to get it invoked when a recording finishes.
I cannot find the path on my system as stated above.

If I open a console as root, PostProcessing.sh is located in mnt/appdata/NextPVR/Config/scripts

If I open a console from the docker, the location to the same file is /config/scripts/, noting that config is in all lowercase to above.

Maybe I haven't got to grips with Linux and docker containers yet, the learning curve is steep for me at the moment.
Win Server: ASRock P67 Pro3 B3, i5 2500K 4.0Ghz, 16GB, Nvidia GT430 HDMI, Win 10 Pro 64bit, Win-TV Quad HD, Win-TV Nova-T USB.
UnRaid NAS Server: Gigabyte i7 2600 3.4Ghz, 16GB, S3 Trio VGA PCI Video, DVB LibreElec for DVB-T tuner drivers, Hauppage Win-TV 2210 Dual DVB-T.
Win Client: Intel NUC i3 Broadwell, 4GB Ram, 128GB SSD, Win 10 Pro 64bit.
Linux Client: Raspberry Pi 3+, OSMC + Kodi
sub
Offline

Administrator

NextPVR HQ, New Zealand
Posts: 102,394
Threads: 741
Joined: Nov 2003
#7
2019-07-29, 05:07 PM
vintdiesel Wrote:If I open a console as root, PostProcessing.sh is located in mnt/appdata/NextPVR/Config/scripts
Is that path right? Is npvr.db3 in /mnt/appdata/NextPVR/Config/?
mvallevand
Offline

Posting Freak

Ontario Canada
Posts: 45,330
Threads: 865
Joined: May 2006
#8
2019-07-29, 06:00 PM
I am a bit confused with @vintdiesel's post because I am not sure if he is talking about a docker or linux install but I tried in linux
based on the thread topic and the instructions seem to work but I don't know if the logic works

Code:
2019-07-29 13:46:00.364    [DEBUG][8]    Starting: /var/opt/nextpvr/scripts/PostProcessing.sh "/home/martin/recordings/Zou/Season 02/Zou.S02E02.Zous Alien Hunt.ts" 24.1 851 23 "Zou"
2019-07-29 13:46:00.378    [DEBUG][8]    Unexpected error starting post processing: System.ComponentModel.Win32Exception (8): Exec format error
   at Interop.Sys.ForkAndExecProcess(String filename, String[] argv, String[] envp, String cwd, Boolean redirectStdin, Boolean redirectStdout, Boolean redirectStderr, Boolean setUser, UInt32 userId, UInt32 groupId, Int32& lpChildPid, Int32& stdinFd, Int32& stdoutFd, Int32& stderrFd, Boolean shouldThrow)
   at System.Diagnostics.Process.StartCore(ProcessStartInfo startInfo)
   at System.Diagnostics.Process.Start()
   at System.Diagnostics.Process.Start(ProcessStartInfo startInfo)
   at NShared.RecordingService.StartPostProcessing(ScheduledRecording scheduledRecording)

running the command from the command line works

Martin
sub
Offline

Administrator

NextPVR HQ, New Zealand
Posts: 102,394
Threads: 741
Joined: Nov 2003
#9
2019-07-29, 06:07 PM
mvallevand Wrote:I am a bit confused with @vintdiesel's post because I am not sure if he is talking about a docker or linux install but I tried in Linux
Yeah I was too. I'm pretty sure he's using docker, so post should really have been in the docker forum.

Quote:based on the thread topic and the instructions seem to work but I don't know if the logic works

Code:
2019-07-29 13:46:00.364    [DEBUG][8]    Starting: /var/opt/nextpvr/scripts/PostProcessing.sh "/home/martin/recordings/Zou/Season 02/Zou.S02E02.Zous Alien Hunt.ts" 24.1 851 23 "Zou"
2019-07-29 13:46:00.378    [DEBUG][8]    Unexpected error starting post processing: System.ComponentModel.Win32Exception (8): Exec format error
   at Interop.Sys.ForkAndExecProcess(String filename, String[] argv, String[] envp, String cwd, Boolean redirectStdin, Boolean redirectStdout, Boolean redirectStderr, Boolean setUser, UInt32 userId, UInt32 groupId, Int32& lpChildPid, Int32& stdinFd, Int32& stdoutFd, Int32& stderrFd, Boolean shouldThrow)
   at System.Diagnostics.Process.StartCore(ProcessStartInfo startInfo)
   at System.Diagnostics.Process.Start()
   at System.Diagnostics.Process.Start(ProcessStartInfo startInfo)
   at NShared.RecordingService.StartPostProcessing(ScheduledRecording scheduledRecording)

running the command from the command line works

Martin
Argh. I see what I need to change. Thanks.
vintdiesel
Offline

Member

Posts: 105
Threads: 21
Joined: Jan 2012
#10
2019-07-29, 10:24 PM
Thanks Guys,

Apologies for the confusion, yes I am running this in docker on a NAS box. Originally the post was about scripting and how to go about writing them, so I though the question could be best posted in the Linux forum for the best audience coverage.

Now I am covering pathing in the docker environment, so it may be best for me to create a new post and continue correspondence in that forum.
Damian
Win Server: ASRock P67 Pro3 B3, i5 2500K 4.0Ghz, 16GB, Nvidia GT430 HDMI, Win 10 Pro 64bit, Win-TV Quad HD, Win-TV Nova-T USB.
UnRaid NAS Server: Gigabyte i7 2600 3.4Ghz, 16GB, S3 Trio VGA PCI Video, DVB LibreElec for DVB-T tuner drivers, Hauppage Win-TV 2210 Dual DVB-T.
Win Client: Intel NUC i3 Broadwell, 4GB Ram, 128GB SSD, Win 10 Pro 64bit.
Linux Client: Raspberry Pi 3+, OSMC + Kodi
« Next Oldest | Next Newest »

Users browsing this thread: 1 Guest(s)

Pages (2): 1 2 Next »


Possibly Related Threads…
Thread Author Replies Views Last Post
  NextPVR Server VOD Downloads Incomplete TS Video Files nonuoha 18 158 2023-03-21, 10:53 PM
Last Post: mvallevand
  Post Processing and moving files ballfam 16 325 2022-12-30, 06:59 PM
Last Post: ballfam
  Think all the script files must've disappeared mlp78758 13 282 2022-11-25, 05:34 PM
Last Post: mvallevand
  TV Show recording broken into multiple files markosjal 2 315 2022-07-09, 04:53 AM
Last Post: markosjal
  Empty files when writing to samba share aimaim 3 307 2022-07-05, 10:31 PM
Last Post: mvallevand
  Linux upgrade shell script.. NextPVR-consumer 3 501 2021-12-05, 03:17 PM
Last Post: mvallevand
  Orphaned livetv buffer files snagglewest 6 585 2021-08-09, 04:23 PM
Last Post: mvallevand
  bulk comskip processing script baj1 7 1,609 2020-11-21, 08:44 PM
Last Post: baj1
  Script locations and parameters ? ceejayemm 2 651 2020-10-14, 12:02 PM
Last Post: ceejayemm
  NextPVR creates empty TS files motocrossmann 11 1,917 2020-06-04, 03:32 PM
Last Post: motocrossmann

  • View a Printable Version
  • Subscribe to this thread
Forum Jump:

© Designed by D&D, modified by NextPVR - Powered by MyBB

Linear Mode
Threaded Mode