deploying oracle database 12c on oracle zfs storage appliance · deploying oracle database 12c on...

31
Deploying Oracle Database 12c on Oracle ZFS Storage Appliance Paul Johnson Principle Software Engineer Ravindran Renganathan Principal Product Manager

Upload: lamnga

Post on 29-May-2018

376 views

Category:

Documents


4 download

TRANSCRIPT

Page 1: Deploying Oracle Database 12c on Oracle ZFS Storage Appliance · Deploying Oracle Database 12c on Oracle ZFS Storage Appliance Paul Johnson ... Oracle Database, 12c Container and

Deploying Oracle Database 12c on Oracle ZFS Storage Appliance Paul Johnson Principle Software Engineer

Ravindran Renganathan Principal Product Manager

Page 2: Deploying Oracle Database 12c on Oracle ZFS Storage Appliance · Deploying Oracle Database 12c on Oracle ZFS Storage Appliance Paul Johnson ... Oracle Database, 12c Container and

DEPLOYING ORACLE DATABASE 12C WITH ORACLE ZFS STORAGE APPLIANCE

Table of Contents

Introduction 1

Provisioning the Oracle ZFS Storage Appliance 2

Log in to the Browser User Interface 2

Create a Project 3

Create Shares 5

Enable SNMP to activate OISP and HCC 8

Provisioning Oracle Linux 11

Terminal 11

Create a Directory Structure 11

Edit /etc/fstab for the New Shares 11

Mount the Shares 11

Enable dNFS 11

Create a Database 13

Use DBCA to Create a Database 13

Monitor Progress and Performance Using Oracle ZFS Storage Analytics 26

Navigate to the Analytics section 26

Add a Statistic 26

Create a Tablespace with HCC 28

Page 3: Deploying Oracle Database 12c on Oracle ZFS Storage Appliance · Deploying Oracle Database 12c on Oracle ZFS Storage Appliance Paul Johnson ... Oracle Database, 12c Container and

1 | DEPLOYING ORACLE DATABASE 12C WITH ORACLE ZFS STORAGE APPLIANCE

Introduction

This hands-on lab demonstrates how to install and manage Oracle Database 12c with Oracle ZFS

Storage Appliance. You’ll learn how to apply Oracle Hybrid Columnar Compression, the Oracle

Intelligent Storage Protocol feature of Oracle ZFS Storage Appliance, the Direct NFS Client feature of

Oracle Database, 12c Container and Pluggable Databases, and more. In addition, you’ll learn how

easy it is to use Oracle ZFS Storage Appliance software to configure services, create and use storage

shares, and monitor database performance with Oracle ZFS Storage Appliance analytics.

This hands-on lab comes with the following components pre-installed:

1. Oracle ZFS Storage Appliance VM Simulator running OS8.6

2. Oracle Linux 6.8 VM

3. Oracle Database 12c Release 1 (12.1)

4. Patch 19630940 for OISP Analytics

Page 4: Deploying Oracle Database 12c on Oracle ZFS Storage Appliance · Deploying Oracle Database 12c on Oracle ZFS Storage Appliance Paul Johnson ... Oracle Database, 12c Container and

2 | DEPLOYING ORACLE DATABASE 12C WITH ORACLE ZFS STORAGE APPLIANCE

Provisioning the Oracle ZFS Storage Appliance

Log in to the Browser User Interface 1. Open a web browser by double-clicking on the Firefox icon on the desktop.

2. Enter https://192.168.56.101:215 into web browser window.

3. In web browser, enter oracle as Username and oow as Password, then press the LOGIN button.

Page 5: Deploying Oracle Database 12c on Oracle ZFS Storage Appliance · Deploying Oracle Database 12c on Oracle ZFS Storage Appliance Paul Johnson ... Oracle Database, 12c Container and

3 | DEPLOYING ORACLE DATABASE 12C WITH ORACLE ZFS STORAGE APPLIANCE

4. The Oracle ZFS Storage Appliance Status Dashboard will be displayed.

Create a Project A project is a collection of filesystems and LUNs that share the same common settings. By grouping all shares into the same project, the management of the storage becomes simplified.

1. Begin by clicking on Shares on the top toolbar.

2. Click on PROJECTS, then click on the + icon to create a new project.

3. Name the project hol1521.

Page 6: Deploying Oracle Database 12c on Oracle ZFS Storage Appliance · Deploying Oracle Database 12c on Oracle ZFS Storage Appliance Paul Johnson ... Oracle Database, 12c Container and

4 | DEPLOYING ORACLE DATABASE 12C WITH ORACLE ZFS STORAGE APPLIANCE

4. Once the project has been created, edit the hol1521 project by selecting the pencil icon.

5. With the hol1521 project opened, select General at the top to view the project settings.

6. The following changes will need to be made:

a. Mountpoint should be /export/hol1521

b. Update access time on read should be deselected

c. User should be 54321

d. Group should be 54321

Page 7: Deploying Oracle Database 12c on Oracle ZFS Storage Appliance · Deploying Oracle Database 12c on Oracle ZFS Storage Appliance Paul Johnson ... Oracle Database, 12c Container and

5 | DEPLOYING ORACLE DATABASE 12C WITH ORACLE ZFS STORAGE APPLIANCE

7. Click APPLY at the top right.

Create Shares The database will be stored on the Oracle ZFS Storage Appliance Simulator. There will need to be three shares setup to store the datafiles, redo logs & control files, and fast recovery area.

Page 8: Deploying Oracle Database 12c on Oracle ZFS Storage Appliance · Deploying Oracle Database 12c on Oracle ZFS Storage Appliance Paul Johnson ... Oracle Database, 12c Container and

6 | DEPLOYING ORACLE DATABASE 12C WITH ORACLE ZFS STORAGE APPLIANCE

1. Click on Shares next to General to begin creation. Do not click SHARES on the top toolbar since this will deselect the current project.

2. Click the + icon to create a new filesystem.

3. Create a share called datafiles and click APPLY.

Page 9: Deploying Oracle Database 12c on Oracle ZFS Storage Appliance · Deploying Oracle Database 12c on Oracle ZFS Storage Appliance Paul Johnson ... Oracle Database, 12c Container and

7 | DEPLOYING ORACLE DATABASE 12C WITH ORACLE ZFS STORAGE APPLIANCE

4. Create a share called fra and click APPLY.

5. Create a share called logs and click APPLY.

Page 10: Deploying Oracle Database 12c on Oracle ZFS Storage Appliance · Deploying Oracle Database 12c on Oracle ZFS Storage Appliance Paul Johnson ... Oracle Database, 12c Container and

8 | DEPLOYING ORACLE DATABASE 12C WITH ORACLE ZFS STORAGE APPLIANCE

You should now have three shares created: datafiles, fra, and logs.

Enable SNMP to activate OISP and HCC

Oracle Intelligent Storage Protocol (OISP) is a unique file storage protocol for Oracle Database 12c and Oracle ZFS Storage Appliance that allows storage to have database awareness. Oracle Intelligent Storage Protocol enables continuous communication between database and storage, automatically and dynamically optimizing critical tuning parameters in real time.

Oracle Intelligent Storage Protocol is available exclusively with the combination of Oracle Database 12c and the Oracle ZFS Storage Appliance because it requires the intelligence on both the database host side and the storage side to pass and interpret cues from the database. With Oracle Intelligent Storage Protocol, Oracle Database can send over 70 different cues, which Oracle ZFS Storage Appliance categorizes into 5 different groups. The different database file types can now be differentiated by the Oracle ZFS Storage Appliance. Oracle Intelligent Storage Protocol dynamically and automatically adjusts share parameter settings to tune the storage system for optimal database performance on the fly. Traditionally, multiple shares would have to be set up for different database file types, each with its own settings all tuned manually by an administrator. But with Oracle Intelligent Storage Protocol and the Oracle ZFS Storage Appliance, the entire process is automated.

Hybrid Columnar Compression (HCC) is an Oracle Database compression technology which enables the highest levels of data compression and provides enterprises with cost savings and performance improvements due to reduced I/O. Average storage savings can range from 6x to 15x, depending on which Hybrid Columnar Compression level is implemented. Hybrid Columnar Compression gives database administrators the flexibility to select from four different levels of Data Warehouse or Archive compression to balance storage savings and I/O reduction with CPU resource utilization. Hybrid Columnar Compression can be enabled on Oracle Databases residing on dNFS shares without ASM on an Oracle ZFS Storage Appliance beginning with Oracle Database Enterprise Edition 11.2.0.3.

Oracle Intelligent Storage Protocol and Hybrid Columnar Compression both rely on SNMP to establish the initial relationship between Oracle Database 12c and Oracle ZFS Storage Appliance.

1. Navigate to Configuration à Services.

Page 11: Deploying Oracle Database 12c on Oracle ZFS Storage Appliance · Deploying Oracle Database 12c on Oracle ZFS Storage Appliance Paul Johnson ... Oracle Database, 12c Container and

9 | DEPLOYING ORACLE DATABASE 12C WITH ORACLE ZFS STORAGE APPLIANCE

2. Click on SNMP underneath System Settings.

3. The following settings should be set:

a. Version: v1/2c

b. Community name: public

c. Authorized network/mask: 0.0.0.0 / 0

d. Appliance contact: HOL

e. Trap destinations: 127.0.0.1

Page 12: Deploying Oracle Database 12c on Oracle ZFS Storage Appliance · Deploying Oracle Database 12c on Oracle ZFS Storage Appliance Paul Johnson ... Oracle Database, 12c Container and

10 | DEPLOYING ORACLE DATABASE 12C WITH ORACLE ZFS STORAGE APPLIANCE

4. Click the power-on button to enable the SNMP service.

5. Verify the SNMP LED turns on (green).

Page 13: Deploying Oracle Database 12c on Oracle ZFS Storage Appliance · Deploying Oracle Database 12c on Oracle ZFS Storage Appliance Paul Johnson ... Oracle Database, 12c Container and

11 | DEPLOYING ORACLE DATABASE 12C WITH ORACLE ZFS STORAGE APPLIANCE

Provisioning Oracle Linux The binaries for Oracle Database 12c have already been preinstalled on the Oracle Linux VM. They are held in the /u01/app/oracle directory.

Note: the password for this VM is oow.

Terminal

Open a new terminal session by double-clicking on the Terminal icon on the desktop:

Create a Directory Structure Each of the shares created on the storage will need a local directory to contain the mounts on the Oracle Linux VM. Please use the following locations:

$ sudo mkdir -p /zfssa/hol1521/datafiles $ sudo mkdir -p /zfssa/hol1521/fra $ sudo mkdir -p /zfssa/hol1521/logs

Edit /etc/fstab for the New Shares The entries have already been populated inside of /etc/fstab:

$ cat /etc/fstab 192.168.56.101:/export/hol1521/datafiles /zfssa/hol1521/datafiles nfs rw,bg,hard,nointr,rsize=1048576,wsize=1048576,tcp,vers=3,timeo=600,noac 0 0 192.168.56.101:/export/hol1521/fra /zfssa/hol1521/fra nfs rw,bg,hard,nointr,rsize=1048576,wsize=1048576,tcp,vers=3,timeo=600,noac 0 0 192.168.56.101:/export/hol1521/logs /zfssa/hol1521/logs nfs rw,bg,hard,nointr,rsize=1048576,wsize=1048576,tcp,vers=3,timeo=600,noac 0 0

Mount the Shares $ sudo mount -a

Enable dNFS The entries have already been populated inside of $ORACLE_HOME/dbs/oranfstab:

$ cat $ORACLE_HOME/dbs/oranfstab server: 192.168.56.101 path: 192.168.56.101 nfs_version: nfsv4 export: /export/hol1521/datafiles mount: /zfssa/hol1521/datafiles export: /export/hol1521/fra mount: /zfssa/hol1521/fra export: /export/hol1521/logs mount: /zfssa/hol1521/logs

Direct NFS, also known as dNFS, is the preferred method for database communication with the Oracle ZFS Storage Appliance. This feature optimizes I/O traffic by replacing the kernel NFS with an NFS client that is tailored specifically for Oracle software. It is only available in Oracle Database 11g and 12c.

$ cd $ORACLE_HOME/rdbms/lib

Page 14: Deploying Oracle Database 12c on Oracle ZFS Storage Appliance · Deploying Oracle Database 12c on Oracle ZFS Storage Appliance Paul Johnson ... Oracle Database, 12c Container and

12 | DEPLOYING ORACLE DATABASE 12C WITH ORACLE ZFS STORAGE APPLIANCE

$ make –f ins_rdbms.mk dnfs_on rm -f /u01/app/oracle/product/12.1.0/dbhome_1/lib/libodm12.so; cp /u01/app/oracle/product/12.1.0/dbhome_1/lib/libnfsodm12.so /u01/app/oracle/product/12.1.0/dbhome_1/lib/libodm12.so

Page 15: Deploying Oracle Database 12c on Oracle ZFS Storage Appliance · Deploying Oracle Database 12c on Oracle ZFS Storage Appliance Paul Johnson ... Oracle Database, 12c Container and

13 | DEPLOYING ORACLE DATABASE 12C WITH ORACLE ZFS STORAGE APPLIANCE

Create a Database

Use DBCA to Create a Database DBCA, the Database Configuration Assistant, is a tool to create, configure, or destroy an Oracle database. It will be utilized in this lab in order to facilitate a database install.

1. Launch dbca from the terminal.

$ dbca

2. In the new window that opens, select Create Database and click Next.

Page 16: Deploying Oracle Database 12c on Oracle ZFS Storage Appliance · Deploying Oracle Database 12c on Oracle ZFS Storage Appliance Paul Johnson ... Oracle Database, 12c Container and

14 | DEPLOYING ORACLE DATABASE 12C WITH ORACLE ZFS STORAGE APPLIANCE

3. Click on Advanced Mode and click Next.

Page 17: Deploying Oracle Database 12c on Oracle ZFS Storage Appliance · Deploying Oracle Database 12c on Oracle ZFS Storage Appliance Paul Johnson ... Oracle Database, 12c Container and

15 | DEPLOYING ORACLE DATABASE 12C WITH ORACLE ZFS STORAGE APPLIANCE

4. Select General Purpose or Transaction Processing and click Next.

Page 18: Deploying Oracle Database 12c on Oracle ZFS Storage Appliance · Deploying Oracle Database 12c on Oracle ZFS Storage Appliance Paul Johnson ... Oracle Database, 12c Container and

16 | DEPLOYING ORACLE DATABASE 12C WITH ORACLE ZFS STORAGE APPLIANCE

5. Enter hol1521 for Global Database Name and hol1521 for SID. Click Next.

6. Deselect Configure Enterprise Manager (EM) Database Express and click Next. Enterprise

Page 19: Deploying Oracle Database 12c on Oracle ZFS Storage Appliance · Deploying Oracle Database 12c on Oracle ZFS Storage Appliance Paul Johnson ... Oracle Database, 12c Container and

17 | DEPLOYING ORACLE DATABASE 12C WITH ORACLE ZFS STORAGE APPLIANCE

Manager is not necessary for this lab.

7. Select Use the Same Administrative Password for All Accounts. Enter oow into both

Page 20: Deploying Oracle Database 12c on Oracle ZFS Storage Appliance · Deploying Oracle Database 12c on Oracle ZFS Storage Appliance Paul Johnson ... Oracle Database, 12c Container and

18 | DEPLOYING ORACLE DATABASE 12C WITH ORACLE ZFS STORAGE APPLIANCE

password fields. Click Next.

Page 21: Deploying Oracle Database 12c on Oracle ZFS Storage Appliance · Deploying Oracle Database 12c on Oracle ZFS Storage Appliance Paul Johnson ... Oracle Database, 12c Container and

19 | DEPLOYING ORACLE DATABASE 12C WITH ORACLE ZFS STORAGE APPLIANCE

8. Click Next on the following screen.

9. Configure to use the NFS shares:

a. Select Use Common Location for All Database Files. Type /zfssa/hol1521/datafiles into the File Location field.

b. Select Use Oracle-Managed Files.

c. Select Specify Fast Recovery Area. Type /zfssa/hol1521/fra into the Fast

Page 22: Deploying Oracle Database 12c on Oracle ZFS Storage Appliance · Deploying Oracle Database 12c on Oracle ZFS Storage Appliance Paul Johnson ... Oracle Database, 12c Container and

20 | DEPLOYING ORACLE DATABASE 12C WITH ORACLE ZFS STORAGE APPLIANCE

Recovery Area field.

10. Click Multiplex Redo Logs and Control Files. Type /zfssa/hol1521/logs into the first

input field. Click OK to close the window. Click Next.

Page 23: Deploying Oracle Database 12c on Oracle ZFS Storage Appliance · Deploying Oracle Database 12c on Oracle ZFS Storage Appliance Paul Johnson ... Oracle Database, 12c Container and

21 | DEPLOYING ORACLE DATABASE 12C WITH ORACLE ZFS STORAGE APPLIANCE

11. Click Next on the following screen.

Page 24: Deploying Oracle Database 12c on Oracle ZFS Storage Appliance · Deploying Oracle Database 12c on Oracle ZFS Storage Appliance Paul Johnson ... Oracle Database, 12c Container and

22 | DEPLOYING ORACLE DATABASE 12C WITH ORACLE ZFS STORAGE APPLIANCE

12. Click Next on the following screen.

Page 25: Deploying Oracle Database 12c on Oracle ZFS Storage Appliance · Deploying Oracle Database 12c on Oracle ZFS Storage Appliance Paul Johnson ... Oracle Database, 12c Container and

23 | DEPLOYING ORACLE DATABASE 12C WITH ORACLE ZFS STORAGE APPLIANCE

13. Click Next on the following screen.

Page 26: Deploying Oracle Database 12c on Oracle ZFS Storage Appliance · Deploying Oracle Database 12c on Oracle ZFS Storage Appliance Paul Johnson ... Oracle Database, 12c Container and

24 | DEPLOYING ORACLE DATABASE 12C WITH ORACLE ZFS STORAGE APPLIANCE

14. Click Finish on the following screen.

Page 27: Deploying Oracle Database 12c on Oracle ZFS Storage Appliance · Deploying Oracle Database 12c on Oracle ZFS Storage Appliance Paul Johnson ... Oracle Database, 12c Container and

25 | DEPLOYING ORACLE DATABASE 12C WITH ORACLE ZFS STORAGE APPLIANCE

15. The database will begin the creation process. No action is needed here.

Page 28: Deploying Oracle Database 12c on Oracle ZFS Storage Appliance · Deploying Oracle Database 12c on Oracle ZFS Storage Appliance Paul Johnson ... Oracle Database, 12c Container and

26 | DEPLOYING ORACLE DATABASE 12C WITH ORACLE ZFS STORAGE APPLIANCE

Monitor Progress and Performance Using Oracle ZFS Storage Analytics Analytics is an advanced facility that you can use to graph a variety of statistics in real-time and record this data for later viewing. It has been designed for both long term monitoring and short term analysis. When needed, it makes use of DTrace to dynamically create custom statistics, which allows different layers of the operating system stack to be analyzed in detail.

Navigate to the Analytics section While the database is installing, click on the Analytics tab on the right side of the upper taskbar.

Add a Statistic On the left side of the browser, click on the + icon next to Add statistic to bring up the statistic menu.

The most relevant statistics for database performance analysis can be found in the NFSv4 category. Select ‘Broken down by Application ID.’

Analytics has been designed around an effective performance analysis technique called drill-down analysis. This involves checking high level statistics first, and to focus on finer details based on findings so far. This allows you to quickly narrow the focus to the most likely areas.

Page 29: Deploying Oracle Database 12c on Oracle ZFS Storage Appliance · Deploying Oracle Database 12c on Oracle ZFS Storage Appliance Paul Johnson ... Oracle Database, 12c Container and

27 | DEPLOYING ORACLE DATABASE 12C WITH ORACLE ZFS STORAGE APPLIANCE

After the database has been created, click on Close.

Page 30: Deploying Oracle Database 12c on Oracle ZFS Storage Appliance · Deploying Oracle Database 12c on Oracle ZFS Storage Appliance Paul Johnson ... Oracle Database, 12c Container and

28 | DEPLOYING ORACLE DATABASE 12C WITH ORACLE ZFS STORAGE APPLIANCE

Create a Tablespace with HCC 1. Change the ORACLE_SID to hol1521, then use SQL*PLUS to interface with the Oracle 12c Database.

$ export ORACLE_SID=hol1521 $ sqlplus / as sysdba SQL*Plus: Release 12.1.0.2.0 Production on Sun Aug 7 09:22:14 2016 Copyright (c) 1982, 2014, Oracle. All rights reserved. Connected to: Oracle Database 12c Enterprise Edition Release 12.1.0.2.0 - 64bit Production With the Partitioning, OLAP, Advanced Analytics and Real Application Testing options

2. Create a tablespace with HCC for hol1521 to be contained on the Oracle ZFS Storage Appliance.

SQL> create bigfile tablespace hol1521 datafile '/zfssa/hol1521/datafiles/hol1521.dbf' size 100M default compress for query high;

Page 31: Deploying Oracle Database 12c on Oracle ZFS Storage Appliance · Deploying Oracle Database 12c on Oracle ZFS Storage Appliance Paul Johnson ... Oracle Database, 12c Container and

Oracle Corporation, World Headquarters 500 Oracle Parkway Redwood Shores, CA 94065, USA

Worldwide Inquiries Phone: +1.650.506.7000 Fax: +1.650.506.7200

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 and Java are registered trademarks of Oracle and/or its affiliates. Other names may be trademarks of their respective owners. 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. 0115 Deploying Oracle Database 12c with Oracle ZFS Storage Appliance September 2016 Author: Paul Johnson

C O N N E C T W I T H U S

blogs.oracle.com/oracle

facebook.com/oracle

twitter.com/oracle

oracle.com