Linux 6.5(Oracle 11.2.0.4)单实例ASM安装(3)

[root@rac1]# chmod +x /etc/rc.d/init.d/rawdevices
 [root@rac1]# chkconfig --add rawdevices
 [root@rac1]# chkconfig rawdevices on
 [root@rac1]# service rawdevices start
 Assigning devices:
 /dev/raw/raw5 --> /dev/sdb
 /dev/raw/raw5: bound to major 8, minor 5
 /dev/raw/raw6 --> /dev/sdc
 /dev/raw/raw6: bound to major 8, minor 6
 /dev/raw/raw7 --> /dev/sdd
 /dev/raw/raw7: bound to major 8, minor 7
 /dev/raw/raw8 --> /dev/sde
 /dev/raw/raw8: bound to major 8, minor 8
 done
 [root@rac1]# raw -qa
 /dev/raw/raw5: bound to major 8, minor 5
 /dev/raw/raw6: bound to major 8, minor 6
 /dev/raw/raw7: bound to major 8, minor 7
 /dev/raw/raw8: bound to major 8, minor 8

如果执行脚本的时候停在Adding daemon to inittab,这是 11.2.0.1和11.2.0.2 在RHEL6上的bug,可以以root身份执行以下命令:

[root@rac1]# dd if=/var/tmp/.oracle/npohasdof=/dev/null bs=1024 count=1

ydasm 2016/11/22 11:21:57 /home/u01/grid/11.2.0/cdata/ydasm/backup_20161122_112157.olr
 Successfully configured Oracle Grid Infrastructure for a Standalone Server

Asmca
 Dbca

2.3 安装后的检查、配置

检查是否正确安装:

$ oraenv

ORACLE_SID=+ASM

The Oracle base for ORACLE_HOME=/u01/app/oracle/product/11.2.0/grid is /u01/app/oracle

$ echo $ORACLE_SID

+ASM

$ crsctl check has

CRS-4638: Oracle High Availability Services is online

$ crs_stat -t
 Name Type Target State Host
 ------------------------------------------------------------
 ora.DATA.dg ora....up.type ONLINE ONLINE ydasm
 ora....ER.lsnr ora....er.type ONLINE ONLINE ydasm
 ora.VOTE.dg ora....up.type ONLINE ONLINE ydasm
 ora.asm ora.asm.type ONLINE ONLINE ydasm
 ora.cssd ora.cssd.type ONLINE ONLINE ydasm
 ora.diskmon ora....on.type OFFLINE OFFLINE
 ora.evmd ora.evm.type ONLINE ONLINE ydasm
 ora.ons ora.ons.type OFFLINE OFFLINE

从11.2.0.3以后,在非Exadata上, ora.diskmon的缺省状态为offline
 ora.ons主要用于中间件和数据库的相连

设置开机自动启动crs:

[root@rac1]# tail -n 1 /etc/inittab //安装完成默认会向inittab文件添加该记录

h1:35:respawn:/etc/init.d/init.ohasd run >/dev/null 2>&1 > /etc/rc.local <

[root@rac1]#rm -rf /u01/app/oracle/product/11.2.0/grid/ //删除grid的安装文件

[root@rac1]# for i in {5..8} ;do dd if=/dev/zero of=/dev/raw/raw$i bs=1024 count=10 ;done //低格裸设备(清除ASM磁盘组信息)

内容版权声明:除非注明,否则皆为本站原创文章。

转载注明出处:https://www.heiqu.com/37c72913adc6fca14d2125b1390c0094.html