crontab: every odd minute

Posted on 2011-04-21
Medium Priority
Last Modified: 2012-05-11
I use the crontab code below to do something every even minute.  How can I do something every odd minute?  

I want to do something every two minutes, starting with one minute after the hour.
*/2 * * * * do_something

Open in new window

Question by:hankknight
1 Comment

Accepted Solution

dmarinenko earned 2000 total points
ID: 35444086
if you need one script to go off every even minute and then anthor ever odd set your cron jobs to go off as below, good for testing tcp / udp listeners
every even minute 0-59/2 * * * *
every odd minute 1-59/2 * * * *
Taken from http://answers.ironlasso.com/?p=29

Featured Post

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

How many times have you wanted to quickly do the same thing to a list but found yourself typing it again and again? I first figured out a small time saver with the up arrow to recall the last command but that can only get you so far if you have a bi…
SSH (Secure Shell) - Tips and Tricks As you all know SSH(Secure Shell) is a network protocol, which we use to access/transfer files securely between two networked devices. SSH was actually designed as a replacement for insecure protocols that sen…
Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:
How to Install VMware Tools in Red Hat Enterprise Linux 6.4 (RHEL 6.4) Step-by-Step Tutorial
Suggested Courses
Course of the Month14 days, 3 hours left to enroll

807 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question