ITPub博客

首页 > 数据库 > Oracle > Linux 安装 Oracle 11g——手工建库(RAC)

Linux 安装 Oracle 11g——手工建库(RAC)

Oracle 作者:不一样的天空w 时间:2019-02-25 11:50:38 0 删除 编辑

https://blog.csdn.net/brj880719/article/details/51925801


1.创建目录

mkdir -p /u01/app/oracle/admin/orcl/adump


2.编辑参数文件

*.memory_target=512m

*.audit_file_dest='/u01/app/oracle/admin/orcl/adump'

*.audit_trail='db'

*.control_files=’+DATADG/ORCL/controlfile/control01.ctl’, ‘+DATADG/ORCL/controlfile/control02.ctl’                                           

*.db_block_size=8192

*.db_create_file_dest='+DATADG'

*.db_domain=''

*.db_name='orcl'

*.db_recovery_file_dest='+DATADG'

*.db_recovery_file_dest_size=1G

*.diagnostic_dest='/u01/app/oracle'

*.open_cursors=300

*.processes=150

*.remote_listener='nodescan:1521'

*.remote_login_passwordfile='exclusive'


3.创建ASM目录和创建spfile

    


4.创建密码文件

cd $ORACLE_HOME/dbs

节点1:orapwd file=orapwORCL1 password=oracle

节点2:orapwd file=orapwORCL2 password=oracle


5.创建DB

CREATE DATABASE orcl

   USER SYS IDENTIFIED BY oracle

   USER SYSTEM IDENTIFIED BY oracle

   LOGFILE GROUP 1 ('+DATADG') SIZE 100M,

           GROUP 2 ('+DATADG') SIZE 100M,

           GROUP 3 ('+DATADG') SIZE 100M

   MAXLOGFILES 5

   MAXLOGMEMBERS 5

   MAXLOGHISTORY 1

   MAXDATAFILES 100

   CHARACTER SET US7ASCII

   NATIONAL CHARACTER SET AL16UTF16

   EXTENT MANAGEMENT LOCAL

   DATAFILE '+DATADG' SIZE 325M

   SYSAUX DATAFILE '+DATADG' SIZE 325M

   DEFAULT TABLESPACE users

      DATAFILE '+DATADG'

      SIZE 500M  AUTOEXTEND ON MAXSIZE UNLIMITED

   DEFAULT TEMPORARY TABLESPACE tempts1

      TEMPFILE '+DATADG'

      SIZE 20M

   UNDO TABLESPACE undotbs1

      DATAFILE '+DATADG'

      SIZE 200M  AUTOEXTEND ON MAXSIZE UNLIMITED;


6.创建undo 和添加redo

UNDO

CREATE UNDO TABLESPACE UNDOTBS2 DATAFILE '+DATADG' SIZE 200M;

REDO

ALTER DATABASE ADD LOGFILE THREAD 2 GROUP 4 '+DATADG' SIZE 100M; 

ALTER DATABASE ADD LOGFILE THREAD 2 GROUP 5 '+DATADG' SIZE 100M;

ALTER DATABASE ADD LOGFILE THREAD 2 GROUP 6 '+DATADG' SIZE 100M; 


7.以下转单实例db到RAC DB


8.执行创建数据字典脚本

@?/rdbms/admin/catalog.sql

@?/rdbms/admin/catproc.sql

@?/rdbms/admin/catclust.sql

@?/rdbms/admin/utlrp.sql


9.注册数据库到Clusterware


   




来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/31397003/viewspace-2636888/,如需转载,请注明出处,否则将追究法律责任。

下一篇: rac静默安装
请登录后发表评论 登录
全部评论

注册时间:2016-09-22

  • 博文量
    905
  • 访问量
    940624