[mythtv-users] How to check if a tuner is in use

Mike Perkins mikep at randomtraveller.org.uk
Wed Oct 15 22:04:11 UTC 2014


On 15/10/14 21:53, Bill Meek wrote:
> On 10/15/2014 03:10 PM, Hika van den Hoven wrote:
>>> ...
>>>> parser.add_argument('--host', type=str, required=False, metavar='<hostname>',
>>>>       help='backend hostname,  default <local hostname>')
>>
>>> You could just add: default='localhost' to the above. Or,
>>> leave required=True and on the command line type --host=localhost
>>> or whatever you choose.
>>
>> Ah, but I need the 'local hostname' not 'localhost'! That's what
>> Mythtv uses. Unless you only have one combined machine.
>
> We must be talking about different things. The --host argument
> is used to form the URL and should be the name of the host, as
> in, the name in /etc/hosts. Which *may* be the same as the MythTV
> hostname in its DB (used as a profile name.)
>
>
You need to be careful using the local hostname. This may be just a host name or 
a fully-qualified domain name (including the host), neither of which may be how 
the mythtv front or back end is identified in the database!

You have to look at config.xml and make decisions based on the contents of that 
as well. I have overrides on all my mythtv hosts, since OS upgrades gave 
inconsistent results to hostname().

-- 

Mike Perkins



More information about the mythtv-users mailing list