User Tools

Site Tools


oracle:install

Oracle ASM

Create loopback raw files (not required)

mkdir /asmfs
dd if=/dev/zero of=/asmfs/disk1 bs=1024k count=30000
dd if=/dev/zero of=/asmfs/disk2 bs=1024k count=30000
dd if=/dev/zero of=/asmfs/disk3 bs=1024k count=30000

/etc/init.d/loopback

#!/bin/bash
#
# chkconfig: 2345 18 18
# description: Loopback

case "$1" in
  start)
/sbin/losetup /dev/loop1 /asmfs/disk1
/sbin/losetup /dev/loop2 /asmfs/disk2
/sbin/losetup /dev/loop3 /asmfs/disk3
raw /dev/raw/raw1 /dev/loop1
raw /dev/raw/raw2 /dev/loop2
raw /dev/raw/raw3 /dev/loop3
chown -R oracle:oinstall /dev/raw/*
touch /var/lock/subsys/loopback
;;
  stop)
/sbin/losetup -d /dev/loop1
/sbin/losetup -d /dev/loop2
/sbin/losetup -d /dev/loop3
;;
esac
chown -R oracle:oinstall /dev/raw/*
fdisk create partition
oracleasm createdisk < disk label > /dev/mapper/< alias >< partition >

Oratab

SID:/u01/app/oracle/product/11.2.0/dbhome_1:Y
+ASM:/u01/app/oracle/product/11.2.0/grid:N

Resize ASM

/etc/init.d/oracleasm listdisks
/etc/init.d/oracleasm createdisk VOLx /dev/raw/raw2
ALTER DISKGROUP DATA ADD DISK 'ORAPL:VOLx';

Oracle bash profile

# User specific environment and startup programs

PATH=$PATH:$HOME/bin:/opt/oracle/product/12.1.0/dbhome_1/bin

export PATH
export ORACLE_HOME=/opt/oracle/product/12.1.0/dbhome_1
export ORACLE_SID=ORAPL

Turn off audit

ALTER SYSTEM SET AUDIT_TRAIL=NONE SCOPE=SPFILE;
oracle/install.txt · Last modified: 2017/10/31 11:11 by Jan Forman