<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Sun, Jan 28, 2018 at 6:12 PM, Craig Huff <span dir="ltr"><<a href="mailto:huffcslists@gmail.com" target="_blank">huffcslists@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div class="gmail_extra"><div class="gmail_quote"><div><div class="gmail-h5">On Sun, Jan 28, 2018 at 5:04 PM, Paul Harrison <span dir="ltr"><<a href="mailto:mythtv@sky.com" target="_blank">mythtv@sky.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
  
    
  
  <div bgcolor="#FFFFFF"><div><div class="gmail-m_-6067935802155653957gmail-h5">
    <div class="gmail-m_-6067935802155653957gmail-m_2652233098947705540moz-cite-prefix">On 28/01/18 22:17, Craig Huff wrote:<br>
    </div>
    <blockquote type="cite">
      <div dir="ltr">On Sun, Jan 28, 2018 at 4:09 PM,
            Craig Huff <span dir="ltr"><<a href="mailto:huffcslists@gmail.com" target="_blank">huffcslists@gmail.com</a>></span>
            wrote:<br>
            <div class="gmail_extra"><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
              <div dir="ltr"><span>
                  <div class="gmail_extra">
                    <div class="gmail_quote">On Sun, Jan 28, 2018 at
                      4:00 PM, Paul Harrison <span dir="ltr"><<a href="mailto:mythtv@sky.com" target="_blank">mythtv@sky.com</a>></span>
                      wrote:<br>
                      <blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
                        <div bgcolor="#FFFFFF">
                          <div>
                            <div class="gmail-m_-6067935802155653957gmail-m_2652233098947705540m_6733518125825962791h5"><br>
                            </div>
                          </div>
                          If you can't repair the recordedseek table one
                          option is to truncate it and restore just that
                          table from your old backup. That way only the
                          seektables for new recordings will be missing
                          which you can fix by running 'mythutil
                          --checkrecordings  --fixseektable'<br>
                          <br>
                          Paul H.<br>
                        </div>
                        <br>
                      </blockquote>
                    </div>
                    <br>
                  </div>
                </span>
                <div class="gmail_extra">Paul-<br>
                  <br>
                </div>
                <div class="gmail_extra">Re-creating the seektable data
                  for the new recordings it what I was hoping to do, but
                  the trick I haven't figured out yet is how to restore
                  just the recordedseek table.<br>
                </div>
                <div class="gmail_extra"><br>
                </div>
                <div class="gmail_extra">Can you give me more details on
                  that?<br>
                  <ul>
                    <li>How do I truncate it (presumably the
                      recordedseek table)?</li>
                    <li>How would you suggest I restore the recordedseek
                      table from the backup?</li>
                  </ul>
                </div>
                <div class="gmail_extra">--<br>
                </div>
                <div class="gmail_extra">Craig.<br>
                </div>
              </div>
            </blockquote>
          </div>
          <br>
        </div>
        <div class="gmail_extra">Looks like truncation would involve
          launching an interactive mysql session and invoking the
          command "TRUNCATE TABLE recordedseek;".  Correct?<br>
          <br>
          --<br>
        </div>
        <div class="gmail_extra">Craig.<br>
        </div>
      </div>
      <br>
    </blockquote>
    <br></div></div>
    Yes that will remove all the data from the recordedseek table. I
    would also drop the table as well since the backup will recreate it.<br>
    <br>
    Your backup will contain all the data for all tables so you will
    have to create a new one with just the recordedseek data in it.
    That's the tricky bit because if you have a lot of recordings the
    backups are very large. You can if they are small enough edit it in
    a text editor but most are to large to do that.<br>
    <br>
    Easiest way is probably to run a sed command to extract it something
    like this works for me<br>
    <pre class="gmail-m_-6067935802155653957gmail-m_2652233098947705540lang-sql gmail-m_-6067935802155653957gmail-m_2652233098947705540prettyprint gmail-m_-6067935802155653957gmail-m_2652233098947705540prettyprinted"><code><span class="gmail-m_-6067935802155653957gmail-m_2652233098947705540pln">sed -n -e '/CREATE TABLE.*`recordedseek`/,/UNLOCK TABLES;/p' mythconverg-1348-2017121500105<wbr>2.sql > recordedseek.sql</span><span class="gmail-m_-6067935802155653957gmail-m_2652233098947705540pln">


Paul H.</span><span class="gmail-m_-6067935802155653957gmail-m_2652233098947705540pun"></span></code></pre>
  </div></blockquote></div></div><div><font size="2"><span style="font-family:arial,helvetica,sans-serif">Paul,<br><br></span></font></div>I thought to use <a href="http://mythconverg_restore.pl" target="_blank">mythconverg_restore.pl</a> to restore the recordedseek table after replacing the contents of my equivalent of  mythconverg-1348-<wbr>20171215001052.sql with the recordedseek.sql contents (after making a backup copy of mythconverg-1348-<wbr>20171215001052.sql elsewhere).<br><br>That didn't work because the rest of the database is still there and the restore program didn't like that -- not really a surprise.  So, I guess I need to feed the recordedseek.sql file into a mysql command line as a command file.  I can figure that out.  I think I've even done it before.<br><br></div><div class="gmail_quote">Many thanks to all for your input.  If this works, I won't clutter the maillist with more traffic.  If you hear from me, it'll be because I'm stuck again.<br><br>--<br></div><div class="gmail_quote">Craig.<br></div></div></div>
</blockquote></div><br>Just to close the loop so to speak, "mysql ..... < recordedseek.sql" 
didn't work either.  I think the problem was that several records got 
lost in the recordedseek table that were "known" to other table(s) and 
so they would always result in detected corruption.  I finally had to 
restore the previous day's backup as resign myself to having a couple of
 recordings orphaned.  No big deal.  They'll come around again and get 
recorded when they do.<br><br>--<br></div><div class="gmail_extra">Craig.<br></div></div>