HOL6749: Deploy Oracle RAC in Minutes on Oracle OpenStack for

Sep 21, 2016 - dependency require_all/restart svc:/network/rpc/bind (online) ..... Oracle and Java are registered trademarks of Oracle and/or its affiliates.
5MB taille 92 téléchargements 543 vues
HOL6749: Deploy Oracle RAC in Minutes on Oracle OpenStack for Oracle Solaris Bruno Philippe Sales Consultant, Oracle France

Christophe Pauliat Sales Consultant, EMEA Solution Center, Oracle

Eric Bezille Chief technologist, Oracle France

Onder Ozbek Product Manager, Oracle

Sonit Tayal Product Manager, Oracle

CONTENTS 1

INTRODUCTION ............................................................................................................................................. 3 1.1 1.2

2

CREATE THREE SOLARIS INSTANCES FROM OPENSTACK CONSOLE ................................................ 4 2.1 2.2 2.3 2.4 2.5

3

CONNECT TO ALL INSTANCES ...................................................................................................................... 10 SHARED STORAGE CONFIGURATION ............................................................................................................. 10 CONFIGURE LOCAL HOSTNAMES RESOLUTION .............................................................................................. 11 MOUNT SHARED STORAGE .......................................................................................................................... 14 OPTIMIZE OUR CONFIGURATION ................................................................................................................... 14 CONFIGURE SSH KEYS FOR USERS GRID AND ORACLE ................................................................................. 15

ORACLE RAC CONFIGURATION ............................................................................................................... 16 4.1 4.2 4.3

5

LAB ENVIRONMENT ....................................................................................................................................... 4 CONNECT TO OPENSTACK DASHBOARD (HORIZON CONSOLE) ........................................................................ 4 START THE SOLARIS INSTANCES ................................................................................................................... 5 SIMULATE THE DEPLOYMENT OF A NEW INSTANCE FOR ORACLE RAC (OPTIONAL) ............................................ 7 ASSOCIATE FLOATING IP ADDRESSES FOR YOUR ORACLE RAC INSTANCES ..................................................... 9

PREREQUISITES FOR ORACLE RAC CONFIGURATION ........................................................................ 10 3.1 3.2 3.3 3.4 3.5 3.6

4

LAB OBJECTIVE ............................................................................................................................................ 3 LAB ENVIRONMENT ....................................................................................................................................... 3

CONFIGURE ORACLE GRID INFRASTRUCTURE .............................................................................................. 16 CONFIGURE ORACLE DATABASE ORACLE_HOME ..................................................................................... 18 DEPLOY AN ORACLE RAC DATABASE .......................................................................................................... 19

APPENDIX A: REFERENCES ...................................................................................................................... 20 5.1 5.2

OFFICIAL DOCUMENTATION ......................................................................................................................... 20 GET THIS DOCUMENT .................................................................................................................................. 20

Last update: September 21, 2016 Author: Bruno Philippe, Christophe Pauliat Special thanks to: Onder Ozbek, Sonit Tayal, Joost Pronk Van Hoogeveen, Glynn Foster

HOL6749: DEPLOY ORACLE RAC IN MINUTES ON ORACLE OPENSTACK FOR ORACLE SOLARIS

2

1 Introduction 1.1

Lab objective

This document details all actions that we will be run during Oracle OpenWorld 2016 session Hands On Lab HOL6749. In this hands-on lab you will deploy an Oracle Database Real Application Cluster 12c environment in an Oracle OpenStack for Oracle Solaris private cloud. Several technical elements are covered in order to build the required virtual network, Oracle Database, and storage components.

1.2

Lab environment

You will use laptops to access a shared Solaris OpenStack environment composed of: • 1 physical server (Oracle X6-2) providing 2 Solaris kernel zones used for OpenStack Controller and Network Controller (L3 agent) • 2 OpenStack compute nodes (Oracle T5-2 and T7-2 physical servers) • 1 Storage system providing iSCSI LUNs (Oracle ZS3-2) • 10 Giga Ethernet networks between those components. See picture of environment below

HOL6749: DEPLOY ORACLE RAC IN MINUTES ON ORACLE OPENSTACK FOR ORACLE SOLARIS

3

2 Create three Solaris instances from OpenStack console 2.1

Lab environment

Each attendee will use dedicated OpenStack user, project, networks net1 and net2) and Solaris instances. You will use 3 Solaris instances: •

rac1

: 1st Solaris 11.3 instance, used as RAC 1st node



rac2

: 2nd Solaris 11.3 instance, used as RAC 2nd node



nfs

: nfs server providing shared storage needed for Oracle RAC to rac1 and rac2

To save time during this lab, all 3 instances were already created for each user.

2.2

Connect to OpenStack Dashboard (Horizon console)

a)

Ask instructors for your user number (between 1 and 40)

b)

On your laptop, start a Firefox web browser and open OpenStack horizon URL: https://10.158.200.21/horizon

c)

Connect with following credentials • User name : oowuser • Password : oowuser

(nn is your user number between 1 and 40)

HOL6749: DEPLOY ORACLE RAC IN MINUTES ON ORACLE OPENSTACK FOR ORACLE SOLARIS

4

You should get a view similar to the following:

2.3 a)

Start the Solaris instances On the left panel, click instances to see your instances You should see you 3 instances

Note: you may also see some other instances used by other labs. If so, please ignore them. b)

Make sure your 3 instances are running (check status in the ‘Power State’ column) If some of them are not running, for each click ‘Start Instance’ on the right (or select them and click ‘Start Instances’ in the ‘More Actions’ pull-down menu.

HOL6749: DEPLOY ORACLE RAC IN MINUTES ON ORACLE OPENSTACK FOR ORACLE SOLARIS

5

HOL6749: DEPLOY ORACLE RAC IN MINUTES ON ORACLE OPENSTACK FOR ORACLE SOLARIS

6

2.4

Simulate the deployment of a new instance for Oracle RAC (optional)

This step is optional. It is provided to show you how the rac1 and rac2 instances were created before the lab. a)

Check the availability zones

We created 2 OpenStack availability zones (1 per compute node) to be able to force location of instances on compute-1 (T5-2 server) or compute-2 (T7-2). • nfs and rac2 instances were created on compute-2 (T7) • rac1 instances were created on compute-1 (T5)

b)

Click ‘Lauch instance’ to request a new instance In the ‘Details’ tab, select: o Availability zone : compute-2 o Flavor : Oracle Solaris kernel – small o Image : HOL6749 – RAC o 2 networks

(this flavor has 4 VCPUs and 4 GB of memory) (customized unified archived imported in OpenStack Glance)

HOL6749: DEPLOY ORACLE RAC IN MINUTES ON ORACLE OPENSTACK FOR ORACLE SOLARIS

7

c)

Click ‘Access & Security’ tab o o

Select the existing SSH Key Pair Enter a root password (set to solaris11 on the existing instances)

d)

Click ‘Networking’ tab o First, select the oowuer_net1 for NIC:1 o Then, select the oowuer_net2 for NIC:2

e)

Click Cancel Note: we don’t want to actually create the instance since it is already created, so just click Cancel. You can see below what you would get if you would click Launch.

HOL6749: DEPLOY ORACLE RAC IN MINUTES ON ORACLE OPENSTACK FOR ORACLE SOLARIS

8

After a few minutes, you would get your instance up and running.

2.5

Associate Floating IP addresses for your Oracle RAC instances

The Solaris instances use private networks so are not yet reachable from your laptop. To give access, you need to associate Floating IP addresses for the laptop network to rac1 and rac2 instances (not needed for nfs). a)

For rac2 instance, click ‘Associate Floating IP’

b)

Select an IP address from the list, then click Associate.

note: make sure to use port for network 192.170.nn.0 c)

Do the same for rac1

d)

Note the floating IP addresses used for rac1 and rac2.

HOL6749: DEPLOY ORACLE RAC IN MINUTES ON ORACLE OPENSTACK FOR ORACLE SOLARIS

9

3 Prerequisites for Oracle RAC configuration 3.1

Connect to all instances

For RAC1: In your Laptop, open a terminal and connect with floating IP address for rac1 ouser@oow-hol-master$ ssh root@

For RAC2: In your Laptop, open a terminal and connect with floating IP address for rac2 ouser@oow-hol-master$ ssh root@

For NFS: You cannot ssh directly to the nfs server from the Openworld laptops as there is no floating IP for this instance. Instead: •

Connect to rac1 or rac2 via in another terminal



Get the IP address of the nfs instance from Horizon dashboard (192.170.nn.x)



# ssh –i /root/.ssh/keypriv

Note: all 3 instances use the same SSH key, so you can use the SSH public key from rac1 root user to connect to rac2 and nfs (TO DO: to be checked) Alternatively, you can connect to nfs console from the Dashboard (TO DO: only works if root password set)

3.2

Shared storage configuration

IMPORTANT: Before you can deploy Oracle RAC on the 2 Solaris instances, you must provide shared storage to both instances (NFS shares in our case). This cannot be done by OpenStack as OpenStack does not yet support shared volumes. To simulate a shared storage, we have created a specific Solaris instance used as NFS server (instance called nfs) a)

Check configuration of NFS server root@nfs:~# svcs -l nfs/server fmri svc:/network/nfs/server:default name NFS server enabled true state online next_state none state_time September 12, 2016 08:35:30 PM UTC logfile /var/svc/log/network-nfs-server:default.log

HOL6749: DEPLOY ORACLE RAC IN MINUTES ON ORACLE OPENSTACK FOR ORACLE SOLARIS

10

restarter contract_id manifest manifest dependency dependency dependency dependency dependency dependency dependency dependency

svc:/system/svc/restarter:default 113 /etc/svc/profile/generic.xml /lib/svc/manifest/network/nfs/server.xml require_any/error svc:/milestone/network (online) require_all/error svc:/network/nfs/nlockmgr (online) optional_all/error svc:/network/nfs/mapid (online) require_all/restart svc:/network/rpc/bind (online) optional_all/none svc:/network/rpc/keyserv (disabled) optional_all/none svc:/network/rpc/gss (online) optional_all/none svc:/system/filesystem/reparse (online) require_all/error svc:/system/filesystem/local (online)

The daemon must be up and running b)

Check the shared storage root@nfs:~# zfs get share NAME rpool/u02/oracle/datas rpool/u02/oracle/voting

Two shares are available: o /u02/oracle/datas o /u02/oracle/voting c)

PROPERTY share share

VALUE SOURCE name=rpool_u02_oracle_datas,path=/u02/oracle/datas,prot=nfs,anon=0 local name=rpool_u02_oracle_voting,path=/u02/oracle/voting,prot=nfs,anon=0 local

will be used for data of databases will be used for data of grid (OCR, Voting Files, and data of Management Database)

Optimize shared storage

It’s recommended to optimize shared storage to obtain the best performance of IO operations. You can see reference on this document: Configuring Oracle Database for OLTP on SPARC T5 Series Servers with the Oracle ZFS Storage Appliance as Primary Storage (http://www.oracle.com/technetwork/server-storage/sun-unified-storage/documentation/oracledb-rac-sparc-zfssa-2414324.pdf) root@nfs:~# zfs set recordsize=128K rpool/u02/oracle/voting root@nfs:~# zfs set logbias=latency rpool/u02/oracle/voting root@nfs:~# zfs set recordsize=8K rpool/u02/oracle/datas root@nfs:~# zfs set logbias=throughput rpool/u02/oracle/datas root@nfs:~# ipadm set-prop -p send_buf=1048576 tcp root@nfs:~# ipadm set-prop -p recv_buf=1048576 tcp root@nfs:~# ipadm set-prop -p max_buf=2097152 tcp Note: to save time you can copy/paste the commands from text below: zfs set recordsize=128K rpool/u02/oracle/voting zfs set logbias=latency rpool/u02/oracle/voting zfs set recordsize=8K rpool/u02/oracle/datas zfs set logbias=throughput rpool/u02/oracle/datas ipadm set-prop -p send_buf=1048576 tcp ipadm set-prop -p recv_buf=1048576 tcp ipadm set-prop -p max_buf=2097152 tcp

3.3

Configure local hostnames resolution

In real life, Oracle RAC requires DNS hostnames resolution. For Simplicity during this lab, we only use local hostname resolution (using /etc/hosts files). a)

Clear DNS configuration

root@rac1:~# svcadm disable dns/client;

rm /etc/resolv.conf

root@rac2:~# svcadm disable dns/client;

rm /etc/resolv.conf



b)

Get the IP addresses that were assigned by Openstack to your instances From the Openstack Dashboard, look at instances, note the following IP addresses: o IP address for rac1 on net1 (192.170.40.4 in the following example) o IP address for rac1 on net2 (192.171.40.3 in the following example) o IP address for rac2 on net1 (192.170.40.5 in the following example) o IP address for rac2 on net2 (192.171.40.4 in the following example)

HOL6749: DEPLOY ORACLE RAC IN MINUTES ON ORACLE OPENSTACK FOR ORACLE SOLARIS

11

o

c)

IP address for nfs on net1

(192.170.40.3 in the following example)

Update file /etc/inet/hosts on rac1 root@rac1:~# vi /etc/inet/hosts If you are user number , please use networks 192.170..0 and 192.171..0 Example of file updated for user 40. Parts in red must be changed to match your case. # # Copyright 2009 Sun Microsystems, Inc. # Use is subject to license terms. # # Internet host table # ::1 localhost 127.0.0.1 localhost loghost # Servers 192.170.40.3 192.170.40.4 # Cluster 192.170.40.100 192.170.40.101 192.170.40.102 192.170.40.103 192.170.40.104

rac1 rac2

All rights reserved.

# IP address for rac1 on net1 # IP address for rac2 on net1

rac1-vip rac2-vip oraclu01-scan oraclu01-scan oraclu01-scan

# Private link for RAC 192.171.40.3 rac1-priv 192.171.40.4 rac2-priv

# IP address for rac1 on net2 # IP address for rac2 on net2

# Storage (NFS server) 192.170.40.3 storage nfs

# IP address for nfs on net1

HOL6749: DEPLOY ORACLE RAC IN MINUTES ON ORACLE OPENSTACK FOR ORACLE SOLARIS

12

Note: to save time you can copy/paste the commands from text below: ::1 localhost 127.0.0.1 localhost loghost # Servers 192.170.40.3 rac1 # IP address for rac1 on net1 192.170.40.4 rac2 # IP address for rac2 on net1 # Cluster 192.170.40.100 rac1-vip 192.170.40.101 rac2-vip 192.170.40.102 oraclu01-scan 192.170.40.103 oraclu01-scan 192.170.40.104 oraclu01-scan # Private link for RAC 192.171.40.3 rac1-priv # IP address for rac1 on net2 192.171.40.4 rac2-priv # IP address for rac2 on net2 # Storage (NFS server) 192.170.40.3 storage nfs # IP address for nfs on net1 d)

IMPORTANT: Double check that the /etc/inet/hosts file is correct, or you will have problems later. Make sure you can ping rac1, rac2, rac1-priv, rac2-priv and nfs root@rac1:~# ping rac1 root@rac1:~# ping rac2 root@rac1:~# ping rac1-priv root@rac1:~# ping rac2-priv root@rac1:~# ping nfs root@rac1:~# ping storage Note : storage and nfs are aliases for the nfs server

e)

Copy this files to rac2 and nfs instances root@rac1:~# scp –i /root/.ssh/keypriv –p /etc/inet/hosts rac2:/etc/inet/hosts root@rac1:~# scp –i /root/.ssh/keypriv –p /etc/inet/hosts nfs:/etc/inet/hosts Note: all 3 instances use the same ssh key, so you can use the public SSH key of rac1 to connect to rac2 and nfs (TO DO: to be checked)

f)

TIPS to resolve DNS name of SCAN Address During RAC initialization, the process (named cluvfy) checks the DNS resolution of SCAN Address. In our lab, we don’t use DNS resolution. To resolve this step, we have modified the /usr/sbin/nslookup command (moved original file to /usr/sbin/nslookup.original and created a script named /usr/sbin/nslookup). Modify the /usr/sbin/nslookup file to use your IP addresses on rac1 root@rac1:~# vi /usr/sbin/nslookup Replace the parts in red by your user number (from 1 to 40) LISTE=$* HOSTNAME="${@: -1}" if [[ $HOSTNAME = "oraclu01-scan" ]]; then echo "Server: 192.170.40.30" echo "Address: 192.170.40.30#53\n"

else

echo echo echo echo echo echo

"Name: "Address: "Name: "Address: "Name: "Address:

oraclu01-scan" 192.170.40.102" oraclu01-scan" 192.170.40.103" oraclu01-scan" 192.170.40.104"

/usr/sbin/nslookup.original $LISTE fi root@rac1:~# scp -i /root/.ssh/keypriv -p /usr/sbin/nslookup rac2:/usr/sbin/nslookup root@rac1:~# scp -i /root/.ssh/keypriv -p /usr/sbin/nslookup nfs:/usr/sbin/nslookup

HOL6749: DEPLOY ORACLE RAC IN MINUTES ON ORACLE OPENSTACK FOR ORACLE SOLARIS

13

3.4

Mount shared storage

Before the configuration of RAC, you must mount the shared storage on each node of Oracle RAC. The SMF service of NFS client is already up and running.

root@rac1:~# root@rac1:~# root@rac1:~# root@rac1:~#

cat /export/work/vfstab >> /etc/vfstab mountall -r chown grid:asmadmin /u02/oracle/voting chown oracle:oinstall /u02/oracle/datas

root@rac2:~# cat /export/work/vfstab >> /etc/vfstab root@rac2:~# mountall -r

For information, the added lines for files /etc/vfstab are shown below: storage:/u02/oracle/voting - /u02/oracle/voting nfs - yes rw,bg,hard,nointr,rsize=1048576,wsize=1048576,proto=tcp,vers=3,noac,forcedirectio storage:/u02/oracle/datas - /u02/oracle/datas nfs - yes rw,bg,hard,nointr,rsize=1048576,wsize=1048576,proto=tcp,noac,vers=3,suid

3.5

Optimize our configuration

Before the configuration of RAC, it’s better to optimize configuration (network and swap size) for the best performance.

root@rac1:~# root@rac1:~# root@rac1:~# root@rac1:~# root@rac1:~# root@rac1:~# root@rac1:~#

ipadm ipadm ipadm ipadm ipadm ipadm ipadm

set-prop set-prop set-prop set-prop set-prop set-prop set-prop

-p -p -p -p -p -p -p

smallest_anon_port=9000 smallest_anon_port=9000 largest_anon_port=65500 largest_anon_port=65500 max_buf=2097152 tcp send_buf=1048576 tcp recv_buf=1048576 tcp

tcp udp tcp udp

root@rac1:~# zfs set volsize=4g rpool/swap

root@rac2:~# root@rac2:~# root@rac2:~# root@rac2:~# root@rac2:~# root@rac2:~# root@rac2:~#

ipadm ipadm ipadm ipadm ipadm ipadm ipadm

set-prop set-prop set-prop set-prop set-prop set-prop set-prop

-p -p -p -p -p -p -p

smallest_anon_port=9000 smallest_anon_port=9000 largest_anon_port=65500 largest_anon_port=65500 max_buf=2097152 tcp send_buf=1048576 tcp recv_buf=1048576 tcp

tcp udp tcp udp

root@rac2:~# zfs set volsize=4g rpool/swap

Note: to save time you can copy/paste the lines below ipadm set-prop -p smallest_anon_port=9000 tcp ipadm set-prop -p smallest_anon_port=9000 udp ipadm set-prop -p largest_anon_port=65500 tcp ipadm set-prop -p largest_anon_port=65500 udp ipadm set-prop -p max_buf=2097152 tcp ipadm set-prop -p send_buf=1048576 tcp ipadm set-prop -p recv_buf=1048576 tcp zfs set volsize=4g rpool/swap



HOL6749: DEPLOY ORACLE RAC IN MINUTES ON ORACLE OPENSTACK FOR ORACLE SOLARIS

14

3.6

Configure SSH keys for users grid and oracle

This is a prerequisite before deploying Oracle Clusterware so that grid and oracle users can run non-interactive commands on remote node without entering password. a)

For user grid

root@rac1:~# /export/work/sshUserSetup.sh -user grid -hosts "rac1 rac2" \ -advanced -exverify -noPromptPassphrase Note: you will be asked for the grid user (grid12) password 4 times b)

For user oracle

root@rac1:~# /export/work/sshUserSetup.sh -user oracle -hosts "rac1 rac2" \ -advanced -exverify -noPromptPassphrase Note: you will be asked for the grid user (oracle12) password 4 times

HOL6749: DEPLOY ORACLE RAC IN MINUTES ON ORACLE OPENSTACK FOR ORACLE SOLARIS

15

4 Oracle RAC configuration 4.1

Configure Oracle Grid infrastructure

Oracle Grid infrastructure binaries are already installed on your 2 Solaris instances (contained in the Glance image used during deployment by OpenStack). Now, you need to configuration the Oracle Grid infrastructure (including Oracle Clusterware). a)

Connect to rac1 instance with user grid

root@rac1:~# su - grid b)

Edit response file /export/work/rac.rsp

Change the configuration of network (see line 260 in this response file). oracle.install.crs.config.networkInterfaceList=net0:192.170.40.0:1,net1:192.171.40.0:2 net0 is the public network 192.170..0 user for database access net1 is the private network 192.171..0 used for RAC interconnect c)

(nn is your user number between 1 and 40) (nn is your user number between 1 and 40)

Configure Oracle Grid infrastructure

grid@rac1:~$ /u01/app/12.1.0/grid/crs/config/config.sh -silent -responseFile /export/work/rac.rsp This operation will take a few minutes. Notes: • •

d)

st

This script only needs to be executed on the 1 RAC node (rac1) Ignore the following warnings: o [WARNING] [INS-41310] More than one Oracle Cluster Registry is in the same partition. o [WARNING] [INS-41508] More than one voting disk file is located on the same partition. o weak passwords or disks (voting and ocr). st

Execute post-installation script on 1 Oracle RAC node as root user

grid@rac1:~$ exit root@rac1:~# /u01/app/12.1.0/grid/root.sh This operation will take a few minutes. IMPORTANT: make sure to complete this before continuing e)

nd

Execute post-installation script on 2 Oracle RAC node as root user

root@rac2:~# /u01/app/12.1.0/grid/root.sh This operation will take a few minutes.

IMPORTANT: • Your Oracle Grid Infrastructure is now up and running. • In the version 12c of Database, there is a specific database used for the management (aka MGMTDB). The next step will create this specific database.

HOL6749: DEPLOY ORACLE RAC IN MINUTES ON ORACLE OPENSTACK FOR ORACLE SOLARIS

16

f)

Configure management database as grid user

root@rac1:~# su - grid grid@rac1:~$ /u01/app/12.1.0/grid/cfgtoollogs/configToolAllCommands RESPONSE_FILE=/export/work/p.r st

Note: This script only needs to be executed on the 1 RAC node (rac1) g)

Check Oracle Grid configuration You can check the Grid configuration with the crsctl command. Only resource ora.asm must be offline (because we don’t use ASM in our lab). grid@rac1:~$ exit root@rac1:~# /u01/app/12.1.0/grid/bin/crsctl status res -t -------------------------------------------------------------------------------Name Target State Server State details -------------------------------------------------------------------------------Local Resources -------------------------------------------------------------------------------ora.LISTENER.lsnr ONLINE ONLINE rac1 STABLE ONLINE ONLINE rac2 STABLE ora.asm OFFLINE OFFLINE rac1 STABLE OFFLINE OFFLINE rac2 Instance Shutdown,ST ABLE ora.net1.network ONLINE ONLINE rac1 STABLE ONLINE ONLINE rac2 STABLE ora.ons ONLINE ONLINE rac1 STABLE ONLINE ONLINE rac2 STABLE -------------------------------------------------------------------------------Cluster Resources -------------------------------------------------------------------------------ora.LISTENER_SCAN1.lsnr 1 ONLINE ONLINE rac1 STABLE ora.LISTENER_SCAN2.lsnr 1 ONLINE ONLINE rac2 STABLE ora.LISTENER_SCAN3.lsnr 1 ONLINE ONLINE rac2 STABLE ora.MGMTLSNR 1 ONLINE ONLINE rac2 169.254.48.23 10.10. 212.6,STABLE ora.cvu 1 ONLINE ONLINE rac2 STABLE ora.mgmtdb 1 ONLINE ONLINE rac2 Open,STABLE ora.oc4j 1 ONLINE ONLINE rac2 STABLE ora.rac1.vip 1 ONLINE ONLINE rac1 STABLE ora.rac2.vip 1 ONLINE ONLINE rac2 STABLE ora.scan1.vip 1 ONLINE ONLINE rac1 STABLE ora.scan2.vip 1 ONLINE ONLINE rac2 STABLE ora.scan3.vip 1 ONLINE ONLINE rac2 STABLE --------------------------------------------------------------------------------

HOL6749: DEPLOY ORACLE RAC IN MINUTES ON ORACLE OPENSTACK FOR ORACLE SOLARIS

17

4.2

Configure Oracle Database ORACLE_HOME

Oracle Database binaries are already installed on your 2 Solaris instances (contained in the Glance image used during deployment by OpenStack). To configure this product (rdbms binaries), we use a clone copy. a)

On both nodes (rac1 and rac2), connect to user oracle root@rac1:~# su - oracle root@rac2:~# su - oracle

b)

On both nodes (rac1 and rac2), edit file /export/work/clone to modify attribute LOCAL_NODE by our hostname. See below examples of files after editing oracle@rac1:~$ cat /export/work/clone $ORACLE_HOME/perl/bin/perl $ORACLE_HOME/clone/bin/clone.pl ORACLE_BASE="/u01/app/oracle" ORACLE_HOME="/u01/app/oracle/product/12.1.0/db" \ OSDBA_GROUP=dba OSOPER_GROUP=oper -defaultHomeName CLUSTER_NODES="{rac1,rac2}" LOCAL_NODE="rac1"

oracle@rac2:~$ cat /export/work/clone $ORACLE_HOME/perl/bin/perl $ORACLE_HOME/clone/bin/clone.pl ORACLE_BASE="/u01/app/oracle" ORACLE_HOME="/u01/app/oracle/product/12.1.0/db" \ OSDBA_GROUP=dba OSOPER_GROUP=oper -defaultHomeName CLUSTER_NODES="{rac1,rac2}" LOCAL_NODE="rac2"

c)

Deploy Oracle Database rdbms binaries on rac1

You execute this clone command with oracle user

oracle@rac1:~$ bash /export/work/clone

Please wait for the completion of the script before continuing. oracle@rac1:~$ exit root@rac1:~# /u01/app/oracle/product/12.1.0/db/root.sh

d)

Deploy Oracle Database rdbms binaries on rac2

You execute this clone command with oracle user

oracle@rac2:~$ bash /export/work/clone Please wait for the completion of the script before continuing. oracle@rac2:~$ exit root@rac2:~# /u01/app/oracle/product/12.1.0/db/root.sh

HOL6749: DEPLOY ORACLE RAC IN MINUTES ON ORACLE OPENSTACK FOR ORACLE SOLARIS

18

4.3

Deploy an Oracle RAC database

To create manually a new Oracle RAC Database, you can use the graphical interface (dbca). From your laptop, open a new session with oracle user with X11 forward (password is oracle12).

oowuser@laptop:~$ ssh -X oracle@

oracle@rac1:~$ dbca



HOL6749: DEPLOY ORACLE RAC IN MINUTES ON ORACLE OPENSTACK FOR ORACLE SOLARIS

19

5 Appendix A: References 5.1

Official documentation

Product

Web site for product documentation

Oracle Database 12c Release 1 (12.1):

http://docs.oracle.com/database/121/

Oracle Solaris 11.3

http://docs.oracle.com/cd/E53394_01/

Oracle OpenStack for Oracle Solaris

http://docs.oracle.com/cd/E65465_01/

5.2

Get this document

This document is available online at http://blogs.oracle.com/cpauliat/entry/hol_oow2016

Oracle Corporation, World Headquarters

Worldwide Inquiries

500 Oracle Parkway

Phone: +1.650.506.7000

Redwood Shores, CA 94065, USA

Fax: +1.650.506.7200

CONNECT WITH US

blogs.oracle.com/oracle

twitter.com/oracle

Copyright © 2016, Oracle and/or its affiliates. All rights reserved. This document is provided for information purposes only, and the contents hereof are subject to change without notice. This document is not warranted to be error-free, nor subject to any other warranties or conditions, whether expressed orally or implied in law, including implied warranties and conditions of merchantability or fitness for a particular purpose. We specifically disclaim any liability with respect to this document, and no contractual obligations are formed either directly or indirectly by this document. This document may not be reproduced or transmitted in any form or by any means, electronic or mechanical, for any purpose, without our prior written permission.

oracle.com

Oracle and Java are registered trademarks of Oracle and/or its affiliates. Other names may be trademarks of their respective owners.

facebook.com/oracle

Intel and Intel Xeon are trademarks or registered trademarks of Intel Corporation. All SPARC trademarks are used under license and are trademarks or registered trademarks of SPARC International, Inc. AMD, Opteron, the AMD logo, and the AMD Opteron logo are trademarks or registered trademarks of Advanced Micro Devices. UNIX is a registered trademark of The Open Group. 0916

HOL6749: DEPLOY ORACLE RAC IN MINUTES ON ORACLE OPENSTACK FOR ORACLE SOLARIS

20