TVHeadend should put recordings on a NAS File

  • Hallo Zusammen,

    Dank Covid19 wollte ich mich meiner Herausforderung stellen (hab ja nun Zeit). Leider bekomme ich es ohne Hilfe nicht hin.

    Ich habe eine NSA325-v2 und TVheadend (auf Rasperry 3b) soll hier in einem Ordner die Aufnahmen ablegen.

    Was habe ich schon gemacht:

    Ich bin nach dieser Anleitung

    Mount LibreElec » permanent ein Netzwerklaufwerk mounten

    vorgegangen und habe die Datei storage-recordings.mount erstellt.

    [Unit]

    Description=Aufnahmepfad zur NAS

    Requires=network-online.service

    After=network-online.service

    # Before=kodi.service

    [Mount]

    What=//192.168.178.57/video/recordings

    Where=/storage/recordings

    Options=username=admin,password=9999

    Type=cifs

    [Install]

    WantedBy=multi-user.target

    Ich bekomme aber diesen Fehler:

    ● storage-recordings.mount - Aufnahmepfad zur NAS

    Loaded: loaded (/storage/.config/system.d/storage-recordings.mount; enabled; vendor preset: disabled)

    Active: failed (Result: exit-code) since Tue 2020-03-24 17:31:48 CET; 27min ago

    Where: /storage/recordings

    What: //192.168.178.57/video/recordings

    Mar 24 17:31:48 LibreELEC systemd[1]: Mounting Aufnahmepfad zur NAS...

    Mar 24 17:31:48 LibreELEC mount[448]: mount: mounting //192.168.178.57/video/recordings on /storage/recordings failed: Host is down

    Mar 24 17:31:48 LibreELEC systemd[1]: storage-recordings.mount: Mount process exited, code=exited status=255

    Mar 24 17:31:48 LibreELEC systemd[1]: storage-recordings.mount: Failed with result 'exit-code'.

    Mar 24 17:31:48 LibreELEC systemd[1]: Failed to mount Aufnahmepfad zur NAS.

    In den Einstellungen bei Libeelec habe ich Samba aktiviert und als niedrigstes Protokoll 1 und höchstes 3 angegeben. Gleicher Fehler.

    Über Windows sieht die Adresszeile im Explorer so aus \\192.168.178.57\video\recordings

    Ich hoffe Ihr könnt mir hier helfen, vielen Dank schon mal dafür und bleibt gesund.

    Holger

    PS Ich nutze Putty um auf den Rasperry 3b zu kommen

  • So I try again,

    Hello everybody,


    Thanks to Covid19 I wanted to face my challenge (now I have time). Unfortunately, I can't do it without help.

    I have an NSA325-v2 and TVheadend (on Rasperry 3b) should put the recordings here in a folder.


    What have I already done:


    I followed these instructions

    Mount LibreElec » permanent ein Netzwerklaufwerk mounten

    and created the file storage-recordings.mount

    [Unit]

    Description=Aufnahmepfad zur NAS

    Requires=network-online.service

    After=network-online.service

    # Before=kodi.service

    [Mount]

    What=//192.168.178.57/video/recordings

    Where=/storage/recordings

    Options=username=admin,password=9999

    Type=cifs

    [Install]

    WantedBy=multi-user.target

    But "systemctl status storage-recordings.mount" output says:

    ● storage-recordings.mount - Aufnahmepfad zur NAS

    Loaded: loaded (/storage/.config/system.d/storage-recordings.mount; enabled; vendor preset: disabled)

    Active: failed (Result: exit-code) since Tue 2020-03-24 17:31:48 CET; 27min ago

    Where: /storage/recordings

    What: //192.168.178.57/video/recordings

    Mar 24 17:31:48 LibreELEC systemd[1]: Mounting Aufnahmepfad zur NAS...

    Mar 24 17:31:48 LibreELEC mount[448]: mount: mounting //192.168.178.57/video/recordings on /storage/recordings failed: Host is down

    Mar 24 17:31:48 LibreELEC systemd[1]: storage-recordings.mount: Mount process exited, code=exited status=255

    Mar 24 17:31:48 LibreELEC systemd[1]: storage-recordings.mount: Failed with result 'exit-code'.

    Mar 24 17:31:48 LibreELEC systemd[1]: Failed to mount Aufnahmepfad zur NAS.

    In the settings at Libeelec I activated Samba and specified the lowest protocol 1 and highest 3. Same mistake.


    In Windows, the address line in Explorer looks like this: \\192.168.178.57\video\recordings


    I hope you can help me here, thank you in advance.


    Holger

    Hardware

    Rasperry 3b (as Server)

    Digibit R1

    Software

    Libreelec (official) 9.0.2 (kernel: Linux 4.19.36)

    Kodi 18.2

    Tvheadend Version 4.2.7-44 (LibreELEC Tvh-addon v9.0.118(HTSP v27))

    Putty

  • I have a TVH server on my synology nas. On the TVH config webpage under the video recorder profiles, I just typed the path //volume1/TV Recordings

    I didn't mount my drive, the nas is NFS, accessible to all networks, (probably not very safe)

    I don't know if this will work with your setup

  • Hi,

    I have only find the samba.conf.sample nothing else.

    I use --> Libreelec (official) 9.0.2 (kernel: Linux 4.19.36)

    Have a nice day.

    # SPDX-License-Identifier: GPL-2.0-or-later

    # Copyright (C) 2009-2016 Stephan Raue ([email protected])

    # Copyright (C) 2017-present Team LibreELEC (LibreELEC – Just enough OS for KODI)

    # samba.conf v4 (do not remove)

    # This configuration file allows you to customize the samba shares

    # available from your machine

    [global]

    server string = LibreELEC

    browseable = yes

    writeable = yes

    printable = no

    deadtime = 30

    mangled names = no

    name resolve order = host bcast

    printcap name = /dev/null

    load printers = no

    encrypt passwords = true

    enable core files = no

    passdb backend = smbpasswd

    smb encrypt = disabled

    fruit:model = Xserve

    # samba share options

    map to guest = Bad User

    guest account = root

    security = user

    # samba tuning options

    socket options = TCP_NODELAY IPTOS_LOWDELAY

    min receivefile size = 16384

    aio read size = 16384

    aio write size = 16384

    use sendfile = yes

    # The following are default values for the master selection process

    # local master = yes

    # preferred master = auto

    # domain master = auto

    # os level = 20

    # "strict allocate = yes" breaks large network transfers to external hdd

    # Force this to "no" in case "yes" becomes the default in future

    strict allocate = no

    allocation roundup size = 0

    # Using the following configurations as a template allows you to add

    # writeable shares of disks and paths under /storage

    [Update]

    path = /storage/.update

    available = yes

    browseable = yes

    public = yes

    writeable = yes

    root preexec = mkdir -p /storage/.update

    [Videos]

    path = /storage/videos

    available = yes

    browseable = yes

    public = yes

    writeable = yes

    root preexec = mkdir -p /storage/videos

    [Music]

    path = /storage/music

    available = yes

    browseable = yes

    public = yes

    writeable = yes

    root preexec = mkdir -p /storage/music

    [TV Shows]

    path = /storage/tvshows

    available = yes

    browseable = yes

    public = yes

    writeable = yes

    root preexec = mkdir -p /storage/tvshows

    [Recordings]

    path = /storage/recordings

    available = yes

    browseable = yes

    public = yes

    writeable = yes

    root preexec = mkdir -p /storage/recordings

    [Downloads]

    path = /storage/downloads

    available = yes

    browseable = yes

    public = yes

    writeable = yes

    root preexec = mkdir -p /storage/downloads

    [Pictures]

    path = /storage/pictures

    available = yes

    browseable = yes

    public = yes

    writeable = yes

    root preexec = mkdir -p /storage/pictures

    [Emulators]

    path = /storage/emulators

    available = yes

    browseable = yes

    public = yes

    writeable = yes

    root preexec = mkdir -p /storage/emulators

    [Configfiles]

    path = /storage/.config

    available = yes

    browseable = yes

    public = yes

    writeable = yes

    root preexec = mkdir -p /storage/.config

    [Userdata]

    path = /storage/.kodi/userdata

    available = yes

    browseable = yes

    public = yes

    writeable = yes

    root preexec = mkdir -p /storage/.kodi/userdata

    [Screenshots]

    path = /storage/screenshots

    available = yes

    browseable = yes

    public = yes

    writeable = yes

    root preexec = mkdir -p /storage/screenshots

    [Logfiles]

    path = /storage/logfiles

    available = yes

    browseable = yes

    public = yes

    writeable = yes

    root preexec = mkdir -p /storage/logfiles

    root preexec = createlog

    [Backup]

    path = /storage/backup

    available = yes

    browseable = yes

    public = yes

    writeable = yes

    root preexec = mkdir -p /storage/backup

    [Picons]

    path = /storage/picons

    available = yes

    browseable = yes

    public = yes

    writeable = yes

    root preexec = mkdir -p /storage/picons/tvh /storage/picons/vdr

  • re-reading and noticing "failed: Host is down" .. is the "server" pi on a static DHCP reservation? .. or did the IP change?

    NB: I use hostnames for mounts/sources and static IPs or static DHCP reservations for anything client devices need to access.

  • Hi,

    it is DHCP but the router give one Itim an IP Adress and than it is static. I have from every pc write and read rights to this File (NAS) also without username and password (from Homenetwork). Both Libreelec and the NAS are in the same WORKGROUP. The NAS is always power on.

    Why do I have no samba.conf or smb.conf but I see in Windows Network the Libreelec and the files - Backup - Configfiles - Downloads -Emulators - Logfiles - Music - Picons - Pictures - Recordings (empty not the file on NAS) - Screenshots - sda1-usb-... - TV Shows - Update - Userdata - Videos -

    With Kodi I able to see all movies on NAS (via SMB Windows Network).

    I change the storage-recordings.mount

    [Unit]

    Description=Aufnahmepfad zur NAS

    Requires=network-online.service

    After=network-online.service

    Before=kodi.service

    [Mount]

    What=//NSA325-V2/video/recordings

    Where=/storage/recordings

    Options=username=admin,password=9999,rw,vers=2.1

    Type=cifs

    [Install]

    WantedBy=multi-user.target


    But systemctl status storage-recordings.mount says


    ● storage-recordings.mount - Aufnahmepfad zur NAS

    Loaded: loaded (/storage/.config/system.d/storage-recordings.mount; enabled; vendor preset: disabled)

    Active: failed (Result: exit-code) since Thu 2020-03-26 15:23:41 CET; 1min 55s ago

    Where: /storage/recordings

    What: //NSA325-V2/video/recordings

    Mar 26 15:23:41 LibreELEC systemd[1]: Mounting Aufnahmepfad zur NAS...

    Mar 26 15:23:41 LibreELEC mount[440]: mount: mounting //NSA325-V2/video/recordings on /storage/recordings failed: Host is down

    Mar 26 15:23:41 LibreELEC systemd[1]: storage-recordings.mount: Mount process exited, code=exited status=255

    Mar 26 15:23:41 LibreELEC systemd[1]: storage-recordings.mount: Failed with result 'exit-code'.

    Mar 26 15:23:41 LibreELEC systemd[1]: Failed to mount Aufnahmepfad zur NAS.

  • Hello!

    Right, there is no samba.conf from the beginning. You can create your own Samba.conf. That's why there is a samba.conf Sample To See how to. If you create a samba.conf within configfiles this samba.conf ist getting used.

    LE Wiki Samba

    Regards

    Nicolas

    Edited once, last by Nicolas (March 26, 2020 at 7:10 PM).

  • Good morning,

    I've create an samba.conf (OK I renamed only the sample.conf).

    Here my samba.conf

    # SPDX-License-Identifier: GPL-2.0-or-later

    # Copyright (C) 2009-2016 Stephan Raue ([email protected])

    # Copyright (C) 2017-present Team LibreELEC (LibreELEC – Just enough OS for KODI)


    # samba.conf v4 (do not remove)


    # This configuration file allows you to customize the samba shares

    # available from your machine


    [global]

    server string = LibreELEC

    browseable = yes

    writeable = yes

    printable = no

    deadtime = 30

    mangled names = no

    name resolve order = host bcast

    printcap name = /dev/null

    load printers = no

    encrypt passwords = true

    enable core files = no

    passdb backend = smbpasswd

    smb encrypt = disabled

    fruit:model = Xserve


    # samba share options

    map to guest = Bad User

    guest account = root

    security = user


    # samba tuning options

    socket options = TCP_NODELAY IPTOS_LOWDELAY

    min receivefile size = 16384

    aio read size = 16384

    aio write size = 16384

    use sendfile = yes


    # The following are default values for the master selection process

    # local master = yes

    # preferred master = auto

    # domain master = auto

    # os level = 20


    # "strict allocate = yes" breaks large network transfers to external hdd

    # Force this to "no" in case "yes" becomes the default in future

    strict allocate = no


    allocation roundup size = 0


    # Using the following configurations as a template allows you to add

    # writeable shares of disks and paths under /storage


    [Update]

    path = /storage/.update

    available = yes

    browseable = yes

    public = yes

    writeable = yes

    root preexec = mkdir -p /storage/.update


    [Videos]

    path = /storage/videos

    available = yes

    browseable = yes

    public = yes

    writeable = yes

    root preexec = mkdir -p /storage/videos


    [Music]

    path = /storage/music

    available = yes

    browseable = yes

    public = yes

    writeable = yes

    root preexec = mkdir -p /storage/music


    [TV Shows]

    path = /storage/tvshows

    available = yes

    browseable = yes

    public = yes

    writeable = yes

    root preexec = mkdir -p /storage/tvshows


    [Recordings]

    path = /storage/recordings

    available = yes

    browseable = yes

    public = yes

    writeable = yes

    root preexec = mkdir -p /storage/recordings


    [Downloads]

    path = /storage/downloads

    available = yes

    browseable = yes

    public = yes

    writeable = yes

    root preexec = mkdir -p /storage/downloads


    [Pictures]

    path = /storage/pictures

    available = yes

    browseable = yes

    public = yes

    writeable = yes

    root preexec = mkdir -p /storage/pictures


    [Emulators]

    path = /storage/emulators

    available = yes

    browseable = yes

    public = yes

    writeable = yes

    root preexec = mkdir -p /storage/emulators


    [Configfiles]

    path = /storage/.config

    available = yes

    browseable = yes

    public = yes

    writeable = yes

    root preexec = mkdir -p /storage/.config


    [Userdata]

    path = /storage/.kodi/userdata

    available = yes

    browseable = yes

    public = yes

    writeable = yes

    root preexec = mkdir -p /storage/.kodi/userdata


    [Screenshots]

    path = /storage/screenshots

    available = yes

    browseable = yes

    public = yes

    writeable = yes

    root preexec = mkdir -p /storage/screenshots


    [Logfiles]

    path = /storage/logfiles

    available = yes

    browseable = yes

    public = yes

    writeable = yes

    root preexec = mkdir -p /storage/logfiles

    root preexec = createlog


    [Backup]

    path = /storage/backup

    available = yes

    browseable = yes

    public = yes

    writeable = yes

    root preexec = mkdir -p /storage/backup


    [Picons]

    path = /storage/picons

    available = yes

    browseable = yes

    public = yes

    writeable = yes

    root preexec = mkdir -p /storage/picons/tvh /storage/picons/vdr

    If I shut down the NAS here the error message:

    ● storage-recordings.mount - Aufnahmepfad zur NAS

    Loaded: loaded (/storage/.config/system.d/storage-recordings.mount; enabled; vendor preset: disabled)

    Active: failed (Result: exit-code) since Fri 2020-03-27 08:30:09 CET; 2min 55s ago

    Where: /storage/recordings

    What: //NSA325-V2/video/recordings


    Mar 27 08:30:03 LibreELEC systemd[1]: Mounting Aufnahmepfad zur NAS...

    Mar 27 08:30:09 LibreELEC mount[423]: mount: mounting //NSA325-V2/video/recordings on /storage/recordings no route to host

    Mar 27 08:30:09 LibreELEC systemd[1]: storage-recordings.mount: Mount process exited, code=exited status=255

    Mar 27 08:30:09 LibreELEC systemd[1]: storage-recordings.mount: Failed with result 'exit-code'.

    Mar 27 08:30:09 LibreELEC systemd[1]: Failed to mount Aufnahmepfad zur NAS.

    If the NAS is on the error message is again "failed: Host is down"

    I've also change

    [Mount] 

    What=//192.168.178.57/video/recordings 

    Where=/storage/recordings

    and

    [Mount] 

    What=//192.168.178.57/video/recordings/

    Where=/storage/recordings/

    and

    [Mount] 

    What=//192.168.178.57/Volume1/video/recordings 

    Where=/storage/recordings

    my last change

    [Mount] 

    What=//192.168.178.57/Volume1/video 

    Where=/storage/video

    but nothing works

    Yes I restart the Raspery after each change