OEM 代理诊断步骤

OEM 代理诊断步骤
1 确认代理名称,类型

[oracle@ykcdb02:/u01/app/oracle/product/agent/agent_inst/bin]{20180711+0 14:57:26}$ emctl config agent listtargets | egrep "oracle_database|rac_database" 
[scmbdg_scmbdg2, oracle_database]
[scmbdg, rac_database]
[oracle@ykcdb02:/u01/app/oracle/product/agent/agent_inst/bin]{20180711+0 14:57:29}$ 
[oracle@ykcdb02:/u01/app/oracle/product/agent/agent_inst/bin]{20180711+0 14:57:29}$ emctl config agent listtargets | grep oracle_pdb 
[scmbdg_CDBROOT, oracle_pdb]
[scmbdg_SPCMB, oracle_pdb]
[oracle@ykcdb02:/u01/app/oracle/product/agent/agent_inst/bin]{20180711+0 14:58:03}$

2 确认定时任务收集

[oracle@ykcdb02:/u01/app/oracle/product/agent/agent_inst/bin]{20180711+0 14:58:03}$ emctl status agent scheduler|grep pdbResponse_cdb
2018-07-11 14:59:24.260 : rac_database:scmbdg:pdbResponse_cdb
[oracle@ykcdb02:/u01/app/oracle/product/agent/agent_inst/bin]{20180711+0 14:59:23}$
 
--node2 --may be wrong
[oracle@ykcdb02:/u01/app/oracle/product/agent/agent_inst/bin]{20180711+0 14:59:23}$ emctl getmetric agent scmbdg,rac_database,pdbResponse_cdb
Oracle Enterprise Manager Cloud Control 13c Release 2  
Copyright (c) 1996, 2016 Oracle Corporation.  All rights reserved.
pdbName,state_num
[oracle@ykcdb02:/u01/app/oracle/product/agent/agent_inst/bin]{20180711+0 14:59:55}$ 
--node1
[oracle@ykcdb01:/u01/app/oracle/product/agent/agent_inst/bin]{20180711+0 14:52:13}$ emctl getmetric agent scmbdg,rac_database,pdbResponse_cdb
Oracle Enterprise Manager Cloud Control 13c Release 2  
Copyright (c) 1996, 2016 Oracle Corporation.  All rights reserved.
pdbName,state_num
SPCMB,1
CDB$ROOT,1

3,确认度量的定时任务

[oracle@ykcdb02:/u01/app/oracle/product/agent/agent_inst/bin]{20180711+0 15:02:06}$ emctl status agent scheduler | grep pdbResponse_cdb
2018-07-11 15:02:54.358 : rac_database:scmbdg:pdbResponse_cdb
[oracle@ykcdb02:/u01/app/oracle/product/agent/agent_inst/bin]{20180711+0 15:02:40}$

4,确认度量收集是错误

setup/manage cloud control/agents
select the agent which manages the pluggable database and click on it to drill down to the agent home page
expand the 'details' section of the  'monitoring' pane (top right hand side corner)
From the 'metric issues' tab check if any metrics are shown in the 'suspended metrics' section
Check if any metrics are shown in the 'metric errors' section
If no metrics are shown as broken or suspended, but the metric is not scheduled, try running the metric manually (as outlined in the section)

5,upload信息
–Check that the agent is able to upload
emctl upload agent

6,确认状态

[oracle@ykcdb01:/u01/app/oracle/product/agent/agent_inst/bin]{20180711+0 15:08:40}$  emctl status agent target scmbdg,rac_database
Oracle Enterprise Manager Cloud Control 13c Release 2  
Copyright (c) 1996, 2016 Oracle Corporation.  All rights reserved.
---------------------------------------------------------------
Target Name : scmbdg
Target Type : rac_database
Current severity state
----------------------
Metric        Column name             Key             State           Timestamp
--------------------------------------------------------------------------------
ME$DataFile_Status Datafile_Status         SYSTEM,+DATADG/SCMBDG/DATAFILE/system.351.973284511 CLEAR           Wed Jul 11 15:05:32 CST 2018
ME$Recover_Area_Used_Pct Recover_Area_Used_Pct   n/a  CLEAR           Wed Jul 11 15:05:31 CST 2018
ME$Tablespace_Status Status           SYSAUX          CLEAR           Wed Jul 11 15:05:32 CST 2018
ME$Tablespace_Status Status           SYSTEM          CLEAR           Wed Jul 11 15:05:32 CST 2018
ME$Tablespace_Status Status           TEMP            CLEAR           Wed Jul 11 15:05:32 CST 2018
ME$Tablespace_Status Status           UNDOTBS1        CLEAR           Wed Jul 11 15:05:32 CST 2018
ME$Tablespace_Status Status           UNDOTBS2        CLEAR           Wed Jul 11 15:05:32 CST 2018
ME$Tablespace_Status Status           USERS           CLEAR           Wed Jul 11 15:05:32 CST 2018
UserLocks     maxBlockedDBTime        TM              CLEAR           Wed Jul 11 15:05:30 CST 2018
UserLocks     maxBlockedDBTime        TX              CLEAR           Wed Jul 11 15:05:30 CST 2018
UserLocks     maxBlockedDBTime        UL              CLEAR           Wed Jul 11 15:05:30 CST 2018
UserLocks     maxBlockedSess          TM              CLEAR           Wed Jul 11 15:05:30 CST 2018
UserLocks     maxBlockedSess          TX              CLEAR           Wed Jul 11 15:05:30 CST 2018
UserLocks     maxBlockedSess          UL              CLEAR           Wed Jul 11 15:05:30 CST 2018
dataguard_sperf_112 dg_fot            n/a             CLEAR           Wed Jul 11 15:05:31 CST 2018
dataguard_sperf_112 dg_lag            n/a             CLEAR           Wed Jul 11 15:05:31 CST 2018
dataguard_sperf_112 dg_pdl            n/a             CLEAR           Wed Jul 11 15:05:31 CST 2018
observer_11g  ob_status               n/a             CLEAR           Wed Jul 11 15:05:29 CST 2018
---------------------------------------------------------------
Agent is Running and Ready
[oracle@ykcdb01:/u01/app/oracle/product/agent/agent_inst/bin]{20180711+0 15:09:17}$ 
[oracle@ykcdb01:/u01/app/oracle/product/agent/agent_inst/bin]{20180711+0 15:09:17}$ 
[oracle@ykcdb01:/u01/app/oracle/product/agent/agent_inst/bin]{20180711+0 15:09:17}$ 
[oracle@ykcdb01:/u01/app/oracle/product/agent/agent_inst/bin]{20180711+0 15:09:17}$ emctl status agent target scmbdg_SPCMB,oracle_pdb
Oracle Enterprise Manager Cloud Control 13c Release 2  
Copyright (c) 1996, 2016 Oracle Corporation.  All rights reserved.
---------------------------------------------------------------
Target Name : scmbdg_SPCMB
Target Type : oracle_pdb
Current severity state
----------------------
Metric        Column name             Key             State           Timestamp
--------------------------------------------------------------------------------
Response      State                   n/a             CLEAR           Wed Jul 11 15:11:23 CST 2018
Response      Status                  n/a             CLEAR           Wed Jul 11 15:11:23 CST 2018
Temporary_File_Status STATUS          3               CLEAR           Wed Jul 11 15:00:30 CST 2018
dbjob_status  broken                  n/a             CLEAR           Wed Jul 11 15:00:31 CST 2018
dbjob_status  failed                  n/a             CLEAR           Wed Jul 11 15:00:31 CST 2018
 
---------------------------------------------------------------
Agent is Running and Ready
[oracle@ykcdb01:/u01/app/oracle/product/agent/agent_inst/bin]{20180711+0 15:11:24}$ 
how to get-------------------------------------
[oracle@ykcdb02:/u01/app/oracle/product/agent/agent_inst/bin]{20180711+0 15:09:06}$  emctl config agent listtargets|grep pdb
[scmbdg_CDBROOT, oracle_pdb]
[scmbdg_SPCMB, oracle_pdb]

重新上传

[oracle@ykcdb02:/u01/app/oracle/product/agent/agent_inst/bin]{20180711+0 15:16:11}$ emctl clearstate agent orcl12,oracle_database,Response
Oracle Enterprise Manager Cloud Control 13c Release 2  
Copyright (c) 1996, 2016 Oracle Corporation.  All rights reserved.
EMD clearstate failed: the oracle_database target "orcl12" does not exist
[oracle@ykcdb02:/u01/app/oracle/product/agent/agent_inst/bin]{20180711+0 15:16:52}$ emctl clearstate agent scmbdg,rac_database,pdbResponse_cdb
Oracle Enterprise Manager Cloud Control 13c Release 2  
Copyright (c) 1996, 2016 Oracle Corporation.  All rights reserved.
Clear target severity state
[oracle@ykcdb02:/u01/app/oracle/product/agent/agent_inst/bin]{20180711+0 15:17:24}$  emctl status agent target  scmbdg,rac_database
Oracle Enterprise Manager Cloud Control 13c Release 2  
Copyright (c) 1996, 2016 Oracle Corporation.  All rights reserved.
---------------------------------------------------------------
No severities are available for the target
---------------------------------------------------------------
Agent is Running and Ready
[oracle@ykcdb02:/u01/app/oracle/product/agent/agent_inst/bin]{20180711+0 15:17:38}$
This entry was posted in Em & Oem. Bookmark the permalink.