Wednesday 23 December 2015

Install oracle restart.( 1 node RAC without SCAN and Voting disk)

check that asmdba, asmoper and asmadmin groups exist and assigned to oracle
sudo groupadd -g 1004 asmoper
sudo groupadd -g 1004 asmoper
sudo groupadd -g 1005 asmadmin
sudo usermod -G asmdba,asmoper,asmoper -a oracle

sudo mkdir /u00/11.2.0 /u00/app
sudo chown oracle:oinstall /u00/11.2.0 /u00/app
mkdir /u00/11.2.0/grid
mkdir /u00/app/software

====== Clone Softaree from tar files you can use normal install====
Copy the following archives to /u00/app/software:
  restart-11.2.0.3.15-rhel-6.6-x_64-1.0.tgz
  database-sa-11.2.0.3.15-rhel-6.6-x_64-1.0.tgz
  soe-standalone-asm.dbt

cd /u00/11.2.0/grid
tar zxpf /u00/app/software/restart-11.2.0.3.15-rhel-6.6-x_64-1.0.tgz
cd /u00/11.2.0/grid/clone/bin
perl clone.pl ORACLE_HOME=/u00/11.2.0/grid ORACLE_BASE=/u00/app/oracle INVENTORY_LOCATION=/u00/app/oraInventory CRS=TRUE
sudo /u00/app/oraInventory/orainstRoot.sh
sudo /u00/11.2.0/grid/root.sh
cat logfile

sudo /u00/11.2.0/grid/perl/bin/perl -I/u00/11.2.0/grid/perl/lib -I/u00/11.2.0/grid/crs/install /u00/11.2.0/grid/crs/install/roothas.pl

if it fails, decofigure HAS, fix the problem and re-run
  /u00/11.2.0/grid/crs/install/roothas.pl -deconfig -force

set environment to ASM

crsctl modify resource ora.cssd -attr "AUTO_START=1"
srvctl add listener -p 2521
srvctl start listener
crsctl stop has
crsctl start has
res

create $ORACLE_HOME/dbs/init+ASM.ora

*._shared_pool_reserved_pct=10
*.asm_diskstring='/etc/asmdisk/data','/etc/asmdisk/fra','/etc/asmdisk/redo1','/etc/asmdisk/redo2'
*.asm_power_limit=1
*.diagnostic_dest='/u00/app/oracle'
*.instance_type='asm'
*.large_pool_size=12M
*.processes=300
*.remote_login_passwordfile='EXCLUSIVE'
*.sga_max_size=2147483648
*.sga_target=1572864000
*.shared_pool_size=1073741824

srvctl add asm
crsctl modify resource ora.asm -attr "AUTO_START=1"

sqlplus / as sysasm
  startup pfile=/u00/11.2.0/grid/dbs/init+ASM.ora
  create spfile from pfile;

srvctl modify asm -p /u00/11.2.0/grid/dbs/spfile+ASM.ora
srvctl modify asm -l LISTENER

rm init+ASM.ora
crsctl stop has
crsctl start has
res

create diskgroups (AU=4M, Database Compatibility=11.2.0.0.0)

mkdir -p /u00/app/oracle/product/11.2.0/db_1
cd /u00/app/oracle/product/11.2.0/db_1
tar zxpf /u00/app/software/database-sa-11.2.0.3.15-rhel-6.6-x_64-1.0.tgz
cd clone/bin
perl clone.pl ORACLE_HOME=/u00/app/oracle/product/11.2.0/db_1 ORACLE_BASE=/u00/app/oracle
sudo /u00/app/oracle/product/11.2.0/db_1/root.sh




mv /u00/app/software/soe-standalone-asm.dbt /u00/app/oracle/product/11.2.0/db_1/assistants/dbca/templates

create database using soe-standalone-asm template and changing all environment-specific parameters, names etc
  note SYS/SYSTEM password

run postinstall for patch 21068553; details are in $ORACLE_HOME/README.txt
 
create tnsnames.ora sqlnet.ora

configure backups
  create rman user
  configure rman
  note RMAN password

put in place .profile, ~/techm and crontab

prepare for database monitoring
  alter user DBSNMP identified by <password> account unlock;

prepare for ASM monitoring
  orapwd file='orapw+ASM'  entries=5 password=<password>
  sqlplus / as sysasm
    create user ASMSNMP identified by <password>;
    grant sysdba to ASMSNMP;
 
reboot host and check that everything starts up correctly

configure OEM monitoring