LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 06-29-2010, 11:01 AM   #1
blainemiller
Member
 
Registered: Dec 2003
Posts: 78

Rep: Reputation: 1
cron not working under cygwin


Hello,

I'm running cygwin 1.7 on a vanilla win2k3 r2 server. I've put together a simple crontab that I'll paste in her in a sec. The crontab entries call several shell scripts that do either scp's or rsync's from linux servers to this win2k3 box under cygwin.

The problem is that the scripts work and run fine from the commandline. Just not when called from the crontab. I'm running from the root equivalent administrator UID. The crontab log files are empty of errors.

crontab is:

0 5 * * * ./home/administrator/scripts/xfer_vvm_ora.sh
0 5 * * * ./home/administrator/scripts/xfer_nab_vnnab.sh
0 10 * * * ./home/administrator/scripts/xfer_nab_csnab.sh
0 6 * * * ./home/administrator/scripts/xfer_dellsrv20.sh
0 6 * * * ./home/administrator/scripts/xfer_directory.sh
0 6 * * * ./home/administrator/scripts/xfer_perforce.sh
0 6 * * 2 ./home/administrator/scripts/xfer_fileserv.sh
0 5 * * * ./home/administrator/scripts/xfer_vvm_mysql.sh


Like I said, the scripts execute fine from the command line.

Any help would be appreciated. Thanks in advance.

Blaine
 
Old 06-29-2010, 12:40 PM   #2
TB0ne
LQ Guru
 
Registered: Jul 2003
Location: Birmingham, Alabama
Distribution: SuSE, RedHat, Slack,CentOS
Posts: 26,553

Rep: Reputation: 7946Reputation: 7946Reputation: 7946Reputation: 7946Reputation: 7946Reputation: 7946Reputation: 7946Reputation: 7946Reputation: 7946Reputation: 7946Reputation: 7946
Quote:
Originally Posted by blainemiller View Post
Hello,

I'm running cygwin 1.7 on a vanilla win2k3 r2 server. I've put together a simple crontab that I'll paste in her in a sec. The crontab entries call several shell scripts that do either scp's or rsync's from linux servers to this win2k3 box under cygwin.

The problem is that the scripts work and run fine from the commandline. Just not when called from the crontab. I'm running from the root equivalent administrator UID. The crontab log files are empty of errors.

crontab is:
Code:
0 5 * * * ./home/administrator/scripts/xfer_vvm_ora.sh
0 5 * * * ./home/administrator/scripts/xfer_nab_vnnab.sh
0 10 * * * ./home/administrator/scripts/xfer_nab_csnab.sh
0 6 * * * ./home/administrator/scripts/xfer_dellsrv20.sh
0 6 * * * ./home/administrator/scripts/xfer_directory.sh
0 6 * * * ./home/administrator/scripts/xfer_perforce.sh
0 6 * * 2 ./home/administrator/scripts/xfer_fileserv.sh
0 5 * * * ./home/administrator/scripts/xfer_vvm_mysql.sh
Like I said, the scripts execute fine from the command line.
Please put things in CODE tags..makes it much easier to read. And Cygwin on a W23K server isn't really Linux, is it?

Regardless, remove the period from the "./home" and try it. You may also want to put something like "> /logs/xfer_nab_vnnab.log" after the commands, so you get some output of what's going on.
 
Old 06-29-2010, 01:43 PM   #3
blainemiller
Member
 
Registered: Dec 2003
Posts: 78

Original Poster
Rep: Reputation: 1
Thanks!

I'll give it a try and let you know...

And I agree with you on the Cygwin on win2k3, but it's what I've been given to work with. Sorry if I've offended the folks here with the "semi"-linux question.

Thanks again for the pointer...

Blaine
 
Old 06-29-2010, 03:10 PM   #4
TB0ne
LQ Guru
 
Registered: Jul 2003
Location: Birmingham, Alabama
Distribution: SuSE, RedHat, Slack,CentOS
Posts: 26,553

Rep: Reputation: 7946Reputation: 7946Reputation: 7946Reputation: 7946Reputation: 7946Reputation: 7946Reputation: 7946Reputation: 7946Reputation: 7946Reputation: 7946Reputation: 7946
Quote:
Originally Posted by blainemiller View Post
Thanks!

I'll give it a try and let you know...

And I agree with you on the Cygwin on win2k3, but it's what I've been given to work with. Sorry if I've offended the folks here with the "semi"-linux question.

Thanks again for the pointer...
Blaine
No offense taken at all, and I hope it helps. The only reason I mention it, is because the advice you get may ONLY work on Linux...Cygwin is a different animal, and may behave differently.
 
  


Reply

Tags
cron, cygwin


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
some command in cygwin is not working ajatshatru General 10 04-16-2010 05:53 AM
cron.daily, cron.weekly not working mwhite74 Linux - Server 2 06-07-2007 09:51 AM
'Having whatever Linux' working like cygwin under MS-Windows ?? Xeratul Linux - Software 2 06-04-2007 01:24 PM
cron not working from crontab nor form /etc/cron/cron.d. What did SuSE change? JZL240I-U SUSE / openSUSE 11 01-04-2007 01:57 AM
Executing cron jobs on a w2k3 server using cygwin hq4ever General 4 06-01-2005 06:45 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 04:54 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration