[mythtv-users] can't set wakealarm

David Hampton mythtv at love2code.net
Fri Aug 10 04:09:32 UTC 2018


On Fri, 2018-08-10 at 03:46 +0000, Mark Perkins wrote:
> 
> On 10 August 2018 12:09:46 pm Douglas Peale <
> Douglas_Peale at comcast.net> wrote:
> 
> > I am attempting to follow these instructions here: 
> > https://www.mythtv.org/wiki/ACPI_Wakeup
> > 
> > when I test setting the wake alarm I get the following:
> > 
> > $ echo 0 > /sys/class/rtc/rtc0/wakealarm
> > bash: /sys/class/rtc/rtc0/wakealarm: Permission denied
> > 
> > 
> > Even sudo does not help here:
> > 
> > $ sudo echo 0 > /sys/class/rtc/rtc0/wakealarm
> > bash: /sys/class/rtc/rtc0/wakealarm: Permission denied
> > 
> > 
> > This was working before I upgraded to Mint 19. but the last time I
> > messed 
> > with this stuff was 8 years ago, so I have forgotten
> > what I knew then.
> > 
> > 
> > What am I missing?
> > 
> > 
> > 
> > 
> > 
> > ----------
> > _______________________________________________
> > mythtv-users mailing list
> > mythtv-users at mythtv.org
> > http://lists.mythtv.org/mailman/listinfo/mythtv-users
> > http://wiki.mythtv.org/Mailing_List_etiquette
> > MythTV Forums: https://forum.mythtv.org
> 
> The sudo only applies to the echo or something like that. Check out
> a 
> couple of examples here or try "sudo bash"  for elevated shell or
> some 
> equivalent.

Right.  The sudo only applies to the echo command.  The redirection is
still being done as your user which doesn't have permissions.  Try
this:

    sudo bash -c "echo 0 > /sys/class/rtc/rtc0/wakealarm"

The quotes will make the redirection happen as the root user.

David




More information about the mythtv-users mailing list