Обсуждение: Re: Cygwin cron
OK, I am running cron as a service now but I'm still not getting the results I want. I looked in my /etc/group file and have this: Everyone:S-1-1-0:0: SYSTEM:S-1-5-18:18: etc. So my SYSTEM group is there. In my crontab file I have this right now: 0,5,10,15,20,25,30,35,40,45,50,55 * * * * /usr/bin/date >> /home/mydir/blah.txt 0 1 * * * /usr/bin/vacuumdb -h localhost -U postgres -d mydb -v -q >> /home/ mydir/vacuumlog.txt But the first one isn't running, or is it a permission issue with files/directories? If it is a permission thing where isthe most appropriate place to write output/log files in the world of Unix for cron? Thanx again. I hope I'm not getting annoying, I have been doing searches on the archives but I can't seem to find anything. Roy. > Did you forget to read the README again? > > $ fgrep cygrunsrv /usr/doc/cygwin/cron.README > cygrunsrv. Install as service like that: > cygrunsrv -I cron -p /usr/sbin/cron -a -D > > Or, did you just forgot to start the service? > > $ net start cron
Roy, On Fri, Sep 21, 2001 at 02:21:12PM -0400, roypgsqlcygwin@xemaps.com wrote: > OK, I am running cron as a service now but I'm still not getting the > results I want. > > I looked in my /etc/group file and have this: > Everyone:S-1-1-0:0: > SYSTEM:S-1-5-18:18: > etc. Is your passwd file up to date? > So my SYSTEM group is there. In my crontab file I have this right now: > 0,5,10,15,20,25,30,35,40,45,50,55 * * * * /usr/bin/date >> /home/mydir/blah.txt > 0 1 * * * /usr/bin/vacuumdb -h localhost -U postgres -d mydb -v -q >> /home/ > mydir/vacuumlog.txt The above looks fine. What version of Cygwin and cron are you using. I hope that it is the latest -- 1.3.3 and 3.0.1-5, respectively. BTW, these types of problems are more appropriate for the cygwin@cygwin.com mailing list. Jason
You might try looking at the application event log for cron errors. I just got cron going this week. I read somewhere that you should have ntsec in the CYGWIN environment variable. This worked for me. See http://sources.redhat.com/ml/cygwin/2001-07/msg01069.html ----- Original Message ----- From: <roypgsqlcygwin@xemaps.com> To: <pgsql-cygwin@postgresql.org> Sent: Friday, September 21, 2001 12:21 PM Subject: Re: [CYGWIN] Cygwin cron > OK, I am running cron as a service now but I'm still not getting the results I want. > > I looked in my /etc/group file and have this: > Everyone:S-1-1-0:0: > SYSTEM:S-1-5-18:18: > etc. > > So my SYSTEM group is there. In my crontab file I have this right now: > 0,5,10,15,20,25,30,35,40,45,50,55 * * * * /usr/bin/date >> /home/mydir/blah.txt > 0 1 * * * /usr/bin/vacuumdb -h localhost -U postgres -d mydb -v -q >> /home/ > mydir/vacuumlog.txt > > But the first one isn't running, or is it a permission issue with files/directories? If it is a permission thing where is the most appropriate place to write output/log files in the world of Unix for cron? > > Thanx again. I hope I'm not getting annoying, I have been doing searches on the archives but I can't seem to find anything. > > Roy. > > > Did you forget to read the README again? > > > > $ fgrep cygrunsrv /usr/doc/cygwin/cron.README > > cygrunsrv. Install as service like that: > > cygrunsrv -I cron -p /usr/sbin/cron -a -D > > > > Or, did you just forgot to start the service? > > > > $ net start cron > > > > > ---------------------------(end of broadcast)--------------------------- > TIP 6: Have you searched our list archives? > > http://archives.postgresql.org