Automatically Restart Crashed Or Hanged Applications

Don’t you hate it when programs hang or crash? I find it especially annoying when a background application like an IM client or a bandwidth monitor silently crashes – sometimes I only notice the problem hours later when I’ve already missed a bunch of messages. I’m sure you’ve encountered a few “Not responding” errors and some irritatingly crash-prone applications yourself.

If you have an unstable program that you absolutely need to run at all times, but don’t want to waste your time monitoring and manually restarting it every time it croaks, I might have something interesting for you.

Restart on Crash is an monitoring tool that will watch the applications that you specify and automatically relaunch any program that hangs or crashes. You can add any number of applications to monitor, enable/disable them individually and edit the command line that will be used to restart an application.

Restart on Crash doesn’t require installation and stores all it’s configuration data in a “settings.ini” file in the program’s folder, so it’s portable. It should be compatible with most NT-based Windows versions.

Download Restart on Crash (1.4 MB)

Screenshots & Documentation

Main application window

The main window

  • To add a new application to monitor, click the “Add” button or press the Ins key.
  • To delete on or more applications from the list, select them and click “Delete” or press Del.
  • To edit the per-application configuration, double-click the corresponding row. This will open the editing dialog (see below).
  • You can also access the RoC configuration by clicking “Settings” and view the activity log by clicking “Show Log”. The log contains information about crashed/hanged applications, executed commands, and so on.
Editing the monitor settings for an application

Editing the monitor settings for an application

Well, this one should be pretty self-explanatory 🙂 One detail to keep in mind is that enabling the “It isn’t running” option will make Restart On Crash treat the application as if it has crashed even if you have purposefully it closed it. You can get around this by disabling the monitoring of the application before you close it.

The configuration dialog. Yes, that's it.

The configuration dialog. Yes, that’s it.

“Grace period” is how long Restart on Crash will wait before trying to terminate/restart an application that it has just terminated/restarted. This is intended to prevent a scenario where RoC kills a hanged program, restarts it, decides it has hanged again (e.g. if the program is non-responsive while starting up) and wrongfully terminates it again.

Known Issues

  • If you configure RoC to automatically kill a hanged application, it will terminate all instances of that application when doing so. This may be fixed eventually.

Release Notes

2022-11-02

  • The “execute a command” feature can now launch shortcuts (.lnk files). Potentially, it can now run almost any type of file as long as file associations are set up correctly.

2019-12-17

  • Improved “application is not responding” detection.
  • Added a “Clear Log” button to the Log window.

2019-08-24

  • Added a “Restart Now” option to the application pop-up menu. It restarts the selected application immediately without waiting for the grace period to expire.
Related posts :

605 Responses to “Automatically Restart Crashed Or Hanged Applications”

  1. Jānis Elsts says:

    I’m not sure why it wouldn’t recognize that the .exe files are different. Does it work if you rename the file(s) to NPProc01.exe, NPProc02.exe and so on?

  2. kazuhiro ISOBE says:

    Thank you.

    We renamed as NPProc01.exe, NPProc02.exe and so on, then it works!

    Sorry, we had miss-understand as RoC is working, it was not working…

  3. trcawthorn says:

    Question when you restart your computer , does restart on crash still have a list of applications you want ran.

  4. Jānis Elsts says:

    Yes, it does. It saves the list to an .ini file when you close close RoC.

  5. Pete says:

    Hi, I have an enhancement request…

    Would it be possible for ROC to close the Windows Dialog box that sometimes opens when a program crashes that says something like “XXX Has Stopped Working, do you want to report the issue to Microsoft”

    The reason is we end up with many of these orphan error messages, one for each time it crashed ??

  6. Craig says:

    Hi, Will this work for IE diagnose connection errors screen. Will it shutdown IE when IE diagnose connection error displayed and then restart IE?

  7. […] on crash」というフリーソフトを使います。 ダウンロード先 http://w-shadow.com/blog/2009/03/04/restart-on-crash/ ダウンロード先の赤枠部分をクリックでダウンロードできます。 […]

  8. Jānis Elsts says:

    @ Craig: No, it probably won’t detect non-standard crashes like that.

  9. Bebop says:

    Could you enhance the ROC program so it would only allow one instance of the ROC program running(maybe as an option) ? I use this in a batch job, and sometimes the system goes into limbo and suddenly I have 100 instances of ROC running 🙁

    Best regards

  10. Jeffrey says:

    Great program! I am having one issue with a particular application. When RoC tries to start the program it receives the following:

    CreateProcess error: The requested operation requires elevation

    I have change the properties of the program to “Run This Program As Administrator” and still have the same issue.

    Any suggestions?

  11. Jānis Elsts says:

    @ Bebop:
    Hmm, I’ll add it to my idea list.

    @ Jeffrey:
    Strange, running it as administrator should prevent any “requires elevation” problems. Are you sure the setting actually works? Try the “Run as Administrator” option from the right-click menu and see if that helps.

  12. Pete says:

    Hi, I have an enhancement request…

    Would it be possible for ROC to close the Windows Dialog box that sometimes opens when a program crashes that says something like “XXX Has Stopped Working, do you want to report the issue to Microsoft”

    The reason is we end up with many of these orphan error messages, one for each time it crashed ??

  13. Jeffrey says:

    Thank you for the suggestion. It appears as though I neglected to set RoC to also Run as Administrator. This corrected the problem.

    Thank you.

  14. […] for some reason once a day they was crashing. So i searched and i found this Restart on Crash : Automatically Restart Crashed Or Hanged Applications | W-Shadow.com Its a small program that auto restart your rellogers if they crash or closes. After download u […]

  15. Michael says:

    Would be swell if there could be a delay before checking on startup. I use this for a few applications but have to manually launch because I need to wait for the system to settle after logging in.

  16. Ian says:

    Hi, anyone knows whether the “execute a command” work for Windows shutdown with /f /r switches? I need to reboot the system whenever an application hang. Thanks!

  17. Jānis Elsts says:

    I expect it would work fine. But if for some reason it does not, you can put the command in a .bat file and use that as the command to execute.

  18. Ian says:

    Thanks Janis! Work a charm running that batch file upon triggered. Great little application.

  19. chris says:

    Hello, works perfect on XP but not able to restart an application on W7, any ideas?

Leave a Reply