Posts

Showing posts from August, 2017

Unregister database from Catalog

Connect to catalog user to find out DBID: C:\Users\Nari>sqlplus rman/recover SQL*Plus: Release 11.2.0.1.0 Production on Fri Aug 25 02:08:33 2017 Copyright (c) 1982, 2010, Oracle.  All rights reserved. Connected to: Oracle Database 12c Enterprise Edition Release 12.1.0.2.0 - 64bit Production With the Partitioning, OLAP, Advanced Analytics and Real Application Testing options SQL>  select DB_NAME,backup_type,incremental_level,bck_typ,status,to_char(completion_time, 'HH24:MI DD-MON-YY') "completion_time" from all_db_backup_status where bck_typ like 'LEVEL%' and DB_NAME='NARI' and completion_time between '03-AUG-17' and '28-AUG-17'  order by completion_time; DB_NAME  B INCREMENTAL_LEVEL BCK_TYP STATUS                  COMPLETIO -------- - ----------------- ------- ----------------------- --------- NARI  I                 0 LEVEL0  COMPLETED               11-AUG-17 NARI  I                 0 LEVEL0  COMPLETED               11-AUG-17 NAR

Database upgrade

MOS  Doc 2239710.1  may be relevant https://community.oracle.com/thread/4049668   https://support.oracle.com/epmos/faces/DocumentDisplay?_afrLoop=362360756838841&id=1503653.1&_afrWindowMode=0&_adf.ctrl-state=khtu9g29k_178 x

Agent decommission from OEM

Agent decommission from OEM: Link for Normal procedure to decommission agent in OEM: https://blog.dbi-services.com/oracle-cloud-control-12c-removing-an-agent-is-much-easier-in-oem-12104/ --------- Here we removed host from OEM directly, So, It is not properly removed. When we tried to push agent again to the target server, we have faced error (target name already exist ) Followed below to resolve issue Manually agent decommission: OMS server: col ENTITY_TYPE for a15  col TYPE_DISPLAY_NAME for a30 col ENTITY_NAME for a40 col DISPLAY_NAME for a50 col EMD_URL for a75 SELECT ENTITY_TYPE,        TYPE_DISPLAY_NAME,        ENTITY_NAME,        DISPLAY_NAME,        EMD_URL FROM   SYSMAN.EM_MANAGEABLE_ENTITIES WHERE  MANAGE_STATUS = 2 AND    EMD_URL like '%TARGET%' AND    REP_SIDE_AVAIL = 0 AND    EMD_URL IS NOT NULL ORDER  BY 1,2,3; >cd D:\oracle\OEM\MW\bin >D: D:\oracle\OEM\MW\bin> emcli setup -url=https://OMS.net.com:7799/em -username=SYSMAN D:\oracle\OEM\MW\bin> emcli log

UPload patches to OEM Manual Method through CMD Prompt

UPload patches to OEM Manual Method through CMD Prompt cd <OMS_HOST>/bin emcli setup -url=https://OEM.LINK.com:7799/em -username=SYSMAN emcli sync emcli upload_patches -patch_files="D:\July_17_patches\p26194136_112040_American English_M.xml;D:\July_17_patches\p26161724_121020_MSWIN-x86-64.zip" -from_host=OMS.HOSTNAME.com -cred_name=OEM_SERVICE_ACCOUNT -cred_owner=SYSMAN

PASSWORD FILE CREATION: DATAGUARD

Linux: Go to ORACLE_HOME/dbs  orapwd file=orapwSID  password=password entries=max_users ignorecase=y Windows: orapwd file=C:\ORACLE\product\11.2.0.4\dbhome\database\PWDSID.ora password=password entries=5 ignorecase=y Copy same file to standby server and rename with standby SID PWD(SID).

Auto SQL Tuning task

https://oracle-base.com/articles/11g/automatic-sql-tuning-11gr1 COLUMN parameter_value FORMAT A30 SELECT parameter_name, parameter_value FROM   dba_advisor_parameters WHERE  task_name = 'SYS_AUTO_SQL_TUNING_TASK'; SELECT parameter_name, parameter_value FROM   dba_advisor_parameters WHERE  task_name = 'SYS_AUTO_SQL_TUNING_TASK' AND    parameter_name IN ('ACCEPT_SQL_PROFILES',                           'MAX_SQL_PROFILES_PER_EXEC',                           'MAX_AUTO_SQL_PROFILES'); select execution_name, execution_start, execution_end, status from dba_advisor_executions where task_name = 'SYS_AUTO_SQL_TUNING_TASK' order by execution_start; select execution_name, count(*) from dba_advisor_objects where task_name ='SYS_AUTO_SQL_TUNING_TASK' and type = 'SQL' group by execution_name order by execution_name; -- Enable BEGIN   DBMS_AUTO_TASK_ADMIN.enable(     client_name => 'sql tuning advisor',     operation   => NU