[mythtv-users] Update to Mint 17.2 broke wakeup function.

Bill Meek keemllib at gmail.com
Sat Aug 8 14:03:04 UTC 2015


On 08/08/2015 01:01 AM, Douglas Peale wrote:
> I am trying to debug what is going wrong since upgrading from Mint 17 to Mint 17.2.
> I can't tell if the script in "Command to set wakeup time" is being run.
>
> The original command is
>
> sudo sh -c "/usr/bin/setwakeup.sh $time"
>
> . I tried to add echo commands to the "setwakeup.sh" script, but I can't seem to figure out how to get the results into a log file.

Hi,

Consider this (*assuming* that the user running the program
doesn't have write permission to the file.):

This will fail:
sudo echo blah >> /tmp/blah

This will work:
echo blah | sudo tee -a /tmp/blah

But an echo within the script works (for me) like the following
which is run as: sudo /usr/local/bin/SetWakeupTime.sh:

     echo "ERROR: Can't write to ${ALARM_FILE}, RC = ${RC}" >> ${ALARM_LOG}

I do have the program name in /etc/sudoers.d/mythtv.

-- 
Bill


More information about the mythtv-users mailing list