Enable the Runtime Performance Advisor tool using scripting
Overview
The Runtime Performance Advisor tool provides advice to help tune systems for optimal performance. One can configure the Runtime Performance Advisor using...
The recommendations display as text in the SystemOut.log file.
The Runtime Performance Advisor (RPA) requires that the Performance Monitoring Service (PMI) is enabled. It does not require that individual counters be enabled. When a counter that is needed by the RPA is not enabled, the RPA will enable it automatically.
There is no MBean/object available for wsadmin to create a RPA configuration. Use wsadmin to change the settings and make them effective at runtime. These changes will not be persisted. The changes remain until you stop the server. Since the RPA is disabled once you stop the server, you may want to disable the PMI Service or the counters that were enabled while it was active. We can enable the following counters using the Runtime Performance Advisor
ThreadPools (module) Web Container (module) Pool Size Active Threads Object Request Broker (module) Pool Size Active Threads JDBC Connection Pools (module) Pool Size Percent used Prepared Statement Discards Servlet Session Manager (module) External Read Size External Write Size External Read Time External Write Time No Room For New Session System Data (module) CPU Utilization Free MemoryThe following provides an explanation for some of the settings that use:
Calculation interval PMI data The calculation interval specifies the length of the time over which data is taken for this advice. Details within the advice messages will appear as averages over this interval. Maximum warning sequence Number of consecutive warnings issued before the threshold is relaxed. For example, if the maximum warning sequence is set to 3, then the advisor only sends three warnings to indicate that the prepared statement cache is overflowing. After that, a new alert is only issued if the rate of discards exceeds the new threshold setting. Number of processors Number of processors on the server. Critical in order to ensure accurate advice for the specific configuration of the system.
To enable the Runtime Performance Advisor tool using the wsadmin tool, perform the following steps:
Enable the Performance Monitoring Service (PMI)
set s1 [$AdminConfig getid /Node:node1/Server:server1/] server1(cells/cell1/nodes/node1/servers/server1:server.xml#Server_1)
set PMI1 [$AdminConfig list PMIService $s1](cells/cell1/nodes/node1/servers/server1:server.xml#PMIService_1)
$AdminConfig modify $PMI1 {{enable true}{initialSpecLevelbeanModule=H:cacheModule=H:connectionPoolModule=H:j2cModule=H:jvmRuntimeModule=H:orbPerfModule=H:servletSessionsModule=H:systemModule=H:threadPoolModule=H:transactionModule=H:webAppModule=H:webServicesModule=H:wlmModule=H:wsgwModule=H}}
$AdminConfig save
s1 = AdminConfig.getid('/Node:node1/Server:server1/', '[server1(cells/cell1/nodes/node1/servers/server1:server.xml#Server_1)]')
print s1
PMI1 = AdminConfig.list('PMIService', s1, 'cells/cell1/nodes/node1/servers/server1:server.xml#PMIService_1')
print PMI1
AdminConfig.modify(PMI1, [['enable', 'true'], ['initialSpecLevel', 'beanModule=H:cacheModule=H:connectionPoolModule=H:j2cModule=H:jvmRuntimeModule=H:orbPerfModule=H:servletSessionsModule=H:systemModule=H:threadPoolModule=H:transactionModule=H:webAppModule=H:webServicesModule=H:wlmModule=H:wsgwModule=H']])
AdminConfig.save()
Setup the Runtime Performance Advisor (RPA)
set perf [$AdminControl queryNames mbeanIdentifier=ServerRuleDriverMBean,process=server1,*]
$AdminControl setAttribute $perf {{enable true}}
$AdminControl invoke $perf reInit
$AdminConfig save
perf = AdminControl.queryNames('mbeanIdentifier=ServerRuleDriverMBean,process=server1,*')
AdminControl.setAttribute(perf, [['enabled', 'true']])
AdminControl.invoke(perf, 'reInit')
AdminConfig.save()
What to do next
After completing the previous steps, start the server and monitor RPA.
See Also
AdminControl object for scripted administration
See Also
Commands for the AdminControl object
Related Information
Using the Runtime Performance Advisor