[Cialug] Cron
David Champion
dchamp1337 at gmail.com
Wed Mar 23 17:09:44 CDT 2016
Also illustrates that you can't count on the order things will execute in
this manner, since second.txt and third.txt are out of order. But, close
enough.
-dc
On Wed, Mar 23, 2016 at 4:46 PM, kristau <kristau at gmail.com> wrote:
> Interesting results:
>
> 40 16 * * * echo "FIRST" > /tmp/first.txt
> 40 16 * * * echo "SECOND" > /tmp/second.txt
> 40 16 * * * echo "THIRD" > /tmp/third.txt
> 40 16 * * * echo "FOURTH" > /tmp/fourth.txt
> 40 16 * * * echo "FIFTH" > /tmp/fifth.txt
>
> ls -lt --full-time /tmp/*.txt
> -rw-r--r--. 1 kristau kristau 6 2016-03-23 16:40:06.350406655 -0500
> /tmp/first.txt
> -rw-r--r--. 1 kristau kristau 6 2016-03-23 16:40:06.340406654 -0500
> /tmp/third.txt
> -rw-r--r--. 1 kristau kristau 7 2016-03-23 16:40:06.335406654 -0500
> /tmp/second.txt
> -rw-r--r--. 1 kristau kristau 7 2016-03-23 16:40:06.327406653 -0500
> /tmp/fourth.txt
> -rw-r--r--. 1 kristau kristau 6 2016-03-23 16:40:06.304406652 -0500
> /tmp/fifth.txt
>
>
> I'd say, "Simultaneous enough?"
>
> On Tue, Mar 22, 2016 at 7:53 PM, Josh More <jmore at starmind.org> wrote:
> > They're basically simultaneous:
> >
> > 50 19 * * * sleep 120; echo "Test" > /tmp/1
> > 50 19 * * * echo "Test" > /tmp/2
> >
> >
> > $ ls -alrt /tmp/?
> > -rw-r--r-- 1 root root 5 Mar 22 19:50 /tmp/2
> > -rw-r--r-- 1 root root 5 Mar 22 19:52 /tmp/1
> >
> >
> > -Josh
> >
> >
> > On Tue, Mar 22, 2016 at 7:38 PM, kristau <kristau at gmail.com> wrote:
> >
> >> I've always assumed they launched practically simultaneously. Your
> >> question, however, challenges that assumption.
> >>
> >> On Tue, Mar 22, 2016 at 7:30 PM, Patrick Mcgillan
> >> <patrick.mcgillan at gmail.com> wrote:
> >> > I have 2 entries in my crontab file like this;
> >> >
> >> > * * * * * do something every minute
> >> > 59 23 * * * do something at 1159PM
> >> >
> >> > Qustion is, does cron run both at same time or does it do one and then
> >> the
> >> > next one.
> >> >
> >> > --
> >> > Patrick
> >> > _______________________________________________
> >> > Cialug mailing list
> >> > Cialug at cialug.org
> >> > http://cialug.org/mailman/listinfo/cialug
> >>
> >>
> >>
> >> --
> >> Tired programmer
> >> Coding late into the night
> >> The core dump follows
> >> _______________________________________________
> >> Cialug mailing list
> >> Cialug at cialug.org
> >> http://cialug.org/mailman/listinfo/cialug
> >>
> > _______________________________________________
> > Cialug mailing list
> > Cialug at cialug.org
> > http://cialug.org/mailman/listinfo/cialug
>
>
>
> --
> Tired programmer
> Coding late into the night
> The core dump follows
> _______________________________________________
> Cialug mailing list
> Cialug at cialug.org
> http://cialug.org/mailman/listinfo/cialug
>
More information about the Cialug
mailing list