Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to use crontab to execute scripts regularly in Linux system

2025-04-06 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)06/01 Report--

This article introduces the knowledge of "how to use crontab to execute scripts regularly in the Linux system". In the operation of actual cases, many people will encounter such a dilemma, so let the editor lead you to learn how to deal with these situations. I hope you can read it carefully and be able to achieve something!

Netizens suddenly asked, thought for a long time, found that it really can not be solved with one command, so only two crontab commands can be used to achieve the goal of crontab setting to execute commands / scripts every 90 minutes (one and a half hours). Here's how to set crontab settings to execute commands / scripts every 90 minutes (one and a half hours):

The code is as follows:

0 command 3, 6, 9, 12, 15, 18, 21, and

30 1 command 4 7 10 10 13 16 19 22 * command / / Note that two command are the same command

I saw someone say I haven't tried to use fcron.

By the way, post the explanation of the crontab settings:

The code is as follows:

* command to be executed

--

| | |

| | +-day of week (0-6) (Sunday=0) |

| | +-month (1-12) |

| | +-day of month (1-31) |

| | +-hour (0-23) |

+-min (0-59)

Crontab sets commands / scripts to be executed every 90 minutes (one and a half hours)

End!

This is the end of the content of "how to use crontab to execute scripts regularly in the Linux system". Thank you for reading. If you want to know more about the industry, you can follow the website, the editor will output more high-quality practical articles for you!

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report