Linux Plan crontab
Start the crontab service
General start service with/sbin/service Crond start
If the root user's cron service can be crond start with sudo services
See if the service is already running with Ps-ax | grep cron
See if the Crontab service under this user was created successfully with Crontab-l
Lists a user's cron service crontab-l//-l lists a user's scheduled tasks
Delete a user's cron service crontab-r//-r Delete a user's task
Edit a user's cron service crontab-e//-e Edit a user's tasks
Specify a user's cron service crontab-u//-u Specify a user
Where to store the crontab files
/etc/crontab
Cron files for users under/var/spool/cron/
Cron file Syntax:
"*" represents a number in the range of values, "/" stands for "each", "-" represents a number from one digit to a number, "," separates several discrete numbers,
For fields that are not specified, use "*" to fill their position
Hour of the week order
0-59 0-23 1-31 1-12 0-6 Command (value range, 0 for Sunday One a row corresponds to a task)
3 3 3 3 * ls (execute ls command every March 3 3:03)
3 3 3,13 3-8 * ls (the LS command is executed every March-August 3rd and 13th 3:03)
*/3 3 3,13 3-8 * ls (the LS command is executed every 3 minutes on 3rd and 13th of March-August of each year 3 o'clock)
- This article is from: Linux Learning Network
Linux Plan crontab