X
X
Xandiem2021-10-14 21:07:04
linux
Xandiem, 2021-10-14 21:07:04

How to create a self-restarting systemd service?

Hi all! In general, the problem is that I need to create a service that restarts itself every 3 minutes, because my mobile Internet works only through a script that turns itself off after 3 minutes ... Therefore, I need to make a service that could itself take and restart the script in the background and at the same time he could execute a script from sudo ... I did not find anything related to this on the Internet, so I decided to ask here ...

Answer the question

In order to leave comments, you need to log in

2 answer(s)
K
ky0, 2021-10-14
@Xandiem

In systemd, there are timers for this . They do exactly what you need.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question