Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

I have a Windows 2000 bat file call

Status
Not open for further replies.

melomon

Programmer
Sep 18, 2003
7
US
I have a Windows 2000 bat file calling for an ant target that is accessing VSS database on a network computer. If I run the script from my desktop it works fine, but if it's invoked by MS Windows Scheduled Task it fails to access the VSS database with the following error:

labelCommon:
[vsslabel] No VSS database (srcsafe.ini) found. Use the SSDIR environment variable or run netsetup.

BUILD FAILED
file:ant/common.inc.xml:49: Failed executing: "C:\Program Files\Microsoft Visual Studio\VSS\win32\ss" Label $/DataCenter/common/ -C- -I-Y -L20040125 -Y...


When scheduling the job I use the same id/password that I use to login into my computer and into the remote VSS database. Also, the target that send files via FTP to other network computers work fine if scheduled.

Can anybody help me?
Thanks
 
I think that's because when the batch file is run by window scheduled task, the start-in directory is not the same as the directory of you batch file. If the file for your VSS database is defined in relative path to batch file, the resulting path to VSS database when run by scheduled task would be incorrect.

 
Hi byam,
I specified both vss.home and VSS_drive as absolute path in ANT_ARGS. VSS_drive belongs to a remote computer which I mapped to my machine. Also, from the error message it's seen that the path for ss.exe is found, but it just failed to execute for some reason. BTW, I don't know what's the SSDIR env variable, but setting it didn't help. Anybody knows how Scheduler privileges effect execution of a job that's running fine when starting from DOS?
Any other suggestions?
Thanks.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top