This discussion is archived
2 Replies Latest reply: Nov 21, 2012 11:28 PM by 671265 RSS

ECM data collection failed with error "Failed to execute pre-load ..."

671265 Newbie
Currently Being Moderated
Hey all,

I am encounter a very strange question. I have code a ECM metric for my mongo database plugin. After deployed it to EM, even though the data collection was all right (from checking Agent browser and upload folder on agent server) and the ECM table was created after the plugin deployed, the data was load into ECM table failed.

Here is the definition of XML.
--- targetType
  <Metric NAME="CheckServiceConf" TYPE="RAW" CONFIG="TRUE">
    <Display>
      <Label NLSID="omd_ecm_checkserviceconf">CheckServiceConf</Label>
    </Display>
    <TableDescriptor TABLE_NAME="MGMT_EMX_MONGO_SERVICE_CONF">
      <ColumnDescriptor NAME="Host_Name" COLUMN_NAME="HOST_NAME" TYPE="STRING" IS_KEY="TRUE" />
      <ColumnDescriptor NAME="Port" COLUMN_NAME="PORT" TYPE="NUMBER" IS_KEY="TRUE" />
      <ColumnDescriptor NAME="Config_File" COLUMN_NAME="CONFIG_FILE" TYPE="STRING" IS_KEY="FALSE" />
      <ColumnDescriptor NAME="Data_Path" COLUMN_NAME="DATA_PATH" TYPE="STRING" IS_KEY="FALSE" />
      <ColumnDescriptor NAME="Log_File" COLUMN_NAME="LOG_FILE" TYPE="STRING" IS_KEY="FALSE" />
      <ColumnDescriptor NAME="Is_Sharding_Server" COLUMN_NAME="IS_SHARDING_SERVER" TYPE="STRING" IS_KEY="FALSE" />
      <ColumnDescriptor NAME="Replication_Set_Name" COLUMN_NAME="REPLICATION_SET_NAME" TYPE="STRING" IS_KEY="FALSE" />
      <ColumnDescriptor NAME="Is_Config_Server" COLUMN_NAME="IS_CONFIG_SERVER" TYPE="STRING" IS_KEY="FALSE" />
      <ColumnDescriptor NAME="List_of_Config_Servers" COLUMN_NAME="LIST_OF_CONFIG_SERVERS" TYPE="STRING" IS_KEY="FALSE" />
      <ColumnDescriptor NAME="Max_Connections" COLUMN_NAME="MAX_CONNECTIONS" TYPE="NUMBER" IS_KEY="FALSE" />
      <ColumnDescriptor NAME="Oplog_Size" COLUMN_NAME="OPLOG_SIZE" TYPE="NUMBER" IS_KEY="FALSE" />
      <ColumnDescriptor NAME="Instance_Version" COLUMN_NAME="INSTANCE_VERSION" TYPE="STRING" IS_KEY="FALSE" />
      <ColumnDescriptor NAME="OS_Process" COLUMN_NAME="OS_PROCESS" TYPE="STRING" IS_KEY="FALSE" />
      <ColumnDescriptor NAME="OS_Process_ID" COLUMN_NAME="OS_PROCESS_ID" TYPE="NUMBER" IS_KEY="FALSE" />
    </TableDescriptor>
    <QueryDescriptor FETCHLET_ID="OSLineToken">
      <Property NAME="emdRoot" SCOPE="SYSTEMGLOBAL">emdRoot</Property>
      <Property NAME="scriptsDir" SCOPE="SYSTEMGLOBAL">scriptsDir</Property>
      <Property NAME="perlBin" SCOPE="SYSTEMGLOBAL">perlBin</Property>
      <Property NAME="host" SCOPE="INSTANCE" OPTIONAL="TRUE">host</Property>
      <Property NAME="port" SCOPE="INSTANCE" OPTIONAL="TRUE">port</Property>
      <Property NAME="uname" SCOPE="INSTANCE" OPTIONAL="TRUE">uname</Property>
      <Property NAME="pass" SCOPE="INSTANCE" OPTIONAL="TRUE">pass</Property>

      <Property NAME="mydelimiter" SCOPE="INSTANCE">mydelimiter</Property>
      <Property NAME="command" SCOPE="GLOBAL">"/usr/bin/perl" -I "%scriptsDir%/emx/%TYPE%" "%scriptsDir%/emx/%TYPE%/CheckServiceConf.pl" "%host%" "%port%" "%uname%" "%pass%" "%mydelimiter%"</Property>
      <Property NAME="delimiter" SCOPE="GLOBAL">%mydelimiter%</Property>
      <Property NAME="startsWith" SCOPE="GLOBAL">em_result=</Property>
      <Property NAME="errStartsWith" SCOPE="GLOBAL">em_error=</Property>
      <Property NAME="em_metric_timeout" SCOPE="GLOBAL">300</Property>
    </QueryDescriptor>
  </Metric>
--- collection metadata
  <CollectionItem NAME="CheckServiceConf" UPLOAD_ON_FETCH="TRUE" CONFIG="TRUE">
    <Schedule OFFSET_TYPE="INCREMENTAL">
      <IntervalSchedule INTERVAL="12" TIME_UNIT="Hr" />
    </Schedule>
    <MetricColl NAME="CheckServiceConf" />
  </CollectionItem>
--- snapshot type metadata
<METADATAS>
  <METADATA SNAP_TYPE="CHECK_SERVICE_CONF" TARGET_TYPE="mongo_database" VER="1" COMPARE_IGNORE="N" COMPARE_UI_IGNORE="N" HISTORY_IGNORE="N" HISTORY_UI_IGNORE="N" UI_IGNORE="N" DROP_EXISTING_DATA="Y">
    <METADATA_UI_NAME>CheckServiceConf</METADATA_UI_NAME>
    <TABLE NAME="MGMT_EMX_MONGO_SERVICE_CONF">
    <UI_NAME>CheckServiceConf</UI_NAME>
      <COLUMN NAME="HOST_NAME" TYPE="STRING" TYPE_FORMAT="512" IS_KEY="Y" >HOST_NAME</COLUMN>
      <COLUMN NAME="PORT" TYPE="NUMBER" IS_KEY="Y" >PORT</COLUMN>
      <COLUMN NAME="CONFIG_FILE" TYPE="STRING" TYPE_FORMAT="512" IS_KEY="N" >CONFIG_FILE</COLUMN>
      <COLUMN NAME="DATA_PATH" TYPE="STRING" TYPE_FORMAT="512" IS_KEY="N" >DATA_PATH</COLUMN>
      <COLUMN NAME="LOG_FILE" TYPE="STRING" TYPE_FORMAT="512" IS_KEY="N" >LOG_FILE</COLUMN>
      <COLUMN NAME="IS_SHARDING_SERVER" TYPE="STRING" TYPE_FORMAT="64" IS_KEY="N" >IS_SHARDING_SERVER</COLUMN>
      <COLUMN NAME="REPLICATION_SET_NAME" TYPE="STRING" TYPE_FORMAT="64" IS_KEY="N" >REPLICATION_SET_NAME</COLUMN>
      <COLUMN NAME="IS_CONFIG_SERVER" TYPE="STRING" TYPE_FORMAT="64" IS_KEY="N" >IS_CONFIG_SERVER</COLUMN>
      <COLUMN NAME="LIST_OF_CONFIG_SERVERS" TYPE="STRING" TYPE_FORMAT="64" IS_KEY="N" >LIST_OF_CONFIG_SERVERS</COLUMN>
      <COLUMN NAME="MAX_CONNECTIONS" TYPE="NUMBER" IS_KEY="N" >MAX_CONNECTIONS</COLUMN>
      <COLUMN NAME="OPLOG_SIZE" TYPE="NUMBER" IS_KEY="N" >OPLOG_SIZE</COLUMN>
      <COLUMN NAME="INSTANCE_VERSION" TYPE="STRING" TYPE_FORMAT="64" IS_KEY="N" >INSTANCE_VERSION</COLUMN>
      <COLUMN NAME="OS_PROCESS" TYPE="STRING" TYPE_FORMAT="64" IS_KEY="N" >OS_PROCESS</COLUMN>
      <COLUMN NAME="OS_PROCESS_ID" TYPE="NUMBER" IS_KEY="N" >OS_PROCESS_ID</COLUMN>
    </TABLE>
  </METADATA>

</METADATAS>
After adding target to em, the errors appeared in emoms_pbs.log on OMS server
2012-11-09 16:08:13,114 [GCLoader[uploadonfetch] - https://ph-10-10-59-224.cp.no.sohu.com:3872/emd/main/] ERROR
 gcloader.CallbackInterface logp.251 - Failed to execute pre-load for: 
Target Id       :CDE026FD2C446D2AE043E19D0B0AA2B6
Collection Name :CheckServiceConf
Agent Url       :https://ph-10-10-59-224.cp.no.sohu.com:3872/emd/main/
version         :1.0
metadata version:2.0
oracle.sysman.eml.ecm.track.RepositoryOperationException: executePreLoad: Config metadata not found: 
collectionName   : CheckServiceConf
targetGuid       : CDE026FD2C446D2AE043E19D0B0AA2B6
        at oracle.sysman.eml.ecm.track.EcmConfigData.executePreLoad(EcmConfigData.java:344)
        at oracle.sysman.core.pbs.gcloader.CallbackInterface.executePreLoad(CallbackInterface.java:245)
        at oracle.sysman.core.pbs.gcloader.DataLoader.executePreLoad(DataLoader.java:1185)
        at oracle.sysman.core.pbs.gcloader.DataLoader.loadDataImpl(DataLoader.java:920)
        at oracle.sysman.core.pbs.gcloader.XMLDocumentDataParser.endElement(XMLDocumentDataParser.java:400)
        at oracle.xml.parser.v2.NonValidatingParser.parseElement(NonValidatingParser.java:1359)
        at oracle.xml.parser.v2.NonValidatingParser.parseRootElement(NonValidatingParser.java:376)
        at oracle.xml.parser.v2.NonValidatingParser.parseDocument(NonValidatingParser.java:322)
        at oracle.xml.parser.v2.XMLParser.parse(XMLParser.java:226)
        at oracle.sysman.core.pbs.gcloader.XMLDocumentDataParser.split(XMLDocumentDataParser.java:148)
        at oracle.sysman.core.pbs.gcloader.DataLoader.loadDataCollection(DataLoader.java:439)
        at oracle.sysman.core.pbs.gcloader.RequestMapper.processDataCollection(RequestMapper.java:200)
        at oracle.sysman.core.pbs.gcloader.RequestMapper.processAll(RequestMapper.java:154)
        at oracle.sysman.core.pbs.gcloader.Receiver.processFile(Receiver.java:1487)
        at oracle.sysman.core.pbs.gcloader.Receiver.doPost(Receiver.java:1309)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
        at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:227)
        at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:125)
        at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:300)
        at weblogic.servlet.internal.TailFilter.doFilter(TailFilter.java:26)
        at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
        at oracle.sysman.core.pbs.app.ContextInitFilter.doFilter(ContextInitFilter.java:113)
        at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
        at oracle.security.jps.ee.http.JpsAbsFilter$1.run(JpsAbsFilter.java:111)
        at java.security.AccessController.doPrivileged(Native Method)
        at oracle.security.jps.util.JpsSubject.doAsPrivileged(JpsSubject.java:313)
        at oracle.security.jps.ee.util.JpsPlatformUtil.runJaasMode(JpsPlatformUtil.java:413)
        at oracle.security.jps.ee.http.JpsAbsFilter.runJaasMode(JpsAbsFilter.java:94)
        at oracle.security.jps.ee.http.JpsAbsFilter.doFilter(JpsAbsFilter.java:161)
        at oracle.security.jps.ee.http.JpsFilter.doFilter(JpsFilter.java:71)
        at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
        at oracle.dms.servlet.DMSServletFilter.doFilter(DMSServletFilter.java:136)
        at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
        at weblogic.servlet.internal.RequestEventsFilter.doFilter(RequestEventsFilter.java:27)
        at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
        at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.wrapRun(WebAppServletContext.
java:3715)
        at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java
:3681)
        at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
        at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:120)
        at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2277)
        at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:2183)
        at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1454)
        at weblogic.work.ExecuteThread.execute(ExecuteThread.java:209)
        at weblogic.work.ExecuteThread.run(ExecuteThread.java:178)
I am really confused with the error message and have no idea how to fix it.
Could anyone give any hints? Thank you in advanced!

Best wishes,
Satine

Legend

  • Correct Answers - 10 points
  • Helpful Answers - 5 points