- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Schedule job every 20 seconds
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
03-06-2005 07:47 PM
03-06-2005 07:47 PM
How can i schedule jobs every 20 sec .I am able to do it by a script with sleep added , but by ( at / cron ) is there any possibility .
Thanks in advance ..
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-06-2005 07:49 PM
03-06-2005 07:49 PM
Re: Schedule job every 20 seconds
Your best bet is probably to do it just like you are with a sleep command. At least that way if 1 execution of the script hangs you will hopefully not have a bunch more trying to execute as well.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-06-2005 07:53 PM
03-06-2005 07:53 PM
SolutionYou should be able to do this with the at command...
For example, if you wanted the job to run every day of the week, every 20 seconds you should be able to use the -t switch, although you might have to setup three at jobs to run at 00 seconds, 20 seconds and 40 seconds...
at ... -t 2005-9901-1201-3100-2300-59.00
at ... -t 2005-9901-1201-3100-2300-59.20
at ... -t 2005-9901-1201-3100-2300-59.40
This would make the job run every 20 seconds, every single day from now until the year 2099.
HTH
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-06-2005 08:06 PM
03-06-2005 08:06 PM
Re: Schedule job every 20 seconds
However, I think you could achieve what it is you are after by combining the use of at and cron. You could put together a script which runs an at job every 20 seconds, and then use cron to schedule that job to run every minute.
Sorry, don't have time to post any examples or test this out, but as previously stated, you probably would be better off just putting sleep commands into your script.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-06-2005 08:14 PM
03-06-2005 08:14 PM
Re: Schedule job every 20 seconds
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-06-2005 08:18 PM
03-06-2005 08:18 PM
Re: Schedule job every 20 seconds
Thanks for your time and valuable comments .It seems that by at/cron it is not possible , so i will stick with sleep command only .I have assigned the points for your replies .
Bye...