Here is my service unit definition
[Unit]
Description=My Service
[Service]
ExecStart=/bin/bash -lc /usr/local/bin//myservice
# ExecStop=/bin/kill -15 $MAINPID
EnvironmentFile=/etc/myservice/config
User=myuser
Group=mygroup
and its timer unit file
[Unit]
Description=Timer for myservice
[Timer]
Unit=myservice.service
OnCalendar=*-*-* 10:33:00
[Install]
WantedBy=timers.target
I have tentatively set the OnCalendar
to *-*-* 10:33:00
(followed by a sudo systemctl daemon-reload
) but as a I was watching my machine, I didn't see the service firing. I had also set it for 5AM but this morning I saw no evidence of execution
When I perform a manual sudo systemctl start myservice
it works as expected.
What might be preventing the service from executing according to its timer
schedule?
You did not start the timer.
sudo systemctl start myservice.timer