At my company, we are using Windows Server 2003 to host various critical services which must be running all the time.

Some of these services execute "DOS" commands via C# code. One command is a simple batch file which fetches a range of files on a FTP server, another command is a simple third party tool which converts file to a proprietary XML format. These commands are completely unrelated, and only some use external IP-resources.

This has been running for about a year without problems, however, after we moved the server into a new hosting center, we are now periodically seeing these commands failing. They are simply not returning within the given time frame. Other commands such as Nagios NPRE_NT are also failing in the event log:

NRPE_NT: Bad return code for [No output available from command...]: 128

The only way to make these commands execute properly is to restart the server - but after a while the problem occurs again.

I was thinking it could be a hardware problem, but I lack the skills to properly do a diagnostics on this.

  • Would be good to know more about what they so. Could be three unrelated problems with similar symptoms. How do you do the system calls? I have a system on VB that makes hundreds of calls to an exe per hour and it has been very stable, unless someone moves the exe on me. – Kyle Aug 2 '09 at 13:37
  • Now a completely unrelated third-party tool failed with the following message: "cmd.exe - Application Error": The application failed to initialize properly (0xc0000142). Click on OK to terminate the application. – mbp Aug 4 '09 at 6:26

If it is c# and you have moved to another server, you may want to check the version of .net and make sure that the method you have used to call the functions have not updated/changed

It could be either the new server has a lower version or even a newer version than the original server.

Or, have you just changed hosts but using the same physical server?

We really need more information on your situation.

  • The server has been physically moved. No software changes has occured. – mbp Aug 3 '09 at 6:35

The first thing to check is that you have the correct .Net runtimes. You should also check the behavior of the apps/scripts that are being called interactively to ensure they are functioning as expected and not throwing up any errors. Do you know if they are exiting cleanly, and are they cleaning up any temporary files / resource handles that they use correctly? If there are network dependencies (such as the FTP call) are those commands completing fast enough from the new location so that you're not causing multiple calls to stack up? A quick check with task manager/process explorer to see if there are multiple copies of these processes running unexpectedly would be a good idea too.

  • I conclude that the internet connection is not an issue since both commands that rely on connection fails, and those who don't rely on a connection fails. – mbp Aug 3 '09 at 6:36

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.