X-Recipient: archive-cygwin@delorie.com
X-SWARE-Spam-Status: No, hits=4.7 required=5.0	tests=AWL,BAYES_50,BOTNET,RCVD_IN_DNSWL_NONE
X-Spam-Check-By: sourceware.org
Message-id: <4E552D8A.5060002@cygwin.com>
Date: Wed, 24 Aug 2011 12:57:46 -0400
From: "Larry Hall (Cygwin)" <reply-to-list-only-lh@cygwin.com>
Reply-to: cygwin@cygwin.com
User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:5.0) Gecko/20110624 Thunderbird/5.0
MIME-version: 1.0
To: cygwin@cygwin.com
Subject: Re: cron
References: <CAFGmhWjcQ4sknOgpy7GZ=KqOb+eLFTzTZ6AWvtp95zrkPm+N3g@mail.gmail.com>
In-reply-to: <CAFGmhWjcQ4sknOgpy7GZ=KqOb+eLFTzTZ6AWvtp95zrkPm+N3g@mail.gmail.com>
Content-type: text/plain; charset=ISO-8859-1; format=flowed
Content-transfer-encoding: 7bit
Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe@cygwin.com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin@cygwin.com>
List-Help: <mailto:cygwin-help@cygwin.com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner@cygwin.com
Mail-Followup-To: cygwin@cygwin.com
Delivered-To: mailing list cygwin@cygwin.com

On 8/24/2011 12:08 PM, mramakishore@gmail.com wrote:
> HI,
> I am sucessed to run the Perl script which uses Net::SSH::Expect
> package from the cygwin command prompt. but i am scheduled the same
> script through crontab but script is breaking in middle.

<snip>

> can you help me as early as possible..

First, have you ensured that you set up the same environment for your
script when run by 'crond' as you have with the interactive shell?
This is a common problem for users of Cron and is not Cygwin-specific.
I would suggest pursuing this first if you have not already verified
that this is not the problem.

Second, if you're accessing any network shares, this won't work by
default.  See <http://cygwin.com/faq-nochunks.html#faq.using.shares>

Third, you have both MSYS and Cygwin in your path.  You should make sure
that only Cygwin is in the path that 'crond' sees and uses.  I'd say the
same about Perl.

-- 
Larry

_____________________________________________________________________

A: Yes.
 > Q: Are you sure?
 >> A: Because it reverses the logical flow of conversation.
 >>> Q: Why is top posting annoying in email?

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

