Mailing List Archive

XMLTV setup can't run mythtv-setup as user mythtv
Trying to get XMLTV set up on a new install of Myth 31. I have xmltv
compiled and installed, now trying to get it linked to the input sources.
The wiki <https://www.mythtv.org/wiki/XMLTV> is pretty insistent that that
I run mythtv-setup as user mythtv for this step, but when I sudo --login
--user=mythtv and enter mythtv-setup it exits without running setup or
giving any error messages. I have already run it as myself, if that makes
a difference. The wiki is a little confusing because it says "If you do
not want to logon to that id or you cannot, you can run the mythtv-setup
from another id on the same backend." But above that it admonishes "Warning:
It seems users are missing the step that says run the setup as the user
that will run mythfilldatabase (which is frequently user mythtv.)" How can
I get setup to run under user mythtv? If I can't, will moving/linking the
.xmltv contents to /home/mythtv do the trick (as suggested in the wiki)?
Re: XMLTV setup can't run mythtv-setup as user mythtv [ In reply to ]
On 7/25/20 3:18 PM, DryHeat122 wrote:
> Trying to get XMLTV set up on a new install of Myth 31.  I have xmltv
> compiled and installed, now trying to get it linked to the input
> sources.  The wiki <https://www.mythtv.org/wiki/XMLTV> is pretty
> insistent that that I run mythtv-setup as user mythtv for this step,
> but when I sudo --login --user=mythtv and enter mythtv-setup it exits
> without running setup or giving any error messages.  I have already
> run it as myself, if that makes a difference.  The wiki is a little
> confusing because it says "If you do not want to logon to that id or
> you cannot, you can run the mythtv-setup from another id on the same
> backend."  But above that it admonishes "Warning: It seems users are
> missing the step that says run the setup as the user that will run
> mythfilldatabase (which is frequently user mythtv.)"  How can I get
> setup to run under user mythtv?  If I can't, will moving/linking the
> .xmltv contents to /home/mythtv do the trick (as suggested in the wiki)?
>
What I do is:

1. Install Ubuntu 20.04 and create my user 'jim'

2. sudo add-apt-repository ppa:mythbuntu/31

3. sudo apt update

4. sudo apt install mythtv

5. sudo su mythtv

6. follow mythtv XMLTV wiki, in my case, tv_grab_zz_sdjson_sqlite, verbatim.

7. exit back to user 'jim'

8. mythtv-setup

JIm A
Re: XMLTV setup can't run mythtv-setup as user mythtv [ In reply to ]
On 7/25/20 2:18 PM, DryHeat122 wrote:
> Trying to get XMLTV set up on a new install of Myth 31.  I have xmltv compiled and installed, now trying to get it linked to the input sources.
> The wiki <https://www.mythtv.org/wiki/XMLTV> is pretty insistent that that I run mythtv-setup as user mythtv for this step, but when I sudo
> --login --user=mythtv and enter mythtv-setup it exits without running setup or giving any error messages.  I have already run it as myself, if
> that makes a difference.  The wiki is a little confusing because it says "If you do not want to logon to that id or you cannot, you can run the
> mythtv-setup from another id on the same backend."  But above that it admonishes "Warning: It seems users are missing the step that says run the
> setup as the user that will run mythfilldatabase (which is frequently user mythtv.)"  How can I get setup to run under user mythtv?  If I can't,
> will moving/linking the .xmltv contents to /home/mythtv do the trick (as suggested in the wiki)?

Actually, the instruction says:

If user mythtv is allowed to login and start the window manager, XMLTV can be configured through the Video Sources Setup page in mythtv-setup.
Otherwise, follow the steps below and do the configuration from the command line.

I know that because I just changed the Wiki. Thanks for pointing this out.

--
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: XMLTV setup can't run mythtv-setup as user mythtv [ In reply to ]
On Sat, Jul 25, 2020 at 1:21 PM Bill Meek <keemllib@gmail.com> wrote:

> On 7/25/20 2:18 PM, DryHeat122 wrote:
> > Trying to get XMLTV set up on a new install of Myth 31. I have xmltv
> compiled and installed, now trying to get it linked to the input sources.
> > The wiki <https://www.mythtv.org/wiki/XMLTV> is pretty insistent that
> that I run mythtv-setup as user mythtv for this step, but when I sudo
> > --login --user=mythtv and enter mythtv-setup it exits without running
> setup or giving any error messages. I have already run it as myself, if
> > that makes a difference. The wiki is a little confusing because it says
> "If you do not want to logon to that id or you cannot, you can run the
> > mythtv-setup from another id on the same backend." But above that it
> admonishes "Warning: It seems users are missing the step that says run the
> > setup as the user that will run mythfilldatabase (which is frequently
> user mythtv.)" How can I get setup to run under user mythtv? If I can't,
> > will moving/linking the .xmltv contents to /home/mythtv do the trick (as
> suggested in the wiki)?
>
> Actually, the instruction says:
>
> If user mythtv is allowed to login and start the window manager, XMLTV can
> be configured through the Video Sources Setup page in mythtv-setup.
> Otherwise, follow the steps below and do the configuration from the
> command line.
>
> I know that because I just changed the Wiki. Thanks for pointing this out.
>
> --
> Bill
>
> My pleasure. Unfortunately I'm having a nightmare getting xmltv
configured. I still can't get mythtv-setup to run from user mythtv. It
just exits, doing nothing. So I went through the procedure of running the
command line configuration for tv_grab_zz_sdjson and selecting all the
channels (not a fun job, terrible interface). It produced a config file in
/home/mythtv/.mythtv but mythfilldatabase was looking for it in
/home/steve/.mythtv So I created a symlink for it there. Now when I run
mythfilldatabase I get the output below. It says unexpected end of file. I
looked at the file. It has info in it like username and pw for schedules
direct, and a bunch of channel items. Not sure what it was looking for that
it didn't get.

2020-07-25 16:08:01.887565 N Using configuration directory =
/home/steve/.mythtv
2020-07-25 16:08:01.887593 I Assumed character encoding: en_US.UTF-8
2020-07-25 16:08:01.887818 I Empty LocalHostName. This is typical.
2020-07-25 16:08:01.887825 I Using a profile name of: 'steve-EP45-UD3P'
(Usually the same as this host's name.)
2020-07-25 16:08:01.887874 I Start up testing connections. DB localhost,
BE , attempt 0, status dbAwake, Delay: 2000
2020-07-25 16:08:02.901952 N Setting QT default locale to en_US
2020-07-25 16:08:02.901966 I Current locale en_US
2020-07-25 16:08:02.902017 N Reading locale defaults from
/usr/share/mythtv//locales/en_us.xml
2020-07-25 16:08:02.920887 I PowerDBus: Added UPower.Device
'/org/freedesktop/UPower/devices/mouse_hidpp_battery_0'
2020-07-25 16:08:02.921152 I Power: On AC power
2020-07-25 16:08:02.950791 I Power: Supported actions:
Suspend,Restart,Shutdown
2020-07-25 16:08:02.951693 I Loading en_us translation for module
mythfrontend
2020-07-25 16:08:02.953200 I Current MythTV Schema Version (DBSchemaVer):
1361
2020-07-25 16:08:02.955403 I MythCoreContext::ConnectCommandSocket():
Connecting to backend server: 192.168.1.200:6543 (try 1 of 1)
2020-07-25 16:08:02.956691 I MythCoreContext::CheckProtoVersion(): Using
protocol version 91 BuzzOff
2020-07-25 16:08:02.956948 I Opening blocking connection to master backend
2020-07-25 16:08:02.957546 I Updating source #1 (sdjson) with grabber
tv_grab_zz_sdjson
2020-07-25 16:08:02.959422 I Found 302 channels for source 1 which use
grabber
2020-07-25 16:08:02.959572 I Starting process manager
2020-07-25 16:08:02.959642 I Starting IO manager (read)
2020-07-25 16:08:02.961686 I Starting IO manager (write)
2020-07-25 16:08:02.961712 I Starting process signal handler
2020-07-25 16:08:03.813955 I Grabber has capabilities: baseline
manualconfig preferredmethod
2020-07-25 16:08:04.464771 I Grabber prefers method: allatonce
2020-07-25 16:08:04.465395 I XMLTV config file is:
/home/steve/.mythtv/sdjson.xmltv
^C2020-07-25 16:09:34.229722 E Error in 577881:15: unexpected end of file
2020-07-25 16:09:35.033778 I No programs found in data.
2020-07-25 16:09:35.038900 E Failed to fetch some program info
Re: XMLTV setup can't run mythtv-setup as user mythtv [ In reply to ]
On 7/25/20 7:09 PM, DryHeat122 wrote:
>
>
> On Sat, Jul 25, 2020 at 1:21 PM Bill Meek <keemllib@gmail.com <mailto:keemllib@gmail.com>> wrote:
>
> On 7/25/20 2:18 PM, DryHeat122 wrote:
> > Trying to get XMLTV set up on a new install of Myth 31.  I have xmltv compiled and installed, now trying to get it linked to the input
> sources.
> > The wiki <https://www.mythtv.org/wiki/XMLTV> is pretty insistent that that I run mythtv-setup as user mythtv for this step, but when I sudo
> > --login --user=mythtv and enter mythtv-setup it exits without running setup or giving any error messages.  I have already run it as
> myself, if
> > that makes a difference.  The wiki is a little confusing because it says "If you do not want to logon to that id or you cannot, you can
> run the
> > mythtv-setup from another id on the same backend."  But above that it admonishes "Warning: It seems users are missing the step that says
> run the
> > setup as the user that will run mythfilldatabase (which is frequently user mythtv.)"  How can I get setup to run under user mythtv?  If I
> can't,
> > will moving/linking the .xmltv contents to /home/mythtv do the trick (as suggested in the wiki)?
>
> Actually, the instruction says:
>
> If user mythtv is allowed to login and start the window manager, XMLTV can be configured through the Video Sources Setup page in mythtv-setup.
> Otherwise, follow the steps below and do the configuration from the command line.
>
> I know that because I just changed the Wiki. Thanks for pointing this out.
>
> --
> Bill
>
> My pleasure.  Unfortunately I'm having a nightmare getting xmltv configured.  I still can't get mythtv-setup to run from user mythtv.  It just
> exits, doing nothing.  So I went through the procedure of running the command line configuration  for tv_grab_zz_sdjson and selecting all the
> channels (not a fun job, terrible interface). It produced a config file in /home/mythtv/.mythtv but mythfilldatabase was looking for it in
> /home/steve/.mythtv So I created a symlink for it there. Now when I run mythfilldatabase I get the output below. It says unexpected end of file.
> I looked at the file. It has info in it like username and pw for schedules direct, and a bunch of channel items. Not sure what it was looking
> for that it didn't get.
>
> 2020-07-25 16:08:01.887565 N  Using configuration directory = /home/steve/.mythtv
> 2020-07-25 16:08:01.887593 I  Assumed character encoding: en_US.UTF-8
> 2020-07-25 16:08:01.887818 I  Empty LocalHostName. This is typical.
> 2020-07-25 16:08:01.887825 I  Using a profile name of: 'steve-EP45-UD3P' (Usually the same as this host's name.)
> 2020-07-25 16:08:01.887874 I  Start up testing connections. DB localhost, BE , attempt 0, status dbAwake, Delay: 2000
> 2020-07-25 16:08:02.901952 N  Setting QT default locale to en_US
> 2020-07-25 16:08:02.901966 I  Current locale en_US
> 2020-07-25 16:08:02.902017 N  Reading locale defaults from /usr/share/mythtv//locales/en_us.xml
> 2020-07-25 16:08:02.920887 I  PowerDBus: Added UPower.Device '/org/freedesktop/UPower/devices/mouse_hidpp_battery_0'
> 2020-07-25 16:08:02.921152 I  Power: On AC power
> 2020-07-25 16:08:02.950791 I  Power: Supported actions: Suspend,Restart,Shutdown
> 2020-07-25 16:08:02.951693 I  Loading en_us translation for module mythfrontend
> 2020-07-25 16:08:02.953200 I  Current MythTV Schema Version (DBSchemaVer): 1361
> 2020-07-25 16:08:02.955403 I  MythCoreContext::ConnectCommandSocket(): Connecting to backend server: 192.168.1.200:6543
> <http://192.168.1.200:6543> (try 1 of 1)
> 2020-07-25 16:08:02.956691 I  MythCoreContext::CheckProtoVersion(): Using protocol version 91 BuzzOff
> 2020-07-25 16:08:02.956948 I  Opening blocking connection to master backend
> 2020-07-25 16:08:02.957546 I  Updating source #1 (sdjson) with grabber tv_grab_zz_sdjson
> 2020-07-25 16:08:02.959422 I  Found 302 channels for source 1 which use grabber
> 2020-07-25 16:08:02.959572 I  Starting process manager
> 2020-07-25 16:08:02.959642 I  Starting IO manager (read)
> 2020-07-25 16:08:02.961686 I  Starting IO manager (write)
> 2020-07-25 16:08:02.961712 I  Starting process signal handler
> 2020-07-25 16:08:03.813955 I  Grabber has capabilities: baseline manualconfig preferredmethod
> 2020-07-25 16:08:04.464771 I  Grabber prefers method: allatonce
> 2020-07-25 16:08:04.465395 I  XMLTV config file is: /home/steve/.mythtv/sdjson.xmltv
> ^C2020-07-25 16:09:34.229722 E  Error in 577881:15: unexpected end of file
> 2020-07-25 16:09:35.033778 I  No programs found in data.
> 2020-07-25 16:09:35.038900 E  Failed to fetch some program info

The intent of doing the setup as user mythtv is to end up with a single set of files
in ~mythtv/.mythtv/*.xmltv and ~mythtv/.xmltv/* where the latter depends on the grabber
selected.

Doing links (hard or symbolic) defeats that and makes a difficult process even harder
to setup and maintain.

Here's the way to run mythfilldatabase from the command line:

sudo --login --user=mythtv mythfilldatabase

When the backend runs it, it will just work because the files are in it's .mythtv
and .xmltv directories.

Run the above with the -v system command and you'll see the tv_grab_zz_sdjson command
line that mythfilldatabase is executing. Run that from the command line to see if
there are more clues to the problem. The file (--output /tmp/blah) won't be removed
so you can look at it too. You can even add --debug to the tv_grab_zz_sdjson command
but don't do that 1st as it's pretty verbose.

I use tv_grab_zz_sdjson_sqlite so won't be of much more help.

Here's a picture of the desired files. Again for the *SQLite version*:

Example for distributions that store MythTV data relative to ~mythtv/.mythtv,

/
??? home
??? mythtv
??? .mythtv
? ??? OTA.xmltv # Which contains:
? ? database=/home/mythtv/.xmltv/SchedulesDirect.DB
? ? lineup=USA-OTA-90210
? ? mythtv-categories=enabled
? ?
? ??? CABLE.xmltv # Which contains:
? database=/home/mythtv/.xmltv/SchedulesDirect.DB
? lineup=USA-IL90210-X
? mythtv-categories=enabled
?
??? .xmltv
??? SchedulesDirect.DB

Note that nothing is stored under the login user's .mythtv or .xmltv

--
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: XMLTV setup can't run mythtv-setup as user mythtv [ In reply to ]
As noted in the other thread you are responding to I am starting over.
This time I am going to use the sqllite version of xmltv since you selected
that and seem to know what you're doing, plus there is a way to make the
channel selections via a file rather than through the command line
interface. Two questions.

(1) in the above you have separate OTA and CABLE configurations. Am I
correct to assume you do this by running the config twice with a different
DB name? And should I run the config scripts as user mythtv?

(2) The wiki says: "Run MythTV Setup and select *Multinational (Schedules
Direct JSON web services with SQLite DB)* for your listings source." So I
run mythtv-setup first, select the suggested option for each source while
not selecting any channels, then exit setup, and then run the config
scripts? This is a little confusing.


On Sat, Jul 25, 2020 at 5:30 PM Bill Meek <keemllib@gmail.com> wrote:

> On 7/25/20 7:09 PM, DryHeat122 wrote:
> >
> >
> > On Sat, Jul 25, 2020 at 1:21 PM Bill Meek <keemllib@gmail.com <mailto:
> keemllib@gmail.com>> wrote:
> >
> > On 7/25/20 2:18 PM, DryHeat122 wrote:
> > > Trying to get XMLTV set up on a new install of Myth 31. I have
> xmltv compiled and installed, now trying to get it linked to the input
> > sources.
> > > The wiki <https://www.mythtv.org/wiki/XMLTV> is pretty
> insistent that that I run mythtv-setup as user mythtv for this step, but
> when I sudo
> > > --login --user=mythtv and enter mythtv-setup it exits without
> running setup or giving any error messages. I have already run it as
> > myself, if
> > > that makes a difference. The wiki is a little confusing because
> it says "If you do not want to logon to that id or you cannot, you can
> > run the
> > > mythtv-setup from another id on the same backend." But above
> that it admonishes "Warning: It seems users are missing the step that says
> > run the
> > > setup as the user that will run mythfilldatabase (which is
> frequently user mythtv.)" How can I get setup to run under user mythtv?
> If I
> > can't,
> > > will moving/linking the .xmltv contents to /home/mythtv do the
> trick (as suggested in the wiki)?
> >
> > Actually, the instruction says:
> >
> > If user mythtv is allowed to login and start the window manager,
> XMLTV can be configured through the Video Sources Setup page in
> mythtv-setup.
> > Otherwise, follow the steps below and do the configuration from the
> command line.
> >
> > I know that because I just changed the Wiki. Thanks for pointing
> this out.
> >
> > --
> > Bill
> >
> > My pleasure. Unfortunately I'm having a nightmare getting xmltv
> configured. I still can't get mythtv-setup to run from user mythtv. It
> just
> > exits, doing nothing. So I went through the procedure of running the
> command line configuration for tv_grab_zz_sdjson and selecting all the
> > channels (not a fun job, terrible interface). It produced a config file
> in /home/mythtv/.mythtv but mythfilldatabase was looking for it in
> > /home/steve/.mythtv So I created a symlink for it there. Now when I run
> mythfilldatabase I get the output below. It says unexpected end of file.
> > I looked at the file. It has info in it like username and pw for
> schedules direct, and a bunch of channel items. Not sure what it was
> looking
> > for that it didn't get.
> >
> > 2020-07-25 16:08:01.887565 N Using configuration directory =
> /home/steve/.mythtv
> > 2020-07-25 16:08:01.887593 I Assumed character encoding: en_US.UTF-8
> > 2020-07-25 16:08:01.887818 I Empty LocalHostName. This is typical.
> > 2020-07-25 16:08:01.887825 I Using a profile name of: 'steve-EP45-UD3P'
> (Usually the same as this host's name.)
> > 2020-07-25 16:08:01.887874 I Start up testing connections. DB
> localhost, BE , attempt 0, status dbAwake, Delay: 2000
> > 2020-07-25 16:08:02.901952 N Setting QT default locale to en_US
> > 2020-07-25 16:08:02.901966 I Current locale en_US
> > 2020-07-25 16:08:02.902017 N Reading locale defaults from
> /usr/share/mythtv//locales/en_us.xml
> > 2020-07-25 16:08:02.920887 I PowerDBus: Added UPower.Device
> '/org/freedesktop/UPower/devices/mouse_hidpp_battery_0'
> > 2020-07-25 16:08:02.921152 I Power: On AC power
> > 2020-07-25 16:08:02.950791 I Power: Supported actions:
> Suspend,Restart,Shutdown
> > 2020-07-25 16:08:02.951693 I Loading en_us translation for module
> mythfrontend
> > 2020-07-25 16:08:02.953200 I Current MythTV Schema Version
> (DBSchemaVer): 1361
> > 2020-07-25 16:08:02.955403 I MythCoreContext::ConnectCommandSocket():
> Connecting to backend server: 192.168.1.200:6543
> > <http://192.168.1.200:6543> (try 1 of 1)
> > 2020-07-25 16:08:02.956691 I MythCoreContext::CheckProtoVersion():
> Using protocol version 91 BuzzOff
> > 2020-07-25 16:08:02.956948 I Opening blocking connection to master
> backend
> > 2020-07-25 16:08:02.957546 I Updating source #1 (sdjson) with grabber
> tv_grab_zz_sdjson
> > 2020-07-25 16:08:02.959422 I Found 302 channels for source 1 which use
> grabber
> > 2020-07-25 16:08:02.959572 I Starting process manager
> > 2020-07-25 16:08:02.959642 I Starting IO manager (read)
> > 2020-07-25 16:08:02.961686 I Starting IO manager (write)
> > 2020-07-25 16:08:02.961712 I Starting process signal handler
> > 2020-07-25 16:08:03.813955 I Grabber has capabilities: baseline
> manualconfig preferredmethod
> > 2020-07-25 16:08:04.464771 I Grabber prefers method: allatonce
> > 2020-07-25 16:08:04.465395 I XMLTV config file is:
> /home/steve/.mythtv/sdjson.xmltv
> > ^C2020-07-25 16:09:34.229722 E Error in 577881:15: unexpected end of
> file
> > 2020-07-25 16:09:35.033778 I No programs found in data.
> > 2020-07-25 16:09:35.038900 E Failed to fetch some program info
>
> The intent of doing the setup as user mythtv is to end up with a single
> set of files
> in ~mythtv/.mythtv/*.xmltv and ~mythtv/.xmltv/* where the latter depends
> on the grabber
> selected.
>
> Doing links (hard or symbolic) defeats that and makes a difficult process
> even harder
> to setup and maintain.
>
> Here's the way to run mythfilldatabase from the command line:
>
> sudo --login --user=mythtv mythfilldatabase
>
> When the backend runs it, it will just work because the files are in it's
> .mythtv
> and .xmltv directories.
>
> Run the above with the -v system command and you'll see the
> tv_grab_zz_sdjson command
> line that mythfilldatabase is executing. Run that from the command line to
> see if
> there are more clues to the problem. The file (--output /tmp/blah) won't
> be removed
> so you can look at it too. You can even add --debug to the
> tv_grab_zz_sdjson command
> but don't do that 1st as it's pretty verbose.
>
> I use tv_grab_zz_sdjson_sqlite so won't be of much more help.
>
> Here's a picture of the desired files. Again for the *SQLite version*:
>
> Example for distributions that store MythTV data relative to
> ~mythtv/.mythtv,
>
> /
> ??? home
> ??? mythtv
> ??? .mythtv
> ? ??? OTA.xmltv # Which contains:
> ? ? database=/home/mythtv/.xmltv/SchedulesDirect.DB
> ? ? lineup=USA-OTA-90210
> ? ? mythtv-categories=enabled
> ? ?
> ? ??? CABLE.xmltv # Which contains:
> ? database=/home/mythtv/.xmltv/SchedulesDirect.DB
> ? lineup=USA-IL90210-X
> ? mythtv-categories=enabled
> ?
> ??? .xmltv
> ??? SchedulesDirect.DB
>
> Note that nothing is stored under the login user's .mythtv or .xmltv
>
> --
> 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: XMLTV setup can't run mythtv-setup as user mythtv [ In reply to ]
On Sat, Jul 25, 2020 at 5:30 PM Bill Meek <keemllib@gmail.com> wrote:

[snip]
>
> The intent of doing the setup as user mythtv is to end up with a single
> set of files
> in ~mythtv/.mythtv/*.xmltv and ~mythtv/.xmltv/* where the latter depends
> on the grabber
> selected.
>
> Doing links (hard or symbolic) defeats that and makes a difficult process
> even harder
> to setup and maintain.
>
> Here's the way to run mythfilldatabase from the command line:
>
> sudo --login --user=mythtv mythfilldatabase
>
> When the backend runs it, it will just work because the files are in it's
> .mythtv
> and .xmltv directories.
>
> Run the above with the -v system command and you'll see the
> tv_grab_zz_sdjson command
> line that mythfilldatabase is executing. Run that from the command line to
> see if
> there are more clues to the problem. The file (--output /tmp/blah) won't
> be removed
> so you can look at it too. You can even add --debug to the
> tv_grab_zz_sdjson command
> but don't do that 1st as it's pretty verbose.
>
> I use tv_grab_zz_sdjson_sqlite so won't be of much more help.
>
> Here's a picture of the desired files. Again for the *SQLite version*:
>
> Example for distributions that store MythTV data relative to
> ~mythtv/.mythtv,
>
> /
> ??? home
> ??? mythtv
> ??? .mythtv
> ? ??? OTA.xmltv # Which contains:
> ? ? database=/home/mythtv/.xmltv/SchedulesDirect.DB
> ? ? lineup=USA-OTA-90210
> ? ? mythtv-categories=enabled
> ? ?
> ? ??? CABLE.xmltv # Which contains:
> ? database=/home/mythtv/.xmltv/SchedulesDirect.DB
> ? lineup=USA-IL90210-X
> ? mythtv-categories=enabled
> ?
> ??? .xmltv
> ??? SchedulesDirect.DB
>
> Note that nothing is stored under the login user's .mythtv or .xmltv
>
>
OK I am close. My contents are the same as yours. The only issue I'm
having is that when I did the second (OTA) configuration, it seems to have
deleted the entries from the first (cable) configuration in the DB. When I
query with select distinct(lineup) from channels it gives only the
US-OTA-XXXXX lineup. And select * from lineups returns only one record for
the same lineup.

To be clear, I followed wiki directions from heading "Setup with
tv_grab_zz_sdjson_sqlite" by cutting from the wiki and pasting to the
terminal, substituting cable for SD the first time, and ota for SD the
second time. I assumed I had to do it twice to get the separate .xmltv
entries. Is there maybe an argument to tv_grab_zz_sdjson_sqlite that's not
noted in the wiki that I have to use to tell sqlite3 I'm appending a second
.xmltv config rather than starting a new DB? I was going to have a look at
the code (assuming it's not binary) but I can't locate the file.
Re: XMLTV setup can't run mythtv-setup as user mythtv [ In reply to ]
On 7/26/20 8:44 PM, DryHeat122 wrote:
> On Sat, Jul 25, 2020 at 5:30 PM Bill Meek <keemllib@gmail.com <mailto:keemllib@gmail.com>> wrote:
>
> [snip]
>
> The intent of doing the setup as user mythtv is to end up with a single set of files
> in ~mythtv/.mythtv/*.xmltv and ~mythtv/.xmltv/* where the latter depends on the grabber
> selected.
>
> Doing links (hard or symbolic) defeats that and makes a difficult process even harder
> to setup and maintain.
>
> Here's the way to run mythfilldatabase from the command line:
>
>    sudo --login --user=mythtv mythfilldatabase
>
> When the backend runs it, it will just work because the files are in it's .mythtv
> and .xmltv directories.
>
> Run the above with the -v system command and you'll see the tv_grab_zz_sdjson command
> line that mythfilldatabase is executing. Run that from the command line to see if
> there are more clues to the problem. The file (--output /tmp/blah) won't be removed
> so you can look at it too. You can even add --debug to the tv_grab_zz_sdjson command
> but don't do that 1st as it's pretty verbose.
>
> I use tv_grab_zz_sdjson_sqlite so won't be of much more help.
>
> Here's a picture of the desired files. Again for the *SQLite version*:
>
> Example for distributions that store MythTV data relative to ~mythtv/.mythtv,
>
> /
> ??? home
>      ??? mythtv
>          ??? .mythtv
>          ?   ??? OTA.xmltv # Which contains:
>          ?   ?       database=/home/mythtv/.xmltv/SchedulesDirect.DB
>          ?   ?       lineup=USA-OTA-90210
>          ?   ?       mythtv-categories=enabled
>          ?   ?
>          ?   ??? CABLE.xmltv # Which contains:
>          ?           database=/home/mythtv/.xmltv/SchedulesDirect.DB
>          ?           lineup=USA-IL90210-X
>          ?           mythtv-categories=enabled
>          ?
>          ??? .xmltv
>              ??? SchedulesDirect.DB
>
> Note that nothing is stored under the login user's .mythtv or .xmltv
>
> OK I am close.  My contents are the same as yours.  The only issue I'm having is that when I did the second (OTA) configuration, it seems to
> have deleted the entries from the first (cable) configuration in the DB.  When I query with select distinct(lineup) from channels it gives
> only the US-OTA-XXXXX lineup.  And select * from lineups returns only one record for the same lineup.

The same as my *example* is OK, but the key is that your source names in mythtv-setup
Video sources -> Video Source Name: are used to form the file name in .mythtv. So, if
you have two sources defined in mythtv-setup AND they're named OTA and CABLE, you're
good to go.

I used the SchedulesDirect.DB name for both DBs, I have two entries when using:
select distinct(lineup) from channels and two entries are found with: select * from lineups

But read on:

> To be clear, I followed wiki directions from heading "Setup with tv_grab_zz_sdjson_sqlite" by cutting from the wiki and pasting to the terminal,
> substituting cable for SD the first time, and ota for SD the second time.  I assumed I had to do it twice to get the separate .xmltv entries.
> Is there maybe an argument to tv_grab_zz_sdjson_sqlite that's not noted in the wiki that I have to use to tell sqlite3 I'm appending a second
> .xmltv config rather than starting a new DB?  I was going to have a look at the code (assuming it's not binary) but I can't locate the file.

"Substituting cable for SD the first time, and ota for SD the second time" is OK. It
just means you'll have two database files. And the database= line in the example must
point to them. E.g.:

In: CABLE.xmltv
database=/home/mythtv/.xmltv/SchedulesDirect.cable

In OTA.xmltv
database=/home/mythtv/.xmltv/SchedulesDirect.ota

Just edit the files and correct the paths as required.

I didn't do that and put everything in SchedulesDirect.DB. Truth be told, if I can carve
out some time, I always meant to do it the way you did.

From the above, you have ~mythtv/.xmltv/SchedulesDirect.cable and ~mythtv/.xmltv/SchedulesDirect.ota
Which is fine. If you want to peek inside the SQLite databases, then you must
do the query in each database name. sqlitebrowser is a bit easier (to me).

tv_grab_zz_sdjson_sqlite is written in Perl (I believe all of the grabbers are.)

--
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: XMLTV setup can't run mythtv-setup as user mythtv [ In reply to ]
On Sun, Jul 26, 2020 at 7:16 PM Bill Meek <keemllib@gmail.com> wrote:

>
> I didn't do that and put everything in SchedulesDirect.DB. Truth be told,
> if I can carve
> out some time, I always meant to do it the way you did.
>

I don't get how you did that. When I tried using the same DB name for the
second grabber, it overwrote the DB rather than appending. TBH that seems
like a better solution to have just one DB, but I will try it like you
suggested with different DB names if that's a solution.


> tv_grab_zz_sdjson_sqlite is written in Perl (I believe all of the grabbers
> are.)
>

Good! I happen to a Perl maven. Do you know where the source files are
located? locate tv_grab_zz_sdjson_sqlite returns nothing.
Re: XMLTV setup can't run mythtv-setup as user mythtv [ In reply to ]
On 7/27/20 10:44 AM, DryHeat122 wrote:
>
> On Sun, Jul 26, 2020 at 7:16 PM Bill Meek <keemllib@gmail.com
> <mailto:keemllib@gmail.com>> wrote:
>
>
> I didn't do that and put everything in SchedulesDirect.DB. Truth
> be told, if I can carve
> out some time, I always meant to do it the way you did.
>
>
> I don't get how you did that.  When I tried using the same DB name for
> the second grabber, it overwrote the DB rather than appending.  TBH
> that seems like a better solution to have just one DB, but I will try
> it like you suggested with different DB names if that's a solution.
>
> tv_grab_zz_sdjson_sqlite is written in Perl (I believe all of the
> grabbers are.)
>
> Good! I happen to a Perl maven.  Do you know where the source files
> are located?  locate tv_grab_zz_sdjson_sqlite returns nothing.
>
I found this on github https://github.com/azlm8t/tv_grab_az_sdjson_sqlite

Readme  says it python and in /usr/bin or /usr/local/bin

Jim A
Re: XMLTV setup can't run mythtv-setup as user mythtv [ In reply to ]
On Mon, Jul 27, 2020 at 8:02 AM Jim Abernathy <jfabernathy@gmail.com> wrote:

>
> On 7/27/20 10:44 AM, DryHeat122 wrote:
>
>
> On Sun, Jul 26, 2020 at 7:16 PM Bill Meek <keemllib@gmail.com> wrote:
>
>>
>> I didn't do that and put everything in SchedulesDirect.DB. Truth be told,
>> if I can carve
>> out some time, I always meant to do it the way you did.
>>
>
> I don't get how you did that. When I tried using the same DB name for the
> second grabber, it overwrote the DB rather than appending. TBH that seems
> like a better solution to have just one DB, but I will try it like you
> suggested with different DB names if that's a solution.
>
>
>> tv_grab_zz_sdjson_sqlite is written in Perl (I believe all of the
>> grabbers are.)
>>
>
> Good! I happen to a Perl maven. Do you know where the source files are
> located? locate tv_grab_zz_sdjson_sqlite returns nothing.
>
> I found this on github https://github.com/azlm8t/tv_grab_az_sdjson_sqlite
>
> Readme says it python and in /usr/bin or /usr/local/bin
>
> Jim A
>
I found the code. It's in ~/build/xmltv/blib/script and it is indeed
Perl. This is part of a big, complicated app with custom Perl modules that
would be hard to understand without taking some time. That said, I didn't
see anything that looks like a switch that is un-noted in the wiki. This
leads me to believe that I caused the problem by deleting the cable lineup
the second time I ran the configurator. I am going to try again and will
post results.
Re: XMLTV setup can't run mythtv-setup as user mythtv [ In reply to ]
On Mon, Jul 27, 2020 at 2:16 AM Bill Meek <keemllib@gmail.com> wrote:

> ... is written in Perl (I believe all of the grabbers are.)

The official XMLTV project only accepts perl
grabbers (for various reasons), but there are
other XMLTV compliant grabbers not part of
the official project floating around which have
been known to be written in languages other
than perl (at least a few are referenced on
the XMLTV project wiki as related projects).

MythTV is agnostic as to the language of the
grabber, as long as the output is compliant
to the XMLTV spec (there are even direct
sources of XMLTV compliant files available
from some providers/sources, making the
"grabber", essentially, a wget/curl download).
_______________________________________________
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: XMLTV setup can't run mythtv-setup as user mythtv [ In reply to ]
On 7/27/20 10:02 AM, Jim Abernathy wrote:
>
> On 7/27/20 10:44 AM, DryHeat122 wrote:
>>
>> On Sun, Jul 26, 2020 at 7:16 PM Bill Meek <keemllib@gmail.com <mailto:keemllib@gmail.com>> wrote:
>>
>>
>> I didn't do that and put everything in SchedulesDirect.DB. Truth be told, if I can carve
>> out some time, I always meant to do it the way you did.
>>
>>
>> I don't get how you did that.  When I tried using the same DB name for the second grabber, it overwrote the DB rather than appending.  TBH
>> that seems like a better solution to have just one DB, but I will try it like you suggested with different DB names if that's a solution.

Unfortunately, I didn't save the complete terminal session from when I did the setup.

Originally, you followed the Wiki exactly and ended up with two DBs.

Best guess is that if only one DB is used, then the 1st step that
initialized the DB should be omitted. I think the Wiki method
should stand.

--
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: XMLTV setup can't run mythtv-setup as user mythtv [ In reply to ]
On Mon, Jul 27, 2020 at 10:41 AM Bill Meek <keemllib@gmail.com> wrote:

> On 7/27/20 10:02 AM, Jim Abernathy wrote:
> >
> > On 7/27/20 10:44 AM, DryHeat122 wrote:
> >>
> >> On Sun, Jul 26, 2020 at 7:16 PM Bill Meek <keemllib@gmail.com <mailto:
> keemllib@gmail.com>> wrote:
> >>
> >>
> >> I didn't do that and put everything in SchedulesDirect.DB. Truth be
> told, if I can carve
> >> out some time, I always meant to do it the way you did.
> >>
> >>
> >> I don't get how you did that. When I tried using the same DB name for
> the second grabber, it overwrote the DB rather than appending. TBH
> >> that seems like a better solution to have just one DB, but I will try
> it like you suggested with different DB names if that's a solution.
>
> Unfortunately, I didn't save the complete terminal session from when I did
> the setup.
>
> Originally, you followed the Wiki exactly and ended up with two DBs.
>
> Best guess is that if only one DB is used, then the 1st step that
> initialized the DB should be omitted. I think the Wiki method
> should stand.
>
> --
> Bill
>
>
Having spent the morning dicking around with this, here is what I learned.
I tried following the steps in the wiki twice with different .xmltv
configurations but using the same DB. After I added the first one I
checked the channels with a sqlite3 query, and they were all there. After
adding the second .xmltv config and checking the channels, all the channels
from the second lineup were there but some (not all) of the channels from
the first lineup/config were gone. Bill, I wonder if this happened to you
and you just don't care about the channels removed.

I suspect this is a bug in tv_grab_zz_sdjson_sqlite because the db has the
structure to keep lineups separate and I can see no reason why adding a
lineup should remove entries from the first one. I posted a query about it
on the Schedules Direct forum
<https://forums.schedulesdirect.org/viewtopic.php?f=15&t=3103>. We will
see if anyone responds.

Meanwhile, I re-did everything with separate DBs, ran mythfilldatabase (as
mythtv!) and everything seems to have worked. So for now, it seems the
best thing to do is have separate DBs. When/if I get a response from
Schedules Direct I will edit the wiki to make note of this stuff.

Thanks for the advice guys. On to the next roadblock :-/
Re: XMLTV setup can't run mythtv-setup as user mythtv [ In reply to ]
On Mon, Jul 27, 2020 at 2:09 PM DryHeat122 <dryheat122@gmail.com> wrote:
> Meanwhile, I re-did everything with separate DBs, ran mythfilldatabase (as mythtv!) and everything seems to have worked. So for now, it seems the best thing to do is have separate DBs. When/if I get a response from Schedules Direct I will edit the wiki to make note of this stuff.

[I work for Schedules Direct]

I wouldn't wait too long for an answer from Schedules Direct; AFAICT,
you're having an application/grabber issue, not a Service issue.
_______________________________________________
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: XMLTV setup can't run mythtv-setup as user mythtv [ In reply to ]
On Mon, Jul 27, 2020 at 1:32 PM Robert Kulagowski <rkulagow@gmail.com>
wrote:

> On Mon, Jul 27, 2020 at 2:09 PM DryHeat122 <dryheat122@gmail.com> wrote:
> > Meanwhile, I re-did everything with separate DBs, ran mythfilldatabase
> (as mythtv!) and everything seems to have worked. So for now, it seems the
> best thing to do is have separate DBs. When/if I get a response from
> Schedules Direct I will edit the wiki to make note of this stuff.
>
> [I work for Schedules Direct]
>
> I wouldn't wait too long for an answer from Schedules Direct; AFAICT,
> you're having an application/grabber issue, not a Service issue.
> _______________________________________________
>

I figured that, which is why I posted to the forum rather than the support
ticket. But to your point, maybe it would be better to post on an XMLTV
forum.