Mailing List Archive

mythtv v31 slave backend help needed
I have a remote v31 backend with a PCIe tuner card running on Ubuntu
18.04 with mariadb-server.

I'd like to add a v31 slave backend running on a RPi4 using a HDHR
quatro tuner.

Is there a guide on how to set this up? I know how to setup the RPi4 as
a v31 remote backend, just not sure as to how to make it a slave off of
my master. I see one setting in mythtv-setup -> General that has a check
box for master or slave. There has to be more than that?

1. Will the slave use the maradb on the Master?

2. Will all frontends see the recordings/ EPG on both the master and slave?

Any help would be appreciated. I didn't find much using google and what
I did was many versions old.

Jim A


_______________________________________________
mythtv-users mailing list
mythtv-users@mythtv.org
http://lists.mythtv.org/mailman/listinfo/mythtv-users
http://wiki.mythtv.org/Mailing_List_etiquette
MythTV Forums: https://forum.mythtv.org
Re: mythtv v31 slave backend help needed [ In reply to ]
On 18/07/2020 23:36, Jim Abernathy wrote:
> I have a remote v31 backend with a PCIe tuner card running on Ubuntu
> 18.04 with mariadb-server.
>
> I'd like to add a v31 slave backend running on a RPi4 using a HDHR
> quatro tuner.
>
> Is there a guide on how to set this up? I know how to setup the RPi4
> as a v31 remote backend, just not sure as to how to make it a slave
> off of my master. I see one setting in mythtv-setup -> General that
> has a check box for master or slave. There has to be more than that?
>
> 1. Will the slave use the maradb on the Master?
>
> 2. Will all frontends see the recordings/ EPG on both the master and
> slave?
>
> Any help would be appreciated. I didn't find much using google and
> what I did was many versions old.
>
> Jim A
>
>
> _______________________________________________
> mythtv-users mailing list
> mythtv-users@mythtv.org
> http://lists.mythtv.org/mailman/listinfo/mythtv-users
> http://wiki.mythtv.org/Mailing_List_etiquette
> MythTV Forums: https://forum.mythtv.org

I was really surprised how easy it was to set up a slave backend.

Make sure the new master is accessible remotely over your network ie a
remote frontend works fine.

Then starting from a stand alone combined front & backend.

Uninstalled the database as a slave uses the one on the machine to be
used as master.

Altered the config.xml for the slave with the host name pointing to the
new master.

Changed the master slave? setting in mythtv-setup .

When running setup on the slave it should now see the masters database.

You set up the tuners on the slave locally.

If you have sources defined on the master the slave can see them so you
don't need to do channel scan.

The storage directories on the slave should all be blank in which case
the system uses those defined on the master.

The slave should be setup so that it sees the file system on the master
at the same address.

I shared the recording folder from the master using samba - works fine
on a Pi 3B.

Recordings are then seamlessly accessible on the master .




_______________________________________________
mythtv-users mailing list
mythtv-users@mythtv.org
http://lists.mythtv.org/mailman/listinfo/mythtv-users
http://wiki.mythtv.org/Mailing_List_etiquette
MythTV Forums: https://forum.mythtv.org
Re: mythtv v31 slave backend help needed [ In reply to ]
On 7/19/20 4:04 AM, John wrote:
> On 18/07/2020 23:36, Jim Abernathy wrote:
>> I have a remote v31 backend with a PCIe tuner card running on Ubuntu
>> 18.04 with mariadb-server.
>>
>> I'd like to add a v31 slave backend running on a RPi4 using a HDHR
>> quatro tuner.
>>
>> Is there a guide on how to set this up? I know how to setup the RPi4
>> as a v31 remote backend, just not sure as to how to make it a slave
>> off of my master. I see one setting in mythtv-setup -> General that
>> has a check box for master or slave. There has to be more than that?
>>
>> 1. Will the slave use the maradb on the Master?
>>
>> 2. Will all frontends see the recordings/ EPG on both the master and
>> slave?
>>
>> Any help would be appreciated. I didn't find much using google and
>> what I did was many versions old.
>>
>> Jim A
>>
>>
>> _______________________________________________
>> mythtv-users mailing list
>> mythtv-users@mythtv.org
>> http://lists.mythtv.org/mailman/listinfo/mythtv-users
>> http://wiki.mythtv.org/Mailing_List_etiquette
>> MythTV Forums: https://forum.mythtv.org
>
> I was really surprised how easy it was to set up a slave backend.
>
> Make sure the new master is accessible remotely over your network ie a
> remote frontend works fine.
>
> Then starting from a stand alone combined front & backend.
>
> Uninstalled the database as a slave uses the one on the machine to be
> used as master.
>
> Altered the config.xml for the slave with the host name pointing to
> the new master.
>
> Changed the master slave? setting in mythtv-setup .
>
> When running setup on the slave it should now see the masters database.
>
> You set up the tuners on the slave locally.
>
> If you have sources defined on the master the slave can see them so
> you don't need to do channel scan.
>
> The storage directories on the slave should all be blank in which case
> the system uses those defined on the master.
>
> The slave should be setup so that it sees the file system on the
> master at the same address.
>
> I shared the recording folder from the master using samba - works fine
> on a Pi 3B.
>
> Recordings are then seamlessly accessible on the master .

Thanks, just a few questions. The need for a slave backend is for many
reasons and 2 that caught my mind were:

1.? adding more tuners.

2.? adding more storage.


Having the tuners defined locally on the slave and no local video source
makes sense because I only use one video source and all my tuners could
use it because there are one set up OTA TV stations.

However, I'm confused on the Storage setup.? The Storage Groups are all
defined on the master, but how is the slave local storage defined and
used?? It sound like you do all your recording on the master.

Jim A


_______________________________________________
mythtv-users mailing list
mythtv-users@mythtv.org
http://lists.mythtv.org/mailman/listinfo/mythtv-users
http://wiki.mythtv.org/Mailing_List_etiquette
MythTV Forums: https://forum.mythtv.org
Re: mythtv v31 slave backend help needed [ In reply to ]
On 7/19/20 6:12 AM, Mike Perkins wrote:
> On 19/07/2020 10:59, Jim Abernathy wrote:
>>
> (snip)
>>
>> Thanks, just a few questions. The need for a slave backend is for
>> many reasons and 2 that caught my mind were:
>>
>> 1.? adding more tuners.
>>
>> 2.? adding more storage.
>>
>>
>> Having the tuners defined locally on the slave and no local video
>> source makes sense because I only use one video source and all my
>> tuners could use it because there are one set up OTA TV stations.
>>
>> However, I'm confused on the Storage setup.? The Storage Groups are
>> all defined on the master, but how is the slave local storage defined
>> and used?? It sound like you do all your recording on the master.
>> A point on the remote tuners: Using a source on another host is only
>> possible if the remote tuners
> are the same type.
>
> A source defines a method of tuning as well as a selection of
> channels. Different tuner types require different sources.
>

So on my current master backend I have Hauppauge WinTV HD Quad PCIe
card.  My slave would have a HDHomerun Quatro, so different types of
tuners.  They could use the same list of channels provided by Schedules
Direct, I think. The master backend could do the scan on one of the
WinTV tuners, but not the HDHR tuners, so it could only establish input
connections for the WinTV tuners, unless Mythtv can tell the slave to
scan the HDHR tuners?

Jim A


_______________________________________________
mythtv-users mailing list
mythtv-users@mythtv.org
http://lists.mythtv.org/mailman/listinfo/mythtv-users
http://wiki.mythtv.org/Mailing_List_etiquette
MythTV Forums: https://forum.mythtv.org
Re: mythtv v31 slave backend help needed [ In reply to ]
On Sun, Jul 19, 2020 at 7:00 AM Mike Perkins <mikep@randomtraveller.org.uk>
wrote:

> On 19/07/2020 11:27, Jim Abernathy wrote:
> >
> > On 7/19/20 6:12 AM, Mike Perkins wrote:
> >> On 19/07/2020 10:59, Jim Abernathy wrote:
> >>>
> >> (snip)
> >>>
> >>> Thanks, just a few questions. The need for a slave backend is for many
> reasons and 2 that caught
> >>> my mind were:
> >>>
> >>> 1.? adding more tuners.
> >>>
> >>> 2.? adding more storage.
> >>>
> >>>
> >>> Having the tuners defined locally on the slave and no local video
> source makes sense because I
> >>> only use one video source and all my tuners could use it because there
> are one set up OTA TV
> >>> stations.
> >>>
> >>> However, I'm confused on the Storage setup.? The Storage Groups are
> all defined on the master,
> >>> but how is the slave local storage defined and used?? It sound like
> you do all your recording on
> >>> the master.
> >>> A point on the remote tuners: Using a source on another host is only
> possible if the remote tuners
> >> are the same type.
> >>
> >> A source defines a method of tuning as well as a selection of channels.
> Different tuner types
> >> require different sources.
> >>
> >
> > So on my current master backend I have Hauppauge WinTV HD Quad PCIe
> card. My slave would have a
> > HDHomerun Quatro, so different types of tuners. They could use the same
> list of channels provided
> > by Schedules Direct, I think. The master backend could do the scan on
> one of the WinTV tuners, but
> > not the HDHR tuners, so it could only establish input connections for
> the WinTV tuners, unless
> > Mythtv can tell the slave to scan the HDHR tuners?
> >
> > Jim A
> >
> >
> You'll be using mythtv-setup on the slave to configure it, so you can
> provide a unique (to it)
> source and do whatever scan it requires there.
>
> You can reference the same channel list from SD, though, since SD doesn't
> care about tuner types,
> just what you watch.
>
> Mmm. Interesting point: presumably mythfilldatabase (mfdb) normally runs
> on the host that has a
> database, the master. How does it know about remote sources? Or do you run
> mfdb on every slave as
> well, updating the database over the network? I can't answer that one, can
> anyone else?
>
> --
>
> Mike Perkins
>

So I've made some progress. I installed Raspberry Pi OS on a fresh SD
card and booted, updated, and then copied the SD image to a USB3 SATA SSD
since the RPi4 now supports USB3 boot with the latest EEPROM bootloader.

Then I installed mythtv-light v31 per the wiki and I downloaded the
pi-utils from: https://github.com/MikeB2013/pi-utils.git
I modified the pi-mythbackend-helper.sh so the only functions I ran were:
fn_get_git
fn_setup_mythtv_user
fn_setup_mythtv_backend_service
fn_setup_directories
fn_tidy_up

After rebooting, I ran mythtv-setup on the slave and it can't find the
database since there isn't one on the slave. So I use the manual setup
option to fill in the info about the master backend, i.e. IP,
mythconverge password, etc.

It then found the master and I could add the tuner cards and it already
knew about the Video Source (SD). I could set up the Input Connections and
scan the first tuner only; the same as when you build a regular backend.

You are not supposed to configure Storage groups on the backend, but that
confuses me.

I also copied my .mythtv/config.xml file to /etc/mythtv/config.xml and that
is symbolic linked to /home/mythtv/.mythtv/config.xml

I defined a mountpoint in the Storage Group Default and created that
directory, but mythtv-setup will not let you create a path that doesn't
exist, even though the wiki says to do that.The directory does exist on the
slave backend. the master is supposed to ignore any directory that doesn't
exit, but since you can't create one that doesn't exist, ????

This is where I'm getting my Storage Group information and I can't seem to
make it work. The errors I'm getting are related to the recordings not
being accessible.

https://www.mythtv.org/wiki/Setup_Storage_Directories#Multiple_Backends
Re: mythtv v31 slave backend help needed [ In reply to ]
On Sat, Jul 18, 2020 at 4:37 PM Jim Abernathy <jfabernathy@gmail.com> wrote:

> I have a remote v31 backend with a PCIe tuner card running on Ubuntu
> 18.04 with mariadb-server.
>
> I'd like to add a v31 slave backend running on a RPi4 using a HDHR
> quatro tuner.
>
> Is there a guide on how to set this up? I know how to setup the RPi4 as
> a v31 remote backend, just not sure as to how to make it a slave off of
> my master. I see one setting in mythtv-setup -> General that has a check
> box for master or slave. There has to be more than that?
>
> 1. Will the slave use the maradb on the Master?
>
> 2. Will all frontends see the recordings/ EPG on both the master and slave?
>
> Any help would be appreciated. I didn't find much using google and what
> I did was many versions old.
>
> Jim A
>

Jim, out of curiosity, why do you want to setup a slave backend? Why not
just configure the HDHR on your main mythtv server?

John
Re: mythtv v31 slave backend help needed [ In reply to ]
On Sun, Jul 19, 2020 at 11:57 AM John P Poet <jppoet@gmail.com> wrote:

>
>>
> Jim, out of curiosity, why do you want to setup a slave backend? Why not
> just configure the HDHR on your main mythtv server?
>
> John
>

John,

I could do it that way, but then my poor RPi4 would have nothing to do and
would be upset with me ????

It's mostly a learning experience about multiple backends. I've never done
it. SInce I'm retired, in a Covid-19 lockdown, and the heat index outside
is over 100 degrees, I need something to work on. I have 4 RPis, and a
closet of old PCs. I'm just trying to stay busy. I even put Archlinux on
one just to try it.

Jim A
Re: mythtv v31 slave backend help needed [ In reply to ]
On 19/07/2020 10:59, Jim Abernathy wrote:
>
> On 7/19/20 4:04 AM, John wrote:
>> On 18/07/2020 23:36, Jim Abernathy wrote:
>>> I have a remote v31 backend with a PCIe tuner card running on Ubuntu
>>> 18.04 with mariadb-server.
>>>
>>> I'd like to add a v31 slave backend running on a RPi4 using a HDHR
>>> quatro tuner.
>>>
>>> Is there a guide on how to set this up? I know how to setup the RPi4
>>> as a v31 remote backend, just not sure as to how to make it a slave
>>> off of my master. I see one setting in mythtv-setup -> General that
>>> has a check box for master or slave. There has to be more than that?
>>>
>>> 1. Will the slave use the maradb on the Master?
>>>
>>> 2. Will all frontends see the recordings/ EPG on both the master and
>>> slave?
>>>
>>> Any help would be appreciated. I didn't find much using google and
>>> what I did was many versions old.
>>>
>>> Jim A
>>>
>>>
>>> _______________________________________________
>>> mythtv-users mailing list
>>> mythtv-users@mythtv.org
>>> http://lists.mythtv.org/mailman/listinfo/mythtv-users
>>> http://wiki.mythtv.org/Mailing_List_etiquette
>>> MythTV Forums: https://forum.mythtv.org
>>
>> I was really surprised how easy it was to set up a slave backend.
>>
>> Make sure the new master is accessible remotely over your network ie
>> a remote frontend works fine.
>>
>> Then starting from a stand alone combined front & backend.
>>
>> Uninstalled the database as a slave uses the one on the machine to be
>> used as master.
>>
>> Altered the config.xml for the slave with the host name pointing to
>> the new master.
>>
>> Changed the master slave? setting in mythtv-setup .
>>
>> When running setup on the slave it should now see the masters database.
>>
>> You set up the tuners on the slave locally.
>>
>> If you have sources defined on the master the slave can see them so
>> you don't need to do channel scan.
>>
>> The storage directories on the slave should all be blank in which
>> case the system uses those defined on the master.
>>
>> The slave should be setup so that it sees the file system on the
>> master at the same address.
>>
>> I shared the recording folder from the master using samba - works
>> fine on a Pi 3B.
>>
>> Recordings are then seamlessly accessible on the master .
>
> Thanks, just a few questions. The need for a slave backend is for many
> reasons and 2 that caught my mind were:
>
> 1.? adding more tuners.
>
> 2.? adding more storage.
>
>
> Having the tuners defined locally on the slave and no local video
> source makes sense because I only use one video source and all my
> tuners could use it because there are one set up OTA TV stations.
>
> However, I'm confused on the Storage setup.? The Storage Groups are
> all defined on the master, but how is the slave local storage defined
> and used?? It sound like you do all your recording on the master.
>
> Jim A
>
>
> _______________________________________________
> mythtv-users mailing list
> mythtv-users@mythtv.org
> http://lists.mythtv.org/mailman/listinfo/mythtv-users
> http://wiki.mythtv.org/Mailing_List_etiquette
> MythTV Forums: https://forum.mythtv.org

In my case I did not want to add more storage. The slave is writing to
storage on the master over the network.

That way you don't need to define any storage groups on the slave.

If you need local storage on the slave then define a storage location
for the local recordings.

However if you do this, the recordings will obviously only be available
when the slave is powered on.

If you keep all recordings on the master the slave needs only to be
powered up when the number of simultaneous recordings merits it.

_______________________________________________
mythtv-users mailing list
mythtv-users@mythtv.org
http://lists.mythtv.org/mailman/listinfo/mythtv-users
http://wiki.mythtv.org/Mailing_List_etiquette
MythTV Forums: https://forum.mythtv.org
Re: mythtv v31 slave backend help needed [ In reply to ]
On Sun, Jul 19, 2020 at 4:05 AM John <jksjdevelop@gmail.com> wrote:

> On 18/07/2020 23:36, Jim Abernathy wrote:
> > I have a remote v31 backend with a PCIe tuner card running on Ubuntu
> > 18.04 with mariadb-server.
> >
> > I'd like to add a v31 slave backend running on a RPi4 using a HDHR
> > quatro tuner.
> >
> > Is there a guide on how to set this up? I know how to setup the RPi4
> > as a v31 remote backend, just not sure as to how to make it a slave
> > off of my master. I see one setting in mythtv-setup -> General that
> > has a check box for master or slave. There has to be more than that?
> >
> > 1. Will the slave use the maradb on the Master?
> >
> > 2. Will all frontends see the recordings/ EPG on both the master and
> > slave?
> >
> > Any help would be appreciated. I didn't find much using google and
> > what I did was many versions old.
> >
> > Jim A
> >
> >
> > _______________________________________________
> > mythtv-users mailing list
> > mythtv-users@mythtv.org
> > http://lists.mythtv.org/mailman/listinfo/mythtv-users
> > http://wiki.mythtv.org/Mailing_List_etiquette
> > MythTV Forums: https://forum.mythtv.org
>
> I was really surprised how easy it was to set up a slave backend.
>
> Make sure the new master is accessible remotely over your network ie a
> remote frontend works fine.
>
> Then starting from a stand alone combined front & backend.
>
> Uninstalled the database as a slave uses the one on the machine to be
> used as master.
>
> Altered the config.xml for the slave with the host name pointing to the
> new master.
>
> Changed the master slave setting in mythtv-setup .
>
> When running setup on the slave it should now see the masters database.
>
> You set up the tuners on the slave locally.
>
> If you have sources defined on the master the slave can see them so you
> don't need to do channel scan.
>
> The storage directories on the slave should all be blank in which case
> the system uses those defined on the master.
>
> The slave should be setup so that it sees the file system on the master
> at the same address.
>
> I shared the recording folder from the master using samba - works fine
> on a Pi 3B.
>
> Recordings are then seamlessly accessible on the master .
>

I seem to have this working. In my case I want the RPi4 Slave Backend to
use it's HDHR tuners and record it's recordings on the SSD connected to the
RPi4.
Here's what I did to get this working:


1.

Fresh install or Raspberry Pi OS on RPi4 4GB
2.

Setup repository and install mythty light per:
https://www.mythtv.org/wiki/MythTV_Light#Repository_Setup
3.

Install pi-utils per: https://github.com/MikeB2013/pi-utils.git
4.

Modify pi-mythbackend-helper.sh to run just part of the functions:

fn_get_git

fn_setup_mythtv_user

fn_setup_mythtv_backend_service

fn_setup_directories

fn_tidy_up
5.

Run my modified pi-mythbackend-helper.sh and reboot
6.

Run mythtv-setup, but expect it to not find the database. Select the
manual setup button and point it to the Master backend IP address and
database password.
7.

Mythtv-setup will then come up as normal and you can setup the options.
I added the HDHR tuners.
8.

The Video Source will already have the source from the Master backend.
9.

I setup the Input Connections as I would on a regular backend setup and
only scan the first tuner.
10.

I didn’t setup the Storage Groups on the slave backend.
11.

I copied the config.xml from “/home/pi/.mythtv/” to “/etc/mythtv/” and
“/home/mythtv/.mythtv/”
12.

The hard part for me was to understand the Storage Groups setup for the
slave backend since you don’t do that when you run mythtv-setup on the
slave. On my Master Backend for the Storage Group ? Default, I have 2
directories defined:
1.

“/mnt/md0/recordings-tv1”
2.

“/mnt/md1/recordings-tv2”

This is because I have 2 sets of RAID mirrors for the recordings.
13.

So to make this work on the slave backend I had to create a directory
“/mnt/md0/recordings-tv1” on the slave backend owned by mythtv:mythtv with
permissions 2775.
14.

At this point I used my Shield TV Android mythtv-frontend and I could
see all the tuners on both backends and I started recording 8 programs. The
recordings worked and were spread out over both backends. And as I wanted
the RPI4’s recordings were in “/mnt/md0/recordings-tv1” on it’s SSD.

Jim A
Re: mythtv v31 slave backend help needed [ In reply to ]
On 7/19/20 10:43 AM, James Abernathy wrote:
>
>
> On Sun, Jul 19, 2020 at 7:00 AM Mike Perkins <mikep@randomtraveller.org.uk <mailto:mikep@randomtraveller.org.uk>> wrote:
>
> On 19/07/2020 11:27, Jim Abernathy wrote:
> >
> > On 7/19/20 6:12 AM, Mike Perkins wrote:
> >> On 19/07/2020 10:59, Jim Abernathy wrote:
> >>>
> >> (snip)
> >>>
> >>> Thanks, just a few questions. The need for a slave backend is for many reasons and 2 that caught
> >>> my mind were:
> >>>
> >>> 1.? adding more tuners.
> >>>
> >>> 2.? adding more storage.
> >>>
> >>>
> >>> Having the tuners defined locally on the slave and no local video source makes sense because I
> >>> only use one video source and all my tuners could use it because there are one set up OTA TV
> >>> stations.
> >>>
> >>> However, I'm confused on the Storage setup.? The Storage Groups are all defined on the master,
> >>> but how is the slave local storage defined and used?? It sound like you do all your recording on
> >>> the master.
> >>> A point on the remote tuners: Using a source on another host is only possible if the remote tuners
> >> are the same type.
> >>
> >> A source defines a method of tuning as well as a selection of channels. Different tuner types
> >> require different sources.
> >>
> >
> > So on my current master backend I have Hauppauge WinTV HD Quad PCIe card.  My slave would have a
> > HDHomerun Quatro, so different types of tuners.  They could use the same list of channels provided
> > by Schedules Direct, I think. The master backend could do the scan on one of the WinTV tuners, but
> > not the HDHR tuners, so it could only establish input connections for the WinTV tuners, unless
> > Mythtv can tell the slave to scan the HDHR tuners?
> >
> > Jim A
> >
> >
> You'll be using mythtv-setup on the slave to configure it, so you can provide a unique (to it)
> source and do whatever scan it requires there.
>
> You can reference the same channel list from SD, though, since SD doesn't care about tuner types,
> just what you watch.
>
> Mmm. Interesting point: presumably mythfilldatabase (mfdb) normally runs on the host that has a
> database, the master. How does it know about remote sources? Or do you run mfdb on every slave as
> well, updating the database over the network? I can't answer that one, can anyone else?
>
> --
>
> Mike Perkins
>
>
> So I've made some progress.   I installed Raspberry Pi OS on a fresh SD card and booted, updated, and then copied the SD image to a USB3 SATA
> SSD since the RPi4 now supports USB3 boot with the latest EEPROM bootloader.
>
> Then I installed mythtv-light v31 per the wiki and I downloaded the pi-utils from: https://github.com/MikeB2013/pi-utils.git
> I modified the pi-mythbackend-helper.sh so the only functions I ran were:
> fn_get_git
> fn_setup_mythtv_user
> fn_setup_mythtv_backend_service
> fn_setup_directories
> fn_tidy_up
>
> After rebooting, I ran mythtv-setup on the slave and it can't find the database since there isn't one on the slave.  So I use the manual setup
> option to fill in the info about the master backend, i.e. IP, mythconverge password, etc.

Right, it will find the database once config.xml knows where the DB is,
And it's most frequently on the same host as the main backend.

> It then found the master and I could add the tuner cards and it already knew about the Video Source (SD). I could set up the Input Connections
> and scan the first tuner only; the same as when you build a regular backend.
>
> You are not supposed to configure Storage groups on the backend, but that confuses me.

Me to, at first, but it's right. More below.

> I also copied my .mythtv/config.xml file to /etc/mythtv/config.xml and that is symbolic linked to /home/mythtv/.mythtv/config.xml

This is what things should look like. The above comment may be OK, but it sounds
reversed. It's the same as on a main backend.

$ ls -ld /etc/mythtv/config.xml {~,~mythtv}/.mythtv/config.xml
-rw-rw---- 1 mythtv mythtv 565 Mar 24 13:53 /etc/mythtv/config.xml
lrwxrwxrwx 1 you you 22 May 26 2019 /home/you/.mythtv/config.xml -> /etc/mythtv/config.xml
lrwxrwxrwx 1 mythtv mythtv 22 May 26 2019 /home/mythtv/.mythtv/config.xml -> /etc/mythtv/config.xml

> I defined a mountpoint in the Storage Group Default and created that directory, but mythtv-setup will not let you create a path that doesn't
> exist, even though the wiki says to do that.The directory does exist on the slave backend.  the master is supposed to ignore any directory that
> doesn't exit, but since you can't create one that doesn't exist, ????

When I was using a remote BE, I didn't mount/share/... anything from the remote backend.

I see your point. And, in the mythtv-setup log:

mythuifilebrowser.cpp:613 (updateLocalFileList) - MythUIFileBrowser: current directory does not exist!

The Services API isn't as picky. Verify the host name known to MythTV
(it takes into account any LocalHostName in config.xml) with this:

curl localhost:6544/Myth/GetHostName

This works, but don't use /tmp/blah!:

curl --data GroupName=Default --data DirName=/tmp/blah --data HostName=yourHostName localhost:6544/Myth/AddStorageGroupDir

You can substitute RemoveStorageGroupDir for AddStorageGroupDir if a typo is made.

> This is where I'm getting my Storage Group information and I can't seem to make it work.  The errors I'm getting are related to the recordings
> not being accessible.
>
> https://www.mythtv.org/wiki/Setup_Storage_Directories#Multiple_Backends

Good choice (and, no I didn't write it.)

This API displays existing Storage Group entries. You can look at it in a browser with

yourBackend:6544/Myth/GetStorageGroupDirs

Or, from the command line (you likely need to install the libxml2-utils package.)
Note the trailing dash:

curl --silent localhost:6544/Myth/GetStorageGroupDirs | xmllint --format -

Here's my 'Default' SG as an example. Note that the HostName is 'mc0', which is my main backend:

curl --silent localhost:6544/Myth/GetStorageGroupDirs?GroupName=Default | xmllint --format -
<?xml version="1.0" encoding="UTF-8"?>
<StorageGroupDirList xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" version="1.0" serializerVersion="1.1">
<StorageGroupDirs>
<StorageGroupDir>
<Id>55</Id>
<GroupName>Default</GroupName>
<HostName>mc0</HostName>
<DirName>/srv/mythtv-0/recordings/</DirName>
<DirRead>true</DirRead>
<DirWrite>true</DirWrite>
<KiBFree>37060992</KiBFree>
</StorageGroupDir>

... omitted others that are on the main backend

<StorageGroupDir>
<Id>40</Id>
<GroupName>Default</GroupName>
<HostName>mc0</HostName>
<DirName>/var/lib/mythtv/remote/recordings/</DirName> # This path doesn't exist on the main backend
<DirRead>false</DirRead>
<DirWrite>false</DirWrite>
<KiBFree>4294967295</KiBFree>
</StorageGroupDir>
</StorageGroupDirs>
</StorageGroupDirList>

--
Bill
_______________________________________________
mythtv-users mailing list
mythtv-users@mythtv.org
http://lists.mythtv.org/mailman/listinfo/mythtv-users
http://wiki.mythtv.org/Mailing_List_etiquette
MythTV Forums: https://forum.mythtv.org
Re: mythtv v31 slave backend help needed [ In reply to ]
On 7/19/20 12:05 PM, James Abernathy wrote:
>
>
> On Sun, Jul 19, 2020 at 11:57 AM John P Poet <jppoet@gmail.com
> <mailto:jppoet@gmail.com>> wrote:
>
>
>
> Jim, out of curiosity, why do you want to setup a slave backend?
> Why not just configure the HDHR on your main mythtv server?
>
> John
>
>
> John,
>
> I could do it that way, but then my poor RPi4 would have nothing to do
> and would be upset with me ????
>
> It's mostly a learning experience about multiple backends.  I've never
> done it. SInce I'm retired, in a Covid-19 lockdown, and the heat index
> outside is over 100 degrees, I need something to work on. I have 4
> RPis, and a closet of old PCs.  I'm just trying to stay busy.  I even
> put Archlinux on one just to try it.
>
> Jim A
>
>

While you are about it, check if leanfront can play recordings from the
slave backend. I did do some minimal testing of that. Also playback
videos on the slave backend. I never tested that. I am not even sure if
you can have videos on a slave backend.

Let me know if there are any problems I should fix.

Peter
Re: mythtv v31 slave backend help needed [ In reply to ]
On 7/19/20 1:15 PM, Bill Meek wrote:
> On 7/19/20 10:43 AM, James Abernathy wrote:
>>
>>
> When I was using a remote BE, I didn't mount/share/... anything from
> the remote backend.
>
> I see your point. And, in the mythtv-setup log:
>
>   mythuifilebrowser.cpp:613 (updateLocalFileList) - MythUIFileBrowser:
> current directory does not exist!
>
> The Services API isn't as picky. Verify the host name known to MythTV
> (it takes into account any LocalHostName in config.xml) with this:
>
>   curl localhost:6544/Myth/GetHostName
>
> This works, but don't use /tmp/blah!:
>
>   curl --data GroupName=Default --data DirName=/tmp/blah --data
> HostName=yourHostName localhost:6544/Myth/AddStorageGroupDir
>
> You can substitute RemoveStorageGroupDir for AddStorageGroupDir if a
> typo is made.
>
>> This is where I'm getting my Storage Group information and I can't
>> seem to make it work.  The errors I'm getting are related to the
>> recordings not being accessible.
>>
>> https://www.mythtv.org/wiki/Setup_Storage_Directories#Multiple_Backends
>
> Good choice (and, no I didn't write it.)
>
> This API displays existing Storage Group entries. You can look at it
> in a browser with
>
>   yourBackend:6544/Myth/GetStorageGroupDirs
>
> Or, from the command line (you likely need to install the
> libxml2-utils package.)
> Note the trailing dash:
>
>   curl --silent localhost:6544/Myth/GetStorageGroupDirs | xmllint
> --format -
>
> Here's my 'Default' SG as an example. Note that the HostName is 'mc0',
> which is my main backend:
>
> curl --silent
> localhost:6544/Myth/GetStorageGroupDirs?GroupName=Default | xmllint
> --format -
> <?xml version="1.0" encoding="UTF-8"?>
> <StorageGroupDirList
> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" version="1.0"
> serializerVersion="1.1">
>   <StorageGroupDirs>
>     <StorageGroupDir>
>       <Id>55</Id>
>       <GroupName>Default</GroupName>
>       <HostName>mc0</HostName>
>       <DirName>/srv/mythtv-0/recordings/</DirName>
>       <DirRead>true</DirRead>
>       <DirWrite>true</DirWrite>
>       <KiBFree>37060992</KiBFree>
>     </StorageGroupDir>
>
>     ... omitted others that are on the main backend
>
>     <StorageGroupDir>
>       <Id>40</Id>
>       <GroupName>Default</GroupName>
>       <HostName>mc0</HostName>
> <DirName>/var/lib/mythtv/remote/recordings/</DirName> # This path
> doesn't exist on the main backend
>       <DirRead>false</DirRead>
>       <DirWrite>false</DirWrite>
>       <KiBFree>4294967295</KiBFree>
>     </StorageGroupDir>
>   </StorageGroupDirs>
> </StorageGroupDirList>
>
So how to you create the
<DirName>/var/lib/mythtv/remote/recordings/</DirName> # This path
doesn't exist on the main backend??

I can't see how to create a mount point on the master backend that
doesn't exist except on the slave backend. Certainly can't do it with
mythtv-setup unless I'm missing a magic button somewhere.

In my setup I created a path on the slave backend that also existed on
the master backend.  So when recordings are being done on the slave
those files get recording in that directory on the slave.

I just can't see how to setup the non-existent directory on the master
that does exist on the slave.

Jim A


_______________________________________________
mythtv-users mailing list
mythtv-users@mythtv.org
http://lists.mythtv.org/mailman/listinfo/mythtv-users
http://wiki.mythtv.org/Mailing_List_etiquette
MythTV Forums: https://forum.mythtv.org
Re: mythtv v31 slave backend help needed [ In reply to ]
On 7/19/20 3:48 PM, Jim Abernathy wrote:
>
> On 7/19/20 1:15 PM, Bill Meek wrote:
>> On 7/19/20 10:43 AM, James Abernathy wrote:
>>>
>>>
>> When I was using a remote BE, I didn't mount/share/... anything from the remote backend.
>>
>> I see your point. And, in the mythtv-setup log:
>>
>>   mythuifilebrowser.cpp:613 (updateLocalFileList) - MythUIFileBrowser: current directory does not exist!
>>
>> The Services API isn't as picky. Verify the host name known to MythTV
>> (it takes into account any LocalHostName in config.xml) with this:
>>
>>   curl localhost:6544/Myth/GetHostName
>>
>> This works, but don't use /tmp/blah!:
>>
>>   curl --data GroupName=Default --data DirName=/tmp/blah --data HostName=yourHostName localhost:6544/Myth/AddStorageGroupDir
>>
>> You can substitute RemoveStorageGroupDir for AddStorageGroupDir if a typo is made.
>>
>>> This is where I'm getting my Storage Group information and I can't seem to make it work.  The errors I'm getting are related to the
>>> recordings not being accessible.
>>>
>>> https://www.mythtv.org/wiki/Setup_Storage_Directories#Multiple_Backends
>>
>> Good choice (and, no I didn't write it.)
>>
>> This API displays existing Storage Group entries. You can look at it in a browser with
>>
>>   yourBackend:6544/Myth/GetStorageGroupDirs
>>
>> Or, from the command line (you likely need to install the libxml2-utils package.)
>> Note the trailing dash:
>>
>>   curl --silent localhost:6544/Myth/GetStorageGroupDirs | xmllint --format -
>>
>> Here's my 'Default' SG as an example. Note that the HostName is 'mc0', which is my main backend:
>>
>> curl --silent localhost:6544/Myth/GetStorageGroupDirs?GroupName=Default | xmllint --format -
>> <?xml version="1.0" encoding="UTF-8"?>
>> <StorageGroupDirList xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" version="1.0" serializerVersion="1.1">
>>   <StorageGroupDirs>
>>     <StorageGroupDir>
>>       <Id>55</Id>
>>       <GroupName>Default</GroupName>
>>       <HostName>mc0</HostName>
>>       <DirName>/srv/mythtv-0/recordings/</DirName>
>>       <DirRead>true</DirRead>
>>       <DirWrite>true</DirWrite>
>>       <KiBFree>37060992</KiBFree>
>>     </StorageGroupDir>
>>
>>     ... omitted others that are on the main backend
>>
>>     <StorageGroupDir>
>>       <Id>40</Id>
>>       <GroupName>Default</GroupName>
>>       <HostName>mc0</HostName>
>> <DirName>/var/lib/mythtv/remote/recordings/</DirName> # This path doesn't exist on the main backend
>>       <DirRead>false</DirRead>
>>       <DirWrite>false</DirWrite>
>>       <KiBFree>4294967295</KiBFree>
>>     </StorageGroupDir>
>>   </StorageGroupDirs>
>> </StorageGroupDirList>
>>
> So how to you create the <DirName>/var/lib/mythtv/remote/recordings/</DirName> # This path doesn't exist on the main backend??

You seem to have found a bug at least in the way the Wiki defines the setup.

> I can't see how to create a mount point on the master backend that doesn't exist except on the slave backend. Certainly can't do it with
> mythtv-setup unless I'm missing a magic button somewhere.

Use the API above.

> In my setup I created a path on the slave backend that also existed on the master backend.  So when recordings are being done on the slave those
> files get recording in that directory on the slave.

You shouldn't have to do that. I'd remove the directory from the main backend
after using mythtv-setup. Otherwise, the main backend will start putting recordings
in that Storage Group directory too.

> I just can't see how to setup the non-existent directory on the master that does exist on the slave.
>

Sounds like you found a way by creating the directory.

It should only exists on the remote backend. This is what the 3rd paragraph in
the Wiki section you cited is trying to say.

"... Note, also, that <the author> did not say that all the directories in
the directory list must exist on all the hosts" ...

--
Bill
_______________________________________________
mythtv-users mailing list
mythtv-users@mythtv.org
http://lists.mythtv.org/mailman/listinfo/mythtv-users
http://wiki.mythtv.org/Mailing_List_etiquette
MythTV Forums: https://forum.mythtv.org
Re: mythtv v31 slave backend help needed [ In reply to ]
On 7/19/20 1:15 PM, Bill Meek wrote:
>
> I see your point. And, in the mythtv-setup log:
>
>   mythuifilebrowser.cpp:613 (updateLocalFileList) - MythUIFileBrowser:
> current directory does not exist!
>
> The Services API isn't as picky. Verify the host name known to MythTV
> (it takes into account any LocalHostName in config.xml) with this:
>
>   curl localhost:6544/Myth/GetHostName
>
> This works, but don't use /tmp/blah!:
>
>   curl --data GroupName=Default --data DirName=/tmp/blah --data
> HostName=yourHostName localhost:6544/Myth/AddStorageGroupDir
>
> You can substitute RemoveStorageGroupDir for AddStorageGroupDir if a
> typo is made.
>
>> This is where I'm getting my Storage Group information and I can't
>> seem to make it work.  The errors I'm getting are related to the
>> recordings not being accessible.
>>
>> https://www.mythtv.org/wiki/Setup_Storage_Directories#Multiple_Backends
>
> Good choice (and, no I didn't write it.)
>
> This API displays existing Storage Group entries. You can look at it
> in a browser with
>
>   yourBackend:6544/Myth/GetStorageGroupDirs
>
> Or, from the command line (you likely need to install the
> libxml2-utils package.)
> Note the trailing dash:
>
>   curl --silent localhost:6544/Myth/GetStorageGroupDirs | xmllint
> --format -
>
> Here's my 'Default' SG as an example. Note that the HostName is 'mc0',
> which is my main backend:
>
> curl --silent
> localhost:6544/Myth/GetStorageGroupDirs?GroupName=Default | xmllint
> --format -
> <?xml version="1.0" encoding="UTF-8"?>
> <StorageGroupDirList
> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" version="1.0"
> serializerVersion="1.1">
>   <StorageGroupDirs>
>     <StorageGroupDir>
>       <Id>55</Id>
>       <GroupName>Default</GroupName>
>       <HostName>mc0</HostName>
>       <DirName>/srv/mythtv-0/recordings/</DirName>
>       <DirRead>true</DirRead>
>       <DirWrite>true</DirWrite>
>       <KiBFree>37060992</KiBFree>
>     </StorageGroupDir>
>
>     ... omitted others that are on the main backend
>
>     <StorageGroupDir>
>       <Id>40</Id>
>       <GroupName>Default</GroupName>
>       <HostName>mc0</HostName>
> <DirName>/var/lib/mythtv/remote/recordings/</DirName> # This path
> doesn't exist on the main backend
>       <DirRead>false</DirRead>
>       <DirWrite>false</DirWrite>
>       <KiBFree>4294967295</KiBFree>
>     </StorageGroupDir>
>   </StorageGroupDirs>
> </StorageGroupDirList>
>
Okay, now that I have my head out of my butt, I see what you are saying.
I used the following command on my Master Backend:

curl --data GroupName=Default --data DirName=/srv/mythtv/recordings
--data HostName=mythbuntu localhost:6544/Myth/AddStorageGroupDir

Now my Master backend Storage Groups look like this:

<StorageGroupDir>
<Id>18</Id>
<GroupName>Default</GroupName>
<HostName>mythbuntu</HostName>
<DirName>/mnt/md0/recorded-tv1</DirName>
<DirRead>true</DirRead>
<DirWrite>true</DirWrite>
<KiBFree>1179876784</KiBFree>
</StorageGroupDir>
<StorageGroupDir>
<Id>19</Id>
<GroupName>Default</GroupName>
<HostName>mythbuntu</HostName>
<DirName>/mnt/md1/recorded-tv2</DirName>
<DirRead>true</DirRead>
<DirWrite>true</DirWrite>
<KiBFree>1378748488</KiBFree>
</StorageGroupDir>
<StorageGroupDir>
<Id>36</Id>
<GroupName>Default</GroupName>
<HostName>mythbuntu</HostName>
<DirName>/srv/mythtv/recordings</DirName>  # this dir doesn't exist on
my Master but does on slave.
<DirRead>false</DirRead>
<DirWrite>false</DirWrite>
<KiBFree>4294967295</KiBFree>
</StorageGroupDir>

So did I do this right? Should I have changed the HostName from
mythbuntu to raspberrypi, which is the hostname of the slave backend? It
looks like you left "mc0" as the hostname on your entry of the
non-existent directory that does exist on the slave. So, I'm guessing I
did it right?

Jim A
Re: mythtv v31 slave backend help needed [ In reply to ]
On 7/19/20 4:29 PM, Jim Abernathy wrote:
>
> On 7/19/20 1:15 PM, Bill Meek wrote:
>>
>> I see your point. And, in the mythtv-setup log:
>>
>>   mythuifilebrowser.cpp:613 (updateLocalFileList) - MythUIFileBrowser: current directory does not exist!
>>
>> The Services API isn't as picky. Verify the host name known to MythTV
>> (it takes into account any LocalHostName in config.xml) with this:
>>
>>   curl localhost:6544/Myth/GetHostName
>>
>> This works, but don't use /tmp/blah!:
>>
>>   curl --data GroupName=Default --data DirName=/tmp/blah --data HostName=yourHostName localhost:6544/Myth/AddStorageGroupDir
>>
>> You can substitute RemoveStorageGroupDir for AddStorageGroupDir if a typo is made.
>>
>>> This is where I'm getting my Storage Group information and I can't seem to make it work.  The errors I'm getting are related to the
>>> recordings not being accessible.
>>>
>>> https://www.mythtv.org/wiki/Setup_Storage_Directories#Multiple_Backends
>>
>> Good choice (and, no I didn't write it.)
>>
>> This API displays existing Storage Group entries. You can look at it in a browser with
>>
>>   yourBackend:6544/Myth/GetStorageGroupDirs
>>
>> Or, from the command line (you likely need to install the libxml2-utils package.)
>> Note the trailing dash:
>>
>>   curl --silent localhost:6544/Myth/GetStorageGroupDirs | xmllint --format -
>>
>> Here's my 'Default' SG as an example. Note that the HostName is 'mc0', which is my main backend:
>>
>> curl --silent localhost:6544/Myth/GetStorageGroupDirs?GroupName=Default | xmllint --format -
>> <?xml version="1.0" encoding="UTF-8"?>
>> <StorageGroupDirList xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" version="1.0" serializerVersion="1.1">
>>   <StorageGroupDirs>
>>     <StorageGroupDir>
>>       <Id>55</Id>
>>       <GroupName>Default</GroupName>
>>       <HostName>mc0</HostName>
>>       <DirName>/srv/mythtv-0/recordings/</DirName>
>>       <DirRead>true</DirRead>
>>       <DirWrite>true</DirWrite>
>>       <KiBFree>37060992</KiBFree>
>>     </StorageGroupDir>
>>
>>     ... omitted others that are on the main backend
>>
>>     <StorageGroupDir>
>>       <Id>40</Id>
>>       <GroupName>Default</GroupName>
>>       <HostName>mc0</HostName>
>> <DirName>/var/lib/mythtv/remote/recordings/</DirName> # This path doesn't exist on the main backend
>>       <DirRead>false</DirRead>
>>       <DirWrite>false</DirWrite>
>>       <KiBFree>4294967295</KiBFree>
>>     </StorageGroupDir>
>>   </StorageGroupDirs>
>> </StorageGroupDirList>
>>
> Okay, now that I have my head out of my butt, I see what you are saying. I used the following command on my Master Backend:
>
> curl --data GroupName=Default --data DirName=/srv/mythtv/recordings --data HostName=mythbuntu localhost:6544/Myth/AddStorageGroupDir
>
> Now my Master backend Storage Groups look like this:
>
> <StorageGroupDir>
> <Id>18</Id>
> <GroupName>Default</GroupName>
> <HostName>mythbuntu</HostName>
> <DirName>/mnt/md0/recorded-tv1</DirName>
> <DirRead>true</DirRead>
> <DirWrite>true</DirWrite>
> <KiBFree>1179876784</KiBFree>
> </StorageGroupDir>
> <StorageGroupDir>
> <Id>19</Id>
> <GroupName>Default</GroupName>
> <HostName>mythbuntu</HostName>
> <DirName>/mnt/md1/recorded-tv2</DirName>
> <DirRead>true</DirRead>
> <DirWrite>true</DirWrite>
> <KiBFree>1378748488</KiBFree>
> </StorageGroupDir>
> <StorageGroupDir>
> <Id>36</Id>
> <GroupName>Default</GroupName>
> <HostName>mythbuntu</HostName>
> <DirName>/srv/mythtv/recordings</DirName>  # this dir doesn't exist on my Master but does on slave.
> <DirRead>false</DirRead>
> <DirWrite>false</DirWrite>
> <KiBFree>4294967295</KiBFree>
> </StorageGroupDir>
>
> So did I do this right? Should I have changed the HostName from mythbuntu to raspberrypi, which is the hostname of the slave backend? It looks
> like you left "mc0" as the hostname on your entry of the non-existent directory that does exist on the slave. So, I'm guessing I did it right?

HostName mythbuntu is right.

--
Bill
_______________________________________________
mythtv-users mailing list
mythtv-users@mythtv.org
http://lists.mythtv.org/mailman/listinfo/mythtv-users
http://wiki.mythtv.org/Mailing_List_etiquette
MythTV Forums: https://forum.mythtv.org
Re: mythtv v31 slave backend help needed [ In reply to ]
On 7/19/20 4:29 PM, Jim Abernathy wrote:
> I used the following command on my Master Backend:
>
> curl --data GroupName=Default --data DirName=/srv/mythtv/recordings --data HostName=mythbuntu localhost:6544/Myth/AddStorageGroupDir

FYI, I did the same for all the other Storage Groups in play for
the remote backend. E.g. Banners/Coverart/Fanart. Maybe you'd
want LiveTV. Also, groups only you know about - perhaps Sports.
Groups that exist in recording rules in other words.

If those don't exist, everything ends up in Default on the remote
backend.

I don't recall testing the above, but it seemed like the right thing
to do at the time.

--
Bill
_______________________________________________
mythtv-users mailing list
mythtv-users@mythtv.org
http://lists.mythtv.org/mailman/listinfo/mythtv-users
http://wiki.mythtv.org/Mailing_List_etiquette
MythTV Forums: https://forum.mythtv.org
Re: mythtv v31 slave backend help needed [ In reply to ]
On 7/19/20 6:06 PM, Bill Meek wrote:
> On 7/19/20 4:29 PM, Jim Abernathy wrote:
>> I used the following command on my Master Backend:
>>
>> curl --data GroupName=Default --data DirName=/srv/mythtv/recordings
>> --data HostName=mythbuntu localhost:6544/Myth/AddStorageGroupDir
>
> FYI, I did the same for all the other Storage Groups in play for
> the remote backend. E.g. Banners/Coverart/Fanart. Maybe you'd
> want LiveTV. Also, groups only you know about - perhaps Sports.
> Groups that exist in recording rules in other words.
>
> If those don't exist, everything ends up in Default on the remote
> backend.
>
> I don't recall testing the above, but it seemed like the right thing
> to do at the time.
>
That brings up an interesting question. I'm looking for a way to force
certain recordings to the slave backend. Stuff like my sports that my
wife could care less about and if that hard drive failed it wouldn't
affect her stuff. The main backend uses RAID Mirror for all recordings. 
The remote backend doesn't. So it would be good to put those unimportant
recording there.

Could I define a Storage Group, like sports, where the directory only
existed on the remote (slave) backend and then set a record rule that
forced those to that Storage Group. At present all I've done is pick a
preferred input that is tied to the remote backend or record 8 programs
at once.

Jim A


_______________________________________________
mythtv-users mailing list
mythtv-users@mythtv.org
http://lists.mythtv.org/mailman/listinfo/mythtv-users
http://wiki.mythtv.org/Mailing_List_etiquette
MythTV Forums: https://forum.mythtv.org
Re: mythtv v31 slave backend help needed [ In reply to ]
On 7/19/20 4:01 PM, Peter Bennett wrote:
>
> While you are about it, check if leanfront can play recordings from
> the slave backend. I did do some minimal testing of that. Also
> playback videos on the slave backend. I never tested that. I am not
> even sure if you can have videos on a slave backend.
>
> Let me know if there are any problems I should fix.
>
> Peter
>
Leanfront can play recordings from the slave backend. Just tested it.
Also I confirmed that those recordings were definitely only in the slave
backend's recording directory.

As to the videos, it will take some time for me to figure that out.  I
have to put some videos that don't exist anywhere else in a slave
Storage group -Videos.

I'll let you know if it works. May be a day or so.

Jim A


_______________________________________________
mythtv-users mailing list
mythtv-users@mythtv.org
http://lists.mythtv.org/mailman/listinfo/mythtv-users
http://wiki.mythtv.org/Mailing_List_etiquette
MythTV Forums: https://forum.mythtv.org
Re: mythtv v31 slave backend help needed [ In reply to ]
On Sun, Jul 19, 2020 at 4:57 PM Jim Abernathy <jfabernathy@gmail.com> wrote:

>
> On 7/19/20 6:06 PM, Bill Meek wrote:
> > On 7/19/20 4:29 PM, Jim Abernathy wrote:
> >> I used the following command on my Master Backend:
> >>
> >> curl --data GroupName=Default --data DirName=/srv/mythtv/recordings
> >> --data HostName=mythbuntu localhost:6544/Myth/AddStorageGroupDir
> >
> > FYI, I did the same for all the other Storage Groups in play for
> > the remote backend. E.g. Banners/Coverart/Fanart. Maybe you'd
> > want LiveTV. Also, groups only you know about - perhaps Sports.
> > Groups that exist in recording rules in other words.
> >
> > If those don't exist, everything ends up in Default on the remote
> > backend.
> >
> > I don't recall testing the above, but it seemed like the right thing
> > to do at the time.
> >
> That brings up an interesting question. I'm looking for a way to force
> certain recordings to the slave backend. Stuff like my sports that my
> wife could care less about and if that hard drive failed it wouldn't
> affect her stuff. The main backend uses RAID Mirror for all recordings.
> The remote backend doesn't. So it would be good to put those unimportant
> recording there.
>
> Could I define a Storage Group, like sports, where the directory only
> existed on the remote (slave) backend and then set a record rule that
> forced those to that Storage Group. At present all I've done is pick a
> preferred input that is tied to the remote backend or record 8 programs
> at once.
>
> Jim A
>

Take a look at [Setup] -> [Video] -> [Recording Priorities] -> [Custom
Priority]
You specify a mysql clause. If that clause is satisfied, then the priority
is modified by the "Priority Change" amount (plus or minus). If the
priority is increased, then the mythtv scheduler will "prefer" to schedule
the recording rule such that the clause is matched.

One example of a way to handle this, would be to increase the priority for
your slave backend when a given set of channels are being recorded:
Priority Change: 10
Clause: channel.callsign IN ('ESPN', 'ESPN2') AND capturecard.hostname =
"slavehostname"

Or, if you want to do it based on Storage Group:
Priority Change:10
RECTABLE.storagegroup = 'SportsGroup' AND
capturecard.hostname="slavehostname"

Or, by program category:
Priority Change:10
program.category = 'Sports event' AND capturecard.hostname="slavehostname"

Depending on your listing source, you may want to use category_type instead
of category:
program.category_type = 'sports' AND capturecard.hostname="slavehostname"

You may want to set multiple rules.

John
Re: mythtv v31 slave backend help needed [ In reply to ]
> On 19 Jul 2020, at 6:27 pm, Jim Abernathy <jfabernathy@gmail.com> wrote:
>
>>> Thanks, just a few questions. The need for a slave backend is for many reasons and 2 that caught my mind were:
>>>
>>> 1.? adding more tuners.
>>>
>>> 2.? adding more storage.
>>>
>>>
>>> Having the tuners defined locally on the slave and no local video source makes sense because I only use one video source and all my tuners could use it because there are one set up OTA TV stations.
>>>
>>> However, I'm confused on the Storage setup.? The Storage Groups are all defined on the master, but how is the slave local storage defined and used?? It sound like you do all your recording on the master.
>>> A point on the remote tuners: Using a source on another host is only possible if the remote tuners
>> are the same type.
>>
>> A source defines a method of tuning as well as a selection of channels. Different tuner types require different sources.
>>
>
> So on my current master backend I have Hauppauge WinTV HD Quad PCIe card. My slave would have a HDHomerun Quatro, so different types of tuners. They could use the same list of channels provided by Schedules Direct, I think. The master backend could do the scan on one of the WinTV tuners, but not the HDHR tuners, so it could only establish input connections for the WinTV tuners, unless Mythtv can tell the slave to scan the HDHR tuners?

Jim I’m a cynic, so questions are retorical:

12 tuners !! (For those who dont know HD Homerun will not do virtual tuners) (and I’m assuming 1 real + 1 virtual tuner per hw)
For disk storage
I use a NUC for my master:
/dev/nvme0n1p5:
Timing cached reads: 22212 MB in 1.99 seconds = 11163.35 MB/se
Timing buffered disk reads: 6830 MB in 3.00 seconds = 2276.14 MB/sec

If you want RaPi the Rock Pi gives about 1500 MB/sec on m2
Also I have used Haupauge Dual HD and Leadteck Win TV on the Rock Pi (but do get the acer M2 from them)

So I see no need for master/slave BE for me.
I’m using 2 off Haupauge Dual HD and as a test I recorded 8 channels (don’t recall but as many HD as I could find, at least 5)
and performance (on an i3 NUC) was flawless.
I too am an auld fart and in last 2 yaers I have never had confilt (on this setup).
We get a burst of movies on sat, mon and fri with a derth midweek.
James


_______________________________________________
mythtv-users mailing list
mythtv-users@mythtv.org
http://lists.mythtv.org/mailman/listinfo/mythtv-users
http://wiki.mythtv.org/Mailing_List_etiquette
MythTV Forums: https://forum.mythtv.org
Re: mythtv v31 slave backend help needed [ In reply to ]
On Sun, Jul 19, 2020, 8:58 PM jam <jam@tigger.ws> wrote:

>
>
> > On 19 Jul 2020, at 6:27 pm, Jim Abernathy <jfabernathy@gmail.com> wrote:
> >
> >>> Thanks, just a few questions. The need for a slave backend is for many
> reasons and 2 that caught my mind were:
> >>>
> >>> 1.? adding more tuners.
> >>>
> >>> 2.? adding more storage.
> >>>
> >>>
> >>> Having the tuners defined locally on the slave and no local video
> source makes sense because I only use one video source and all my tuners
> could use it because there are one set up OTA TV stations.
> >>>
> >>> However, I'm confused on the Storage setup.? The Storage Groups are
> all defined on the master, but how is the slave local storage defined and
> used?? It sound like you do all your recording on the master.
> >>> A point on the remote tuners: Using a source on another host is only
> possible if the remote tuners
> >> are the same type.
> >>
> >> A source defines a method of tuning as well as a selection of channels.
> Different tuner types require different sources.
> >>
> >
> > So on my current master backend I have Hauppauge WinTV HD Quad PCIe
> card. My slave would have a HDHomerun Quatro, so different types of
> tuners. They could use the same list of channels provided by Schedules
> Direct, I think. The master backend could do the scan on one of the WinTV
> tuners, but not the HDHR tuners, so it could only establish input
> connections for the WinTV tuners, unless Mythtv can tell the slave to scan
> the HDHR tuners?
>
> Jim I’m a cynic, so questions are retorical:
>
> 12 tuners !! (For those who dont know HD Homerun will not do virtual
> tuners) (and I’m assuming 1 real + 1 virtual tuner per hw)
> For disk storage
> I use a NUC for my master:
> /dev/nvme0n1p5:
> Timing cached reads: 22212 MB in 1.99 seconds = 11163.35 MB/se
> Timing buffered disk reads: 6830 MB in 3.00 seconds = 2276.14 MB/sec
>
> If you want RaPi the Rock Pi gives about 1500 MB/sec on m2
> Also I have used Haupauge Dual HD and Leadteck Win TV on the Rock Pi (but
> do get the acer M2 from them)
>
> So I see no need for master/slave BE for me.
> I’m using 2 off Haupauge Dual HD and as a test I recorded 8 channels
> (don’t recall but as many HD as I could find, at least 5)
> and performance (on an i3 NUC) was flawless.
> I too am an auld fart and in last 2 yaers I have never had confilt (on
> this setup).
> We get a burst of movies on sat, mon and fri with a derth midweek.
> James
>

I'm doing the slave backend stuff as a challenge. I have no need for a
core i7 pc with more than 4 tuners. But I'm bored and need a project. I
even created a tvheadend server using libreelec just to reassure myself
that mythtv is still the best option for OTA DVR.

I have tested 4 simulation HD recordings on a RPi4 while viewing a previous
recorded program using the mythtv frontend on the RPi4.

I need a new project.
Re: mythtv v31 slave backend help needed [ In reply to ]
On 7/19/20 4:01 PM, Peter Bennett wrote:
>
>
> On 7/19/20 12:05 PM, James Abernathy wrote:
>>
>>
>> On Sun, Jul 19, 2020 at 11:57 AM John P Poet <jppoet@gmail.com
>> <mailto:jppoet@gmail.com>> wrote:
>>
>>
>>
>> Jim, out of curiosity, why do you want to setup a slave backend?
>> Why not just configure the HDHR on your main mythtv server?
>>
>> John
>>
>>
>> John,
>>
>> I could do it that way, but then my poor RPi4 would have nothing to
>> do and would be upset with me ????
>>
>> It's mostly a learning experience about multiple backends.  I've
>> never done it. SInce I'm retired, in a Covid-19 lockdown, and the
>> heat index outside is over 100 degrees, I need something to work on.
>> I have 4 RPis, and a closet of old PCs.  I'm just trying to stay
>> busy.  I even put Archlinux on one just to try it.
>>
>> Jim A
>>
>>
>
> While you are about it, check if leanfront can play recordings from
> the slave backend. I did do some minimal testing of that. Also
> playback videos on the slave backend. I never tested that. I am not
> even sure if you can have videos on a slave backend.
>
> Let me know if there are any problems I should fix.
>
> Peter
>
So on Videos, here's what I did. I added the /srv/mythtv/videos to my
Videos Storage group on the master and it doesn't exist on Master, only
on the slave.  I then copied a m4a video file to that directory on the
slave.

With Leanfront I had a directory folder with no name and it had a
collection of videos that use to say "test videos" but now had all the
videos from "test videos" plus the video from my slave.  They all played
but it seems there maybe a folder naming issue.

So it didn't take a few days to get this tested. Just shows what a
bourbon on the rocks and half a bottle of wine can do. :-)

Jim A
Re: mythtv v31 slave backend help needed [ In reply to ]
Peter,

More testing results: Leanfront does display and play the Videos from the
remote backend the same as it does for master backends. My previous comment
about the missing folder name may be caused by my name for the folder
having a blank in the name. Below is the Storage groups:
<StorageGroupDir>
<Id>26</Id>
<GroupName>Videos</GroupName>
<HostName>mythbuntu</HostName>
<DirName>/mnt/md1/samba/public/media/test videos/</DirName>
<DirRead>true</DirRead>
<DirWrite>true</DirWrite>
<KiBFree>1376791348</KiBFree>
</StorageGroupDir>
<StorageGroupDir>
<Id>29</Id>
<GroupName>Videos</GroupName>
<HostName>mythbuntu</HostName>
<DirName>/mnt/md1/samba/public/media/tv-shows/</DirName>
<DirRead>true</DirRead>
<DirWrite>true</DirWrite>
<KiBFree>1376791348</KiBFree>
</StorageGroupDir>
<StorageGroupDir>
<Id>37</Id>
<GroupName>Videos</GroupName>
<HostName>mythbuntu</HostName>
<DirName>/srv/mythtv/videos</DirName>
<DirRead>false</DirRead>
<DirWrite>false</DirWrite>
<KiBFree>4294967295</KiBFree

When I look at my leanfront screen at the top level I see a list of items
along the left of:
All, Default, LiveTV, and Videos.

When I select Videos now I see a list of items along the left of:
Folder symbol with no title, Folder symbol with title "The Big Bang
Theory", and folder symbol with title "Hogan's Heroes"
The two folders with names are from /mnt/md1/samba/public/media/tv-shows/
and the titles are sub-folders

The blank folder are videos from either remote backend /srv/mythtv/videos
or master backend /mnt/md1/samba/public/media/test videos/

Note the space between "test videos"

One more note. The file counts under the folders is interesting. The blank
named folder has 6, and if you move the cursor over and count you do have 6
so that's correct. The Folder named The Big Bang Theory has 172 with
agrees with what Windows says using file explorer which also mounts that
directory.

However, the folder named Hogan's Heroes says 336 files but there are 168
files in that directory.

Jim A


On Sun, Jul 19, 2020 at 11:13 PM Jim Abernathy <jfabernathy@gmail.com>
wrote:

>
> On 7/19/20 4:01 PM, Peter Bennett wrote:
>
>
> On 7/19/20 12:05 PM, James Abernathy wrote:
>
>
>
> On Sun, Jul 19, 2020 at 11:57 AM John P Poet <jppoet@gmail.com> wrote:
>
>>
>>>
>> Jim, out of curiosity, why do you want to setup a slave backend? Why not
>> just configure the HDHR on your main mythtv server?
>>
>> John
>>
>
> John,
>
> I could do it that way, but then my poor RPi4 would have nothing to do and
> would be upset with me ????
>
> It's mostly a learning experience about multiple backends. I've never
> done it. SInce I'm retired, in a Covid-19 lockdown, and the heat index
> outside is over 100 degrees, I need something to work on. I have 4 RPis,
> and a closet of old PCs. I'm just trying to stay busy. I even put
> Archlinux on one just to try it.
>
> Jim A
>
>
>
> While you are about it, check if leanfront can play recordings from the
> slave backend. I did do some minimal testing of that. Also playback videos
> on the slave backend. I never tested that. I am not even sure if you can
> have videos on a slave backend.
>
> Let me know if there are any problems I should fix.
>
> Peter
>
> So on Videos, here's what I did. I added the /srv/mythtv/videos to my
> Videos Storage group on the master and it doesn't exist on Master, only on
> the slave. I then copied a m4a video file to that directory on the slave.
>
> With Leanfront I had a directory folder with no name and it had a
> collection of videos that use to say "test videos" but now had all the
> videos from "test videos" plus the video from my slave. They all played
> but it seems there maybe a folder naming issue.
>
> So it didn't take a few days to get this tested. Just shows what a bourbon
> on the rocks and half a bottle of wine can do. :-)
>
> Jim A
>
>
>
Re: mythtv v31 slave backend help needed [ In reply to ]
> When I look at my leanfront screen at the top level I see a list of
> items along the left of:
> All, Default, LiveTV, and Videos.
>
> When I select Videos now I see a list of items along the left of:
> Folder symbol with no title, Folder symbol with title "The Big Bang
> Theory", and folder symbol with title "Hogan's Heroes"
> The two folders with names are from
> /mnt/md1/samba/public/media/tv-shows/  and the titles are sub-folders
>
> The blank folder are videos from either remote backend
> /srv/mythtv/videos or master backend /mnt/md1/samba/public/media/test
> videos/
>
> Note the space between "test videos"
>
> One more note. The file counts under the folders is interesting.  The
> blank named folder has 6, and if you move the cursor over and count
> you do have 6 so that's correct.  The Folder named The Big Bang Theory
> has 172 with agrees with what Windows says using file explorer which
> also mounts that directory.
>
> However, the folder named Hogan's Heroes says 336 files but there are
> 168 files in that directory.
>
> Jim A


Peter,

more testing on the folder name issue.  Noticing that in my Videos -> TV
Shows directory I had another directory for each show, I duplicated that
for test videos. Now I have a directory structure like: test
videos/Various Videos.

So now Leanfront -> Videos show one folder for each TV show as it did
before but now there is a Various Videos directory with all my test videos.

There is still a blank folder on the left side, but that only contains
the videos from my remote/slave backend videos directory.

The file count is still off on Hogan's Heroes directory: 168 files
Leanfront count is 336, which is double.  I know 168 is because all
Hogan's Heroes fans know there where 168 episodes recorded back in the
60's. Also Ubuntu's properties displays 168 for items in the folder.

Jim A
Re: mythtv v31 slave backend help needed [ In reply to ]
On 7/20/20 9:25 AM, Jim Abernathy wrote:
>
>> When I look at my leanfront screen at the top level I see a list of
>> items along the left of:
>> All, Default, LiveTV, and Videos.
>>
>> When I select Videos now I see a list of items along the left of:
>> Folder symbol with no title, Folder symbol with title "The Big Bang
>> Theory", and folder symbol with title "Hogan's Heroes"
>> The two folders with names are from
>> /mnt/md1/samba/public/media/tv-shows/  and the titles are sub-folders
>>
>> The blank folder are videos from either remote backend
>> /srv/mythtv/videos or master backend /mnt/md1/samba/public/media/test
>> videos/
>>
>> Note the space between "test videos"
>>
>> One more note. The file counts under the folders is interesting.  The
>> blank named folder has 6, and if you move the cursor over and count
>> you do have 6 so that's correct.  The Folder named The Big Bang
>> Theory has 172 with agrees with what Windows says using file explorer
>> which also mounts that directory.
>>
>> However, the folder named Hogan's Heroes says 336 files but there are
>> 168 files in that directory.
>>
>> Jim A
>
>
> Peter,
>
> more testing on the folder name issue.  Noticing that in my Videos ->
> TV Shows directory I had another directory for each show, I duplicated
> that for test videos. Now I have a directory structure like: test
> videos/Various Videos.
>
> So now Leanfront -> Videos show one folder for each TV show as it did
> before but now there is a Various Videos directory with all my test
> videos.
>
> There is still a blank folder on the left side, but that only contains
> the videos from my remote/slave backend videos directory.
>
The blank folder name should contain files in the root of your videos
directory structure, i.e. not in a subdirectory under videos.
>
> The file count is still off on Hogan's Heroes directory: 168 files
> Leanfront count is 336, which is double.  I know 168 is because all
> Hogan's Heroes fans know there where 168 episodes recorded back in the
> 60's. Also Ubuntu's properties displays 168 for items in the folder.
>
The file count is actually just a count of the number of iicons to the
right. If you scroll right you will likely find each show icon is
displayed twice. Is it possible that these are being accessed in two
ways? Perhaps the directory is shared and accessed by your slave as well
as by the master? I see samba is mentioned above, perhaps that samba
directory is in both the master and slave setup.

If that is the case it looks like mythfrontend has some sort of
duplicate elimination method built in but the api does not.  If so I can
build that into leanfront or fix the api.

> Jim A
>
>
>

1 2  View All