# MCbegin.cfg: Describes the Explorer Data Collection # $Id: MCbegin.cfg,v 1.5 2013/10/30 07:18:24 RDA Exp $ # ARCS: $Header: /home/cvs/cvs/RDA_8/src/scripting/lib/collect/EXPLORER/MCbegin.cfg,v 1.5 2013/10/30 07:18:24 RDA Exp $ # # Copyright (c) 2002, 2016, Oracle and/or its affiliates. All rights reserved. # # Change History # 20131001 KRA Moved advanced setup level to 6. ############################################################################### # Setup information for Initialization of the Explorer Data Collection ############################################################################### #------------------------------------------------------------------------------ # Module definition #------------------------------------------------------------------------------ def="COL/${CUR.K_MODULE}.BEGIN" dsc='Describes the Explorer Data Collection' var=xplr_begin_auto,B_FILTER #------------------------------------------------------------------------------ # Settings definitions #------------------------------------------------------------------------------ [xplr_begin_auto] typ=B dft=${RUN.EXPLORER.N_PID} dsc='Is the information provided by Oracle Explorer?' nam=- var=false:T_CUSTOMER_NAME,T_CONTRACT_ID,T_SERIAL,T_REPLY,T_NOTIFY,\ T_USER_NAME,T_USER_EMAIL,T_PHONE,T_ADDRESS_1,T_ADDRESS_2,\ T_ADDRESS_CITY,T_ADDRESS_STATE,T_ADDRESS_COUNTRY,T_ADDRESS_ZIP,\ T_ADDRESS_COUNTRY_CODE,T_LICENSE,T_SR,T_ESCALATION exe=sdcl { "if ${RUN.EXPLORER.N_PID} "{# Get the information from the Oracle Explorer interface " var ${RUN.EXPLORER.XPLR.BEGIN.F_DEFAULT:'Explorer defaults file'} = \ " catFile(${RUN.EXPLORER.D_ETC},'default','explorer') " var ${T_ADDRESS_1:'Customer contact address'} = \ " ${RUN.EXPLORER.XPLR.BEGIN.T_ADDRESS_1} " var ${T_ADDRESS_2:'Customer contact address (line 2)'} = \ " ${RUN.EXPLORER.XPLR.BEGIN.T_ADDRESS_2} " var ${T_ADDRESS_CITY:'Customer contact city'} = \ " ${RUN.EXPLORER.XPLR.BEGIN.T_ADDRESS_CITY} " var ${T_ADDRESS_COUNTRY:'Customer contact country'} = \ " ${RUN.EXPLORER.XPLR.BEGIN.T_ADDRESS_COUNTRY} " var ${T_ADDRESS_COUNTRY_CODE:'Customer contact country code'} = \ " ${RUN.EXPLORER.XPLR.BEGIN.T_ADDRESS_COUNTRY_CODE} " var ${T_ADDRESS_STATE:'Customer contact state'} = \ " ${RUN.EXPLORER.XPLR.BEGIN.T_ADDRESS_STATE} " var ${T_ADDRESS_ZIP:'Customer contact Zip'} = \ " ${RUN.EXPLORER.XPLR.BEGIN.T_ADDRESS_ZIP} " var ${T_CONTRACT_ID:'Contract ID'} = \ " ${RUN.EXPLORER.XPLR.BEGIN.T_CONTRACT_ID} " var ${T_CUSTOMER_NAME:'Customer name'} = \ " ${RUN.EXPLORER.XPLR.BEGIN.T_CUSTOMER_NAME} " var ${T_LICENSE:'Software license agreement'} = \ " ${RUN.EXPLORER.XPLR.BEGIN.T_LICENSE} " var ${T_NOTIFY:'Email address to notify when explorer data loaded'} = \ " ${RUN.EXPLORER.XPLR.BEGIN.T_NOTIFY} " var ${T_PHONE:'Customer contact phone number'} = \ " ${RUN.EXPLORER.XPLR.BEGIN.T_PHONE} " var ${T_REPLY:'Email address where replies should be sent'} = \ " ${RUN.EXPLORER.XPLR.BEGIN.T_REPLY} " var ${T_SERIAL:'Serial number for host'} = \ " ${RUN.EXPLORER.XPLR.BEGIN.T_SERIAL} " var ${T_USER_EMAIL:'Customer contact Email'} = \ " ${RUN.EXPLORER.XPLR.BEGIN.T_USER_EMAIL} " var ${T_USER_NAME:'Customer contact name'} = \ " ${RUN.EXPLORER.XPLR.BEGIN.T_USER_NAME} "} "elsif ${T_CUSTOMER_NAME/M} "{# Load defaults information when accessible " run EXPLORER:XPLRlib() " if ?${ENV.EXP_CONFIG} " var $fil = catFile(last,'default','explorer') " elsif and(${OS.solaris},expr('<',get_osv(),11)) " var $fil = '/etc/opt/SUNWexplo/default/explorer' " else " var $fil = '/etc/explorer/default/explorer' " if createBuffer('DEFAULT','R',$fil) " {var @sta = getStat($fil) " if !expr('&',$sta[2],077) " {# Parse the default file " var $pat ='^(ADDRESS_(1|2|CITY|COUNTRY(_CODE)?|STATE|ZIP)|CONTRACT_ID|\ " CUSTOMER_NAME|LICENSE|NOTIFY|PHONE|REPLY|USER_(EMAIL|NAME))$' " var $snp = concat('^SERIAL_',command('/usr/bin/hostid')) " while ?getLine('DEFAULT') " {var $lin = chomp(last) " next match($lin,'^\s*#') " var ($key,$val) = split('=',trim($lin),2) " next !?$val " var $key = replace($key,'^EXP_') " if match($key,$snp,true) " var ${T_SERIAL/T} = trim($val,'"') " elsif match($key,$pat) " var ${T_${VAR.key}/T} = trim($val,'"') " } " } " call deleteBuffer('DEFAULT') " } "} } [T_CUSTOMER_NAME] typ=T dsc='Customer name' inp='Enter the company name' [T_CONTRACT_ID] typ=T dsc='Contract ID' inp='Enter Contract ID' [T_SERIAL] typ=T dsc='Serial number for host' inp='Enter the serial number for host' lvl=6 opt=true exe=sdcl { "if ${T_SERIAL/T} "{run EXPLORER:XPLRlib() " if ?get_bin_tool('serial_finder') " var (${AUX.dft}) = command(quote(last)) "} } [T_REPLY] typ=T clr='-' dsc='Email address where replies should be sent' inp='Enter the Email address where replies should be sent' [T_NOTIFY] typ=T clr='-' dsc='Email address to notify when explorer data loaded' inp='Enter the Email address to notify when explorer data loaded' lvl=6 opt=true [T_USER_NAME] typ=T dsc='Customer contact name' inp='Enter the contact name' [T_USER_EMAIL] typ=T clr='-' dsc='Customer contact Email' inp='Enter the contact Email' [T_PHONE] typ=T clr='-' dsc='Customer contact phone number' inp='Enter the contact phone number' [T_ADDRESS_1] typ=T clr='-' dsc='Customer contact address' inp='Enter a first address line' [T_ADDRESS_2] typ=T clr='-' dsc='Customer contact address (line 2)' inp='Enter a second address line' [T_ADDRESS_CITY] typ=T clr='-' dsc='Customer contact city' inp='Enter the city' [T_ADDRESS_STATE] typ=T clr='-' dsc='Customer contact state' inp='Enter the state' [T_ADDRESS_COUNTRY] typ=T clr='-' dsc='Customer contact country' inp='Enter the country' [T_ADDRESS_ZIP] typ=T clr='-' dsc='Customer contact Zip' inp='Enter the Zip code' [T_ADDRESS_COUNTRY_CODE] typ=T clr='-' dsc='Customer contact country code' inp='Enter the country code' [T_LICENSE] typ=T dft=${RDA.T_GMTIME} dsc='Software license agreement' opt=true [T_SR] typ=T clr='-' dsc='Service request' inp='Enter the service request identifier' lvl=6 opt=true [T_ESCALATION] typ=T clr='-' dsc='Escalation number' inp='Enter the escalation number' lvl=6 opt=true [B_FILTER] typ=B dft=false dsc='Can RDA filter the README and defaults reports?' inp='Can RDA filter the README and defaults reports (Y/N)?' lvl=6