This is the mail archive of the cygwin 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: help cron cygwin


"Christian Lanconelli (servizio)" wrote:

> c:\cvi\ICARO\dati>xcopy c:\cvi\ICARO\dati\??060106.*  \\pc27\CO2_O3\ /D /F
> /Z
> C:\cvi\ICARO\dati\DD060106.GAS -> \\pc27\CO2_O3\DD060106.GAS
> C:\cvi\ICARO\dati\DD060106.MET -> \\pc27\CO2_O3\DD060106.MET
> C:\cvi\ICARO\dati\DD060106.RAD -> \\pc27\CO2_O3\DD060106.RAD
> C:\cvi\ICARO\dati\MN060106.DEU -> \\pc27\CO2_O3\MN060106.DEU
> C:\cvi\ICARO\dati\MN060106.GAS -> \\pc27\CO2_O3\MN060106.GAS
> C:\cvi\ICARO\dati\MN060106.MET -> \\pc27\CO2_O3\MN060106.MET
> C:\cvi\ICARO\dati\MN060106.RAD -> \\pc27\CO2_O3\MN060106.RAD

In addition to what others have said about the PATH setting, if you're
trying to access a non-public network drive in a cronjob you are
probably going to fail.  There is a FAQ entry about this I think. 
Without the user's password, cron can only partially impersonate the
crontab's owner.  This means that network shares that are not public are
not accessible.

The workaround is to explicitly mount the network share (providing the
username and password) with NET USE in the cron job, or run the cron as
the desired user account.  The latter has the drawback of only being
able to run crontabs of that one user since regular user accounts lack
the privileges to switch user context.  Though you might be able to
change this using 'editrights', but the restriction of not being able to
access network shares while impersonating will still exist.

> Bye Bye
> Christian
> BTN Antarctica 74°S - 165°E
> Programma Nazionale di Ricerche in Antartide

Brrrrr... hope you have ample stocks of heavy jackets!

Brian


--
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/


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