XK0-005 · Question #877
A Linux administrator is investigating the reason a system timer is not running every night at midnight. The administrator reviews the following unit file: Which of the following modifications…
The correct answer is C. Change OnCalendar to*-*-* 00:00:00. F. Remove OnCalendar=*-*-01 00:00:00. The timer is intended to run every night at midnight but is not doing so because the OnCalendar entry 'OnCalendar=--01 00:00:00' means 'run on the 1st day of every month at midnight' - not every night. Two fixes are needed: (F) Remove the incorrect 'OnCalendar=--01 00:00:00'…
Question
A Linux administrator is investigating the reason a system timer is not running every night at midnight. The administrator reviews the following unit file:
Which of the following modifications should the administrator make in the unit file? (Choose two.)
Options
- ARemove RandomizedDelaySec=10800.
- BAdd WakeSystem=Midnight.
- CChange OnCalendar to*-- 00:00:00.
- DAdd OnCalendar=--* daily.
- EAdd AccuracySec=1.
- FRemove OnCalendar=--01 00:00:00.
How the community answered
(22 responses)- A14% (3)
- B5% (1)
- C77% (17)
- D5% (1)
Explanation
The timer is intended to run every night at midnight but is not doing so because the OnCalendar entry 'OnCalendar=--01 00:00:00' means 'run on the 1st day of every month at midnight' - not every night. Two fixes are needed: (F) Remove the incorrect 'OnCalendar=--01 00:00:00' line entirely, and (C) add or change OnCalendar to '--* 00:00:00', which correctly means 'every day () of every month () of every year () at midnight'. The other options are distractors: RandomizedDelaySec and AccuracySec affect timing precision but do not fix the scheduling logic, and 'WakeSystem=Midnight' and 'OnCalendar=-- daily' are not valid systemd timer directives.
Topics
Community Discussion
No community discussion yet for this question.