Win a copy of Programmer's Guide to Java SE 8 Oracle Certified Associate (OCA) this week in the OCAJP forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Stop and Restart the IBM WAS

 
Luke Zechariah
Ranch Hand
Posts: 128
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

My application runs on IBM WAS 7.0.0.25 on Windows 2008 Server. I want to konw if there is a way to programatically stop and restart my server? It has to trigger when I get a certain kind of exception. Any idea would be of great help.

Thank for your time.
Lk.
 
Harneet Singh
Greenhorn
Posts: 18
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am not a programmer but can suggest you one thing.
You can write a script to capture you logs for the error and re-direct it to another file and then add a scheduler which can react to the captured event to restart WAS.
If it has been a UNIX based system then I would simply use crontab to run every minute or 5 minutes to check for the error and then issue KILL -9 for the JVM which would automatically restart it.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic