[HowTo]: install vdr and vnsiserver to watch live-tv

To install vdr with streamdev-server and vnsiserver to watch live-tv in osmc and on your home-pc and android devices

  • log in via ssh

ssh osmc@osmc

  • and execute the following commands:

sudo apt-get install nano pciutils usbutils mc
sudo nano /etc/apt/sources.list

  • add this line to your sources.list:

deb-src Index of /debian jessie main contrib non-free

  • press crtl+x, y, enter to save and exit
  • exit kodi to update osmc:

sudo systemctl stop mediacenter
sudo apt-get update && sudo apt-get dist-upgrade

  • to install dvb firmware files:

sudo apt-get install dvb-firmware-osmc firmware-linux-free dvb-apps w-scan

  • install the software to build the vnsiserver:

sudo apt-get build-dep vdr
sudo apt-get install git vdr vdr-dev

  • let vdr create the video.00 directory and choose the right type of your dvb-tuner.
  • to install many more dvb-firmware files do:

git clone GitHub - OpenELEC/dvb-firmware
cd dvb-firmware
sudo ./install
cd

  • to build and install vnsiserver :

copy release 1.5.0 of vnsiserver from here: Releases · FernetMenta/vdr-plugin-vnsiserver · GitHub,
extract it and change to that directory
cd vdr-plugin-vnsiserver-1.5.0
make
sudo make install
sudo cp -R ./vnsiserver /var/lib/vdr/plugins/
cd

  • install some helpful vdr-plugins:
  • to see the full list of vdr-plugins execute: apt-cache search vdr

sudo apt-get install vdr-plugin-epgsearch vdr-plugin-live vdr-plugin-streamdev-server vdr-plugin-svdrpservice vdr-plugin-svdrposd

  • now use midnight-commander to edit the following files:

sudo mc

  • navigate to /etc/default and edit the file: vdr, set ENABLED to 1, press ctrl+x, y and enter to save and exit.

  • navigate to /etc/vdr and edit the file svdrphosts.conf, and add your home-network ip.

  • for example mine is 192.168.178.0/24, press ctrl+x, y and enter to save and exit.

  • repeat this with the file: streamdevhosts.conf in /etc/vdr/plugins ,

  • and with: allowed_hosts.conf in /var/lib/vdr/plugins/vnsiserver.

  • use w_scan -h to find out how to create a working channels.conf file for your type of TV-card.
    for example : for my dvb-t stick i use: w_scan -f t -A 1 -c DE > channels.conf
    copy the created channels.conf to /var/lib/vdr/channels.conf

  • now reboot and if you’re lucky vdr should start and you can enable the VDR VNSI Client addon in osmc to watch live-tv.

  • enter http://ip of osmc:8008 in your browser to access the vdr-live plugin from your PC, login is admin, password live.

  • enter http://ip of osmc:3000 in your browser to access the vdr-streamdev plugin from your PC

  • on your android devices use the App: AndroVdr to watch live-tv on your android phone or tablet.

  • if it doesn’t work look if the firmware for you dvb-device is installed in /lib/firmware and check the output of:
    dmesg | grep -i dvb

  • to see if your device is recognized at boot.

Hello, tried to follow your instructions (thanks they are detailled enough even for me).

At the step

~/vdr-plugin-vnsiserver$ make

I get this error:

g++ -g -O2 -fstack-protector-strong -Wformat -Werror=format-security -D_FORTIFY_SOURCE=2 -fPIC -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -std=c++11 -c -D_GNU_SOURCE -DPLUGIN_NAME_I18N=‘“vnsiserver”’ -DVNSI_SERVER_VERSION=‘“1.5.1”’ -o videoinput.o videoinput.c
videoinput.c: In static member function ‘static std::shared_ptr cDummyReceiver::Create(cDevice*)’:
videoinput.c:468:40: error: ‘class cDummyReceiver’ has no member named ‘Device’
if (!recv->BeenDetached() && recv->Device() == device)
^
Makefile:86: recipe for target ‘videoinput.o’ failed

Advice appreciated !

Cheers,
Wolf

Same here, the newest release doesn’t work with vdr 2.0.3. Download release 1.5.0 Releases · FernetMenta/vdr-plugin-vnsiserver · GitHub ,unzip, and make from there. That worked for me.

The instructions here are DANGEROUS!

NEVER run apt-get upgrade it will break your system.

Instead run apt-get dist-upgrade

If you have already followed these instructions you will need to reinstall OSMC from scratch as the damage is irrepairable.

Thank you very much for updating the instructions. I could build and launch VDR - and it’s nicely integrated. Great!

Now, with quite some struggle I found the recordings unter /var/lib/video.00. Hm, interesting place…
Tried to symlink this directory to /mnt/video0 (where my hard disk lives) - but again I’m stupid enough not to manage it.
Sorry - again I do need your valued advice.

BTW: “live” web interface is in English, on my German system. Can I change that?

Cheers,
Wolf

How do you mean by you didn’t manage it?

What error did you get when you ran sudo ln -s /var/lib/video.00 /mnt/video0/recordings

Also did you follow the opening post directly? If you did, please see my other post above about dangerous commands.

@ yknivag
Hello. I followed the instuctions directly, and did not destroy my system.

When I create your symlink, the recording still is placed on the SD card, and not on the external HD, mounted under /mnt/video0. - But I need to redirect the recordings to the external hard disk.

Oh sorry, I think I didn’t quite understand what you wanted to do. Try this instead:

sudo -s
cd /var/lib/video.00
mv * /mnt/video0
cd ..
rmdir video.00
ln -s /mnt/video0 ./video.00
exit

sudo apt-get upgrade won’t stop your system working right away, but it will almost certainly have caused hidden damage which will appear as and when you do future upgrades. If you have run that command then you will need to re-install at some point.

I found this easy solution - but it was really difficult to find:

Edit the /etc/defaults/vdr, and add the recording path by -v :

OPTIONS=“-w 60 -v /mnt/video1”

I think it might be a good idea to set it to /video0 as default.

Now I’m looking for my beloved cutting and editing feature… (-;
Luckily I found this table, so I already have got basic control over the system.

W

edit /etc/default/vdr and add your video directory to the OPTIONS line.
OPTIONS="-w 60 --video /mnt/video0"
you must change the owner and group of your video directory
sudo chown vdr:vdr /mnt/video0
to change the live plugin to german adding this line to /etc/default/vdr should work
export VDR_LANG=de_DE.UTF-8
if it doesn’t work you have to add de_DE.UTF-8 to your locales.
sudo dpkg-reconfigure locales
mark de_DE.ISO-8859-1 and de_DE.UTF-8 in the list,
in the next dialog
select de_DE.UTF-8 as system locale and reboot.

Yes, this works! - Thank you.
Now remains the question - how can I use VDR’s cutting and editing features?
I found how I can set bookmarks at the timeline - but the number keys are not doing anything, as I was used with VDR. Is the feature disabled?

W

You should be able to edit the HowTo to adjust this command.

It seems it has now been edited.

Good stuff.

I never used this feature, but it’s builtin in every vdr version. I found this: VDR User's Manual - VDR Wiki
but i believe you must run VDR directly from commandline, not from inside kodi. Try to exit the mediacenter and run vdr from commandline with /etc/init.d/vdr start

Till now, I could not make a standalone VDR work. It shows up as a process at “top” - but I cannot see any activity on my TV screen.

Es fehlt ein Ausgabeplugin für vdr

howto:
sudo apt-get install git libavcodec56 libavformat56 libavutil54 libavresample2 libfreetype6 libavcodec-dev libavformat-dev libavutil-dev libavresample-dev libfreetype6-dev rbp-userland-dev-osmc

git clone git://projects.vdr-developer.org/vdr-plugin-rpihddevice.git rpihddevice
cd rpihddevice

  • alles aus /opt/vc/include/ nach rpihddevice kopieren
    make
    sudo make install

  • exit kodi to the commandline

sudo systemctl stop mediacenter
sudo /etc/init.d/vdr restart

I tested this and it works, but it’s unusable with OSMC, you have Kodi and vdr running at the same time in one display. This means you can use vdr from commandline but not in kodi.
For your cutting and editing needs i would recommend MiniDVBLinux Distribution
here you have kodi and vdr clearly separated. You could run vdr on commandline for cutting and editing and inside kodi to watch tv without problems.

Thank you very much for all your effort.
To be honest - that’s not why I choose osmc. My goal was to have a comfortable and configurable solution, where as much as possible works out of the box.

Hopefully, one day some smart fellow will manage to map VDR’s editing commands through Kodi and we’ll have a nicely integrated solution. Luckily, I’m not short of disk space at the moment and can wait quite some time for that. In the case of emergency, ffmpeg offers a comparatively easy cutting feature.

Here’s an easier way to install VDR backend for RPi users:

Download the Xbian packages here

sudo dpkg -i vdr*.deb

In /etc/systemd/system create a file vdr.service and insert the following

[Unit]
Descritpion=vdr

[Service]
Type=once
ExecStart=/usr/bin/vdr
TimeoutSec=20

[Install]
WantedBy=multi-user.target

sudo systemctl enable vdr.service