Avoid killing a job in batch files
Posted on 2009-05-14
I've a batch file, that take a while to complete. Consists in a deletion of a directory and its files, then change of drive, and lauch a command that takes long time to accomplish its job.
@del /Q e:\Dir\subdir
@rmdir e:\Dir\subdir /s /q
@cd "C:\program files\XXX\XX"
@command.exe -h ip1 -u administrator -p password -a ipaddr:ip2 -r e:\Dir\subdir -t fullvm -M 1 > E:\Dir\log.txt
The problem, is that, often, we accees via TS for work, and in logoff, we kill the job.
It's possible to avoid this behaviour, with a instruction in a batch file