Re: Inhibit sleep from systemd service

2021-03-24 Thread Tim via users
On Wed, 2021-03-24 at 14:17 -0400, Matthew Miller wrote: > my new workstation system is a little too power-hungry to make me > feel good about leaving on all the time. It might be worth measuring what it actually uses. A system may have a 500 watt power supply, but that's the amount its able to s

Re: Inhibit sleep from systemd service

2021-03-24 Thread Gordon Messmer
On 3/24/21 11:17 AM, Matthew Miller wrote: This is pretty cool -- I'm thinking of something similar, as my new workstation system is a little too power-hungry to make me feel good about leaving on all the time. Do you have a blog post or repo with your complete solution? I keep this in a priva

Re: Inhibit sleep from systemd service

2021-03-24 Thread Matthew Miller
On Tue, Mar 23, 2021 at 09:40:04PM -0700, Gordon Messmer wrote: > All sorted out and working as expected now. This is pretty cool -- I'm thinking of something similar, as my new workstation system is a little too power-hungry to make me feel good about leaving on all the time. Do you have a blog p

Re: Inhibit sleep from systemd service

2021-03-23 Thread Gordon Messmer
On 3/21/21 11:08 PM, Ed Greshko wrote: So, does your backup process work when called from crontab entry? Yes, it does, and that's part of what confused me.  However -- and this is rather embarrassing -- the real problem was a missing environment variable in the script when the process was ru

Re: Inhibit sleep from systemd service

2021-03-22 Thread Ed Greshko
On 22/03/2021 14:08, Ed Greshko wrote: But, when testing things I like to use examples which use simple system  commands.  To verify that things work as I think they should in various ways before trying my commands/scripts. Along those lines [egreshko@f33k ~]$ cat /etc/systemd/system/mycro

Re: Inhibit sleep from systemd service

2021-03-21 Thread Ed Greshko
On 22/03/2021 11:07, Gordon Messmer wrote: I'd like to inhibit suspend while backups run on my laptop.  I'm scheduling those backups with a systemd timer[1] and service[2]. I've read that the default polkit policy only permits inhibiting suspend from within a login session, so I've also tried t

Inhibit sleep from systemd service

2021-03-21 Thread Gordon Messmer
I'd like to inhibit suspend while backups run on my laptop.  I'm scheduling those backups with a systemd timer[1] and service[2]. I've read that the default polkit policy only permits inhibiting suspend from within a login session, so I've also tried to add rules to allow the root user to inhib