Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > Weird Diagnostics.Process bug

Reply
Thread Tools

Weird Diagnostics.Process bug

 
 
Bill Rapoza
Guest
Posts: n/a
 
      08-29-2005
We have a method that executes an arbitrary batch file (we use it for remote
upgrades of our system).

When we execute this method from outside of ASP.NET (either in the
foreground app or from a windows service), the method works fine. However,
when we execute it from ASP.NET, the execution fails on some machines. Now,
if instead of running the batch file directly, I run cmd.exe and have it run
the batch file:

cmd /k platformupgrade.bat

the batch file still does not execute (note: I'm using /k instead of /c for
debugging purposes. the behavior is identical).

However, if I run cmd and have it also run cmd and have the second cmd run
the batch file:

cmd /k cmd /c platformupgrade.bat

The batch file runs fine.

What's going on here? Frankly, I'm very leery of including this "fix" into
my application because it's so strange.


 
Reply With Quote
 
 
 
 
Steven Cheng[MSFT]
Guest
Posts: n/a
 
      08-30-2005
Hi Bill,

Welcome to ASP.NET newsgroup.
Regarding on this executing bat file under asp.net app fail problem, based
on my experience, it seems likely something related to the asp.net's
workerprocess account which is a very restricted account.

As for the the failure on some machine, did it means the bat file even not
get executed or executed and fail in the middle or at certain point? If it
fails at certain point, I'd suggest we try simplify the bat file to get
what operation make the broken.
In addition, have you found any eventlog entry on that machine related to
this problem? Also, for the current workaround you mentioned, I'm also
feeling a bit strange, but I think we may need to perform some general test
first so as to make thing clearer.

Looking forward to your response. Thanks,

Steven Cheng
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)




--------------------
| From: "Bill Rapoza" <(E-Mail Removed)>
| Subject: Weird Diagnostics.Process bug
| Date: Mon, 29 Aug 2005 10:21:03 -0700
| Lines: 25
| X-Priority: 3
| X-MSMail-Priority: Normal
| X-Newsreader: Microsoft Outlook Express 6.00.2900.2180
| X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2180
| X-RFC2646: Format=Flowed; Original
| Message-ID: <(E-Mail Removed)>
| Newsgroups: microsoft.public.dotnet.framework.aspnet
| NNTP-Posting-Host: 199.244.171.156
| Path: TK2MSFTNGXA01.phx.gbl!TK2MSFTNGP08.phx.gbl!tk2msft ngp13.phx.gbl
| Xref: TK2MSFTNGXA01.phx.gbl
microsoft.public.dotnet.framework.aspnet:120967
| X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet
|
| We have a method that executes an arbitrary batch file (we use it for
remote
| upgrades of our system).
|
| When we execute this method from outside of ASP.NET (either in the
| foreground app or from a windows service), the method works fine.
However,
| when we execute it from ASP.NET, the execution fails on some machines.
Now,
| if instead of running the batch file directly, I run cmd.exe and have it
run
| the batch file:
|
| cmd /k platformupgrade.bat
|
| the batch file still does not execute (note: I'm using /k instead of /c
for
| debugging purposes. the behavior is identical).
|
| However, if I run cmd and have it also run cmd and have the second cmd
run
| the batch file:
|
| cmd /k cmd /c platformupgrade.bat
|
| The batch file runs fine.
|
| What's going on here? Frankly, I'm very leery of including this "fix"
into
| my application because it's so strange.
|
|
|

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Re: A Weird Appearance for a Weird Site Beauregard T. Shagnasty HTML 1 01-21-2011 04:17 PM
Re: A Weird Appearance for a Weird Site richard HTML 0 01-21-2011 07:10 AM
Re: A Weird Appearance for a Weird Site dorayme HTML 1 01-21-2011 06:51 AM
Re: A Weird Appearance for a Weird Site richard HTML 0 01-21-2011 06:46 AM
*bug* *bug* *bug* David Raleigh Arnold Firefox 12 04-02-2007 03:13 AM



Advertisments