Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com Date: Mon, 10 Oct 2005 10:44:38 -0400 (EDT) From: Igor Pechtchanski Reply-To: cygwin AT cygwin DOT com To: Orfeo Da Via cc: cygwin AT cygwin DOT com Subject: Re: Cron problem In-Reply-To: Message-ID: References: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Please make sure your mailer respects the Reply-To: header -- I set it for a reason. There's no need to send the message to my mailbox -- I read the list. On Mon, 10 Oct 2005, Orfeo Da Via wrote: > On Mon, 10 Oct 2005, Igor Pechtchanski wrote: > > > > $ uname > > > Linux > > > > > > $ export VISUAL=zile > > > > > > $ crontab -e > > > > > > ...edit the file.. > > > > Hmm, one detail that's missing: when was the above done? Before 8:00, or > > after? > > About at 8.45, all the commands in the example are sequentially. Interesting... I thought the semantics were such that if the start time is missed, the next day is used. I'll have to re-read the cron documentation. > > Since you're testing cron, I would suggest starting with > > > > */5 * * * * /bin/date >> /home/calox/tmp/date.out 2>&1 > > > > and waiting 5 minutes. If /home/calox/tmp is still empty, then we'll > > debug further. > > In my linux box the my home is /home/calox, in Cygwin my home is > /home/micekiller, then the crontab is > > $ crontab -l > # DO NOT EDIT THIS FILE - edit the master and reinstall. > # (/tmp/crontab.592 installed on Mon Oct 10 14:51:37 2005) > # (Cron version -- $Id: crontab.c,v 1.8 2004/12/21 16:14:41 corinna Exp $) > */5 * * * * /bin/date >> /home/micekiller/tmp/date.out 2>&1 > > so, I waited for 10 min but ~/tmp (/home/micekiller/tmp) is empty. Is your user an administrative user? Is your home on a network share? Try changing the above to */5 * * * * /bin/date >> /tmp/date.out 2>&1 Does /tmp/date.out get created? > > A few obvious questions: does /home/calox/tmp exist in Cygwin? What are > > its permissions (do an "ls -ld")? > > $ ls -ld ~/tmp/ > drwxrwxrwx+ 2 micekiller None 0 Oct 8 11:03 /home/micekiller/tmp/ > > Here the group in None, it's OK? (in Linux is the usergroup)...maybe in > Cygwin isn't possible set the group? It is possible, but the group shouldn't matter. Note that '+' at the end of the permission string means that there are extra ACLs set for that directory -- some of these may deny the necessary access. > > Are you checking /home/calox/tmp or > > ~/tmp (IOW, is your $HOME set to /home/calox)? > > my $HOME is > > $ echo $HOME > /home/micekiller > > and I check /home/micekiller/tmp Ok, just a sanity check. > > And, finally, do you have SHELL set in the Windows environment, and if > > so, to what value? > > Mmmm, in 'Control Panel-> System -> Advanced -> Environment variable' the > SHELL variable *not* exists, but in Cygwin > > $ echo $SHELL > /bin/bash That's ok -- bash sets SHELL if it's not set in the parent environment. > If usefull, my environment var is (in win2000 cmd.exe) > > C:\>set > [snip] > PATH='/usr/local/bin:/usr/bin:/bin:/usr/X11R6/bin:/mnt/c/imagemagick:/usr/bin:/mnt/c/texmf/miktex/bin:/mnt/c/WINNT/system32:/mnt/c/WINNT:/mnt/c/shared:/mnt/c/WINNT/Microsoft.NET/Framework/v1.1.4322/:/mnt/c/gs/gs8.11/bin:/mnt/c/GnuWin32/bin:/mnt/c/Pico:/mnt/c/Program Files/Support Tools/:.:/cygdriver/c/texUtils/latex2html/bin:/cygdriver/c/Mono/bin:/opt/dar' Aside from the fact that you seem to have run "set" from a bash shell, whereas your prompt above is from a "cmd" shell, and that you use "/cygdriver" instead of the standard "/cygdrive", the output looks fine. FWIW, I just installed "cron" from scratch using /usr/bin/cron-config, put */5 * * * * /bin/date >> /tmp/date.out 2>&1 in my crontab, and sure enough, /tmp/date.out got created. Try that one first, and if it works, you'll know that there is some issue with your home directory that prevents cron from writing there. BTW, what are the permissions on /home and /home/micekiller? They have to have at least the execute bits set for /home/micekiller/tmp to be accessible. HTH, Igor -- http://cs.nyu.edu/~pechtcha/ |\ _,,,---,,_ pechtcha AT cs DOT nyu DOT edu ZZZzz /,`.-'`' -. ;-;;,_ igor AT watson DOT ibm DOT com |,4- ) )-,_. ,\ ( `'-' Igor Pechtchanski, Ph.D. '---''(_/--' `-'\_) fL a.k.a JaguaR-R-R-r-r-r-.-.-. Meow! If there's any real truth it's that the entire multidimensional infinity of the Universe is almost certainly being run by a bunch of maniacs. /DA -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/