Professional Documents
Culture Documents
This is just a test scenario downgrade Oracle Database from 11.2.0.1 to 10.2.0.5 on LINUX OS for
Self Practice. In this article I explain step by step how to downgrade database from 11g to 10g.
Oracle database can be downgraded from to the release from which you upgraded.
Database upgraded from 10.2.0.5.0 to 11.2.0.1.0
Its possible only to downgrade to 10.2.0.5.0 and you cannot to downgrade 11.1.X or 10.1.X.
Once you decided to downgrade do NOT change COMPATIBLE parameter.
After upgrade is complete, you can increase the setting of the compatible initialization parameter.
However after you increase COMPATIBLE parameter, the database subsequently cannot be downgraded.
After upgraded to 11g, direct downgrade of EM is not supported. Refer NOTE: 870877.1.
This is test database, in my case, I do not have enterprise manager.
11g $ORACLE_HOME : /u01/app/oracle/product/11.2.0/db_home
10g $ORACLE_HOME : /u02/app/oracle/product/10.2.0/db_home
11.2.0.1.0
Production
TYPE
VALUE
string
10.2.0.5.0
# STOP LISTENER
$ lsnrctl stop <listener_name>
...
# STOP EM CONSOLE
||
TIMESTAMP
----------------------------------------------------------COMP_TIMESTAMP DWGRD_END 2015-10-10 09:13:50 2457306 33230
1 row selected.
SQL>
SQL> Rem ***********************************************************************
SQL> Rem END catdwgrd.sql
SQL> Rem ***********************************************************************
SYS> spool off;
SYS> shut immediate;
...
2015-10-10 10:04:26
1 row selected.
COMP_NAME
STATUS
VERSION
VALID
10.2.0.5.0
VALID
10.2.0.5.0
VALID
10.2.0.5.0
Oracle XDK
VALID
10.2.0.5.0
VALID
10.2.0.5.0
Oracle Text
VALID
10.2.0.5.0
VALID
10.2.0.5.0
VALID
10.2.0.5.0
VALID
10.2.0.5.0
VALID
10.2.0.5.0
OLAP Catalog
VALID
10.2.0.5.0
VALID
10.2.0.5.0
Oracle interMedia
VALID
10.2.0.5.0
Spatial
INVALID
10.2.0.5.0
INVALID
10.2.0.5.0
INVALID
10.2.0.5.0
16 rows selected.
DOC>#######################################################################
DOC>#######################################################################
DOC>
DOC>
The above query lists the SERVER components now loaded in the
DOC>
DOC>
DOC>
Please review the status and version columns and look for
DOC>
DOC>
file, or any components are not VALID or not the correct 10.1.0
DOC>
DOC>
DOC>
DOC>
DOC>
DOC>
DOC>#######################################################################
DOC>#######################################################################
DOC>#
SYS> spool off;
SYS> shutdown immediate;
...
SYS> startup;
...
STATUS
OBJECT_TYPE
CREATED
INVALID SYNONYM
19-APR-10
SETEMVIEWUSERCONTEXT
INVALID SYNONYM
19-APR-10
MGMT$ALERT_CURRENT
INVALID SYNONYM
19-APR-10
MGMT$ALERT_HISTORY
INVALID SYNONYM
19-APR-10
MGMT$AVAILABILITY_CURRENT
INVALID SYNONYM
19-APR-10
MGMT$AVAILABILITY_HISTORY
INVALID SYNONYM
19-APR-10
MGMT$BLACKOUT_HISTORY
INVALID SYNONYM
19-APR-10
MGMT$CLUSTER_INTERCONNECTS
INVALID SYNONYM
19-APR-10
MGMT$CSA_CLIENTS
INVALID SYNONYM
19-APR-10
MGMT$CSA_HOST_COOKIES
INVALID SYNONYM
19-APR-10
MGMT$CSA_HOST_CPUS
INVALID SYNONYM
19-APR-10
MGMT_PAF$PROCEDURES
INVALID SYNONYM
14-OCT-15
MGMT_PAF$INSTANCES
INVALID SYNONYM
14-OCT-15
MGMT_PAF$STATES
INVALID SYNONYM
14-OCT-15
MGMT_PAF$APPLICATIONS
INVALID SYNONYM
14-OCT-15
MGMT$ECM_CONFIG_HISTORY
INVALID SYNONYM
14-OCT-15
MGMT$ECM_CONFIG_HISTORY_KEY1
INVALID SYNONYM
14-OCT-15
MGMT$ECM_CONFIG_HISTORY_KEY2
INVALID SYNONYM
14-OCT-15
..
...
..
...
TABLE_OWNE TABLE_NAME
SYSMAN
MGMT_MESSAGES
MGMT_PAF_PROCS_LATEST
SYSMAN
MGMT_PAF_PROCS_LATEST
MGMT_PAF_JOBS
SYSMAN
MGMT_PAF_JOBS
MGMT_PAF$PROCEDURES
SYSMAN
MGMT_PAF$PROCEDURES
MGMT_PAF$INSTANCES
SYSMAN
MGMT_PAF$INSTANCES
MGMT_PAF$STATES
SYSMAN
MGMT_PAF$STATES
MGMT_PAF$APPLICATIONS
SYSMAN
MGMT_PAF$APPLICATIONS
MGMT$ECM_CONFIG_HISTORY
SYSMAN
MGMT$ECM_CONFIG_HISTORY
MGMT$ECM_CONFIG_HISTORY_KEY1
SYSMAN
MGMT$ECM_CONFIG_HISTORY_KEY1
MGMT$ECM_CONFIG_HISTORY_KEY2
SYSMAN
MGMT$ECM_CONFIG_HISTORY_KEY2
MGMT$ECM_CONFIG_HISTORY_KEY3
SYSMAN
MGMT$ECM_CONFIG_HISTORY_KEY3
..
...
Already we have dropped SYSMAN schema before to downgrade the database.
Dropping an object does NOT drop their synonyms. So we can drop these synonyms.
SYS> spool invalid_synonym.log;
SYS> select 'drop ' || 'public synonym ' || OBJECT_NAME ||';'
from dba_objects where status ='INVALID';
..
...
SYS> spool off;
SYS> @invalid_synonym.log;
..
...
SYS> select object_name, status, object_type,created from dba_objects where status='INVALID';
no rows selected
SQL> show parameter dump_dest;
NAME
TYPE
VALUE
string
/u02/app/oracle/admin/devdb/bdump
core_dump_dest
string
/u02/app/oracle/admin/devdb/cdump
user_dump_dest
string
/u02/app/oracle/admin/devdb/udump
REF_DOCS
http://docs.oracle.com/cd/E11882_01/server.112/e23633/downgrade.htm#UPGRD12554