I am trying to run WSUS Offline in an unattended fashion.

When I run a start/wait doupdate.cmd it opens a new command window and performs tasks and then exits to the new window. If this new window never closes, the start /wait never finishes and the original batch file can never finish.

Anyone know how I would get this new CMD window to close?
0 Comments   [ + ] Show Comments

Comments

Please log in to comment

Rating comments in this legacy AppDeploy message board thread won't reorder them,
so that the conversation will remain readable.

Answers

0
I would suggest from the main CMD call the second cmd as cmd /c <path of the second cmd>. & Add try to use Exit command in both the CMD.
For more help you can check cmd.exe /? in the Command prompt.
I hope it will help to solve your problem. cmd
Answered 02/03/2011 by: guy.forum
Orange Belt

Please log in to comment
0
I'd abandon the Stone Age mentatility of batch-building and build a script in a more capable and robust language. That script would test for the existence of a process or processes within a timed loop and take appropriate action when time 'x' has elpased.
Answered 02/03/2011 by: VBScab
Red Belt

Please log in to comment
0
Believe me, I am trying to. However, I am a staff of 1 managing over 750+ computers and my free time to learn scripting is scarce.

It was a bonehead mistake in that I was using start /wait with a .cmd instead of calling it which kept it in the same windows alleviating the problem.

Hey Scab, if you'd be interested in helping me abandon the Stone Age please take a look at the question I am about to post on printer installation/vbscript in general.

Thanks,

-DHF

ORIGINAL: VBScab

I'd abandon the Stone Age mentatility of batch-building and build a script in a more capable and robust language. That script would test for the existence of a process or processes within a timed loop and take appropriate action when time 'x' has elpased.
Answered 02/15/2011 by: dyehardfan
Second Degree Blue Belt

Please log in to comment
Answer this question or Comment on this question for clarity
Admin Script Editor
Admin Script Editor is an integrated scripting environment available free here at ITNinja

Share