nextpvr helper - sub3/NextPVR GitHub Wiki

Linux Installer: nextpvr-helper.deb

This Installer will download all the components needed to install and run NextPVR-Server on a Linux machine as a service. For security reasons the installed server will run as user 'nextpvr'.

The Installer is in the form of a Linux .deb file (nextpvr-helper.deb, referred to here as the 'Installer') which will:

  • fetch the current NextPVR stable application version and other additional software components needed by the Installer
  • update/upgrade Microsoft Netcore (.Net) if applicable
  • install the NextPVR application, including the nextpvr-server as a service
  • provide a notification if a newer version of the .deb file is available.

IMPORTANT: This Installer is ONLY intended to be used with Debian based Linux O/S variants. For any other Linux installations please follow the standard Linux installation instructions here

The current version of nextpvr-helper is 2.1

Prerequisites

If not already installed, curl is needed by the installation process, use:
sudo apt update
sudo apt install curl

Install nextpvr-helper

Download the Installer file:
curl https://nextpvr.com/nextpvr-helper.deb -O

First time installation of the Installer:
sudo apt install ./nextpvr-helper.deb --install-recommends

the ./ in the command above is important.

Wait for it to start, then open:

or

to setup NextPVR.

New versions of the Installer will be announced here, it is not necessary to download/upgrade the Installer unless a new version is announced.

Upgrade to a newer version of the Installer:
curl https://nextpvr.com/nextpvr-helper.deb -O

Upgrade to a newer version of the NextPVR application: sudo dpkg -i nextpvr-helper.deb

To Uninstall nextpvr-helper

  1. Uninstall the program files (except dotnet)
    sudo apt remove nextpvr-helper

  2. Remove the Installer.
    CAUTION: this will remove the Installer and ALL NextPVR configuration data (npvr.db3 database, configuration files etc). Make sure you have a good backup of the relevant files BEFORE using this command.
    sudo apt purge nextpvr-helper

Please see Purge Notes below for further information regarding removing the Installer files.

Useful Commands

The Installer creates the nextpvr-server service which will run automatically after the installation completes

Check the status of the server service:
service nextpvr-server status

Stop the server service:
sudo service nextpvr-server stop

Start the server service:
sudo service nextpvr-server start
or
sudo service nextpvr-server restart

Prevent the server service from starting automatically:
sudo systemctl disable nextpvr-server

Permission Requirements

Note: The nextpvr-server service runs with username nextpvr, all recording folders used by the service need to be given the appropriate permissions to be accessed by the user nextpvr or for members of the video group. Folders held on a share may need to be treated differently with access/permissions being set on the share provider system.

In the following commands {folder} relates to the folder path being assigned the relevant access/permissions.

  1. Allow access to video group
    chgrp video {folder}

  2. Give video group write permission
    chmod +775 {folder}

  3. Create new files create with video group
    chmod g+s {folder}

  4. Give write access to video group
    setfacl -d -m g::rwX {folder}

The Installer includes a script to help set the required permissions. Its general use is:

sudo /opt/nextpvr/shell/nextpvr-recording.sh {folder}

Examples of its use are shown below:

sudo /opt/nextpvr/shell/nextpvr-recording.sh /videos/livetv
sudo /opt/nextpvr/shell/nextpvr-recording.sh /videos/recordings
sudo /opt/nextpvr/shell/nextpvr-recording.sh /movies

If you don't want to give access to the video group you will need to chown the folder to the nextpvr user and you can ignore the group settings.

Purge Notes

As noted above using purge commands will remove ALL the NextPVR configuration data, make sure you have a good backup of the relevant files BEFORE using any of these commands

Remove dotnet

For removal, the files are mainly in the folder:

/opt/dotnet

There may be multiple versions of the dotnet runtime held in this folder. To list the install dotnet runtimes use the following command:

/opt/dotnet/dotnet --list-runtimes

These have to be removed manually on Linux. With v6 I will include this as a script so users can uninstall specific versions based on this script.

Users wishing to update/upgrade dotnet sepatately should:

  1. Backup the /opt/dotnet folder to another folder
  2. Remove the /opt/dotnet folder
  3. Run the installation command (using dpkg) will recreate it

To completely uninstall the dotnet runtimes:

sudo rm -r /opt/dotnet

Remove the nextpvr user

The nextpvr user can be removed with

sudo userdel nextpvr

Find any files created by the nextpvr user, user the following command:

find / -user nextpvr

This will list all the recordings (and other files) that the nextpvr user created. If you wish to remove these files you may find this article useful.

Please note however THERE IS ABSOLUTELY NO SUPPORT AVAILABLE if you go down this route and if you encounter any subsequent problems it may be necessary to completely reinstall NextPVR.

Frequently Asked Questions

Q: Does uninstalling the program files using ‘sudo apt remove nextpvr-helper’ only uninstall content from ‘curl https://nextpvr.com/nextpvr-helper.deb -O’ Or does it mess with/access any other files on my device? I am a bit new to how the OS works with files. I want to make sure running the uninstall command doesn’t mess with any other files or things on my device that wasn't installed using the installer.

A: The apt process only uninstalls programs that it installed. Linux tracks other programs installed using apt that have dependencies but if you manually add programs then they may lose functionality. The apt remove command also tells you which programs and libraries are going to be uninstalled giving you a chance to abort the uninstall if necessary. There may also be a second run needed to remove dependencies.

A good example of a potential conflict might be ffmpeg. The installer will install it if it isn't already installed and it will uninstalled it using this command. If ffmpeg is needed for other purposes on your device then you will need to reinstall it manually.

Page Status

Authors: Martin Vallevand, Chris Metcalfe \

Change History

v2.1 2022-09-04 v1.5 2022-03-22