Problem in executing a script on the server side ! Script found but nothing executed !

Discussion in 'ASP .Net' started by Cédric Rossé, Nov 9, 2004.

  1. Hello,

    I'm currently developping a web application in C# / ASP.net.
    On a specific form of my application, I have a simple button which calls the
    following code :

    Process myProcess;
    myProcess = new Process();

    myProcess.StartInfo.UseShellExecute = false;

    myProcess.StartInfo.RedirectStandardOutput = true;

    myProcess.StartInfo.RedirectStandardError = true;

    myProcess.StartInfo.WorkingDirectory = "C:\\Inetpub\\wwwroot\\NetGuard";

    myProcess.StartInfo.FileName =
    "C:\\Inetpub\\wwwroot\\NetGuard\\GoNetSH.cmd";

    myProcess.Start();

    It is just a call to a simple script (GoNetSH.cmd) running on the server
    side (Windows server 2003).

    The content of the script is the following :

    c:\windows\system32\ping cronos > C:\Inetpub\wwwroot\NetGuard\cronos.txt

    As you can see there is no call to any graphical program, just a simple
    command line... !

    My problem is the following. The script is well called but the code inside
    is not executed and I can't find why !
    I checked the NTFS security, the IIS parameters, I even put "everyone",
    "system", "IUSR_machinename" and so one in "Administrators" group (just for
    testing...) but nothing is executed !

    Here is my web.config parameters :
    <authentication mode="Windows" />

    <identity impersonate="true"/>

    And my machine.config parameters:

    <processModel enable="true" timeout="Infinite" idleTimeout="Infinite"
    shutdownTimeout="0:00:05" requestLimit="Infinite" requestQueueLimit="5000"
    restartQueueLimit="10" memoryLimit="60" webGarden="false"
    cpuMask="0xffffffff" userName="SYSTEM" password="AutoGenerate"
    logLevel="Errors" clientConnectedCheck="0:00:05"
    comAuthenticationLevel="Connect" comImpersonationLevel="Impersonate"
    responseDeadlockInterval="00:03:00" maxWorkerThreads="20"
    maxIoThreads="20"/>

    The configuration of the framewok is full trust for all the zones !!

    Is there something specific with Windows Server 2003 ? Can someone help me ?

    Thank you in advance for all your responses !

    Cédric
    Cédric Rossé, Nov 9, 2004
    #1
    1. Advertising

  2. For information :

    I have to let the IIS service interact with the desktop and then it
    works correctly...

    Thank you

    Cédric

    ----------------------------------------------------------------------------------


    "Cédric Rossé" <> a écrit dans le message de news:
    ...
    > Hello,
    >
    > I'm currently developping a web application in C# / ASP.net.
    > On a specific form of my application, I have a simple button which calls
    > the following code :
    >
    > Process myProcess;
    > myProcess = new Process();
    >
    > myProcess.StartInfo.UseShellExecute = false;
    >
    > myProcess.StartInfo.RedirectStandardOutput = true;
    >
    > myProcess.StartInfo.RedirectStandardError = true;
    >
    > myProcess.StartInfo.WorkingDirectory =
    > "C:\\Inetpub\\wwwroot\\NetGuard";
    >
    > myProcess.StartInfo.FileName =
    > "C:\\Inetpub\\wwwroot\\NetGuard\\GoNetSH.cmd";
    >
    > myProcess.Start();
    >
    > It is just a call to a simple script (GoNetSH.cmd) running on the server
    > side (Windows server 2003).
    >
    > The content of the script is the following :
    >
    > c:\windows\system32\ping cronos >
    > C:\Inetpub\wwwroot\NetGuard\cronos.txt
    >
    > As you can see there is no call to any graphical program, just a simple
    > command line... !
    >
    > My problem is the following. The script is well called but the code inside
    > is not executed and I can't find why !
    > I checked the NTFS security, the IIS parameters, I even put "everyone",
    > "system", "IUSR_machinename" and so one in "Administrators" group (just
    > for testing...) but nothing is executed !
    >
    > Here is my web.config parameters :
    > <authentication mode="Windows" />
    >
    > <identity impersonate="true"/>
    >
    > And my machine.config parameters:
    >
    > <processModel enable="true" timeout="Infinite" idleTimeout="Infinite"
    > shutdownTimeout="0:00:05" requestLimit="Infinite" requestQueueLimit="5000"
    > restartQueueLimit="10" memoryLimit="60" webGarden="false"
    > cpuMask="0xffffffff" userName="SYSTEM" password="AutoGenerate"
    > logLevel="Errors" clientConnectedCheck="0:00:05"
    > comAuthenticationLevel="Connect" comImpersonationLevel="Impersonate"
    > responseDeadlockInterval="00:03:00" maxWorkerThreads="20"
    > maxIoThreads="20"/>
    >
    > The configuration of the framewok is full trust for all the zones !!
    >
    > Is there something specific with Windows Server 2003 ? Can someone help me
    > ?
    >
    > Thank you in advance for all your responses !
    >
    > Cédric
    >
    Cédric Rossé, Nov 9, 2004
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Guadala Harry
    Replies:
    4
    Views:
    1,498
    =?Utf-8?B?aGFyaSBwcmFzYWQ=?=
    Jun 15, 2004
  2. Magnus Blomberg
    Replies:
    3
    Views:
    703
    Magnus Blomberg
    Apr 14, 2005
  3. Devin Jeanpierre
    Replies:
    2
    Views:
    428
    Devin Jeanpierre
    Feb 14, 2012
  4. Henry
    Replies:
    7
    Views:
    131
    Sherm Pendley
    Dec 12, 2003
  5. Replies:
    0
    Views:
    88
Loading...

Share This Page