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

Linux scheduling tasks

2025-01-16 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

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

Set up one-time scheduled tasks: at time

Check that the task is not currently executed: at-l

Delete one-time scheduled task: atrm task serial number

[root@linuxprobe ~] # at 23:30

At > systemctl restart httpd

At > Please press Ctrl+d at the same time here to finish writing the planning task

Job 3 at Mon Apr 27 23:30:00 2015

[root@linuxprobe ~] # at-l

3 Mon Apr 27 23:30:00 2016 a root

[root@linuxprobe ~] # echo "systemctl restart httpd" | at 23:30

Create repetitive scheduled tasks

Edit crontab-e

View crontab-l

Delete crontab-r

Set the parameter format of the crond service, "minute, hour, day, month, week command"

[root@master1-192,168117-18] # crontab-e

25, 3, 1, 3, usr/bin/tar, 5 / usr/bin/tar-czvf backup.tar.gz / home/wwwroot

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