You didn't indicate where exactly the script failed.   My guess is that
it has to do with the script running in local system context which
prevents it from accessing any network resource.   A simple way to
troubleshoot this is to run the scheduler interactively with a command
prompt.   To do so, schedule a a job with the following command 'at
<time> /interactive "cmd /k"'.  A command prompt should pop up at the
specified time.  Run your script and see what fails and troublshoots
accordingly.

-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Dave
Budd
Sent: Tuesday, October 19, 2004 3:16 AM
To: [EMAIL PROTECTED]
Subject: Windows mapped drives


I'm new here, and I see from the archive that this is a perennial
subject, but I haven't trawled enough yet to know if the answer to my
particular problem is in there somewhere. I have this .bat (names
changed to protect the innocent):

if exist q:\grep.exe goto qok
net use q: /delete
net use q: \\IPADDRESS\SHARE /user:USERNAME PASSWORD
:qok
c:\perl\bin\perl c:\pins\econ.pl

This is all fine on my workstation, either kicked off manually or from
the Windows Scheduler, and also fine if run manually on the server that
is the intended host. But it doesn't work on the server from the
scheduler. I've verified that the net use is working and that the Perl
script does actually get started. I can't work out if it's having
trouble with the fact the drive is mapped, or if it's because the
mapping is set up with a different username/pw to the one the .bat runs
under (mine, not SYSTEM). The c: in the line that calls the Perl was
only put in to rule out another possible source of the problem, they
don't seem necessary in the 3 ways of running it that work. Should I try
doing the net stuff from inside the script, in a system(....);
statement? NB The people running this server still have Perl back at 5.6

_______________________________________________
ActivePerl mailing list
[EMAIL PROTECTED]
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs


------------------------------------------------------------------------------
This e-mail message is for the sole use of the intended recipient(s) and contains 
confidential and/or privileged information belonging to Siebel Systems, Inc. or its 
customers or partners.  Any unauthorized review, use, copying, disclosure or 
distribution of this message is strictly prohibited.  If you are not an intended 
recipient of this message, please contact the sender by reply e-mail and destroy all 
soft and hard copies of the message and any attachments.  Thank you for your 
cooperation.
====================================================


_______________________________________________
ActivePerl mailing list
[EMAIL PROTECTED]
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs

Reply via email to