Oracle Study之-AIX6.1构建Oracle 10gR2 RAC(5)
一、安装Oracle软件
以Oracle身份安装:
Oracle软件安装完成后,运行“root.sh”脚本,完成Oracle安装!
二、配置网络(Listener)
通过netca配置网络:
[oracle@aix203 Disk1]$lsnrctl status
LSNRCTL for IBM/AIX RISC System/6000: Version 10.2.0.1.0 - Production on 16-MAR-2016 17:39:24 Copyright (c) 1991, 2005, Oracle. All rights reserved. Connecting to (ADDRESS=(PROTOCOL=tcp)(HOST=)(PORT=1521)) STATUS of the LISTENER ------------------------ Alias LISTENER_AIX203 Version TNSLSNR for IBM/AIX RISC System/6000: Version 10.2.0.1.0 - Production Start Date 16-MAR-2016 17:06:09 Uptime 0 days 0 hr. 33 min. 14 sec Trace Level off Security ON: Local OS Authentication SNMP ON Listener Parameter File /u01/app/oracle/product/10.2.0/db_1/network/admin/listener.ora Listener Log File /u01/app/oracle/product/10.2.0/db_1/network/log/listener_aix203.log Listening Endpoints Summary... (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=192.168.8.251)(PORT=1521))) (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=192.168.8.203)(PORT=1521))) Services Summary... Service "PLSExtProc" has 1 instance(s). Instance "PLSExtProc", status UNKNOWN, has 1 handler(s) for this service... The command completed successfully
三、通过DBCA建库
建库准备工作:
由于DataBase是通过raw存储,在建库时为管理方便需做以下准备工作:
1)建立raw的链接文件
[oracle@aix203 oracle]$mkdir -p oradata/prod
[oracle@aix203 oracle]$ls
oraInventory oradata product
[oracle@aix203 ~]$cat mkln.sh
ln -s /dev/rsystem /u01/app/oracle/oradata/prod/system01.dbf ln -s /dev/rsysaux /u01/app/oracle/oradata/prod/sysaux01.dbf ln -s /dev/rusers /u01/app/oracle/oradata/prod/users01.dbf ln -s /dev/rundotbs1 /u01/app/oracle/oradata/prod/undotbs01.dbf ln -s /dev/rundotbs2 /u01/app/oracle/oradata/prod/undotbs02.dbf ln -s /dev/rtemp /u01/app/oracle/oradata/prod/temp01.dbf ln -s /dev/rcontrol1_1 /u01/app/oracle/oradata/prod/control01.ctl ln -s /dev/rcontrol2_2 /u01/app/oracle/oradata/prod/control02.ctl ln -s /dev/rcontrol3_3 /u01/app/oracle/oradata/prod/control03.ctl ln -s /dev/rredo1_1 /u01/app/oracle/oradata/prod/log11.log ln -s /dev/rredo1_2 /u01/app/oracle/oradata/prod/log12.log ln -s /dev/rredo2_1 /u01/app/oracle/oradata/prod/log21.log ln -s /dev/rredo2_2 /u01/app/oracle/oradata/prod/log22.log ln -s /dev/rindex /u01/app/oracle/oradata/prod/index01.dbf ln -s /dev/rspfile /u01/app/oracle/oradata/prod/spfile01 ln -s /dev/rexample /u01/app/oracle/oradata/prod/example01.dbf
[oracle@aix203 ~]$sh mkln.sh
[oracle@aix203 ~]$ls -l /u01/app/oracle/oradata/prod/
total 0
l
rwxrwxrwx 1 oracle oinstall 16 Mar 16 17:49 control01.ctl -> /dev/rcontrol1_1 lrwxrwxrwx 1 oracle oinstall 16 Mar 16 17:49 control02.ctl -> /dev/rcontrol2_2 lrwxrwxrwx 1 oracle oinstall 16 Mar 16 17:49 control03.ctl -> /dev/rcontrol3_3 lrwxrwxrwx 1 oracle oinstall 13 Mar 16 17:49 example01.dbf -> /dev/rexample lrwxrwxrwx 1 oracle oinstall 11 Mar 16 17:49 index01.dbf -> /dev/rindex lrwxrwxrwx 1 oracle oinstall 13 Mar 16 17:49 log11.log -> /dev/rredo1_1 lrwxrwxrwx 1 oracle oinstall 13 Mar 16 17:49 log12.log -> /dev/rredo1_2 lrwxrwxrwx 1 oracle oinstall 13 Mar 16 17:49 log21.log -> /dev/rredo2_1 lrwxrwxrwx 1 oracle oinstall 13 Mar 16 17:49 log22.log -> /dev/rredo2_2 lrwxrwxrwx 1 oracle oinstall 12 Mar 16 17:49 spfile01 -> /dev/rspfile lrwxrwxrwx 1 oracle oinstall 12 Mar 16 17:49 sysaux01.dbf -> /dev/rsysaux lrwxrwxrwx 1 oracle oinstall 12 Mar 16 17:49 system01.dbf -> /dev/rsystem lrwxrwxrwx 1 oracle oinstall 10 Mar 16 17:49 temp01.dbf -> /dev/rtemp lrwxrwxrwx 1 oracle oinstall 14 Mar 16 17:49 undotbs01.dbf -> /dev/rundotbs1 lrwxrwxrwx 1 oracle oinstall 14 Mar 16 17:49 undotbs02.dbf -> /dev/rundotbs2 lrwxrwxrwx 1 oracle oinstall 11 Mar 16 17:49 users01.dbf -> /dev/rusers
2)建立raw存储映射
[oracle@aix203 ~]$cat map.txt
system=/u01/app/oracle/oradata/prod/system01.dbf sysaux=/u01/app/oracle/oradata/prod/sysaux01.dbf users=/u01/app/oracle/oradata/prod/users01.dbf undotbs1=/u01/app/oracle/oradata/prod/undotbs01.dbf undotbs2=/u01/app/oracle/oradata/prod/undotbs02.dbf temp=/u01/app/oracle/oradata/prod/temp01.dbf control1=/u01/app/oracle/oradata/prod/control01.ctl control2=/u01/app/oracle/oradata/prod/control02.ctl control3=/u01/app/oracle/oradata/prod/control03.ctl redo1_1=/u01/app/oracle/oradata/prod/log11.log redo1_2=/u01/app/oracle/oradata/prod/log12.log redo2_1=/u01/app/oracle/oradata/prod/log21.log redo2_2=/u01/app/oracle/oradata/prod/log22.log index=/u01/app/oracle/oradata/prod/index01.dbf spfile=/u01/app/oracle/oradata/prod/spfile01 example=/u01/app/oracle/oradata/prod/example01.dbf
在安装时,DataBase选择“裸设备”
四、验证
[oracle@aix203 ~]$crs_stat -t
Name Type Target State Host ------------------------------------------------------------ ora....03.lsnr application ONLINE ONLINE aix203 ora.aix203.gsd application ONLINE ONLINE aix203 ora.aix203.ons application ONLINE ONLINE aix203 ora.aix203.vip application ONLINE ONLINE aix203 ora....04.lsnr application ONLINE ONLINE aix204 ora.aix204.gsd application ONLINE ONLINE aix204 ora.aix204.ons application ONLINE ONLINE aix204 ora.aix204.vip application ONLINE ONLINE aix204 ora.prod.db application ONLINE ONLINE aix204 ora....d1.inst application ONLINE ONLINE aix203 ora....d2.inst application ONLINE ONLINE aix204
连接和访问数据库:
[oracle@aix203 ~]$sqlplus '/as sysdba'
SQL*Plus: Release 10.2.0.1.0 - Production on Wed Mar 16 18:12:43 2016
Copyright (c) 1982, 2005, Oracle. All rights reserved.
Connected to:
Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - 64bit Production
With the Partitioning, Real Application Clusters, OLAP and Data Mining options
SQL> select instance_name,status from gv$instance;
INSTANCE_NAME STATUS ---------------- ------------ prod1 OPEN prod2 OPEN
SQL> select name from v$datafile;
NAME -------------------------------------------------------------------------------- /u01/app/oracle/oradata/prod/system01.dbf /u01/app/oracle/oradata/prod/undotbs01.dbf /u01/app/oracle/oradata/prod/sysaux01.dbf /u01/app/oracle/oradata/prod/users01.dbf /u01/app/oracle/oradata/prod/example01.dbf /u01/app/oracle/oradata/prod/undotbs02.dbf 6 rows selected.
免责声明:本站发布的内容(图片、视频和文字)以原创、转载和分享为主,文章观点不代表本网站立场,如果涉及侵权请联系站长邮箱:is@yisu.com进行举报,并提供相关证据,一经查实,将立刻删除涉嫌侵权内容。