CompTIA
XK0-005 · Question #1747
A Linux administrator is investigating the reason a systemd timer is not running every night at midnight. The administrator sees the following unit file: [Unit] Description=Execute backup every day…
The correct answer is A. Remove RandomizedDelaySec=10800. The RandomizedDelaySec parameter delays the timer by a random time within the specified seconds, which can be up to 3 hours in this case. Removing it will ensure the timer triggers at exactly midnight. Additionally, using OnCalendar=--* daily correctly schedules the timer to…
System Management
Question
A Linux administrator is investigating the reason a systemd timer is not running every night at midnight. The administrator sees the following unit file: [Unit] Description=Execute backup every day at midnight [Timer] OnCalendar=--01 00:00:00 Unit=backup.service RandomizedDelaySec=10800 [Install] WantedBy=multi-user.target Which of the following modifications should the administrator make in the unit file? (Select 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
(64 responses)- A72% (46)
- B8% (5)
- C5% (3)
- D13% (8)
- E2% (1)
- F2% (1)
Explanation
The RandomizedDelaySec parameter delays the timer by a random time within the specified seconds, which can be up to 3 hours in this case. Removing it will ensure the timer triggers at exactly midnight. Additionally, using OnCalendar=--* daily correctly schedules the timer to run every day at midnight.
Topics
#systemd#systemd timers#Linux scheduling#Unit files
Community Discussion
No community discussion yet for this question.