12
返回列表 发新帖
楼主: oracle_ren

[原创] 怎样将oracle11g升级为oracle11g rac 环境?

[复制链接]
论坛徽章:
28
ITPUB元老
日期:2005-06-18 23:14:252011新春纪念徽章
日期:2011-01-25 15:42:152011新春纪念徽章
日期:2011-01-25 15:42:332011新春纪念徽章
日期:2011-01-25 15:42:562011新春纪念徽章
日期:2011-02-18 11:42:47现任管理团队成员
日期:2011-05-07 01:45:08ITPUB十周年纪念徽章
日期:2011-11-01 16:19:412012新春纪念徽章
日期:2012-01-04 11:49:542012新春纪念徽章
日期:2012-02-13 15:13:202012新春纪念徽章
日期:2012-02-13 15:13:20
11#
发表于 2010-10-14 14:49 | 只看该作者
原帖由 〇〇 于 2010-10-9 18:55 发表
个人觉得没法升级,把数据库数据备份了,然后装rac,再导入


key wordush rac
搭好环境,dbca里面可以push crs and db software
再修改init 运行脚本,别忘了创建undo redo

做过很多次,10g生产环境,没问题的

使用道具 举报

回复
招聘 : 数据库管理员
论坛徽章:
4
授权会员
日期:2005-10-30 17:05:332010新春纪念徽章
日期:2010-03-01 11:20:00ITPUB9周年纪念徽章
日期:2010-10-08 09:28:51ITPUB十周年纪念徽章
日期:2011-11-01 16:19:41
12#
发表于 2010-10-15 14:02 | 只看该作者
找2台机器,装好crs和software,把需要的参数都copy过来,主要是cluster设成true,停掉原来的单几点,启动rac节点的db

如果rac非要包括原来的节点,我不确认能不能在db跑的时候装crs

如果用dataguard停机可能更短,用rac做standby,做一次切换也ok

使用道具 举报

回复
论坛徽章:
76
双子座
日期:2015-07-28 14:26:072012新春纪念徽章
日期:2012-02-13 15:09:52ITPUB十周年纪念徽章
日期:2011-11-01 16:21:15鲜花蛋
日期:2011-08-26 02:02:24管理团队成员
日期:2011-05-07 01:45:082010广州亚运会纪念徽章:皮划艇
日期:2011-04-18 11:24:412011新春纪念徽章
日期:2011-02-18 11:43:342011新春纪念徽章
日期:2011-01-25 15:42:562011新春纪念徽章
日期:2011-01-25 15:42:332011新春纪念徽章
日期:2011-01-25 15:42:15
13#
发表于 2010-10-16 11:23 | 只看该作者
我这有篇10的,可以按照这个方法是11版本上测试下
How to Convert 10g Single-Instance database to 10g RAC using Manual Conversion procedure [ID 747457.1]   

--------------------------------------------------------------------------------

  修改时间 16-JAN-2009     类型 HOWTO     状态 PUBLISHED   

In this Document
  Goal
  Solution
  References



--------------------------------------------------------------------------------



Applies to:
Oracle Server - Enterprise Edition - Version: 10.1.0.2
Information in this document applies to any platform.
This note applies to all Unix platforms.
Goal
This article provides a method to convert a Single Instance 10g database to a RAC 10g database. It can be used for 10gR2 or 11gR1, too.
Solution
Following are the steps:


1. on the first node


Make a full database backup of the single-instance database before you change anything.

1) Install Oracle Clusterware on all nodes you intend to have as cluster members, following the directions in Chapter 4 and Chapter 5 (Oracle&reg; Database Oracle Clusterware and Oracle Real Application Clusters Installation Guide <platform>.
http://www.oracle.com/pls/db102/ ... elected=3#index-ORA

Eventually patch the clusterware software (the clusterware version need to be equal or higher than the rdbms version) as well as the rdbms software

During the "Install Oracle Database 10g Software with Real Application Clusters", make sure that you select a new Oracle home other than the one from which the single-instance database was running in case the single-instance database is running on one of the systems. Upgrade the RAC RDBMS software to the same version as the original single-instance database.

2) Configure the cluster listener, i.e. configure the listener through netca from the new cluster RDBMS Home. Eventually stop the single instance listeners when they are running on one of the clustered nodes in case they are using the same listener ports. Ideally, use the 'LISTENER' as name for that listener.

3) Restore the backup of datafiles,redo logs,control file to a shared location on the cluster
(If you are using ASM ,then please follow Note 452758.1 How to Convert a Single-Instance ASM to Cluster ASM)

4) Take a backup of original single-instance pfile to e.g. /tmp/initorcl.ora and Add the following entry in pfile, e.g. for a two node RAC cluster


*.cluster_database = TRUE
*.cluster_database_instances = 2
*.undo_management=AUTO
<SID1>.undo_tablespace=undotbs (undo tablespace which already exists)
<SID1>.instance_name=<SID1>
<SID1>.instance_number=1
<SID1>.thread=1
<SID1>.local_listener=<LISTENERNAME>_<HOSTNAME1>
<SID2>.instance_name=<SID2>
<SID2>.instance_number=2
<SID2>.local_listener=<LISTENERNAME>_<HOSTNAME2>
<SID2>.thread=2
<SID2>.undo_tablespace=UNDOTBS2
<SID2>.cluster_database = TRUE
<SID2>.cluster_database_instances = 2

<SID1> is equal to "<db_name>1". <SID2> is equal to "<db_name>2", e.g. ORCL1, ORCL2.


5) change the location of control file in parameter file

local drive to shared cluster file system location

ie control_files='<local path>/control01.ctl'

to ie control_files='<shared cluster file system path>/control01.ctl'

6) create spfile from pfile( spfile should be stored in shared device)

export ORACLE_SID=ORCL1
sqlplus "/ as sysdba"
create spfile='<shared cluster file system path>/spfileORCL.ora' from pfile='/tmp/initORCL.ora';
exit

7) Create the $ORACLE_HOME/dbs/init<sid>.ora e.g. initORCL1.ora file that contains the following entry

spfile='spfile_path_name'

spfile_path_name is the complete path name of the SPFILE.

example :-

spfile='/cfs/spfile/spfileORCL1.ora'

8) create new password file for ORCL1 instance.

orapwd file=orapwORCL1 password=oracle

9) start the database in mount stage

10) Rename the datafile,redo logs to new shared device

alter database rename file '<full path of source file name>' to '<new shared location path';

11) Add second instance redo logs (or more when multiple instances will be started)

alter database
add logfile thread 2
group 3 ('<shared location/redo2_01_100.dbf') size 100M,
group 4 ('<shared location/redo2_02_100.dbf') size 100M;

alter database enable public thread 2;


12) create the second (or more) instance undo tablespace from existing instance

Path and file name will different for your environment


CREATE UNDO TABLESPACE UNDOTBS2 DATAFILE
'/dev/RAC/undotbs_02_210.dbf' SIZE 200M ;


13) Open your database (i.e. alter database open and run $ORACLE_HOME/rdbms/admin/catclust.sql to create cluster database specific views within the existing instance


2. On the second node and other nodes

14) Set ORACLE_SID and ORACLE_HOME environment variables on the second node

15) Create the $ORACLE_HOME/dbs/init<sid>.ora e.g. initORCL2.ora file for the second node the same way as with point 7.

16) create new password file for second instance ORCL2 instance as in point 8

orapwd file=orapwORCL2 password=oracle

17) Start the second Instance

3. on one of the nodes

18) After configuring the listener,you have to add the database in cluster as below


srvctl add database -d <database name> -o <ORACLE_HOME path> -p <spfile location and name>

srvctl add instance -d <database name> -i <instance 1 name> -n <node 1 name >

srvctl add instance -d <database name> -i <instance 2 name> -n <node 2 name >
19) in case ASM is used, add the rdbms instance / asm dependency, e.g.

srvctl modify instance -d <db_unique_name> -i <SID1> -s <+ASM1>

使用道具 举报

回复
论坛徽章:
26
2009新春纪念徽章
日期:2009-01-04 14:52:28咸鸭蛋
日期:2011-11-13 14:16:262012新春纪念徽章
日期:2012-01-04 11:51:22紫蛋头
日期:2012-02-02 13:13:42玉石琵琶
日期:2012-02-21 15:04:38蛋疼蛋
日期:2012-03-09 08:25:45奥运纪念徽章
日期:2012-11-27 15:37:34复活蛋
日期:2012-12-07 13:05:172013年新春福章
日期:2013-02-25 14:51:242014年世界杯参赛球队:西班牙
日期:2014-06-26 12:03:53
14#
发表于 2010-11-5 09:03 | 只看该作者
怎样将oracle11g rac 降级为oracle11g  环境?

使用道具 举报

回复
论坛徽章:
21
ITPUB新首页上线纪念徽章
日期:2007-10-20 08:38:44生肖徽章2007版:兔
日期:2011-01-20 12:58:492011新春纪念徽章
日期:2011-02-18 11:42:47ITPUB十周年纪念徽章
日期:2011-11-01 16:20:282012新春纪念徽章
日期:2012-01-04 11:50:44法拉利
日期:2013-09-10 14:11:32本田
日期:2014-02-16 22:57:59奔驰
日期:2014-02-16 23:04:212014年新春福章
日期:2014-02-18 16:41:112011新春纪念徽章
日期:2011-01-04 10:24:58
15#
发表于 2010-11-8 15:37 | 只看该作者
rac搭建,然后imp

使用道具 举报

回复

您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

TOP技术积分榜 社区积分榜 徽章 团队 统计 知识索引树 积分竞拍 文本模式 帮助
  ITPUB首页 | ITPUB论坛 | 数据库技术 | 企业信息化 | 开发技术 | 微软技术 | 软件工程与项目管理 | IBM技术园地 | 行业纵向讨论 | IT招聘 | IT文档
  ChinaUnix | ChinaUnix博客 | ChinaUnix论坛
CopyRight 1999-2011 itpub.net All Right Reserved. 北京盛拓优讯信息技术有限公司版权所有 联系我们 未成年人举报专区 
京ICP备16024965号-8  北京市公安局海淀分局网监中心备案编号:11010802021510 广播电视节目制作经营许可证:编号(京)字第1149号
  
快速回复 返回顶部 返回列表