[comp.unix.xenix] apparent cron lockup

richard@berner.UUCP (Richard Greenall) (01/25/89)

I have been having a problem with the cron utility under XENIX 368
version 2.3.1.  When cron is started , it will run for a while, and
then apparently lock up, not running any more jobs until it
is stopped, and then restarted again.

This occured this morning when I scheduled a backup job with "at" to
be run during the early morning.  When I arrived this morning, the
job had not run, and cron had not run any of its jobs since about
8 hours previous.  When I killed cron and restarted it, the job
was released.

Does anybody know what is happening, and whether it is something
I am doing or this is an actual bug in cron?


			thanks in advance.

			richard greenall

			watmath!dvlmarv!berner!richard
			uunet!mnetor!becker!berner!richard

morris@dms.UUCP (Jim Morris) (01/31/89)

From article <286@berner.UUCP>, by richard@berner.UUCP (Richard Greenall):
> 
> I have been having a problem with the cron utility under XENIX 368
> version 2.3.1.  When cron is started , it will run for a while, and
> then apparently lock up, not running any more jobs until it
> is stopped, and then restarted again.
> 
> Does anybody know what is happening, and whether it is something
> I am doing or this is an actual bug in cron?
> 

Yes, I have the same problem.
The cure appears to be to put a dummy entry that will make cron wake up
every hour. This was suggested to me by someone at SCO.

I did the following which "cured" the problem:
put the following line in /usr/spool/cron/crontabs/root

10 * * * * /bin/true


	thats it. I don't have a clue why it fixes the problem.

-- 
Jim Morris.         			 morris@dms.UUCP or weitek!dms!morris
           Atari Games Corporation, Sycamore Drive, Milpitas CA 95035.
       (Arcade Video Game Manufacturer, NOT Atari Corp. ST manufacturer).
 Any opinions expressed are probably my own, and not those of Atari Games Corp.

croot@lynpac.oz (Admin) (02/02/89)

In article <286@berner.UUCP> richard@berner.UUCP (Richard Greenall) writes:
>
>I have been having a problem with the cron utility under XENIX 368
>version 2.3.1.  When cron is started , it will run for a while, and
>then apparently lock up, not running any more jobs until it
>is stopped, and then restarted again.
>
> [ deleted ]
>
>			richard greenall

I have heard that XENIX/386 cron must run *something* at least once every
six (or so) hours. Our /usr/spool/cron/crontabs/root file contains:

0 0,6,12,18 * * * /bin/true >/dev/null 2>&1 

so force this to occur ... otherwise it dies as yours has. Matt.

-- 
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
"life? don't talk to me about life!"          Matt Atterbury. :-) :-( :-) :-(
"klaatu nikto barada"     Lynwood Pacific, Sydney, Australia. :-( :-) :-( :-)
matt@lynpac.oz.au (Europe/Internet) || uunet!munnari!lynpac.oz.au!matt (UUCP)

davidsen@steinmetz.ge.com (William E. Davidsen Jr) (02/03/89)

In article <611@dms.UUCP> morris@dms.UUCP (Jim Morris) writes:

| I did the following which "cured" the problem:
| put the following line in /usr/spool/cron/crontabs/root
| 
| 10 * * * * /bin/true

  Ah ha! No wonder I never saw the problem. My machines as heavy uucp
boxes and run uucico several time an hour to check for queued outgoing
mail. No wonder I haven't seen this.

  Thanks for the info!
-- 
	bill davidsen		(wedu@ge-crd.arpa)
  {uunet | philabs}!steinmetz!crdos1!davidsen
"Stupidity, like virtue, is its own reward" -me

richard@berner.UUCP (Richard Greenall) (02/03/89)

In article <13073@steinmetz.ge.com> davidsen@crdos1.UUCP (bill davidsen) writes:
>In article <611@dms.UUCP> morris@dms.UUCP (Jim Morris) writes:
>
>| I did the following which "cured" the problem:
>| put the following line in /usr/spool/cron/crontabs/root
>| 
>| 10 * * * * /bin/true
>
>  Ah ha! No wonder I never saw the problem. My machines as heavy uucp
>boxes and run uucico several time an hour to check for queued outgoing
>mail. No wonder I haven't seen this.
>

I don't think that that was the entire problem with cron.  I also
run uucp a couple times an hour and still get the cron lockup
quite regularly with 2.3.1 I even added the /bin/true to run about
every half hour with little success.  I even went back to the
cron in version 2.2.1 and installed that, and STILL got the
same symptoms.

			richard greenall
			berner!richard

aryeh@eddie.MIT.EDU (Aryeh M. Weiss) (02/03/89)

The problem appears to be the fact that the cron distributed with SCO 386
is actually the old 8086 executable where int's are 16-bits..ts.
Therefore since days are 86400 seconds long, cron will fail if you
only try to run one thing once a day.  Putting in a dummy program to
run every hour cures the problem.  The.is never seems to come up since
people generally do run something via cron on an hourly basis.

This is clearly another inanity on the part of SCO for not having 
recompiled their utility.ies under the 386 compiler.

Of course without bugs in the system, what would we have to talk about?

-- 
aryeh@eddie.mit.edu
mit-eddie!lees-rif!aryeh

debra@alice.UUCP (Paul De Bra) (02/05/89)

In article <455@berner.UUCP> richard@berner.UUCP (Richard Greenall) writes:
>In article <13073@steinmetz.ge.com> davidsen@crdos1.UUCP (bill davidsen) writes:
>> [ doubtful explanation of cron problem deleted ]
>
>I don't think that that was the entire problem with cron.  I also
>run uucp a couple times an hour and still get the cron lockup
>quite regularly with 2.3.1 I even added the /bin/true to run about
>every half hour with little success.  I even went back to the
>cron in version 2.2.1 and installed that, and STILL got the
>same symptoms.

The cron problem exists in other versions of Unix as well. The time between
events is irrelevant since cron is supposed to wake up every minute to check
whether the crontab (or crontabs in newer releases) has changed.

The only instances of cron falling asleep that I have seen occured in a
system where cron had been swapped out. Apparently there is a bug in some
Unix systems (not just Xenix and not only on intel processors!) that causes
processes that are swapped out while sleeping to remain asleep for ever. 
(I mean waiting for the end of sleep(), not waiting for some other event
like I/O).

I never noticed the problem in my Xenix box because it has enough memory
to avoid all swapping.

Paul.
-- 
------------------------------------------------------
|debra@research.att.com   | uunet!research!debra     |
------------------------------------------------------

tif@cpe.UUCP (02/08/89)

Written  6:47 pm  Feb  4, 1989 by alice.UUCP!debra in cpe:comp.unix.xenix
>The cron problem exists in other versions of Unix as well. The time between
>events is irrelevant since cron is supposed to wake up every minute to check
>whether the crontab (or crontabs in newer releases) has changed.

I thought this was pre-System V behavior.

			Paul Chamberlain
			Computer Product Engineering, Tandy Corp.
			{killer | texbell}!cpe!tif