LinHES Forums
http://forum.linhes.org/

Solved: How to remove Stale Card inputs?
http://forum.linhes.org/viewtopic.php?f=11&t=15017
Page 1 of 1

Author:  bigbro [ Sun Apr 22, 2007 6:15 pm ]
Post subject:  Solved: How to remove Stale Card inputs?

In this post R5E50 Upgrade Hints and Hazards http://mysettopbox.tv/phpBB2/viewtopic.php?p=88235#88235
A couple of quotes from TJC...
Quote:
..getting errors/warnings when you try to exit mythtv-setup along the lines of "Card 0 (type) is set to start on channel 2, which does not exist." see this thread...on getting rid of stale capture...

Later in thread..
Quote:
If the following commands show a cardid (especially 0) in the cardinput table which is not listed in the capturecard table you should remove all references to it:


There is a post referenced in there for removing the False or stale or No Longer Valid inputs however, it doesn't seem to be available.

I did look for the posts.

Here is the script I ran and my outputs.
As root:
Code:
mysql mythconverg -e "select cardid, videodevice, defaultinput from capturecard"
+--------+-------------+--------------+
| cardid | videodevice | defaultinput |
+--------+-------------+--------------+
|      1 | /dev/video0 | S-Video 0    |
|      2 | /dev/video0 | S-Video 0    |
|      3 | /dev/video0 | S-Video 0    |
|      4 | /dev/video1 | Composite 0  |
+--------+-------------+--------------+

mysql mythconverg -e "select cardid, sourceid, inputname from cardinput"
+--------+----------+-------------+
| cardid | sourceid | inputname   |
+--------+----------+-------------+
|      0 |        0 |             |
|      1 |        1 | S-Video 0   |
|      0 |        0 |             |
|      2 |        1 | S-Video 0   |
|      0 |        0 |             |
|      3 |        1 | S-Video 0   |
|      0 |        0 |             |
|      4 |        1 | Composite 0 |
|      0 |        0 |             |
+--------+----------+-------------+



My Question and I am sure there is more than one answer. What is the way to get rid of these "0" cardids?

I am thinking I can use Webmin > Servers > Mysql Database Server.
Select table "mythconverg"
Search out "cardinput"
It will show a Table. Select that table and it will show the fields.

At this point Select View Data

That gives me a list of the card inputs similar to the table above.
I can then select the Id's that are a "0" and tell it to delete the selected rows.

Is this workable?

If there is another method, please post as well.

Asking before I try.

Using Knoppmyth R5C7

TIA.

Andy

Author:  tjc [ Sun Apr 22, 2007 6:43 pm ]
Post subject: 

Code:
mysql mythconverg -e "delete from cardinput where cardid=0"

Webmin works too. I added the trailing post becuse the other thread had been lost.

Author:  bigbro [ Sun Apr 22, 2007 7:07 pm ]
Post subject:  Solved: Two methods to remove Stale inputs

Thanks. I didn't see your trail when I was looking.

I'll close this one now with Solved and a How To:

Author:  bburtin [ Thu Jun 28, 2007 11:06 pm ]
Post subject: 

I hit this case with a fresh install of R5F1. I went on autopilot and created new cards and video sources without realizing that the installer did it for me automatically. As a result the backend failed to start. Then the mythtv-setup UI wouldn't let me delete the extra cards and sources. I'd hit "D", confirm, and nothing happened.

Once I hacked my cardinput and videosource tables my backend started up successfully. Weird.

Page 1 of 1 All times are UTC - 6 hours
Powered by phpBB® Forum Software © phpBB Group
http://www.phpbb.com/