<br><div class="gmail_quote">On Thu, May 10, 2012 at 2:05 PM, Gabe Rubin <span dir="ltr">&lt;<a href="mailto:gaberubin@gmail.com" target="_blank">gaberubin@gmail.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div class="im"><br>
<br>
On May 9, 2012, at 8:48 PM, &quot;Michael T. Dean&quot; &lt;<a href="mailto:mtdean@thirdcontact.com">mtdean@thirdcontact.com</a>&gt; wrote:<br>
<br>
&gt; On 05/09/2012 11:43 PM, Bill Meek wrote:<br>
&gt;&gt; On 05/09/2012 10:33 PM, Gabe Rubin wrote:<br>
&gt;&gt; ...<br>
&gt;&gt;&gt; [mythtv@localhost backup]$ more /home/mythtv/.mythtv/backuprc<br>
&gt;&gt;&gt; DBBackupDirectory=/home/mythtv/.mythtv/backup<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; And the command works from the command line.  It just seems that none<br>
&gt;&gt;&gt; of my cronjobs are functioning.<br>
&gt;&gt;<br>
&gt;&gt; But isn&#39;t your cron job running as root? If so, there<br>
&gt;&gt; should be a similar entry in ~root/.mythtv.<br>
&gt;&gt;<br>
&gt;&gt; At least that would explain why cron fails and command line works.<br>
&gt;&gt;<br>
&gt;<br>
<br>
</div>This is my mythtv cron job.  What I pasted in my first email was from running crontab -e as the mythtv user.<br>
<div class="im"><br>
&gt; And/or you need to specify a value for HOME to point to /home/mythtv<br>
&gt;<br>
&gt; (without a valid HOME, nearly all things MythTV will fail--including <a href="http://optimize_mythdb.pl" target="_blank">optimize_mythdb.pl</a> and <a href="http://mythconverg_backup.pl" target="_blank">mythconverg_backup.pl</a>)<br>

&gt;<br>
<br>
</div>I am not sure I understand what this means. And does it change anything that the cron job is running as mythtv?<br>
<div class="HOEnZb"><div class="h5">_______________________________________________<br>
mythtv-users mailing list<br>
<a href="mailto:mythtv-users@mythtv.org">mythtv-users@mythtv.org</a><br>
<a href="http://www.mythtv.org/mailman/listinfo/mythtv-users" target="_blank">http://www.mythtv.org/mailman/listinfo/mythtv-users</a><br>
</div></div></blockquote></div><br><div>It&#39;s a shell thing. So have in mind that when you run the cronjob it runs without shell so it doesn&#39;t inherit your environment settings which explains why it is successful from the shell command line and fails from cron.</div>
<div><br></div><div>You need to source your <span style>/home/mythtv/.mythtv/backuprc file first. So try putting the cron like this:</span></div><div><span style><br></span></div><div><span style>30 3 * * * . </span><span style>/home/mythtv/.mythtv/backuprc &amp;&amp; </span><span style>/usr/bin/</span><a href="http://mythconverg_backup.pl/" target="_blank" style>mythconverg_backup.pl</a></div>
<div>               ^</div><div>(yes, that&#39;s a dot then a space then the rest of the line here)</div><div><br></div><div>Igor</div><div><br></div><div><br></div>