Cygwin

From dbawiki
Revision as of 15:53, 27 November 2014 by Stuart (talk | contribs) (Created page with "===How to run a crontab in Cygwin on Windows=== * Install cygrunsrv and cron packages from the admin bundle (with 'Install from internet" option) * From a Cygwin prompt, type:...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

How to run a crontab in Cygwin on Windows

  • Install cygrunsrv and cron packages from the admin bundle (with 'Install from internet" option)
  • From a Cygwin prompt, type:
cygrunsrv --install cron --path /usr/sbin/cron --args -n
  • Start the cron daemon from a Windows prompt with:
net start cron

or from a Cygwin prompt with:

cygrunsrv --start cron

or don't use cron at all!
Create a scheduled task with the windows scheduler by calling the shell program

C:\cygwin\bin\bash.exe -l -c /cygwin/path/to/shell

Configure cron

Run

cron-config

from a Cygwin terminal

Diagnose problems

Check installed modules

cygcheck.exe -c

Check current status

cygrunsrv -Q cron

Show system log of possible problems from the cron daemon (service)

/usr/bin/cronevents