Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-20-2006 08:37 AM
02-20-2006 08:37 AM
vi /tmp/test2
1). find / -name core -print > /tmp/test1
2). chmod +x /tmp/test2
3). crontab -e
4). 30 10 * * * /tmp/test2.sh // i wanted it to run one time at 10:30.
What i was expecting was a file being created /tmp/test1 with the core files in it at 10:30. Can anyone tell me what went wrong???
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-20-2006 08:44 AM
02-20-2006 08:44 AM
Re: cron
Jeff Traigle
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-20-2006 08:45 AM
02-20-2006 08:45 AM
Re: cron
Second, maybe there weren't any core files on your system? What happens if you run that command from the command line? Do you get any results in the /tmp/test1 file?
Third, are you sure the statement ran? Check /var/adm/cron/log and see what the return code was for that script.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-20-2006 08:58 AM
02-20-2006 08:58 AM
Re: cron
/tmp/test1 is the file i want to send the output to, i ran the find / -name core -print command it worked on the shell. and now it 4:57 i wanted it to run at 5pm today only so below is the entry in the crontab
* 17 * * * /tmp/test2.sh
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-20-2006 09:15 AM
02-20-2006 09:15 AM
Re: cron
Either:
mv /tmp/test2 /tmp/test2.sh
or:
crontab -e
30 10 * * * /tmp/test2
Jeff Traigle
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-20-2006 09:26 AM
02-20-2006 09:26 AM
Solution1) The name of the file MUST be the same in BOTH places. It must be either /tmp/test2.sh or /tmp/test2. You must be consistent. Either rename the file or edit your crontab entry as suggested above.
2) If you do '* 17 * * *' then your script will run EVERY MINUTE during the the 5PM hour (17:01, 17:02, etc.) If you just want at 17:00, then '0 17 * * *' is what you want.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-20-2006 02:42 PM
02-20-2006 02:42 PM
Re: cron
#crontab -e
30 10 * * * /usr/bin/find / -name "core" -print > /tmp/test.out 2>/tmp/test.err
save it.
--
Muthu
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-20-2006 03:11 PM
02-20-2006 03:11 PM
Re: cron
you should add this "template" to your crontabs:
#*******************************************************************************
# min|hour |day |month|day |script
# | |of mo| |of wk|
#----|-----|-----|-----|-----|--------------------------------------------------
#*******************************************************************************
#*******************************************************************************
# END OF TABLE day0->Sunday day6->Saturday
#*******************************************************************************
this will help you when setting the times of execution of your scripts!
above all, please check you scripts in isolation before putting it in your crontable!
hope this helps too!
kind regards
yogeeraj