Deploying a batch file
|
Logged in as: Guest
|
|
Users viewing this topic:
none
|
|
Login | |
|
Deploying a batch file - 6.Oct.2003 11:47:00 AM
|
|
|
2500hd
Posts: 4
Joined: 5.Oct.2003
Status: offline
|
Hello, I am trying to run a batch file on a remote computer. Using the deploy custom patch program I am trying to push out a .bat file. The batch file calls a file located on a share drive. I have tested this batch file on the remote machines and it works properly if I run the batch file withing cmd.exe.
Here is the syntax msiexec /i "\\SERVER\SHARE\test.msi" /qn
When I try to deploy this .bat file nothing happens on the remote machine.
When I run Deploy_batch.bat from c:/winnt/system32/patches on remote computer the batch file works great.
Thanks, Mark
|
|
|
|
RE: Deploying a batch file - 6.Oct.2003 7:10:00 PM
|
|
|
xnih
Posts: 2465
Joined: 30.May2001
From: Idaho
Status: offline
|
run it in interactive mode first, see if it shows you anything else.
I've deployed multiple things in the past with no problems.
eric
|
|
|
|
RE: Deploying a batch file - 6.Oct.2003 8:14:00 PM
|
|
|
2500hd
Posts: 4
Joined: 5.Oct.2003
Status: offline
|
I have tried to run in interactive mode but I have had no results. Will a .bat file automatically run with cmd.exe on the remote machine? The batch file downloads to the machine but it does not start. If I manually run the batch file it work fine. Thanks, Mark
|
|
|
|
RE: Deploying a batch file - 6.Oct.2003 8:48:00 PM
|
|
|
xnih
Posts: 2465
Joined: 30.May2001
From: Idaho
Status: offline
|
anything you push as a scheduled task (which is any normal patch or custom patch) it is going to run, by default in the background.
add something like notepad.exe at the end of your bat file, see if it is running that part.
hmm, now I'm trying to remember if I ever have actually used a bat file like that....
quote: When I run Deploy_batch.bat from c:/winnt/system32/patches on remote computer the batch file works great.
then I would assume 1 of 2 things:
1. Task is scheduled in the future sometime and didn't run. Go to the machine, goto a cmd prompt and type AT and hit enter, it will tell you what scheduled tasks there are.
2. The scheduled taks isn't running for some reason. Could be a problem with the scheduler. check this: quote: it might be not be a problem after all, well it could be the window task scheduler problem, ask them to check the task logs on the deployed to PCs, this can be found in the control panel, scheduled tasks then click on Advanced -> view logs
If there are log entries which return an exit code of 80 than it's the scheduler bug (log entry should look like this : "At1.job" (deploy_patches.bat) Finished 9/12/2003 3:35:00 PM Result: The task completed with an exit code of (80).
If the exit code is indeed 80 than its due to the following problem which we have no control over, there is also a workaround posted by Microsoft regarnding this at the same location ie here : http://support.microsoft.com/default.aspx?scid=kb;en-us;812400
If it says it ran fine then I have no idea.
eric
|
|
|
|
RE: Deploying a batch file - 7.Oct.2003 9:51:00 AM
|
|
|
2500hd
Posts: 4
Joined: 5.Oct.2003
Status: offline
|
Notepad.bat file has one command in it. notepad.exe
Notepad does not run on the remote machine. Everything else seems to work fine. I have tried this on 3 machines. Regular patches work fine.
there were some entries in the shceduled tasks that showed they were running.
"At2.job" (deploy_patches.bat) Finished 10/6/2003 4:18:00 PM Result: The task completed with an exit code of (0). "At3.job" (deploy_patches.bat) Started 10/7/2003 9:11:00 AM "Task Scheduler Service" Exited at 10/7/2003 9:12:15 AM "Task Scheduler Service" Started at 10/7/2003 9:13:40 AM "Task Scheduler Service" 4.71.2195.6704"At1.job" (deploy_patches.bat) Started 10/7/2003 9:18:00 AM "At2.job" (deploy_patches.bat) Started 10/7/2003 9:23:00 AM "At3.job" (deploy_patches.bat) Started 10/7/2003 9:24:00 AM
Deployment log for SUSTEST1 () Copying patches to \\TEST1\C$\WINNT\system32\Patches ... Copying patch notepad.bat (1 left to go) ... Patch copied. Creating batch file deploy_patches.bat ... Copying qchain.exe ... Preparing patch installation ... Let's verify if Schedule service is runnning ... Scheduled job added. Waiting for scheduled job to start ... Scheduled job started. Patches are being installed ... For all of the patches to be installed in the background can take some time before they are fully applied. There is no way to check the status of deployment once the scheduling of deployment has been set. It is recommended to re-scan the computer in around half an hour to verify complete deployment of the selected patches / service packs. Done
|
|
|
|
RE: Deploying a batch file - 7.Oct.2003 10:01:00 AM
|
|
|
2500hd
Posts: 4
Joined: 5.Oct.2003
Status: offline
|
After looking at task manager there are many notepade.exe procesess running. Also I cannot end task them. So it seems like things are running.
Another update. I set the patch to interactive and now notepad.exe shows on the screen. I will check my custom batch file now.
Thanks for the help. Mark
|
|
|
|
RE: Deploying a batch file - 7.Oct.2003 5:05:00 PM
|
|
|
xnih
Posts: 2465
Joined: 30.May2001
From: Idaho
Status: offline
|
yeah, if not run in interactive mode it is going to run as a background task that you never see.
eric
|
|
|
|
RE: Deploying a batch file - 20.Oct.2003 8:31:00 AM
|
|
|
Kaleta
Posts: 8
Joined: 29.Sep.2003
Status: offline
|
Hi! IŠve the same problem like 2500hd. but the problem is, that it worked 2 weeks ago and today it donŠt like. iŠve execute a .exe file on a remote computer.
|
|
|
|
RE: Deploying a batch file - 20.Oct.2003 11:01:00 AM
|
|
|
xnih
Posts: 2465
Joined: 30.May2001
From: Idaho
Status: offline
|
a little more info would be needed there.
Ultimately, unless set in interactive mode anything you send as a task to a remote machine is going to be run in the background, so in most cases you won't see it running.
Check the remote machine, go to the cmd prompt, type AT, see if the job is scheduled for the future and just hasn't gone. Monitor task manager see if the process is actually launching in the background and you're just not seeing it. Launch the file from c:\winnt\system32\patches by hand, see if if it has problems.
Any custom patches/pushes, ultimately, are unsupported, but for the most part we should be able to track some of it down with more info.
So let me know.
eric
|
|
|
|
RE: Deploying a batch file - 21.Oct.2003 4:44:00 AM
|
|
|
Kaleta
Posts: 8
Joined: 29.Sep.2003
Status: offline
|
my problem: iŠd like to deploy a sfx.exe file. the exe file is ok, iŠve tested it. the coping from the nss to the remote clients works well. the deployment starts after one minute. the task starts but it will not end (that i can see in the task manager). The tasks logfile tells me that everything works ok. if i start the exe file at the remote computer in the patch directory (%systemroot%\system32\patches)it works well. iŠve tryed to deploy an exe file, witch iŠve deployed 2 weeks ago without a problem, but it didnŠt work.
|
|
|
|
RE: Deploying a batch file - 21.Oct.2003 8:55:00 AM
|
|
|
Kaleta
Posts: 8
Joined: 29.Sep.2003
Status: offline
|
cound it be, that MS have something changed with the last patch MS039, so that it isnŠt possible to install no MS sign exe files????? [ October 21, 2003, 02:56 PM: Message edited by: Kaleta ]
|
|
|
|
RE: Deploying a batch file - 21.Oct.2003 9:16:00 AM
|
|
|
xnih
Posts: 2465
Joined: 30.May2001
From: Idaho
Status: offline
|
anything is possible with MS these days, but it isn't something I've seen/noticed.
Trying to track down what a process is doing in the background is always a pain.
Is your sfx prompting the end user for any input? Do you have it set for interactive mode or completely silent (anymore anything I push I do it in interactive mode repeatedly until I'm sure it is working correctly, then attempt it without it, some things just don't work real well when they are not done in interactive mode, don't know why).
Without having the file and doing my own testing it is hard to say, but the main issues I've run into are the 'interactive' setting and then setting up the autorun feature on the sfx incorrectly (when it was unextracting it was putting it one directory deeper than I thought). Anyway, if it is running by hand it may be an interactive thing.
I'll try to do a test or two with a fully patched machine to see if I can reproduce any problems with the latest MS patches. But from what I recall reading on them I can't think of what may have caused it. Therefor I doubt it was one of the latest patches.
eric
|
|
|
|
RE: Deploying a batch file - 21.Oct.2003 10:13:00 AM
|
|
|
Kaleta
Posts: 8
Joined: 29.Sep.2003
Status: offline
|
Thank you xnih!The sfx file contains an reg file witch will starts after the sfx file is unpack. if you like i can send you the sfx file and the reg file. iŠve make the sfx.exe with winrar and i told that the unpacking shoudnŠt be diplayed.
|
|
|
|
RE: Deploying a batch file - 28.Oct.2003 7:09:00 AM
|
|
|
Guest
|
Hello
I've found the same problem with running .bat files from the custom patch option. However I have also run into this same issue trying to activate .bat files using AT. Basically I found that on NT and W2K machiens .bat files no matter what they ran or contained wouldn't run when called by AT which I believe is exactly how Languard inniates the patches it deploys.
Sorry I can't help solve your problem but I thought I'd let you know that you aren't alone
Jim
|
|
|
|
New Messages |
No New Messages |
Hot Topic w/ New Messages |
Hot Topic w/o New Messages |
Locked w/ New Messages |
Locked w/o New Messages |
|
Post New Thread
Reply to Message
Post New Poll
Submit Vote
Delete My Own Post
Delete My Own Thread
Rate Posts |
|
|