Using systemd timer

Systemd timer can be used to replace Cron for job scheduler. A timer file must be accompanied by a service file with the same name by default (except for the suffix). The service is triggered when the timer elapses. Because Omarine 6.0 does not use dcron, I write this article to guide you to create your own timer if needed.
We begin with a timer updating virus database that has been set up in Omarine 6.0. That is the pair of timer file clamav-freshclam.timer and service file clamav-freshclam.service.

In the [Timer] section, OnCalendar=02,14:10:00 defines that the timer will trigger the service at 02:10 and 14:10 daily. With Persistent=true, the last triggered time is stored on disk, and the service will be triggered immediately if at least one triggering event is lost while the machine is off. This ensures the reasonability of the event over time. See systemd.timer(5) and systemd.time(7) for more options.