In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-02-23 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/03 Report--
This article will explain in detail how to detect the response of crontab timing tasks, the content of the article is of high quality, so share it for your reference. I hope you can get something after reading this article.
1. Set rules
To prevent some path errors, use absolute paths
* / 1 * / home/anaconda3/bin/python3 home/mysticbiant/code/test.py > > / home/mysticbiant/test.py.log 2 > & 1 &
2. Check whether crontab is started.
Systemctl status crond
If it doesn't start, search for how to start crontab.
3. Check the crontab log
# you need to switch root to see the log tail-f / var/log/cron
If the log is not started at the corresponding time, there is a problem.
4. Check account permissions and paths
This is the key point. Many beginners will make mistakes on this issue. Please read it carefully.
The regular task planning rule of crontab is that one account is independent and each does not affect each other. For example, root has its own scheduled task plan, and the MyTicBary sub-account you created also has its own scheduled task plan, so the redirection rules you write > > out.log will be generated under your corresponding account path. For example, if you use root to create crontab scheduled tasks, then you have to switch to / root/ to view the out.log file.
The above is the method to detect the response of crontab scheduled tasks, and do you get anything after reading it? If you want to know more about it, you are welcome to follow the industry information. Thank you for reading.
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.