Re: Process.Start() in windows service on Windows Server 2003, problem
From: Tobias Johansson (no)
Date: 02/23/05
- Next message: Martijn Laan: "Re: SE_REGISTRY_WOW64_64KEY?"
- Previous message: Noolyg: "Storing certificate on a hardware token (SC)"
- In reply to: Pavel Lebedinsky: "Re: Process.Start() in windows service on Windows Server 2003, problem"
- Next in thread: Pavel Lebedinsky: "Re: Process.Start() in windows service on Windows Server 2003, problem"
- Reply: Pavel Lebedinsky: "Re: Process.Start() in windows service on Windows Server 2003, problem"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Date: Wed, 23 Feb 2005 17:07:54 +0100
Thank you for your reply,
I have tried both your suggestions,
but a can't get it to interact with the desktop. (no cmd window starts)
The cmd starts but not ExtExp.exe (monitored in task manager)
And I get no exceptions running it in remote debug mode.
I also made the extexp write to a log file the first thing it does..
nothing is in the log file after a run attempt .. wich means the program
never actually runs.
If you have any other ideas, they are greatly appreciated.
Thank you once again for your time.
"Pavel Lebedinsky" <m_pll at hotmail com> skrev i meddelandet
news:ujZs6GXGFHA.3732@tk2msftngp13.phx.gbl...
> So it looks like the process starts successfully but then terminates
> for some reason. May be it doesn't like the service environment
> or something like that.
>
> You could try configuring the service to run as System and enabling
> the "allow to interact with desktop" checkbox. Then you should be
> able to see your process window while it's running. If it goes away
> too quickly change the command line to something like
> "cmd /k test.cmd" and put the actual command in the test.cmd file.
>
> Another option is to run your process under the built in debugger
> (ntsd.exe) to see if you're getting any exceptions. You'll need to use
> the -server and -remote options to connect to the debugger session
> (unless you change your service to be interactive as described above).
>
> "Tobias Johansson" wrote:
>
>> I tested with notepad before and it worked,
>> but I can't actually see it because the program is running as a windows
>> service.
>>
>> However I tried it again today with the same result.
>> I also tried with ipconfig.exe and it worked without problem
>> and I got the output of my ip configuration in my log file.
>>
>> I also corrected the deadlock issue,
>> to read the stream before exit. Thanks pointing that out.
>>
>> I know win 2003 server has extra security on running exe files mapped on
>> network drives
>> but this is not on a mapped drive, it's local.
>> But coul'd it be related ? but then console program wouldn't have worked
>> either...?
>>
>> I have also tried setting the current work dir of the service to the work
>> dir where the exe is
>> before executing it .. no change..
>>
>> I have also checked the permissions on the file
>> and that the user that the service runs as has access to it (currently as
>> local admin just to make it work)
>
>
- Next message: Martijn Laan: "Re: SE_REGISTRY_WOW64_64KEY?"
- Previous message: Noolyg: "Storing certificate on a hardware token (SC)"
- In reply to: Pavel Lebedinsky: "Re: Process.Start() in windows service on Windows Server 2003, problem"
- Next in thread: Pavel Lebedinsky: "Re: Process.Start() in windows service on Windows Server 2003, problem"
- Reply: Pavel Lebedinsky: "Re: Process.Start() in windows service on Windows Server 2003, problem"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Relevant Pages
|