This is the mail archive of the cygwin mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: cron fails to run as a service


At 02:13 AM 3/2/2010, Paul McFerrin wrote:
I've been using "cron" for more that a few weeks without any problems, until my needs changed. I installed cron as a service using "cygrunsrv". I keep getting errors about creating lockfile. I removed the lockfile but it got created again. At first, I got the Win32 error and ran the cron_diagnose.sh script and got it further along but still nogo. Attached is a copy of "cronbug.txt" as instructed. It is trying to start cron, but cron fails to start as a service. It run perfectly when not a service/

One difference: the service control manager added a "-n" option to my cron command that I did not specify. How can I turn off this feature??

Paul,


The -n switch keeps cron in the foreground. This is advisable when cron runs under cygrunsrv.

Some of your problems are due to launching a new cron daemon while an old one is still running.
If you experiment with cron, you can view the cron log by using "cronevents"


2010/03/01 01:38:45 [Paul] /usr/sbin/cron: PID 368: (CRON) STARTUP (V5.0)
2010/03/01 01:47:26 [Paul] /usr/sbin/cron: PID 2508: (CRON) DEATH (can't lock /var/run/cron.pid, otherpid may be 368: Resource temporarily unavailable)


I will think about your SIGHUP request when I have more time.
How do other Cygwin services handle this?

Pierre


-- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]