In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-19 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/01 Report--
This article is about how to solve the problem of non-execution of crontab scheduled tasks. The editor thinks it is very practical, so share it with you as a reference and follow the editor to have a look.
Preface
The scheduled tasks to implement Linux are: cron, anacron, at, etc. Cron is the service name, crond is the background process, and crontab is the customized schedule of scheduled tasks.
Today, however, it takes so long for crontab to realize that it also needs to be started.
Added scheduled tasks but didn't work well
[root@dev-gl-lh2 ApiAgent] # cat / etc/crontab SHELL=/bin/bashPATH=/sbin:/bin:/usr/sbin:/usr/binMAILTO=rootHOME=/# For details see man 4 crontabs# Example of job definition:#.-minute (0-59) # |.-hour (0-23) # | |.-day of month (1-31) # |.-month (1-12) OR jan Feb,mar,apr. # |.-day of week (0-6) (Sunday=0 or 7) OR sun,mon,tue,wed,thu,fri Sat# | # * user-name command to be executed# cache coin mapping data * / 5 * root / usr/bin/php / data/application/SwooleMoney/script/bin/cli.php CacheData cacheCoinMap# cache transaction pair information * / 1 * root / usr/bin/php / data/application/SwooleMoney/script/bin/cli.php CacheData cacheSymbol# delete depth data * / 1 * root / usr/bin/php / data/application/SwooleMoney/script/bin/cli.php CacheData clearExchangeDepths > / tmp/clearExchangeDepths.log~ ~
The script is executed every minute, but when the flowers are gone, they don't wait for the log.
# View crontab status [root@dev-gl-lh2 ApiAgent] # / etc/init.d/crond status crond dead but pid file exists# start crontab service [root@dev-gl-lh2 ApiAgent] # / etc/init.d/crond startStarting crond:
The log has output the successful execution of the script, increasing knowledge.
Thank you for reading! This is the end of this article on "how to solve the problem of non-execution of crontab scheduled tasks". I hope the above content can be of some help to you, so that you can learn more knowledge. if you think the article is good, you can share it out for more people to see!
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.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.