Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: MythTV: Users

How to delete encoders from mythtv database

 

 

MythTV users RSS feed   Index | Next | Previous | View Threaded


agraham at g-b

May 11, 2008, 12:17 PM

Post #1 of 14 (526 views)
Permalink
How to delete encoders from mythtv database

How do you delete encoders from MythWeb ?

I have two boxes (frontend + backend), these have both had there names
changed, only the back end has an encoder installed.

MythWeb is showing 5 encoders - on the previous hostnames

The problem is I am unable to sheduale anything to record because - (I
think) the backend is trying to use the first encoder which does not
exist (Mythweb says the encoder is not connected"

e.g.


Encoder status

Encoder 1 is remote on agraham.g-b.net (currently not connected).
Encoder 2 is remote on laptop (currently not connected).
Encoder 3 is local on SAL-9000 and is not recording.
Encoder 4 is remote on agraham (currently not connected).
Encoder 5 is remote on JVC-TV (currently not connected).

In My case on the Encoder 3 exists, how can I delete the others ?

Albert.

_______________________________________________
mythtv-users mailing list
mythtv-users[at]mythtv.org
http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-users


myth at dermanouelian

May 11, 2008, 12:26 PM

Post #2 of 14 (503 views)
Permalink
Re: How to delete encoders from mythtv database [In reply to]

On May 11, 2008, at 12:17 PM, Albert Graham wrote:

> How do you delete encoders from MythWeb ?

You can't. Run mythtv-setup on your backend machine. Delete all cards
and recreate the one that you have. However, this will not prevent
scheduling like you said it is doing. Even with your current setup,
you should be able to schedule recordings and it will only schedule
programs to record on the tuner that's actually working.

_______________________________________________
mythtv-users mailing list
mythtv-users[at]mythtv.org
http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-users


knowledgejunkie at gmail

May 11, 2008, 12:26 PM

Post #3 of 14 (504 views)
Permalink
Re: How to delete encoders from mythtv database [In reply to]

On 11/05/2008, Albert Graham <agraham[at]g-b.net> wrote:
> How do you delete encoders from MythWeb ?

You should be using mythtv-setup to do this type of configuration.

> I have two boxes (frontend + backend), these have both had there names
> changed, only the back end has an encoder installed.

In this case, you will also need to ensure that all references to
these machine, both for MythTV and for MySQL database access, are
updated to the new hostnames.

--
Nick Morrott

MythTV Official wiki:
http://mythtv.org/wiki/
MythTV users list archive:
http://www.gossamer-threads.com/lists/mythtv/users

"An investment in knowledge always pays the best interest." - Benjamin Franklin
_______________________________________________
mythtv-users mailing list
mythtv-users[at]mythtv.org
http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-users


agraham at g-b

May 11, 2008, 12:34 PM

Post #4 of 14 (495 views)
Permalink
Re: How to delete encoders from mythtv database [In reply to]

Brad DerManouelian wrote:
> On May 11, 2008, at 12:17 PM, Albert Graham wrote:
>
>
>> How do you delete encoders from MythWeb ?
>>
> Even with your current setup,
> you should be able to schedule recordings and it will only schedule
> programs to record on the tuner that's actually working.
>

This was my understanding, and it was working up until now, but now
"Upcoming Recordings" is blank (with all options checked as if its
cannot figure out which input to use ?, but TV listings works OK

I'm stuck.

Albert.



_______________________________________________
mythtv-users mailing list
mythtv-users[at]mythtv.org
http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-users


agraham at g-b

May 11, 2008, 12:38 PM

Post #5 of 14 (494 views)
Permalink
Re: How to delete encoders from mythtv database [In reply to]

Nick Morrott wrote:
> On 11/05/2008, Albert Graham <agraham[at]g-b.net> wrote:
>
>> How do you delete encoders from MythWeb ?
>>
>
> You should be using mythtv-setup to do this type of configuration.
>
Any I did, only the, there is only 1 encoder on each machine in the
setup (but the front end has no source), only the back end.

>
>> I have two boxes (frontend + backend), these have both had there names
>> changed, only the back end has an encoder installed.
>>
>
> In this case, you will also need to ensure that all references to
> these machine, both for MythTV and for MySQL database access, are
> updated to the new hostnames.
>
>
Well, I've done this with MythTV, but how would I do this with the MySql
Database - do you have a SQL I could run ?

Also, is this the root of my problem ?, i.e. "cannot schedules anything
to record ?"

Albert.




_______________________________________________
mythtv-users mailing list
mythtv-users[at]mythtv.org
http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-users


agraham at g-b

May 11, 2008, 12:46 PM

Post #6 of 14 (494 views)
Permalink
Re: How to delete encoders from mythtv database [In reply to]

Brad,

Reading the docs at:

http://www.mythtv.org/docs/mythtv-HOWTO-23.html#advanced_backend_config

Confirms what you are saying to be correct.

Quote:
"The scheduler in MythTV checks whether an encoder is available; if a
slave backend isn't running, its encoder isn't available, so the
scheduler will look for the next available encoder. This makes MythTV
very flexible; slave tuners can come and go, and as long as there are
enough tuners for what you'd like to record it doesn't matter which
tuner in particular is going to be used"

In my case I have no slave back end's at all.

So why can't a schedule anything to record, also why is there nothing in
my "upcoming recordings", it's like some select is pointing to the wrong
value, but what ?

Albert.


Brad DerManouelian wrote:
> On May 11, 2008, at 12:17 PM, Albert Graham wrote:
>
>
>> How do you delete encoders from MythWeb ?
>>
>
> You can't. Run mythtv-setup on your backend machine. Delete all cards
> and recreate the one that you have. However, this will not prevent
> scheduling like you said it is doing. Even with your current setup,
> you should be able to schedule recordings and it will only schedule
> programs to record on the tuner that's actually working.
>
> _______________________________________________
> mythtv-users mailing list
> mythtv-users[at]mythtv.org
> http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-users
>

_______________________________________________
mythtv-users mailing list
mythtv-users[at]mythtv.org
http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-users


knowledgejunkie at gmail

May 11, 2008, 3:04 PM

Post #7 of 14 (490 views)
Permalink
Re: How to delete encoders from mythtv database [In reply to]

On 11/05/2008, Albert Graham <agraham[at]g-b.net> wrote:

> So why can't a schedule anything to record, also why is there nothing in
> my "upcoming recordings", it's like some select is pointing to the wrong
> value, but what ?

Go back into mythtv-setup, and make sure that on the Input Connections
page, your video source is connected to the correct encoder input.

--
Nick Morrott

MythTV Official wiki:
http://mythtv.org/wiki/
MythTV users list archive:
http://www.gossamer-threads.com/lists/mythtv/users

"An investment in knowledge always pays the best interest." - Benjamin Franklin
_______________________________________________
mythtv-users mailing list
mythtv-users[at]mythtv.org
http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-users


mtdean at thirdcontact

May 11, 2008, 3:06 PM

Post #8 of 14 (490 views)
Permalink
Re: How to delete encoders from mythtv database [In reply to]

On 05/11/2008 03:26 PM, Nick Morrott wrote:
> On 11/05/2008, Albert Graham <agraham[at]g-b.net> wrote:
>
>> I have two boxes (frontend + backend), these have both had there names
>> changed, only the back end has an encoder installed.
>>
> In this case, you will also need to ensure that all references to
> these machine, both for MythTV and for MySQL database access, are
> updated to the new hostnames.

http://mythtv.org/docs/mythtv-HOWTO-23.html#ss23.15

Mike
_______________________________________________
mythtv-users mailing list
mythtv-users[at]mythtv.org
http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-users


mtdean at thirdcontact

May 11, 2008, 3:07 PM

Post #9 of 14 (489 views)
Permalink
Re: How to delete encoders from mythtv database [In reply to]

On 05/11/2008 03:38 PM, Albert Graham wrote:
> Nick Morrott wrote:
>
>> On 11/05/2008, Albert Graham <agraham[at]g-b.net> wrote:
>>> I have two boxes (frontend + backend), these have both had there names
>>> changed, only the back end has an encoder installed.
>> In this case, you will also need to ensure that all references to
>> these machine, both for MythTV and for MySQL database access, are
>> updated to the new hostnames.
> Well, I've done this with MythTV, but how would I do this with the MySql
> Database - do you have a SQL I could run ?
>
> Also, is this the root of my problem ?, i.e. "cannot schedules anything
> to record ?"

Yep.

Mike
_______________________________________________
mythtv-users mailing list
mythtv-users[at]mythtv.org
http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-users


agraham at g-b

May 11, 2008, 3:20 PM

Post #10 of 14 (490 views)
Permalink
Re: How to delete encoders from mythtv database [In reply to]

Hi Nick,

I checked that and it is correct, in fact I originally thought that was
the problem, but it is set correctly - btw I can watch and record Live
TV - and "I" info displays the correct info - I can also change channels OK.

Albert.

Nick Morrott wrote:
> On 11/05/2008, Albert Graham <agraham[at]g-b.net> wrote:
>
>
>> So why can't a schedule anything to record, also why is there nothing in
>> my "upcoming recordings", it's like some select is pointing to the wrong
>> value, but what ?
>>
>
> Go back into mythtv-setup, and make sure that on the Input Connections
> page, your video source is connected to the correct encoder input.
>
>

_______________________________________________
mythtv-users mailing list
mythtv-users[at]mythtv.org
http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-users


agraham at g-b

May 11, 2008, 3:57 PM

Post #11 of 14 (490 views)
Permalink
Re: How to delete encoders from mythtv database [In reply to]

Mike,

That thread assumes a perfect world, my database seems to have lots of
configurations for lost of hostnames
get duplicate key errors when I run that sql.

Is it possible to clean up the databases and remove any references to
non-existing host names, if so how ?

Also, I don't think this is the root of my problem, because every single
other function works, including TV listings and watching and recording
from TV ?

Albert.


Michael T. Dean wrote:
> On 05/11/2008 03:26 PM, Nick Morrott wrote:
>
>> On 11/05/2008, Albert Graham <agraham[at]g-b.net> wrote:
>>
>>
>>> I have two boxes (frontend + backend), these have both had there names
>>> changed, only the back end has an encoder installed.
>>>
>>>
>> In this case, you will also need to ensure that all references to
>> these machine, both for MythTV and for MySQL database access, are
>> updated to the new hostnames.
>>
>
> http://mythtv.org/docs/mythtv-HOWTO-23.html#ss23.15
>
> Mike
> _______________________________________________
> mythtv-users mailing list
> mythtv-users[at]mythtv.org
> http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-users
>

_______________________________________________
mythtv-users mailing list
mythtv-users[at]mythtv.org
http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-users


mtdean at thirdcontact

May 11, 2008, 5:29 PM

Post #12 of 14 (477 views)
Permalink
Re: How to delete encoders from mythtv database [In reply to]

On 05/11/2008 06:57 PM, Albert Graham wrote:
> That thread assumes a perfect world, my database seems to have lots of
> configurations for lost of hostnames
> get duplicate key errors when I run that sql.
>
> Is it possible to clean up the databases and remove any references to
> non-existing host names, if so how ?
>

Spring cleaning: http://mythtv.org/docs/mythtv-HOWTO-23.html#ss23.7

Basically, first, make sure you have a backup of the "most-working"
state of the database. Then, drop the DB, then run mc.sql, then start
and exit mythtv-setup (allowing it to upgrade the database). Then,
follow the instructions in the link above (ideally using the
new-hostname database backup on which you ran the new-hostname sed
commands). If everything imports correctly (i.e. without duplicate key
errors), you're good to go (and begin to reconfigure your Myth box with
mythtv-setup, then mythfrontend settings).

If the 23.7 tables don't import cleanly, let me know and I'll give you a
more involved process.

> Also, I don't think this is the root of my problem, because every single
> other function works, including TV listings and watching and recording
> from TV ?

I think the current state of the database is the root of the problem.
How it got into the current state isn't too important. Just do as
above, and it should fix it.

Mike
_______________________________________________
mythtv-users mailing list
mythtv-users[at]mythtv.org
http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-users


agraham at g-b

May 11, 2008, 6:27 PM

Post #13 of 14 (476 views)
Permalink
Re: How to delete encoders from mythtv database [In reply to]

Mike,

Well, thanks for that, looks like it should solve the problem, will give
it a go.

Thanks again.

Albert.



Michael T. Dean wrote:
> On 05/11/2008 06:57 PM, Albert Graham wrote:
>
>> That thread assumes a perfect world, my database seems to have lots of
>> configurations for lost of hostnames
>> get duplicate key errors when I run that sql.
>>
>> Is it possible to clean up the databases and remove any references to
>> non-existing host names, if so how ?
>>
>>
>
> Spring cleaning: http://mythtv.org/docs/mythtv-HOWTO-23.html#ss23.7
>
> Basically, first, make sure you have a backup of the "most-working"
> state of the database. Then, drop the DB, then run mc.sql, then start
> and exit mythtv-setup (allowing it to upgrade the database). Then,
> follow the instructions in the link above (ideally using the
> new-hostname database backup on which you ran the new-hostname sed
> commands). If everything imports correctly (i.e. without duplicate key
> errors), you're good to go (and begin to reconfigure your Myth box with
> mythtv-setup, then mythfrontend settings).
>
> If the 23.7 tables don't import cleanly, let me know and I'll give you a
> more involved process.
>
>
>> Also, I don't think this is the root of my problem, because every single
>> other function works, including TV listings and watching and recording
>> from TV ?
>>
>
> I think the current state of the database is the root of the problem.
> How it got into the current state isn't too important. Just do as
> above, and it should fix it.
>
> Mike
> _______________________________________________
> mythtv-users mailing list
> mythtv-users[at]mythtv.org
> http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-users
>

_______________________________________________
mythtv-users mailing list
mythtv-users[at]mythtv.org
http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-users


agraham at g-b

May 12, 2008, 5:31 PM

Post #14 of 14 (410 views)
Permalink
Re: How to delete encoders from mythtv database [In reply to]

Hi Mike,

Fixed, thank you for the points - I really didn't want to start over
again :(

Basically I backed up the broken database, them created a separate
"tablname".sql for each table in the database using a script like the
following.

=== Start ====
#!/bin/sh

filename="tables.txt" # This is a file that contains tables names - 1
per line

backup="backup.sql" # contains a backup of the original database

cat $filename| \
while read line;do

if [ -n "$line" ]; then
# echo "-> $line"
echo "grep \"INSERT INTO \`$line\` \" "$backup" > \"tmp/${line}.sql\""
grep "INSERT INTO \`$line\` " "$backup" > "tmp/${line}.sql"

mysql -u root mythconverg < tmp/${line}.sql

fi

done

===========

When I got Duplicate keys, I removed that table name from the tables.txt
file, then restored the 'new clean" database and re-ran the above script
- so I get no errors - managed to keep 60 tables - so I'm a happy camper.

Anyway, thanks for you help, very very much appreciated.

Albert.



Michael T. Dean wrote:
> On 05/11/2008 06:57 PM, Albert Graham wrote:
>
>> That thread assumes a perfect world, my database seems to have lots of
>> configurations for lost of hostnames
>> get duplicate key errors when I run that sql.
>>
>> Is it possible to clean up the databases and remove any references to
>> non-existing host names, if so how ?
>>
>>
>
> Spring cleaning: http://mythtv.org/docs/mythtv-HOWTO-23.html#ss23.7
>
> Basically, first, make sure you have a backup of the "most-working"
> state of the database. Then, drop the DB, then run mc.sql, then start
> and exit mythtv-setup (allowing it to upgrade the database). Then,
> follow the instructions in the link above (ideally using the
> new-hostname database backup on which you ran the new-hostname sed
> commands). If everything imports correctly (i.e. without duplicate key
> errors), you're good to go (and begin to reconfigure your Myth box with
> mythtv-setup, then mythfrontend settings).
>
> If the 23.7 tables don't import cleanly, let me know and I'll give you a
> more involved process.
>
>
>> Also, I don't think this is the root of my problem, because every single
>> other function works, including TV listings and watching and recording
>> from TV ?
>>
>
> I think the current state of the database is the root of the problem.
> How it got into the current state isn't too important. Just do as
> above, and it should fix it.
>
> Mike
> _______________________________________________
> mythtv-users mailing list
> mythtv-users[at]mythtv.org
> http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-users
>

_______________________________________________
mythtv-users mailing list
mythtv-users[at]mythtv.org
http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-users

MythTV users RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact lists@gossamer-threads.com
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.