From the course: Exploring Linux Internals: Advanced Insights and Practical Applications
Unlock this course with a free trial
Join today to access over 24,900 courses taught by industry experts.
Scheduling processes with timers - Linux Tutorial
From the course: Exploring Linux Internals: Advanced Insights and Practical Applications
Scheduling processes with timers
- In this video, you will learn about systemd timers. So systemd timers are used to run scheduled jobs and they replace cron functionality. That is something that is actually already happening. If you look at cron jobs on a RHEL 9 system, for instance, you won't see any because they have been replaced by timers as a default. Now, a systemd timer runs a command for a specific amount of time, and it can also run a command after occurrence of a specific event. And as I mentioned, currently, distributors are replacing cron with systemd timers. Let's check them out. So first, I would like to investigate cron. We are on which operating system? Well, this is CentOS Stream version 9. And if we will use ls on etc/cron*, then what do we see? We see that the etc/cron.d and cron.daily and cron.hourly, monthly and weekly, they're all empty. Cron jobs are gone. And that's because of the timers. So let's use systemctl list units minus t timer. And here, we can see the timers that are currently…
Contents
-
-
-
-
-
-
(Locked)
Learning objectives55s
-
(Locked)
Manually starting systemd4m 32s
-
(Locked)
Systemd unit files4m 39s
-
(Locked)
Tweaking unit files7m 5s
-
Mounting filesystems with systemd11m 18s
-
(Locked)
Using sockets4m 2s
-
(Locked)
Scheduling processes with timers4m 35s
-
(Locked)
Analyzing systemd performance4m 25s
-
(Locked)
Advanced dependency handling5m 34s
-
(Locked)
Managing resource allocation, part 112m 16s
-
(Locked)
Managing resource allocation, part 26m 16s
-
(Locked)
Managing resource allocation, part 33m 20s
-
(Locked)
Creating custom units3m 50s
-
(Locked)
Creating custom targets5m 31s
-
(Locked)
Running user processes in systemd4m 52s
-
(Locked)
Real-world scenario: Booting without /etc/fstab9m 39s
-
(Locked)
-
-
-
-
-
-
-
-
-
-
-