locked
.NET 2.0 application crashing .NET service on Win2000 - how can that be? RRS feed

  • Question

  • Ok, I know this is old stuff, but the target machine happens to run Windows 2000 ... 

    I have a software solution written in C# for .NET 2.0 that consists of two parts: a backend/server running as a Windows Service and a client/WinForms app. 

    Everything runs fine under Windows XP, Vista and Win7. However, on Windows 2000 it seems that only one of the two apps can run at the same time. The service is started automatically, but when I start the client, either the client crashes, the service crashes or both, pretty much randomly.

    The client would show a "...has encountered a problem and needs to close. We are sorry for inconvenience" dialog box. For the service DW20 would fire up and then the service dies.

    I wonder how this can be and how I could troubleshoot the issue.

    • the two applications don't talk to each other or share any resources (well, they normally would, but all this has been disabled/removed)
    • The two apps share a few assemblies/libraries, but that should not be a problem, right? I have even created to separate folders, one with client and all libs and one with server and all libs, with no difference
    • I have run the server as a console application instead. This shows the same issue of either of the two crashing
    • I have added global exception handlers to the client, but none of them ever seem to get called
    • I have added a MessageBox.Show as the first call in the client, but sometimes the client or service would crash even before that message is shown (I know, there could be some static initializer running before that, but I am pretty sure there isn't).

    The Win2000 machine doesn't have Visual Studio installed. My development machine has VS2010. What can I do to debug or further analyzer the issue?

    J.-

    Thursday, October 27, 2011 6:55 AM

Answers

  • Hi J.Vollmering,

     

    For this wierd issue, I suggest you first get crash dump file for analysis.

    You can visit http://www.microsoft.com/whdc/devtools/debugging/default.mspx to install "Debugging Tools for Windows".

    After the debug tool installed, please follow up instructions listed in http://support.microsoft.com/kb/934650 to capture dump file.

    Meanwhile, you can use some monitoring tool like Process explorer and Perfmon to check if any abnormal issues happened.

    Furtherly, you can detect if any handle leak, memory leak, or other security issues existed. Otherwise, Windows Event Log and custom app-specific log probably can give you some clues.

     

     


    Best wishes,


    Robin [MSFT]
    MSDN Community Support | Feedback to us
    Get or Request Code Sample from Microsoft
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.
    • Proposed as answer by Paul Zhou Monday, November 7, 2011 7:36 AM
    • Marked as answer by Paul Zhou Wednesday, November 9, 2011 7:44 AM
    Friday, October 28, 2011 2:35 AM

All replies

  • From the description the problem probably occurs at the runtime level or lower, so your code doesn't have a chance to handle this.

    While you may send the crashdump files for someone who knows to take a check, I'd suggest to do some standard environment check first.

    E.g.: Is anything logged at the event viewer? Does disabling antivirus helps? Is the RAM size enough? How about the page files?

    How does the service and client communicates? If it's based on TCP/IP, does seperate then on different machine helps?

    You know your program best and should be able to determine a list of possible area to check to see if they're relevent.



    • Edited by cheong00 Friday, October 28, 2011 2:33 AM
    Friday, October 28, 2011 2:33 AM
  • Hi J.Vollmering,

     

    For this wierd issue, I suggest you first get crash dump file for analysis.

    You can visit http://www.microsoft.com/whdc/devtools/debugging/default.mspx to install "Debugging Tools for Windows".

    After the debug tool installed, please follow up instructions listed in http://support.microsoft.com/kb/934650 to capture dump file.

    Meanwhile, you can use some monitoring tool like Process explorer and Perfmon to check if any abnormal issues happened.

    Furtherly, you can detect if any handle leak, memory leak, or other security issues existed. Otherwise, Windows Event Log and custom app-specific log probably can give you some clues.

     

     


    Best wishes,


    Robin [MSFT]
    MSDN Community Support | Feedback to us
    Get or Request Code Sample from Microsoft
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.
    • Proposed as answer by Paul Zhou Monday, November 7, 2011 7:36 AM
    • Marked as answer by Paul Zhou Wednesday, November 9, 2011 7:44 AM
    Friday, October 28, 2011 2:35 AM
  • Hi,

     

    Would you mind letting us know the result of the suggestions?

     

    Now I will mark an answer, you can mark others that you think to be so useful to your issue.

    If you still have any questions about this issue, please feel free to let me know.

     

    Have a nice day!


    Paul Zhou [MSFT]
    MSDN Community Support | Feedback to us
    Get or Request Code Sample from Microsoft
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.

    Wednesday, November 9, 2011 7:44 AM