setupdatabase&as&aservice using&em12c db#plugin12.1.0 · 2013-02-20 ·...
TRANSCRIPT
Setup Database as a Service using EM12c DB Plugin 12.1.0.3 Date: 20/02/13 Author: Rob Zoeteweij http://oemgc.wordpress.com 15 February, an update of some Plugins was released.
The new version of the DB plugin (12.1.0.3) includes several new features in the area of diagnostics, High Availability, Manageability, RAC and Grid Infrastructure, Security etc. The list of new plugins include the brand new plugin “Oracle Storage Management Framework”, enabling Snap Clone functionality leveraging the “Snapshot” and Copy features of the underlying storage. The new and updated plugins are packaged with new features including “Testing as a Service”, “Snap Clone”, “Schema as a Service” and “RMAN based Database Provisioning”. This document describes an example of the setup of the Database Cloud, by using a Service Template that is based on a DBCA template. It also shows an example of the execution of a request made by a user in the Self Service Portal, using the newly created Service Template. Checkout the documentation for more detailed descriptions and examples: http://docs.oracle.com/cd/E24628_01/doc.121/e28814/cloud_db_using.htm
The Setup of the Database Cloud Before we can start setting up the Database as a Service we need to create a PaaS Infrastructure Zone. For the administrative steps to do the PaaS Infrastructure setup, I have created an Administrator called “CLOUD_ADMIN”. This Administrator has granted the role “EM_CLOUD_ADMINISTRATOR” that allows him to setup and deploy the cloud
infrastructure (servers, pools, zones) and to perform operations for performance and configuration management.
Next we will connect to the EM12c Console as administrator CLOUD_ADMIN. From the Enterprise Menu select Cloud Middleware and Database Home.
Next from the Middleware and Database Cloud menu select Create PaaS Infrastructure Zone.
Press [Next]
Add those Targets to be included in the PaaS Infrastructure Zone (in this example I have included host myserver1.mycorpdomain.com). Press [Next]
By adding roles we can limit the access to this PaaS Infrastructure Zone. In this example I have add 3 “Developer” roles. NOTE As this step involves the authorization of users to servers, we might consider assigning this task to a Security Role! Press [Next]
After a final review, to make sure you have entered everything correctly, press [Submit] to create the Zone.
Next we will perform the same steps to create the PaaS Infrastructure Zone for “Production” Lifecycle Phase Targets. This Zone will be accessible only by Operation Support Engineers only, as they are the only authorized personnel to access the Production Environment.
Now we have finished setting up the Platform as a Service Infrastructure we can start with the setup of Database as a Service. For the administrative steps to do the DBaaS setup, I have created an Administrator called “DBAAS_ADMIN”. This Administrator has granted the role “EM_SSA_ADMINISTRATOR” that allows him to define quotas and constraints for self service users and grant them access privileges.
Next we connect to the EM12c Console as the DBAAS_ADMIN administrator:
Next we will navigate Setup Cloud Database
Here we need to start to setup our Database Pools. A Database Pool is a collection of Database Servers or Clusters that will participate in your Database As A Service setup. Each of these Servers or Clusters should have the Database Software installed.
We will select [Create] to create one of our Database Pools. Notice that we can now choose between the creation of Database Pool for Database creation or Schema Requests.
In this page we will define a name and description for the Pool. We select already created Named Credentials that will be used during execution of database creation requests. Notice that is this page you can select the PaaS Infrastructure Zone you want the Pool to be created, the Platform (in our example Linux x86-‐64), a specific Database Configuration (Database Instance or Cluster Database) and the version of the Database we want to be able to create in this Pool (in our example 11.2.0.3). By using the [Add] icon we will be able to include the Oracle Homes where we want to locate our Databases. Note that we will only be able to find homes that are already present on one or more hosts. After indicating the max number of databases that can be created in the pool, we press [Submit] to finalize the creation of the Pool.
The next thing to do is the setup of Request Settings
In this example we say that: • There are no restrictions in the number of days a user can make any requests • There are no restrictions in the number of days before an archived request will be
deleted from the system • There are no restrictions in the number of days a request can last
Next we can set the quota for Memory, Storage and number of Databases per Role and number of Schema Service Requests that we allow to use (create).
Next we select Profile and Service Templates.
Let us first create a Profile that we can use later when creating our Service Templates. Press [Create]
I have used the magnifier icon to select database orcl1.mycorpdomain.com as based for the Profile I want to create. In this example I want to create a Provisioning Profile based on a DBCA template. So I select ‘Data Content’, ‘Structure Only’ and ‘Database Template’. I have deselected the rest of the options. Next I select the Named Credentials for both the host ‘myserver2.mycorpdomain.com’ and database ‘orcl1.mycorpdomain.com’ and press [Next] to continue. Press [Next]
In the profile page we now can indicate where in the Software Library we want the Profile to be stored, what name we want to give it. As you notice the properties ‘Profile Version’, ‘Vendor’ and ‘Notes’ are entered automatically. As in this example we want create this Profile immediately, we accept the defaults and press [Next]
Make sure all entered data is correct and press [Submit] to have the Profile created.
Next you see the complete flow of the procedure creating the Profile.
If we would now navigate Enterprise Provisioning and Patching Database Provisioning we will notice the just created Database Profile
When navigating from here to:
we end up in the Software Library
Notice the folders ‘Database Provisioning Profile’ – ’11.2.0.3.0’ – ‘Linux_x64’ that were created by DBAAS_ADMIN and the Database Template and Database Provisioning Profile that were created and located to the Software Library, ready to be used. Now we return to the Database Cloud Self Service Setup page to continue Here we will create the Service Template
Select ‘For Database’ as this is what we want to create the Template for
In this page we enter a name and description for the Service Template. We select the Profile we have just created and acknowledge the fact that we want to use this Service Template to support the creation of a Single Instance Database. The page next enables us to enter a prefix of three letters and Domain Name to be used for the name of a newly created Database. Finally we specify the Listener Port that need to be used. Press [Next]
In the next page we specify the File System location for the database files to be created and enter a password for the SYS, SYSTEM and DBSNMP users in the new database. Optionally we could have chosen to enable the usage of Fast Recovery, but skipped is for this example. Press [Next]
The Initialization Parameters Page allows you to adjust the Initialization Parameters for any new database created based on this Service Template, by selecting a Parameter and press the [Set] icon. Press [Next]
You might want to use the possibility to include a Pre-‐/Post Database Creation script to for instance: create entries in OID Oracle Internet Directory) or to configure a Tape Management System to allow for backup of the newly created database, etc. Press [Next]
In the next page we need to add the Zone we allow this Service Template to create databases (“Development Zone” in this example). Press [Next]
In the next page we need to add the Role(s) that we allow to use the Service Template we are creating (“CS_FINANCE_DEV” in this example). Press [Next]
The next page shows us the data we just entered to create the Service Template. Assuming we entered the correct data, we press [Submit] to complete the creation of this Service Template.
Finally we need to address the Charge Back maintenance pages.
We address the Charge Back maintenance pages by selecting the ‘Chargeback’ option from the Enterprise Menu.
Reference Oracle® Enterprise Manager Cloud Administration Guide 12c Release 2 (12.1.0.2) Chapter 4 Chargeback Administration Next we select Configure Charge Plan
By selecting a Metric and pressing the [Edit] icon we can set the rates for each of the resource metrics CPU, Memory and Storage
In this example we will charge a dollar per day for usage of a CPU, 2 dollars per day for the usage of 2GB Memory and a dollar per day for the usage of 1GB Storage. The Date Range field shows that the Universal Plan settings we just did will be valid from 01-‐nov-‐2012 and onward. Next we will create an Extended Chargeback Plan to charge for usage of Software Licenses and Datacentre facilities (cooling, racks etc.)
Press [Create] to create a new Extended Plan and enter a name for it
In this example we have created an Extended Charge plan where we will charge $1 a day for usage of Oracle Database Licenses. In the same example we will charge $1.25 per day for using Oracle Weblogic Licenses. Next we will define Cost Centres to allow Chargeback being based on it
In this example we have create a Cost Centre structure with ‘THE BUSINESS” as Top and “FINANCE” and “IT” underneath Please note that we are also able to base this structure on LDAP integration Next we will assign a Charge Back plan to our Targets
Accessing and using the Self Service Portal We will now connect to the Self Service Portal as user FINANCE_DEV1
Notice that this user as granted two Roles: • EM_SSA_USER to allow access to the Self Service Portal • US_FINANCE_DEV to allow access to the “Development, Test and Acceptance”
Lifecycle phase targets owned sued by the FINANCE Line of Business After the Database Cloud has been set up we will now access the Self Service Portal as user FINANCE_DEV1 We have selected the “My Databases” option and see that this user has created no Databases yet. We will now request for the creation of a Database by pressing the [Request Database] button
From the Service Template overview we will select the “Create Single Instance…” template and press [Select]
We will leave the automatic generated Request Name and select the “Development Zone” to deploy our database in.
During the deployment of the new Database, we need to specify a name of the administration user for this database. Note that you are not allowed to use any of the default administration users like SYS and SYSTEM. In this example we use “master” as the administrative user for the new database. As we can’t wait to see what will happen, we will schedule for immediate execution Press [Submit]
Notice that the creation of the database is ‘Scheduled When connected to the EM Console as CLOUD_ADMIN and navigating to Provisioning Procedure Activity, I see the following:
When selecting link DBAAS-‐CREATE-‐#1 (in this example) we will get an overview of the Procedure progress
After completion of the procedure we re-‐connect to the Self Service Portal as user FINANCE_DEV1
Notice that from the Self Service Portal I am able to delete the Database as well. When selecting the database that was just created you will get a complete status overview page, allowing you to Stop / Start the Database.
Notice that the name of the newly created Database includes ‘DBS’ as 3 letter prefix and .mycorpdomain.com as the domain.