[mythtv-users] How do I use sudo to write to a root-owned file?

Chris Adams rocket at extremelan.net
Sun Oct 11 23:57:16 UTC 2009


>> It's much easier to all specific sudo access to a command like tee in
>> a specific folder than to a whole script...
>>
>> simply edit the /etc/sudoers file with the proper configuration
>
> Ahhh, I have only ever added a user to the sudoers file. I didn't
> realize you could control things with that type of granularity in the
> sudoers file. Perhaps that is the information that would be useful to
> the OP.

Another note on the granularity; in the sudoers file you can also
control which parameters are allowed. You can let the mythtv user only
"sudo tee" stuff to /sys/class/rtc/rtc0/wakealarm. It avoids the
ability to hose other system files, however unlikely that is.


More information about the mythtv-users mailing list