Thank you, Richard. you answered another question I had about one. I can
now fix all of my cronjobs to be .service/.timer pairs.

Trever

On 06/15/2017 03:18 PM, Richard Shaw wrote:
> On Thu, Jun 15, 2017 at 4:12 PM, Trever L. Adams
> <tre...@middleearth.sapphiresunday.org
> <mailto:tre...@middleearth.sapphiresunday.org>> wrote:
>
>     I am needing a bit of help. I am converting some of my old crontab
>     entries to xxx.timer and xxx.service systemd files. I have the
>     following
>     (the system is a backup server that can be woken by magic packets or
>     some amount of time before the backups run):
>
>     ExecStart=/usr/sbin/rtcwake -m mem -t $(/usr/bin/date +\%s -d 'today
>     23:50') > /dev/null
>
>     It yeilds:
>
>     Invalid escape sequences in line, correcting: "/usr/sbin/rtcwake
>     -m mem
>     -t $(/usr/bin/date +\%s -d 'today 23:50') > /dev/null"
>
>
>     Is there a way to correct this easily, or am I going to have to turn
>     that line into a separate shell script?
>
>
> SystemD executes the binaries directly without a shell so you can't
> use shell variables and such. You could write a script or I think
> prepending /usr/bin/bash on the front may work. You may need to put
> the commands in quotes. Google should find you an example.
>
> Thanks,
> Richard 
>
>
> _______________________________________________
> users mailing list -- users@lists.fedoraproject.org
> To unsubscribe send an email to users-le...@lists.fedoraproject.org


Attachment: signature.asc
Description: OpenPGP digital signature

_______________________________________________
users mailing list -- users@lists.fedoraproject.org
To unsubscribe send an email to users-le...@lists.fedoraproject.org

Reply via email to