# SCxplr.ctl: Oracle Explorer collection # $Id: SCxplr.ctl,v 1.4 2015/01/07 19:38:54 RDA Exp $ # ARCS: $Header: /home/cvs/cvs/RDA_8/src/scripting/lib/collect/EXPLORER/SCxplr.ctl,v 1.4 2015/01/07 19:38:54 RDA Exp $ # # Change History # 20141212 LDE Define the refresh section. =head1 NAME SCxplr - Performs an Oracle Explorer collection =head1 DESCRIPTION -XRda start XPLR [-t] [-R] [...] This start scenario creates the collector inside the target directory, performs the discovery, setup, and collection of Oracle Explorer. It also converts the collection result to Explorer format and packages the collection result in ZIP format. It selects the C, C, and C RDA data collection modules per default. You can specify extra RDA modules as arguments. It renders the RDA reports when the C<-R> option is present. =cut use Content options Rt: =head1 RELOCATE SECTION Creates the result directory structure and relocates the collector inside the new structure. =cut section relocate # Determine the result name if ?${CMD.HOSTID} var ($hid) = match(first(command(last)),'^(\w+)$') var ${RUN.PACKAGE.T_EXPLORER} = $nam = \ join('_','explorer',$hid,${RDA.T_NODE},gmtime('%Y_%m_%d_%H_%M')) # Determine the relocation directory if ?testDir('e',$top = catDir(nvl($opt{'t'},getGroup('D_CWD')),$nam)) die A,"Directory ${VAR.top} already exists" return catDir($top,'rda','work') =head1 START SECTION Performs the initial discovery and the whole Oracle Explorer collection. =cut section start # Define the result name var ${COL.PACKAGE.T_EXPLORER} = ${RUN.PACKAGE.T_EXPLORER} # Define the input and profile targets debug " Define the input and profile targets" loop $tgt ($[COL]->get_targets) call defineTarget($tgt) # Perform the automated creation of the collector definition file debug ' Set up the Oracle Explorer collection' call $[COL]->add_setup(['OS'],true,false,'NET','OS') var $flg = $[COL]->set_isolated(true) call $[COL]->end_setup(true) call $[COL]->set_isolated($flg) # Allow to set up extra modules interactively call $[COL]->add_setup(undef,true,false,@arg) call $[COL]->add_setup(['EXPLORER'],true,false,'XPLR') call $[COL]->end_setup(true) # Define the post treatment if $opt{'R'} {var ${COL.RENDER.B_RENDER} = true var ${SET.EXPLORER.T_POST_COLLECT} = 'EXPLORER:XPLRpost-render-convert-package' } else var ${SET.EXPLORER.T_POST_COLLECT} = 'EXPLORER:XPLRpost-convert-package' # Perform the collection debug ' Perform the Oracle Explorer collection' call $[COL]->add_collect(undef,$[COL]->get_pending) call $[COL]->end_collect(true) =head1 REFRESH SECTION Refreshes the collector definition. =cut section refresh # Perform non-interactive setup of the modules on the setup-queue var $flg = $[COL]->set_isolated(true) call $[COL]->end_setup(true) call $[COL]->set_isolated($flg) # Define the post treatment var ${SET.EXPLORER.T_POST_COLLECT} = \ cond(${COL.RENDER.B_RENDER},'EXPLORER:XPLRpost-render-convert-package',\ 'EXPLORER:XPLRpost-convert-package') # Perform the collection debug ' Perform the Oracle Explorer collection' call $[COL]->add_collect(undef,$[COL]->get_modules) call $[COL]->end_collect(true) =head1 COPYRIGHT NOTICE Copyright (c) 2002, 2016, 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