1Q).. How does nodeagent monitor the application server and how does it know the previous state of the application server?
When the nodeagent monitors the application server (with the monitoring policy created as mentioned in question 1) it saves the server state information in the monitoring.state file. It will maintain the previous server state and the application server PID. In case of an application server crash or hang, the nodeagent will get the previous state of the server from the monitoring.state file and then try to start the application server automatically.
Note: If you notice StringIndexOutOfBoundsException or any other exception in the NodeAgent.loadNodeState stack (nodeagent Systemout.log file), it means the monitored.state file is corrupted. You must stop all servers, delete the file and then start the nodeagent again. For example:
Caused by: java.lang.StringIndexOutOfBoundsException
at java.lang.String.substring(String.java:1115)
at com.ibm.ws.management.nodeagent.NodeAgent.loadNodeState(NodeAgent .java:3210)
2Q). My application servers were monitored by the nodeagent. When the server was hung, why didn't the nodeagent restart the server?
Nodeagent PidWaiter sends the signal every ping time out interval to get the status of the application server. If the PidWaiter does not get the response back from Application Server then AppServer is considered hung. Once the application server is identified as unresponsive/hung the nodeagent PidWaiter sends a SIGTERM to the process, which does not guarantee the process is immediately stopped. It sends the signal wait for the process to normally shutdown. If the server doesn't respond to any request, the server just stays hung forever.
If you want the server to be killed when it's hung or doesn't respond to the nodeagent ping, then you need to set "com.ibm.server.allow.sigkill" property to true in the nodeagent custom property. Please review section "Java virtual machine settings" in the product documentation for more information.
3Q).. How can we start the application servers in parallel? In other words, can I start all application servers at the same time (not in sequence)?
Yes, you can do it using the com.ibm.websphere.management.nodeagent.bootstrap.maxthreadpool custom property.
Set the property under System Administration > Node agent > nodeagent_name > Java and process management > Process definition > Java virtual machine > Custom properties.
Use this property to control the number of threads that can be included in a newly created thread pool. A dedicated thread is created to start each application server Java virtual machine (JVM). The JVMs with dedicated threads in this thread pool are the JVMs that are started in parallel whenever the node agent starts.
You can specify an integer from 0 - 5 as the value for this property. If the value you specify is greater than 0, a thread pool is created with that value as the maximum number of threads that can be included in this newly created thread pool. The following table lists the supported values for this custom property and their effect.
Property threadpool.maxsize is set to 0 or not specified - The node agent starts up to five JVMs in parallel.
Property threadpool.maxsize is set to 1 - The node agent starts the JVMs serially.
Property threadpool.maxsize value between 2 and 5 - The node agent starts a number of JVMs equal to the specified value in parallel.
Note: With this property you can only start a maximum of 5 servers at a time.
Wikipedia
Search results
Sunday, 10 December 2017
Important question and answers for Websphere Application server
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment