English 中文(简体)
autosys doesn t run batch file
原标题:

i wrote a batch file to open a webrowser, then close it, then open another and close it. upon opening the browser it will send email out. when i manually run the batch it works, but when i use autosys to run it, email never got sent. here s the batch file:

@echo off
start iexplore.exe http://localhost/licensedb/Dev/home.php
ping 123.45.67.89 -n 1 -w 20000 > nul
taskkill /im iexplore.exe
start iexplore.exe http://localhost/licensedb/Dev/send_mail.php
ping 123.45.67.89 -n 1 -w 10000 > nul
taskkill /im iexplore.exe

Here s the autosys command line:

insert_job: cots_license_tracker   job_type: c 
command: "D:Application Tracking	ext.bat"
machine: computer name
owner: serviceautosys@domain
permission: 
date_conditions: 1
run_calendar: Bi-weekly_Mondays
start_times: "09:00"
std_out_file: D:logsAutoSyssys\%AUTO_JOB_NAME%.out
std_err_file: D:logsAutoSyssys\%AUTO_JOB_NAME%.err
alarm_if_fail: 0

Sorry if I asked in the wrong place... first time posting here

问题回答

When defining the command in Autosys, you should either use double quotes around the entire command or escape special characters. You are doing both here - you probably need to use double quotes around everything since there is a space in your command, so try removing the escape character before the colon.





相关问题
complex batch replacement linux

I m trying to do some batch replacement for/with a fairly complex pattern So far I find the pattern as: find ( -name *.php -o -name *.html ) -exec grep -i -n hello {} + The string I want ...

How to split a string by spaces in a Windows batch file?

Suppose I have a string "AAA BBB CCC DDD EEE FFF". How can I split the string and retrieve the nth substring, in a batch file? The equivalent in C# would be "AAA BBB CCC DDD EEE FFF".Split()[n]

How to check which Operating System?

How can I check OS version in a batch file or through a vbs in an Windows 2k/2k3 environment ? You know ... Something like ... : "If winver Win2k then ... or if winver Win2k3 then ....

热门标签