# S572EPMA.def: Collects Enterprise Performance Management Architect Information # $Id: S572EPMA.def,v 2.26 2012/09/04 11:53:21 mschenke Exp $ # ARCS: $Header: /home/cvs/cvs/RDA_4/src/scripting/lib/modules/S572EPMA.def,v 2.26 2012/09/04 11:53:21 mschenke Exp $ # # Change History # 20120904 KRA Improve EPMA events pattern matching. =head1 NAME S572EPMA - Collects Oracle Hyperion Enterprise Performance Management Architect Information =head1 DESCRIPTION This module collects information for Oracle Hyperion Enterprise Performance Management Architect (EPMA). The following reports can be generated and is regrouped under C, where $BPMA represents F<$EPM_HOME/products/Foundation/BPMA>: =cut use Buffer use Xml echo tput('bold'),'Processing EPMA module ...',tput('off') # Initialization # Initialization var $EPM_HOME = ${EPM_HOME:${ENV.EPM_ORACLE_HOME:${ENV.HYPERION_HOME:''}}} var $EPMA_REQUESTS = ${EPMA_REQUESTS} var $TAIL = getSetting('EPMA_TAIL',5000) var $AGE = getSetting('EPMA_LOG_AGE',15) var $BPMA = catDir($EPM_HOME,'products','Foundation','BPMA') var $TOC = '%TOC%' var $TOP = '[[#Top][Back to top]]' pretoc '1:Performance Management Architect' # Validate the time settings var $START_TIME = trim(getSetting('EPMA_START_TIME',''),'-') var $END_TIME = trim(getSetting('EPMA_END_TIME',''),'-') var $pat = '^([0-3]\d\-[A-Za-z]{3}\-[12]\d{3}_[0-2]\d:[0-5]\d)?$' if !match($START_TIME,$pat) {echo 'Start time format should be DD-Mon-YYYY_HH24:MI. Task audit and \ HsvEventLog information information will be gathered for the last 14 \ days.' var $START_TIME = '' } if !match($END_TIME,$pat) {echo 'End time format should be DD-Mon-YYYY_HH24:MI. Task audit and \ HsvEventLog information information will be gathered from ',\ nvl($START_TIME,'last 14 days'),' to the current time' var $END_TIME = '' } # Load the common library run library() run INSTinfo() =head2 dbver - Generic Database Information Collects generic information for Enterprise Performance Management Architect from an Oracle Database. =cut if getSetting('EPMA_DB') {run DBinfo() # Change the database context if getSetting('EPMA_LOCAL') {var $sid = getSetting('ORACLE_SID') var $usr = getSetting('SQL_LOGIN') } elsif getSetting('EPMA_SID') {var $sid = last var $usr = uc(getSetting('EPMA_LOGIN','EPMA')) # Determine the user password if compare('eq',$usr,'/') var ($usr,$pwd) = ('','') elsif hasSqlPassword($usr,$sid) var $pwd = undef else var $pwd = askPassword(concat('Enter ',$usr,'@',$sid,' user password:')) # Change the current user var $old = setSqlLogin($usr,$pwd,$sid) # If requested, change the database context if getSetting('EPMA_SWITCH') var $env = setSqlSid($sid) else var $env = undef var $try = setSqlFailure(0) } else {# Disable the database access var $env = undef var $old = setSqlLogin('','') var $try = setSqlFailure(-1) } # Test the database connection and collect information debug ' Inside EPMA module, getting generic database information' report epma write '---+!! Generic Database Information' toc '2:[[',getFile(),'][rda_report][Generic Database Information]]' if testSql() {echo '' echo tput('bold'),\ 'The schema containing EPMA repository is not accessible.',tput('off') if $msg = getSqlMessage() {echo $msg } echo '' write 'EPMA repository not accessible (',$msg,')' } else {# Display Oracle version set $sql {SELECT '|' || v.banner || '|' " FROM v$version v; } prefix {write '---+ Oracle Database Versions from V$Version' write '|*Banner*|' } call writeSql($sql) =head2 xmldocs - XML Documents Collects XML documents from an Oracle Database for a specified time period. When the time period is not correctly specified, it collects XML documents from the last 14 days. =cut debug ' Inside EPMA module, getting XML documents' report xmldocs set $sql {SET serveroutput on size 1000000 "SET LONG 100000000 "DECLARE " l_lgt NUMBER; " l_off NUMBER; " CURSOR C1 IS " SELECT job_id, " start_date, " attachment_id, " name, " sequence_id, " REPLACE(REPLACE(REPLACE(REPLACE(REPLACE(REPLACE(REPLACE( " LTRIM(attachment_value), " '|','|'), " ']',']'), " '[','['), " '<','<'), " '>','>'), " CHR(10),'%BR%'), " ' ',' ') attachment_value " FROM (SELECT job.i_job_id job_id, " to_char(job.d_started,'DD-Mon-YYYY HH24:MI:SS') start_date, " attach.i_attachment_id attachment_id, " attach.c_name name, " batch.i_batch_sequence_id sequence_id, " batch.x_attachment_value attachment_value " FROM jm_job job, " jm_attachment attach, " jm_batch batch " WHERE job.i_job_id = attach.i_job_id " AND job.i_job_id = batch.i_job_id " AND attach.i_attachment_id = batch.i_attachment_id " AND job.d_started >= :1 " AND job.d_started <= :2 " ORDER BY job.d_started DESC); "BEGIN " FOR data IN c1 LOOP " l_lgt := DBMS_LOB.GETLENGTH(data.attachment_value); " l_off := 1; " DBMS_OUTPUT.PUT_LINE('[[[' || CHR(10) || " '|' || " data.job_id || '|' || " data.start_date || ' | ' || " data.attachment_id || '|' || " data.name || ' | ' || " data.sequence_id || '|'); " LOOP " EXIT WHEN l_off > l_lgt; " DBMS_OUTPUT.PUT_LINE(DBMS_LOB.SUBSTR(data.attachment_value,255,l_off)); " l_off := l_off + 255; " END LOOP; " DBMS_OUTPUT.PUT_LINE('|' || CHR(10) || ']]]'); " END LOOP; "END; "/ } prefix {write '---+ XML Documents' write $txt write '| *Job ID*|*Start Date*| *Attachment ID*|*Name*| *Sequence ID*|\ *Attachment Value*|' } if $START_TIME {var $beg = concat("TO_DATE('",$START_TIME,"','DD-Mon-YYYY_HH24:MI')") if $END_TIME {var $end = concat("TO_DATE('",$END_TIME,"','DD-Mon-YYYY_HH24:MI')") var $txt = concat(' * Start time: ``',$START_TIME,\ "``\012 * End time: ``",$END_TIME,'``') } else {var $end = 'SYSDATE' var $txt = concat(' * Start time: ``',$START_TIME,\ "``\012 * End time: Current time") } } else {var $beg = 'SYSDATE - 14' var $end = 'SYSDATE' var $txt = ' * From last day' } call writeSql(bindSql($sql,$beg,$end),4) if isCreated(true) {write $TOP toc '2:[[',getFile(),'][rda_report][XML Documents]]' } } # Restore the previous database context if defined($env) call setSqlSid($env) call setSqlFailure($try) call setSqlLogin($old) } =head2 serverconfig - Server Configuration Collect server configuration file F. =cut var $fil = catFile($BPMA,'AppServer','DimensionServer','ServerEngine','bin',\ 'BPMA_Server_Config.xml') if testFile('r',$fil) {report serverconfig prefix {write '---+ Server Configuration' write '---## Information Taken from: ',$fil } call writeFile($fil) if isCreated(true) toc '2:[[',getFile(),'][rda_report][Server Configuration]]' } =head2 deployconfig - Deployment Configuration Collect deployment configuration file F. =cut var $fil = catFile($BPMA,'AppServer','DimensionServer','ServerEngine',\ 'Transformations','FinishedDeploymentDocument.xml') if testFile('r',$fil) {report deployconfig prefix {write '---+ Deployment Configuration' write '---## Information Taken from: ',$fil } call writeFile($fil) if isCreated(true) toc '2:[[',getFile(),'][rda_report][Deployment Configuration]]' } =head2 webconfig - Web Configuration Collect web configuration file F =cut var $fil = catFile($BPMA,'AppServer','DimensionServer','WebService',\ 'web.config') if testFile('r',$fil) {report webconfig prefix {write '---+ Web Configuration' write '---## Information taken from: ',$fil } call writeFile($fil) if isCreated(true) toc '2:[[',getFile(),'][rda_report][Web Configuration]]' } =head2 Executable, Library, and Java Archive Versions For Windows, collects the executable, library, and Java archive versions from F<$BPMA/AppServer/DimensionServer/ServerEngine/bin>. When F is available, it extracts the manifest from Java archives. =cut if or(isWindows(),isCygwin()) {debug ' Inside EPMA module, gathering file versions' pretoc '2:Executable, Library, and Java Archive Versions' macro dsp_versions {var ($rpt,$dir,$lnk,$opt) = @arg import $TOC,$TOP,$UNZIP keep $TOC,$TOP,$UNZIP call $[OUT]->add_report('C',$rpt,0) prefix {write '---+!! Version Information from ',$lnk,' Directory' write $TOC } loop $fil (grepDir($dir,'\.(dll|exe|jar)$',$opt)) {write '---+ Version Information from ',encode(basename($fil)) call statFile('p',$fil) write '%BR%' var $inf = getVersionInfo($fil) loop $key (keys($inf)) write '|*',$key,' *|',replace($inf->{$key},'\012','%BR%',true),' |' write $TOP if and(match($fil,'\.jar$',true),$UNZIP) {prefix write '---++ Manifest Information' call writeCommand(concat($UNZIP,' -p ',$fil,' META-INF/MANIFEST.MF')) if hasOutput(true) write $TOP } } if isCreated(true) toc '4:[[',getFile(),'][rda_report][In ',$lnk,']]' } macro rpt_versions {var ($rpt,$top,$sub) = @arg var $cnt = 0 call dsp_versions($rpt,\ $top,$sub,'dip') loop $fil (grepDir($top,'^\.+$','nv')) {if testDir('d',$dir = catDir($top,$fil)) call dsp_versions(concat($rpt,incr($cnt)),\ $dir,encode(catDir($sub,$fil)),'dir') } } var $UNZIP = findCommand('unzip') pretoc '3:',catDir('$BPMA','AppServer','DimensionServer','ServerEngine') call rpt_versions('ver_epma',\ catDir($BPMA,'AppServer','DimensionServer','ServerEngine','bin'),'bin') unpretoc 2 } =head2 metadata - Metadata Information Collects all files from F<$BPMA/AppServer/DimensionServer/ServerEngine/metadataOnly> directory. =cut report metadata debug ' Inside EPMA, getting metadata information' prefix {write '---+ Metadata Information' write ' * Links point to files that have been collected in their original \ format. Opening them directly in your browser can present \ risks. To prevent them, access the file outside the browser or \ use the link to save them and use an adequate viewer.' write '|*File Name*| *Size*|*Last Modified Date*|' } loop $fil (grepDir(catDir($BPMA,'AppServer','DimensionServer','ServerEngine',\ 'metadataOnly'),'^[^\.]','dr')) {if testFile('fr',$fil) {output d,'system.log' if ${CUR.LAST}->write_data($fil) {write '|[[',${CUR.LAST}->get_file,'][_blank][',encode($fil),']]| ',\ getSize($fil),'|',\ getLastModify($fil,'%d-%b-%Y %H:%M:%S'),' |' } } } if isCreated(true) toc '2:[[',getFile(),'][rda_report][Metadata Information]]' =head2 transform - Transformation Information Collect F<*.xsl>, F and F from F<$BPMA/AppServer/DimensionServer/ServerEngine/Transformations> directory. =cut report transform debug ' Inside EPMA, getting transformation information' prefix {write '---+ Transformation Information' write ' * Links point to files that have been collected in their original \ format. Opening them directly in your browser can present \ risks. To prevent them, access the file outside the browser or \ use the link to save them and use an adequate viewer.' write '|*File Name*| *Size*|*Last Modified Date*|' } loop $fil (grepDir(catDir($BPMA,'AppServer','DimensionServer','ServerEngine',\ 'Transformations'),\ '(\.xsl$|^FinishedDeploymentDocument.*\.xml$|\ ^GenericDeploymentDocument.*\.xml)','dr')) {if testFile('fr',$fil) {output d,'system.log' if ${CUR.LAST}->write_data($fil) {write '|[[',${CUR.LAST}->get_file,'][_blank][',encode($fil),']]| ',\ getSize($fil),'|',\ getLastModify($fil,'%d-%b-%Y %H:%M:%S'),' |' } } } if isCreated(true) toc '2:[[',getFile(),'][rda_report][Transformation Information]]' =head2 eventx - EPMA Events Extracts Enterprise Performance Management Architect events from the application event log using the F command. (Only available for Windows Vista, Windows Server 2008, and Windows 7) =cut if or(isWindows(),isCygwin()) {debug ' Inside EPMA module, getting event log information' var $osv = getRegValue('HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion',\ 'CurrentVersion') if compare('ge',$osv,'6') {if findCommand('wevtutil') {var $evt = last var $msc = expr('*',$AGE,86400000) var $tmp = getTemp('dat') call command(concat($evt,' qe Application ',\ '"/q:*[System[TimeCreated[timediff(@SystemTime) <= ',$msc,\ ']]]" /f:xml > ',quote($tmp,'x'))) code write_data {loop $lin (parseBuffer()) write $lin } report eventx write '---+!! Enterprise Performance Management Architect Events' prefix call beginBlock(true) if createBuffer('EVT','R',$tmp) {call parseReset() call parseBegin('TOP',\ '^','Event') call parseEnd('Event','.*$') call parseInfo('Event','buf',-1) call parseInfo('Event','end',&write_data) call parseInfo('Event','llp',false) call parse('EVT') call deleteBuffer('EVT') } if hasOutput(true) call endBlock(['C','wevtutil qe Application | grep -i [EB]PMA']) else write '**No Enterprise Performance Management Architect events found.**%BR%' toc '2:[[',getFile(),'][rda_report][EPMA Events]]' call unlinkTemp('dat') } } =head2 events - EPMA Events Extracts Enterprise Performance Management Architect events from the application event log. (Only available for Windows NT, Windows 2000, Windows XP, and Windows 2003) =cut else {# Get the event file var $fil = replaceEnv(getRegValue(\ 'HKLM\SYSTEM\CurrentControlSet\Services\EventLog\Application',\ 'File')) # If the file is not readable try to copy to a temporary file var $flg = false if testFile('r',$fil) {var $evt = $fil } else {if testFile('f',$cmd = getGroupFile('D_CWD','cmd.exe')) {var $cmd = quote($cmd,'x') if grepCommand(concat($cmd,' /c if exist mode.com echo 32to64'),'^32to64') {var $flg = true var $evt = getTemp('evt','.evt') call system(concat($cmd,' /c copy ',\ quote($fil,'x'),' ',\ quote($evt,'x'),' >NUL 2>NUL')) } } } # Extract the Performance Management Architect events if testFile('r',$evt) {report events write '---+ Application Events' if !writeEvents($evt,'[EeBb][Pp][Mm][Aa]',$AGE) write '**No Enterprise Performance Management Architect events found.**%BR%' toc '2:[[',getFile(),'][rda_report][EPMA Events]]' } if $flg call unlinkTemp('evt') } } =head2 synclogs - Synchronization Log Files Collects the synchronization log files from F<$EPM_HOME/logs/services> directory. =cut report synclogs var $log = catDir($EPM_HOME,'logs','services') prefix {write '---+!! Web and Data Synchronization Log Files' write '---## From: ',$log write ' * Last ',$TAIL,' lines from the log files captured' write ' * Links point to files that have been collected in their original \ format. Opening them directly in your browser can present \ risks. To prevent them, access the file outside the browser or \ use the link to save them and use an adequate viewer.' write '|*File Name*| *Size*|*Last Modified Date*|' } loop $fil (grepDir($log,'\.log$','irt')) {if $buf = new('Buffer','r',$fil) {var $lnk = encode($fil) var $siz = getSize($fil) if $siz {output d,concat('L_',basename($fil)) if ${CUR.LAST}->write_tail($buf,$TAIL,['F',$fil,'T','T']) var $lnk = concat('[[',${CUR.LAST}->get_file,'][_blank][',$lnk,']]') end ${CUR.LAST} } write '|',$lnk,' | ',$siz,'|',\ getLastModify($fil,'%d-%b-%Y %H:%M:%S'),' |' } } if isCreated(true) toc '2:[[',getFile(),'][rda_report][Synchronization Log Files]]' =head2 EPMA Log Files Gathers Enterprise Performance Management Architect log files. =cut debug ' Inside EPMA module, gathering EPMA log files' pretoc '2:EPMA Log Files' call sort_files(3,$TAIL,\ catFile($EPM_HOME,'logs','epma.log'),\ catFile($EPM_HOME,'logs','epma_err.log'),\ catFile($EPM_HOME,'logs','epma','epma.log'),\ catFile($EPM_HOME,'logs','epma','epma_err.log'),\ catFile($EPM_HOME,'logs','Shared_Services_Client.log'),\ catFile($EPM_HOME,'logs','services',\ 'HyS9EPMADataSynchronizer-syserr.log'),\ catFile($EPM_HOME,'logs','services',\ 'HyS9EPMADataSynchronizer-sysout.log'),\ catFile($EPM_HOME,'logs','services','HyS9EPMAWebTier-syserr.log'),\ catFile($EPM_HOME,'logs','services','HyS9EPMAWebTier-sysout.log')) unpretoc =head2 IIS Log Files For Windows, gathers recent Internet Information Services (IIS) log files. This is applicable for IIS version 6 or 7 only. =cut if or(isWindows(),isCygwin()) {debug ' Inside EPMA module, gathering recent IIS log files' # Get SystemRoot if getEnv('SystemRoot') var $dir = last else var ($dir) = command('echo %SystemRoot%') # Get IIS version if hasRegOption() {if getReg64Value('HKLM\SOFTWARE\Microsoft\InetMgr\Parameters','MajorVersion') var $ver = hex2dec(last) elsif getReg32Value('HKLM\SOFTWARE\Microsoft\InetMgr\Parameters',\ 'MajorVersion') var $ver = hex2dec(last) } elsif getRegValue('HKLM\SOFTWARE\Microsoft\InetMgr\Parameters','MajorVersion') var $ver = hex2dec(last) elsif getRegValue('HKLM\SOFTWARE\Wow6432Node\Microsoft\InetMgr\Parameters',\ 'MajorVersion') var $ver = hex2dec(last) # Determine the IIS log directory var $log if expr('==',$ver,6) {if or(testFile('r',catFile($dir,'system32','inetsrv','MetaBase.xml')),\ testFile('r',catFile($dir,'Sysnative','inetsrv','MetaBase.xml'))) {var $xml = xmlLoadFile(lastFile(),xmlDisable(xmlParser(),'DR')) if $xml->find('.../IIsWebServer')->get_value('LogFileDirectory') var $log = catDir(last,'W3SVC1') elsif $xml->find('.../IIsWebService')->get_value('LogFileDirectory') var $log = catDir(last,'W3SVC1') } elsif testFile('f',$cmd = getGroupFile('D_CWD','cmd.exe')) {var $fil = catFile($dir,'system32','inetsrv','MetaBase.xml') var $xml = xmlLoadCommand(concat(quote($cmd,'x'),' /c type "',$fil,'"'),\ xmlDisable(xmlParser(),'DR')) if $xml->find('.../IIsWebServer')->get_value('LogFileDirectory') var $log = catDir(last,'W3SVC1') elsif $xml->find('.../IIsWebService')->get_value('LogFileDirectory') var $log = catDir(last,'W3SVC1') } if !$log {if or(testDir('d',catDir($dir,'system32','LogFiles','W3SVC1')),\ testDir('d',catDir($dir,'Sysnative','LogFiles','W3SVC1'))) var $log = lastDir() } } elsif expr('==',$ver,7) {if or(testFile('r',catFile($dir,'system32','inetsrv',\ 'Applicationhost.config')),\ testFile('r',catFile($dir,'Sysnative','inetsrv',\ 'Applicationhost.config')),\ testFile('r',catFile($dir,'system32','inetsrv','config',\ 'Applicationhost.config')),\ testFile('r',catFile($dir,'Sysnative','inetsrv','config',\ 'Applicationhost.config'))) {var $xml = xmlLoadFile(lastFile(),xmlDisable(xmlParser(),'DR')) if $xml->find('.../logFile')->get_value('directory') var $log = catDir(replaceEnv(last)) elsif $xml->find('.../log/centralW3CLogFile')->get_value('directory') var $log = catDir(replaceEnv(last)) if testDir('d',catDir($log,'W3SVC1')) var $log = lastDir() } elsif testFile('f',$cmd = getGroupFile('D_CWD','cmd.exe')) {loop $fil (catFile($dir,'system32','inetsrv','Applicationhost.config'),\ catFile($dir,'system32','inetsrv','config','Applicationhost.config')) {var $xml = xmlLoadCommand(concat(quote($cmd,'x'),' /c type "',$fil,'"'),\ xmlDisable(xmlParser(),'DR')) next xmlStatCommand() if $xml->find('.../log/centralW3CLogFile')->get_value('directory') var $log = catDir(replaceEnv(last)) elsif $xml->find('.../logFile')->get_value('directory') var $log = catDir(replaceEnv(last)) if testDir('d',catDir($log,'W3SVC1')) var $log = lastDir() break } } if !$log {if or(testDir('d',catDir($dir,'system32','inetpub','logs','LogFiles')),\ testDir('d',catDir($dir,'Sysnative','inetpub','logs','LogFiles'))) var $log = lastDir() } } # Collect recent log files if $log {report iislog prefix {write '---+!! IIS Log Files' write '---## From: ',$log write ' * Limited to last ',$AGE,' days' write ' * Links point to files that have been collected in their original \ format. Opening them directly in your browser can present \ risks. To prevent them, access the file outside the browser or \ use the link to save them and use an adequate viewer.' write '|*File Name*| *Size*|*Last Modified Date*|' } loop $fil (grepDir($log,'\.log$','ipt')) {break isOlder($fil,$AGE) if $buf = new('Buffer','r',$fil) {var $lnk = encode($fil) var $siz = getSize($fil) if $siz {output d,basename($fil) if ${CUR.LAST}->write_tail($buf,$TAIL,['F',$fil,'T','T']) var $lnk = concat('[[',${CUR.LAST}->get_file,'][_blank][',$lnk,']]') end ${CUR.LAST} } write '|',$lnk,' | ',$siz,'|',\ getLastModify($fil,'%d-%b-%Y %H:%M:%S'),' |' } } if isCreated(true) toc '2:[[',getFile(),'][rda_report][IIS Log Files]]' } } =head2 Application Server Log Files Gathers application server log files. =cut debug ' Inside EPMA module, gathering Application Server log files' pretoc '2:Application Server Log Files' call sort_files(3,$TAIL,\ grepDir(catDir($EPM_HOME,'deployments','WebSphere6','profile',\ 'logs','EPMAWebServer'),'\.log$','p'),\ grepDir(catDir($EPM_HOME,'deployments','WebSphere6','profile',\ 'logs','EPMADataSynchronizer'),'\.log$','p'),\ grepDir(catDir($EPM_HOME,'deployments','WebLogic9','servers',\ 'EPMADataSynchronizer','logs'),'\.log$','p'),\ grepDir(catDir($EPM_HOME,'deployments','WebLogic9','servers',\ 'EPMAWebServer','logs'),'\.log$','p'),\ grepDir(catDir($EPM_HOME,'deployment','Tomcat5','EPMAWebServer',\ 'logs'),'\.log$','p'),\ grepDir(catDir($EPM_HOME,'deployment','Tomcat5',\ 'EPMADataSynchronizer','logs'),'\.log$','p'),\ grepDir(catDir($EPM_HOME,'deployments','Oracle10g','EPMAWebServer',\ 'applicationdeployments','EPMAWebServer'),\ '^application\.log$','r'),\ grepDir(catDir($EPM_HOME,'deployments','Oracle10g','dataSynchronizer',\ 'applicationdeployments','EPMAdataSynchronizer'),\ '^application\.log$','p')) unpretoc if !?$EPMA_REQUESTS { =head2 Oracle WebLogic Server Information Includes the Oracle WebLogic reports generated by the WREQ module for the associated Oracle WebLogic Server domain (on versions earlier than 11.1.2 having a product registry). =cut if ?${EPMA_DOM_REQ_DOMAIN} {var $dom = basename(last) toc '%PUSH("%SPLIT%")%' toc '%PUSH("1+:Oracle WebLogic Server Overview")%' toc '%INCLUDE("',${CUR.GROUP},'_WREQ_EPMA_TOP.toc")%' toc '%POP2%' toc '%PUSH("%SPLIT%")%' toc '%PUSH("1+:',"'",$dom,"'",' Domain")%' toc '%INCLUDE("',${CUR.GROUP},'_WREQ_EPMA_DOM.toc")%' toc '%POP2%' } } =head1 DEPLOYMENT REPORTS Available on version 11.1.2 and later. =cut else {loop $uid (split('\|',$EPMA_REQUESTS)) {next !$uid var $ins = getSetting(concat('EPMA_HOME',$uid)) call setAbbr(concat('EPMA_i',$uid)) toc '%SPLIT%' toc "1+:'",getSetting(concat('EPMA_INSTANCE',$uid)),"' Deployment" =head2 Configuration Files Collects the logging configuration files from the F<$INSTANCE_HOME/config> directory. =cut debug ' Inside EPMA module, getting the logging configuration files' pretoc '2:Configuration Files' call sort_files(3,0,\ catFile($ins,'config','EPMA','DataSync','dme.properties'),\ catFile($ins,'config','EPMA','DataSync','essbase.properties'),\ catFile($ins,'config','EPMA','DimensionServer','logging.xml'),\ catFile($ins,'config','EPMA','WebTier','AwbConfig.properties')) unpretoc =head2 diaglogs - Diagnostic Log Files Collects the diagnostic log files from F<$INSTANCE_HOME/diagnostics/logs> directory. =cut debug ' Inside EPMA module, getting the diagnostic log files' report diaglogs var $log = catDir($ins,'diagnostics','logs') prefix {write '---+!! Diagnostic Log Files' write '---## From: ',$log write ' * Last ',$TAIL,' lines from the log files captured' write ' * Links point to files that have been collected in their original \ format. Opening them directly in your browser can present \ risks. To prevent them, access the file outside the browser or \ use the link to save them and use an adequate viewer.' write '|*File Name*| *Size*|*Last Modified Date*|' } loop $fil (grepDir($log,'\.log(\.\d+)?$','irt')) {if $buf = new('Buffer','r',$fil) {var $lnk = encode($fil) var $siz = getSize($fil) if $siz {output d,concat('L_',basename($fil)) if ${CUR.LAST}->write_tail($buf,$TAIL,['F',$fil,'T','T']) var $lnk = concat('[[',${CUR.LAST}->get_file,'][_blank][',$lnk,']]') end ${CUR.LAST} } write '|',$lnk,' | ',$siz,'|',\ getLastModify($fil,'%d-%b-%Y %H:%M:%S'),' |' } } if isCreated(true) toc '2:[[',getFile(),'][rda_report][Diagnostic Log Files]]' =head2 Oracle WebLogic Server Information Includes the Oracle WebLogic Server reports generated by the WREQ module for the associated Oracle WebLogic Server domain. =cut if ?getSetting(concat('EPMA_DOM',$uid,'_REQ_DOMAIN')) {var $dom = basename(last) toc '%PUSH("%SPLIT%")%' toc '%PUSH("1++:Oracle WebLogic Server Overview")%' toc '%INCLUDE("',${CUR.GROUP},'_WREQ_EPMA_TOP',$uid,'.toc",1)%' toc '%POP2%' toc '%PUSH("%SPLIT%")%' toc '%PUSH("1++:',"'",$dom,"'",' Domain")%' toc '%INCLUDE("',${CUR.GROUP},'_WREQ_EPMA_DOM',$uid,'.toc",1)%' toc '%POP2%' } } } =head1 SEE ALSO L, L, L =begin credits =over 10 =item RDA 4.18: Sudev Alampalli. =item RDA 4.20: Tony Mitri, Satheesh Naraginti. =item RDA 4.28: Chethan Kopparam. =item RDA 4.29: Sudarshan Subbegowda. =back =end credits =head1 COPYRIGHT NOTICE Copyright (c) 2002, 2012, Oracle and/or its affiliates. All rights reserved. =head1 TRADEMARK NOTICE Oracle and Java are registered trademarks of Oracle and/or its affiliates. Other names may be trademarks of their respective owners. =cut