《wmware10+redhat6.5+oracle11.2.0.4+RAC+asmlib方式安装配置》由会员分享,可在线阅读,更多相关《wmware10+redhat6.5+oracle11.2.0.4+RAC+asmlib方式安装配置(38页珍藏版)》请在金锄头文库上搜索。
1、1.Wmware 上安装上创建共享磁盘:上安装上创建共享磁盘:网络设置:使用 NAT 模式,配置子网为 192.168.59.0,两个虚拟机的网络选择 NAT 方式,并且配置 192.168.59 网段的 IP 地址,在笔记本电脑上可以直接访问。创建一个虚拟机安装 redhat6.5 操作系统后,要禁用 Firewall 和 SElinux,调整参数:增加共享存储: A.创建共享磁盘在 cmd 中进入 WMware Workstation 10.0 安装目录:1.创建存储 Oracle Clusterware 文件 (Oracle Cluster Registry and voting dis
2、k) 的磁盘: vmware-vdiskmanager.exe -c -s 1Gb -a lsilogic -t 2 “D:vm-linux6.5-rac- storageShareDiskOCR.vmdk“2.创建存储 Oracle 共享数据文件的磁盘: vmware-vdiskmanager.exe -c -s 10Gb -a lsilogic -t 2 “D:vm-linux6.5-rac- storageShareDiskData01.vmdk“编辑虚拟机配置文件B.关闭两台虚拟机,用记事本打开虚拟机名字.wmx,到虛拟机的目录比如 E:SoftwareInstallvmwarelin
3、uxrac1,直接编辑*.vmx 文件, 加上下面语句(所有虛拟机节点):或者直接在两台 VM 上使用图形界面上直接添加磁盘选择已有的磁盘-选择上面创建的 共享磁盘,然后点高级中选择 scsi 卡,最后确定。 scsi1:1.deviceType = “disk“ scsi1:1.present = “TRUE“ scsi1:1.fileName = “D:vm-linux6.5-rac-storageShareDiskOCR.vmdk“ scsi1:1.mode = “independent-persistent“ scsi1:1.redo = “scsi1:2.deviceType = “
4、disk“ scsi1:2.present = “TRUE“ scsi1:2.fileName = “D:vm-linux6.5-rac-storageShareDiskData01.vmdk“ scsi1:2.mode = “independent-persistent“ scsi1:2.redo = “scsi1:1.deviceType = “disk“ 加入配置文件中。2. 采用采用 UEK 内核来创建共享内核来创建共享 ASMLIB 存储:存储:2.1.在在 redhat6.5 操作系统上安装如下操作系统上安装如下 RPM 包:包:kmod-oracleasm-2.0.6.rh1-3
5、.el6.x86_64.rpm oracleasm-support-2.1.8-1.el6.x86_64.rpm oracleasmlib-2.0.4-1.el6.x86_64.rpm kernel-uek-firmware-2.6.39-300.17.3.el6uek.noarch.rpm kernel-uek-2.6.39-300.17.3.el6uek.x86_64.rpm#rpm ihv *.rpm2.2 创建创建 ASM Disk Volumes对磁盘需要新进行 fdisk 分区,oracleasm configure -i 之后两个节点需要重启!# oracleasm config
6、ure -i 两个节点上都要操作两个节点上都要操作 节点一上: rootoradb1 soft# oracleasm configure -i Configuring the Oracle ASM library driver.This will configure the on-boot properties of the Oracle ASM library driver. The following questions will determine whether the driver is loaded on boot and what permissions it will have
7、. The current values will be shown in brackets (). Hitting without typing an answer will keep that current value. Ctrl-C will abort.Default user to own the driver interface : grid Default group to own the driver interface : asmadmin Start Oracle ASM library driver on boot (y/n) n: y Scan for Oracle
8、ASM disks on boot (y/n) y: y Writing Oracle ASM library driver configuration: done配置后 reboot 重启主机!节点二上: rootoradb2 disks# oracleasm configure -i Configuring the Oracle ASM library driver.This will configure the on-boot properties of the Oracle ASM library driver. The following questions will determi
9、ne whether the driver is loaded on boot and what permissions it will have. The current values will be shown in brackets (). Hitting without typing an answer will keep that current value. Ctrl-C will abort.Default user to own the driver interface grid: Default group to own the driver interface asmadm
10、: asmadmin Start Oracle ASM library driver on boot (y/n) y: Scan for Oracle ASM disks on boot (y/n) y: Writing Oracle ASM library driver configuration: done配置后 reboot 重启主机!# oracleasm configure 查看配置查看配置 rootoradb2 # oracleasm configureORACLEASM_ENABLED=true ORACLEASM_UID=grid ORACLEASM_GID=asmadmin
11、ORACLEASM_SCANBOOT=true ORACLEASM_SCANORDER=“ ORACLEASM_SCANEXCLUDE=“ ORACLEASM_USE_LOGICAL_BLOCK_SIZE=“falserootoradb1 soft# oracleasm init Loading module “oracleasm“: oracleasm Mounting ASMlib driver filesystem: /dev/oracleasm rootoradb1 soft# rootoradb2 soft# oracleasm init Loading module “oracle
12、asm“: oracleasm Mounting ASMlib driver filesystem: /dev/oracleasm rootoradb2 soft# 在节点一上创建即可,节点二上可以直接扫描出来: rootoradb1 soft# oracleasm createdisk CRSVOL /dev/sdb1 Writing disk header: done Instantiating disk: done rootoradb1 soft# oracleasm createdisk DATAVOL /dev/sdc1 Writing disk header: done Insta
13、ntiating disk: done rootoradb1 soft# rootoradb1 soft# oracleasm listdisks CRSVOL DATAVOL rootoradb1 soft# oracleasm-discover Using ASMLib from /opt/oracle/extapi/64/asm/orcl/1/libasm.so ASM Library - Generic Linux, version 2.0.4 (KABI_V2) Discovered disk: ORCL:CRSVOL 2088387 blocks (1069254144 bytes
14、), maxio 512 Discovered disk: ORCL:DATAVOL 20964762 blocks (10733958144 bytes), maxio 512 rootoradb1 soft# 在节点二上直接在节点二上直接 scandisks 后就会出现已创建的后就会出现已创建的 asmdisk. rootoradb2 soft# oracleasm scandisks Reloading disk partitions: done Cleaning any stale ASM disks. Scanning system for ASM disks. Instantiat
15、ing disk “CRSVOL“Instantiating disk “DATAVOL“ rootoradb2 soft# oracleasm listdisks CRSVOL DATAVOL rootoradb2 soft# gridoradb1 disks$ ls -atl /dev/oracleasm/disks 查看属性查看属性 grid:asmadmin total 0 brw-rw- 1 grid asmadmin 8, 33 May 7 08:42 DATAVOL brw-rw- 1 grid asmadmin 8, 17 May 7 08:42 CRSVOL drwxr-xr
16、-x 1 root root 0 May 7 08:37 . drwxr-xr-x 4 root root 0 May 7 08:37 .3. redhat6.5 操作系统上配置操作系统上配置3.1 主机主机 IP 配置:配置:192.168.59.130 oradb1 192.168.59.131 oradb2 192.168.59.132 oradb1-vip 192.168.59.133 oradb2-vip 192.168.59.134 scan-ip 10.10.10.130 oradb1-priv 10.10.10.131 oradb2-priv3.2 创建组及用户:创建组及用户:groupadd -g 1000