This is the mail archive of the cygwin@cygwin.com 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: scheduling jobs


You're going to have to work through this in stages:

   1. You need to get the bash shell working (yes, things can be done
without it, but something basic is not set up properly at this point).

   2. Yes, cron can be made to work just as you have been using it in
the unix environment.  You'll want to get basic cron functionality (ugh,
i used that word) in place before you attempt to get it to run scripts,
otherwise you end up trying to debug two problems at the same time.

You should be able to find the 'Cygwin Bash Shell' (that is, bash)
program in the 'Start' | 'Programs' | 'Cygwin' menu.  (Normally, setup
will also put an icon on your desktop also.  Why it has not makes me
wonder about what happened when setup.exe was run.)  Once you have that
running, you'll want to sanity check on some basics, such as:

   $ echo $HOME
   $ uname -r
   $ id
   $ echo $CYGWIN

> -----Original Message-----
> From: Karen McLaughlin [mailto:k.mclaughlin@umassp.edu]
> Sent: Wednesday, October 23, 2002 4:20 PM
> To: cygwin@cygwin.com
> Subject: scheduling jobs
> 
> 
> I briefly went through the archives and apologize if this is an
> extremely elementary question but i seem to have a brain 
> cramp here ....
> 
> My boss installed cygwin on a win 2000 machine
> 
> I am having trouble finding the window that cygwin and nt talk to each
> other through ...
> 
> what i basically have done is written a simple bash script 
> --- i am now
> trying to schedule it
> 
> from the setup log it appears boss has not installed cron ...
> he thinks i should be able to schedule a batch job as follows 
> that calls
> the bash shell script --- it doesnt seem to work (I am fairly 
> unix savvy
> i am not terribly nt savvy but i have been in the IT field a number of
> year) -- i had also had that thought last night because i thought of
> COURSE the boss knows what he is talking about and if he says 
> i can use
> windows at command to schedule something in cygwin it must be the way
> ....
> 
> so my question(s) are:
> 
> 1) can i use windows nt to access the bash job and how ...
> I tried the following and got the following errors
> 
> C:\jobs>e:\cygwin\bin\bash -c e:/cygwin/jobs/umassonline_log_rotate.sh
> date: not found
> date: not found
> date: not found
> cp: not found
> date: not found
> cp: not found
> C:\jobs>date
> 
> added #!/bin/bash to top of shell script
> C:\jobs>e:\cygwin\bin\bash -c e:/cygwin/jobs/umassonline_log_rotate.sh
> e:/cygwin/jobs/umassonline_log_rotate.sh: date: command not found
> e:/cygwin/jobs/umassonline_log_rotate.sh: date: command not found
> e:/cygwin/jobs/umassonline_log_rotate.sh: date: command not found
> e:/cygwin/jobs/umassonline_log_rotate.sh: cp: command not found
> e:/cygwin/jobs/umassonline_log_rotate.sh: date: command not found
> e:/cygwin/jobs/umassonline_log_rotate.sh: cp: command not found
> C:\jobs>umassonline_rotate_logs.bat
> 
> 
> 
> 2) if not --- i probably need cron?
> to add this to the current setup without messing up anything the boss
> installed -- do i run setup again? or something else ..
> 
> 3) how do i keep cron up in the windows environment? ie --- 
> do i need to
> run inetd as a service or cron as a service??? can you point me toward
> how to do this?
> 
> I have perused various parts of the documentations and mailing list
> archives.
> I can't seem to find an answer and since i wasted a lot of time trying
> to get cronolog (log rotation program) to work i am way behind on
> getting this shell script running (it is a log rotation script) ...
> Thanks in advance for any help on this ...
> 
> Karen
> 

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/


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