Run crontab on a regular basis in Ubuntu.

Source: Internet
Author: User
Starting with the operation, I used the simplest process to solve the problem. Instead of taking the theoretical path, I wanted to back up the data regularly under Ubuntu! I want to restart regularly! I want to schedule... use crontab to handle it. Run the following command: crontab-e // edit the cron service editing format: ***** date Description: minute (0-59) hour (0-23) date (1-31) month (1-12) Week (0-6, 0 is Sunday) date is

Starting with the operation, solve the problem with the simplest process without going through the theoretical line

In Ubuntu, I want to back up regularly! I want to restart regularly! I want to schedule it... use crontab to handle it.

Instructions: crontab-e // edit the cron Service

Edit format: ***** date

Note: minute (0-59) hour (0-23) Date (1-31) month (1-12) Week (0-6, 0 is Sunday) date is the file you want to execute

For example, if you want to execute a shell script at every day, you can edit the script as follows: 01 00 ***/usr/local/runtime/backup. sh

If you have a lot of things that need to be done by the operating system for you at regular intervals, append one by one below.

Next command: crontab-l // list the cron you have added

After adding the record, the restart takes effect: service crond restart

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.