Oracle 10g to 11g database migration Experiment

Source: Internet
Author: User
Use rman to migrate 10 Gb servers across databases and servers: 192.168.182.133Oracle10.2.0.1.0RHEL432bit11g server: Server 192.168

Use rman to migrate 10 Gb servers across databases and servers: 192.168.182.20.oracle 10.2.0.1.0 RHEL 4 32bit 11g server: Server 192.168

Using rman for cross-database and cross-server migration
10g server: 192.168.182.20.oracle 10.2.0.1.0 RHEL 4 32bit

11g Server:
Server 192.168.182.131 OEL5.8 _ 32 Oracle 11.2.0.1.0 32bit
[Oracle @ oelr5u8-1 admin] $ uname-
Linux oelr5u8-1.localdomain 2.6.32-300.10.1.el5uek #1 SMP Wed Feb 22 17:22:40 EST 2012 i686 i686 i386 GNU/Linux

SYS @ PROD> select * from v $ version;

BANNER
--------------------------------------------------------------------------------
Oracle Database 11g Enterprise Edition Release 11.2.0.1.0-Production
PL/SQL Release 11.2.0.1.0-Production
CORE 11.2.0.1.0 Production
TNS for Linux: Version 11.2.0.1.0-Production
NLSRTL Version 11.2.0.1.0-Production

Migrate the 10g Database PROD2 on the server 192.168.182.6.2 to the 11g database PROD4 on the server 192.168.182.131

1. Preparations
1.1 setup auxiliary instance
1.1.1 orapwd
On 131-source database server
Cd $ ORACLE_HOME/dbs
Orapwd file = orapwPROD4 password = oracle

1.1.2 export ORACLE_SID = PROD4
On 131

1.1.3 mkdir
On 131
Mkdir-p/u01/app/oracle/admin/PROD4/{a, B, c, u} dump
Mkdir-p/u01/app/oracle/oradata/PROD4/

1.1.4 pfile
On 133-target database server
Cd $ ORACLE_HOME/dbs
Sqlplus/as sysdba
Create pfile from spfile;

Scp initPROD2.ora oelr5u8-1:/u01/app/oracle/product/11.2.0/db_1/dbs/initPROD4.ora

On 131
Cd $ ORACLE_HOME/dbs
Vi initPROD4.ora
PROD2. _ db_cache_size = 167772160
PROD2. _ java_pool_size = 4194304
PROD2. _ large_pool_size = 4194304
PROD2. _ shared_pool_size = 100663296
PROD2. _ streams_pool_size = 0
*. Aq_tm_processes = 1
*. Audit_file_dest = '/u01/app/oracle/admin/PROD2/adump'
*. Background_dump_dest = '/u01/app/oracle/admin/PROD2/bdump'
*. Compatible = '10. 2.0.1.0'
*. Control_files = '/u01/app/oracle/oradata/PROD2/control01.ctl', '/u01/app/oracle/oradata/PROD2/control02.ctl ', '/u01/app/oracle/oradata/PROD2/control03.ctl'
*. Core_dump_dest = '/u01/app/oracle/admin/PROD2/cdump'
*. Db_block_size = 8192
*. Db_domain =''
*. Db_file_multiblock_read_count = 16
*. Db_name = 'prod2'
*. Dispatchers =''
*. Job_queue_processes = 10
*. Nls_language = 'simplified CHINESE'
*. Nls_territory = 'China'
*. Open_cursors = 300
*. Pga_aggregate_target = 94371840
*. Processses = 150
*. Remote_login_passwordfile = 'clusive'
*. Session_cached_cursors = 200
*. Sga_target = 285212672
*. Undo_management = 'auto'
*. Undo_tablespace = 'undotbs1'
*. User_dump_dest = '/u01/app/oracle/admin/PROD2/udump'

Changed to meet the requirements of the secondary instance and 11g Database.

PROD4. _ db_cache_size = 167772160
PROD4. _ java_pool_size = 4194304
Prod4. _ large_pool_size = 4194304
PROD4. _ shared_pool_size = 100663296
PROD4. _ streams_pool_size = 0
*. Aq_tm_processes = 1
*. Audit_file_dest = '/u01/app/oracle/admin/PROD4/adump'
*. Control_files = '/u01/app/oracle/oradata/PROD4/control01.ctl', '/u01/app/oracle/oradata/PROD4/control02.ctl ', '/u01/app/oracle/oradata/PROD4/control03.ctl'
*. Db_block_size = 8192
*. Db_domain =''
*. Db_file_multiblock_read_count = 16
*. Db_name = 'prod4'
*. Dispatchers =''
*. Job_queue_processes = 10
*. Nls_language = 'simplified CHINESE'
*. Nls_territory = 'China'
*. Open_cursors = 300
*. Pga_aggregate_target = 94371840
*. Processses = 150
*. Remote_login_passwordfile = 'clusive'
*. Session_cached_cursors = 200
*. Sga_target = 285212672
*. Undo_management = 'auto'
*. Undo_tablespace = 'undotbs1'
# For auxiliary instance
DB_FILE_NAME_CONVERT = 'prod2', 'prod4'
LOG_FILE_NAME_CONVERT = 'prod2', 'prod4'

1.1.5 startup nomount on auxiliary instance
On 131

Export ORACLE_SID = PROD4
Sqlplus/as sysdba
Create spfile from pfile = '/u01/app/oracle/product/11.2.0/db_1/dbs/initPROD4.ora ';

1.1.6 setup listener and tnsnames
On 133
Vi tnsnames. ora
Add:
PROD4_oelr5u8-1 =
(Description =
(Address = (protocol = tcp) (host = oelr5u8-1) (port = 1521 ))
(Connect_data =
(Server = dedicated)
(Service_name = PROD4)
)
)

On 131
Vi listener. ora
Add into sid_list_listener:
(Sid_desc =
(Global_dbname = PROD4)
(Oracle_home =/u01/app/oracle/product/11.2.0/db_1)
(Sid_name = PROD4
)

Lsnrctl start

Vi tnsnames. ora
PROD2_odd-oelr4u8 =
(Description =
(Address = (protocol = tcp) (host = odd-oelr4u8) (port = 1521 ))
(Connect_data =
(Server = dedicated)
(Service_name = PROD2)
)
)

1.2 check target database's backup
On 133
Ensure that archive log mode is on

Rman target/
List backup of database;
Note: cannot use backup as compressed backupset... errors will be reported when duplicating

2. duplicate

Rman target sys/oracle @ PROD2 auxiliary sys/oracle @ PROD4_oelr5u8-1

Recovery Manager: Release 10.2.0.1.0-Production on Sat Apr 5 15:37:35 2014

Copyright (c) 1982,200 5, Oracle. All rights reserved.

Connected to target database: PROD2 (DBID = 1490667694)
Connected to auxiliary database: PROD4 (not mounted)

RMAN> duplicate target database to PROD4;

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.