Click here to Skip to main content
15,887,485 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
Hi
I have a WCF windows service on a windows server 2008 R2 whose job is simply to act as a remote exe launcher from clients. There is 1 exe which takes some parameters and does some background work, basically some bulk copies from sql and generating some txts.The exe by itself if run locally, works perfectly good, no problem at all, the deal breaker comes when it launches from the wcf service which creates a System.Diagnostics.Process with the parameters and then calls the .Start() on a new Thread so it can process multiple requests concurrently.

So the problem is an isolated weird behaviour where the exe will be killed without notice, no advice, no error message, it just gets halfway or less and dies, but only sometimes, not always.

The question here is, what could be a possible cause? the service is running under the SYSTEM account so it has privileges, I was guessing that maybe it has something to do with the memory or cpu usage since the exe grabs a lot of cpu and since it runs many functions on sql, the sql service holds almost half the memory available, but that's just a wild guess. Any thoughts??? Thanks a lot to anyone who can take time to reply.
Posted

Assuming you've implemented an appropriate level of exception handling which isn't showing you where the problem might be...

Write diagnostic info to the system log (or a text file). This is going to take a while because unless you have an idea of where/why it's breaking, you're doing to have to start with a broad brush and narrow it down by running the app and seeing what happens, and moving/adding logging code around.
 
Share this answer
 
After several testing and logging, it seems that in the end (I wasn't informed of the execution environment) everything was set in a Virtual Windows Server 2008 R2 and the SQL server version was quite limited in regards of memory and allowed connections, so we're about to change our test environment to some more adequate server, we'll conduct some tests but we found plenty of inconsistent scenarios where remote and local connections to the server showed weird behaviours or unavailability of the database itself.

Thanks a lot for the support and I'll keep this thread informed with the end result.

Best regards!
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900