Skip Headers
Oracle® Enterprise Manager Cloud Administration Guide
12c Release 3 (12.1.0.3)

E28814-10
Go to Documentation Home
Home
Go to Book List
Book List
Go to Table of Contents
Contents
Go to Index
Index
Go to Feedback page
Contact Us

Go to previous page
Previous
Go to next page
Next
PDF · Mobi · ePub

12 ­­Setting Up the DBaaS Self Service Portal

This chapter describes the procedure to set up and use the Database Self Service Portal. It contains the following sections:

12.1 Setting Up the Database Cloud Self Service Portal

The Database Cloud Self Service Portal is a Web page where Cloud users can request, monitor, and manage their own databases using Enterprise Manager. An administrator with the EM_SSA_ADMINISTRATOR role can configure and set up the database self service portal by defining database pools, service templates, and so on.

12.2 Using DBaaS to Provision Databases

You can provision databases based on:

12.2.1 DBaaS Using Snap Clone Based Database Provisioning Profile

You can create a snap clone of a large database which will allow to quickly provision the database. The snap clone is stored in the Software Library and can be used to create service templates and provision databases. The snap clone feature is useful if your data size is very large and the database files are present on supported storage systems like ZFS Storage Appliance and NetApp Storage System. See Section 11.8, "Registering and Managing Storage Servers" for details.

To provision a database using snapshots, follow these steps:

  1. Follow the steps in the Getting Started section to enable DBaaS. See Section 11.2, "Getting Started".

  2. Set up one or more PaaS Infrastructure Zones. See Section 9.3, "Creating a PaaS Infrastructure Zone".

  3. Create a Database Pool. See Section 12.5, "Creating a Database Pool".

  4. Configure the request settings. See Section 12.6, "Configuring Request Settings".

  5. Define quotas for each self service user. See Section 12.7, "Setting Up Quotas".

  6. Register the storage server. See Section 11.8, "Registering and Managing Storage Servers".

  7. Create a database provisioning profile using a snap clone. Snap clones are available only if the storage system such as ZFS Storage Appliance or Netapp Storage System has been registered and the database is running on it. See Section 12.8.1.1, "Creating a Database Provisioning Profile Using Snapshots".

  8. Create a service template that is based on the profile you have created. See Section 12.8.2, "Creating a Database Service Template".

  9. Configure the Chargeback Service. See Section 22, "Chargeback Administration"

  10. While deploying a database, select the service template (associated with the snapshot based profile) you have created. See Section 13.2, "Requesting Databases, Pluggable Databases, and Schemas".

12.2.2 DBaaS Using RMAN Backup Based Database Provisioning Profile

Database backups created by RMAN (Recovery Manager) are stored as image copies or backup sets. To provision a database using RMAN backup, follow these steps:

  1. Follow the steps in the Getting Started section to enable DBaaS. See Section 11.2, "Getting Started".

  2. Set up one or more PaaS Infrastructure Zones. See Section 9.3, "Creating a PaaS Infrastructure Zone".

  3. Create a Database Pool. See Section 12.5, "Creating a Database Pool".

  4. Configure the request settings. See Section 12.6, "Configuring Request Settings".

  5. Define quotas for each self service user. See Section 12.7, "Setting Up Quotas".

  6. Register the storage server. See Section 11.8, "Registering and Managing Storage Servers" .

  7. Create a database provisioning profile using RMAN Backup. See Section 12.8.1.2, "Creating a Database Provisioning Profile Using RMAN Backup".

  8. Create a service template that is based on the profile you have created. See Section 12.8.2, "Creating a Database Service Template".

  9. Configure the Chargeback Service. See Section 22, "Chargeback Administration"

  10. While deploying a database, select the service template (associated with the RMAN Backup based profile) you have created. See Section 13.2, "Requesting Databases, Pluggable Databases, and Schemas".

12.2.3 DBaaS Using DBCA Template Based Database Provisioning Profile

You can create database (DBCA) templates that can be used to provision databases. To provision a database using DBCA templates, follow these steps:

  1. Follow the steps in the Getting Started section to enable DBaaS. See Section 11.2, "Getting Started".

  2. Set up one or more PaaS Infrastructure Zones. See Section 9.3, "Creating a PaaS Infrastructure Zone".

  3. Create a Database Pool. See Section 12.5, "Creating a Database Pool".

  4. Configure the request settings. See Section 12.6, "Configuring Request Settings".

  5. Define quotas for each self service user. See Section 12.7, "Setting Up Quotas".

  6. Register the storage server. See Section 11.8, "Registering and Managing Storage Servers".

  7. Create a database provisioning profile using a DBCA Template. See Section 12.8.1.4, "Creating a Database Provisioning Profile Using DBCA Template".

  8. Create a service template that is based on the profile you have created. See Section 12.8.2, "Creating a Database Service Template".

  9. Configure the Chargeback Service. See Section 22, "Chargeback Administration"

  10. While deploying a database, select the service template (associated with the DBCA template based profile) you have created. See Section 13.2, "Requesting Databases, Pluggable Databases, and Schemas".

12.3 Using Schema as a Service to Create Schemas

Enterprise Manager Schema as a Service feature allows you to create one or more schemas on a running database. Follow these steps to create a schema on a database:

  1. Create a database pool. See Section 12.3.1, "Creating a Database Pool for Schema as a Service".

  2. Configure the request settings. See Section 12.6, "Configuring Request Settings".

  3. Define quotas for each self service user. See Section 12.7, "Setting Up Quotas".

  4. Create a database provisioning profile. This step is optional and is required if you are importing schemas from a profile.

  5. Create a service template. A service template can contain:

    See Section 12.3.2, "Creating a Service Template for Schema as a Service".

  6. Configure the Chargeback service. See Section 22, "Chargeback Administration".

  7. Create the schema based on a specified service template. See Section 13.2.1, "Requesting a Schema".

12.3.1 Creating a Database Pool for Schema as a Service

You can create a database service with one or more schemas with or without seed data and database objects. To do so, follow these steps:

  1. Log into Enterprise Manager as a user with the EM_SSA_ADMINISTRATOR role.

  2. From the Setup menu, select Cloud, then select Database. The Database Cloud Self Service Portal Setup page appears.

  3. From the Create menu, select For Schema.

  4. Enter a name and description for the database pool.

  5. In the Credentials region, specify the credentials that will be used for performing database operations. Specify the following credentials:

    • Host: Required for starting the database.

    • Database: Required for creating schemas on the database.

    • Grid Infrastructure: Required for cluster databases.

  6. Specify the following details:

    • PaaS Infrastructure Zone: Select the PaaS Infrastructure Zone in which the databases are present. The schemas will be created on the databases selected for the pool.

    • Target Type: Specify the configuration of the target database on which the schema is being deployed. This can be Single Instance or Cluster Database (RAC).

    • Platform and Version: Specify the platform and version of the database being deployed.

  7. Click Add and select one or more databases to be added to the pool. All databases you select must be present in the same PaaS Infrastructure Zone.

    Note:

    You can search for database groups that meet your requirements by specifying a search string in the Groups field.
  8. Click Next. The Create New Pool: Policies page appears. Specify the placement policy constraints to set maximum ceilings for resource utilization on each database. Placement policy constraints for each database can be defined by services or workloads as follows:

    • Services: If you select this check box, you must specify the Maximum Number of Database Services that can be running on each database.

    • Workloads Associated with Service Requests: The amount of resources (such as CPU and memory) to manage the workload can be specified here. Specify the total workload for each database.

      • Maximum CPU Allocation: Specify the maximum CPU that can be allocated to each database.

      • Maximum Memory Allocation: Specify the maximum memory that can be allocated for each database.

  9. If you have chosen to set the placement constraints by Workloads Associated with Service Requests, you can choose to enable the resource manager by selecting the Enable Resource Manager for CPU check box. You can use the resource manager to manage the CPU resource and ensure that EM_SSA_USER will not exceed the maximum allocated value.

  10. Click Submit to create a database pool. The newly created database pool will appear in the Database Cloud Self Service Portal Setup: Database Pools page.

12.3.2 Creating a Service Template for Schema as a Service

One or more schemas can be created based on the service template definition. To create a service template for schema as a service, follow these steps:

  1. Log into Enterprise Manager as a user with the EM_SSA_ADMINISTRATOR role.

  2. From the Setup menu, select Cloud, then select Database. The Database Cloud Self Service Portal Setup page appears.

  3. Click Profiles and Service Templates. In the Service Templates region, select For Schema from the Create menu. The Create Service Template: Name page appears.

    Figure 12-1 Create Service Template: Name (Schema)

    Create New Service Template: Name
  4. Enter a name and description for the service template. The description must be unique and provide information on the type of service template being created.

  5. In the Source region, you can choose to:

    • Create User Defined Schemas: Select this option to create empty schemas which can be configured by the user. If you select this option, you can specify the Maximum Number of Schemas that can be created.

    • Import Schemas from Profile: Select a database provisioning profile from which the schema is to be imported. Click the Search icon next to the Profile field and select an export schema objects based profile from the list. If a profile does not exist, you must create one. See Section 12.8.1.5, "Creating a Database Provisioning Profile Using Export Schema Objects".

      • Master Account: If you select the Import Schemas from Profile option, you must select the Master Account that has privileges on all the schemas. If the Master Account is not selected, the EM_SSA_USER will select it when requesting a schema.

  6. In the Zones region, click Add to select a PaaS Infrastructure Zone into which the service instance is to be provisioned. Click Assign Pool to add a Database Pool for the zone.

  7. After you have selected the zone and the pool, the host target is populated in the Reference Host field.

  8. If you creating a service template based on an export schema objects profile, in the Dump File Location region, specify the Path or the shared location on all hosts in which the schema dumps are present. The Dump File Location must be accessible by all the databases.

  9. Click Next. The Create New Service Template: Configurations page appears.

    Figure 12-2 Create Service Template: Schema Details (Schema)

    Create New Service Template: Schema Details

    Specify the following details:

    • Workload Size: Workload represents the total CPU, memory, and storage requirements for each service. You can define workload sizes such as small, medium, and large. Click Create and in the Create Workload window, enter the name, CPU, Memory, and Storage limit for each service.

    • Role: Specify the role to which the database privileges such as CREATE_SESSION, CREATE DIMENSION, and so on will be granted. Enter the name of the user and the privileges that will be granted to the user.

      Note:

      • If the role with the name specified already exists in the database, the database privileges cannot be modified.

      • The Master Account will have the CREATE SESSION, CREATE DIMENSION, CREATE INDEXTYPE, CREATE OPERATOR, CREATE PROCEDURE, CREATE SEQUENCE, CREATE TABLE, CREATE TRIGGER, CREATE TYPE, CREATE VIEW, and CREATE SYNONYM privileges over all the schemas created as part of this service request.

    • Tablespace: Specify the tablespace storage configuration. Enter the following details:

      • Maximum Size: The maximum size of the tablespace can be Unlimited or Specified by the workload size selected at request time.

      • Auto Extend: Select this check box to automatically extend the new data file.

      • Initial Size: If you selected Specified by the workload size selected at request time in the Maximum Size field, enter the initial size of the tablespace.

      • Increment: If you have selected the Auto Extend checkbox, specify the size by which the data file is to be automatically incremented.

  10. Click Next. The Create Service Template: Scripts page appears. Specify the custom scripts that need to be executed before and after the service instance has been created. See Section 12.12, "Pre and Post Request Creation / Deletion Scripts" for details.

    Figure 12-3 Create Service Template: Scripts (Schema)

    Create Service Template: Scripts Page
  11. Click Next. The Create Service Template: Roles page appears. Click Add to select the SSA user roles to which this service template will be available. All users belonging to the selected role can use this service template.

  12. Click Submit. The newly created service template will appear in the Database Cloud Self Service Portal Setup: Service Templates page. You can click on the Service Template Name link to view additional details.

12.4 Using DBaaS to Provision Pluggable Databases

An Oracle Database can contain a portable collection of schemas, schema objects, and nonschema objects, that appear to an Oracle Net client as a separate database. This self-contained collection is called a pluggable database (PDB). A multi-tenant container database (CDB) is a database that includes one or more PDBs. Oracle Database 12c Release 1 (12.1) and later versions allow you to create many PDBs within a single CDB.

Follow these steps to use DBaaS to provision pluggable databases:

  1. Create a database pool for PDB as a Service. See Section 12.10, "Creating a Database Pool for PDB as a Service".

  2. Configure the request settings. See Section 12.6, "Configuring Request Settings".

  3. Define quotas for each self service user. See Section 12.7, "Setting Up Quotas".

  4. Create a database provisioning profile. Section 12.8.1, "Creating a Database Provisioning Profile".

  5. Create a service template. A service template can contain:

    • Empty Pluggable Database: In this case, the service template is created with an empty schema.

    • Pluggable Database from a Profile: In this case, you can import schemas from a database provisioning profile. You can select this option for applications with data such as eBusiness applications.

    See Section 12.11, "Creating a Service Template for PDB as a Service".

  6. Configure the Chargeback service. See Section 12.9, "Configuring Chargeback"

  7. Create the pluggable database based on a specified service template.

12.5 Creating a Database Pool

A Database Pool contains a set of resources that can be used to provision a database instance within a PaaS Infrastructure Zone. A database pool is a collection of homogenous targets such as servers or clusters with database software installed.

To create a database pool for database as a service, follow these steps:

  1. Log into Enterprise Manager as a user with the EM_SSA_ADMINISTRATOR role.

  2. From the Setup menu, select Cloud, then select Database. The Database Cloud Self Service Portal Setup page appears.From the Create menu, select For Database. The Create New Pool page appears.

    Figure 12-4 Create Database Pool

    Create Database Pool
  3. In the Credentials region, specify the following credentials:

  4. Enter a name and description for the database pool.

  5. Specify the following details:

    • PaaS Infrastructure Zone: Select the PaaS Infrastructure Zone into which the database instance is to be provisioned.

    • Database Configuration: Specify the configuration of the database being provisioned. This can either be Single Instance or Cluster Database (RAC) but cannot be a combination of both.

    • Platform and Version: Specify the platform and version of the database being deployed.

  6. Click Add and select one or more Oracle Homes to be added to the database pool.

  7. In the Maximum Number of Database Instances (per host), enter the maximum number of database instances that can be running on each host in the pool.

    Note:

    For RAC databases. the value specified in this field is used to ensure that the nodes on which the database is be created meets this criteria.
  8. Click Submit to create a database pool. The newly created pool will appear in the Database Cloud Self Service Portal Setup: Database Pools page. The database pool can now be added to the Service Template.

12.6 Configuring Request Settings

You can configure the database request settings by specifying when a request can be made, its duration, and so on. To configure the request settings, follow these steps:

  1. Log into Enterprise Manager as a user with the EM_SSA_ADMINISTRATOR. role.

  2. From the Setup menu, select Cloud, then select Database. The Database Cloud Self Service Portal Setup page appears.

  3. Click the Request Settings tab. Specify the following:

    • Future Reservation Length: How far in advance a request can be scheduled. You can select:

      • No Restriction: A new database request can be scheduled on any date later than the current date.

      • Restricted Reservation: A new database request can be scheduled in the future within the period specified here. Any future request scheduled beyond the Restricted Reservation date will be denied.

        For example, if the Restricted Reservation is 1 year, and the current date is June 20, 2013, you can schedule a future request on or before June 20, 2014.

    • Request Archive Retention: Period after which the requests are automatically archived. You can select:

      • No Restriction: If this option is selected, requests are not archived.

      • Restricted Retention: Requests that older than the specified duration will be archived. The date on which a request is archived is based on the last modified date of the request.

        For example, if a request has been created on June 10, 2013 and the Restricted Retention period specified is 10 days. Suppose there are some associated child requests as follows:

        - Reschedule Request: Submitted on June 12

        - Start Instance: Submitted on June 14

        - Stop Instance: Submitted on June 17

        - Start Instance: Submitted on June 18

        - Delete Instance: Submitted on June 20

        Since the date on which the request was last modified is June 20, the request will be purged on June 30th (Restricted Retention = 10 days).

    • Default Retirement Period: The maximum period for which the service instance can be retained. You can select:

      • No Restriction: Requests do not have a end date and can be extended as required.

      • Restricted Duration: The period after which the service instance is to be released.

        For example, if the Restricted Duration is 15 days, and the request begin date is June 5, 2013, the service instance will be retired or released on June 25, 2013.

  4. Click Apply.

12.7 Setting Up Quotas

Quota is the aggregate amount of resources that can be granted to each self service user belonging to a certain role. This quota applies only to the databases provisioned through the Database Cloud Self Service Portal. To set up quotas, follow these steps:

  1. Log into Enterprise Manager as a user with the EM_SSA_ADMINISTRATOR role.

  2. From the Setup menu, select Cloud, then select Database. The Database Cloud Self Service Portal Setup page appears.

  3. Click the Quotas tab and then click Create.

    Note:

    Quota validation ensures that a request is executed only if the user's current usage is within the limits specified for the roles to which the user belongs. Only the direct roles are considered for the quota determination, and not nested ones.
  4. In the Create New Quota window, select the Role Name for which the quota is to be granted. Only roles that have the EM_SSA_USER privileges are displayed in the Select Roles dialog box. After you have selected the role, enter the following details:

    • Memory: Total allocated memory that can be assigned for all the databases owned by a specific user.

    • Storage: Total allocated storage that can be assigned for all the databases owned by a user.

    • Number of Database Requests: The number of databases that can be requested by a user at any point in time.

    • Number of Schema Service Requests: The number of database services that can be requested by the user.

    • Number of Pluggable Database Service Requests: The number of PDBs that can be requested by the user.

    For example, if a user has 3 roles and the quota defined for each role is as follows:

    Role Name Attribute Value
    Dev Role Memory 2 GB
      Storage 15 GB
      DB Requests 10
      Schema Requests 2
    Test Role Memory 5 GB
      Storage 10 GB
      DB Requests 12
      Schema Requests 3
    PM Role Memory Quota not set
      Storage Quota not set
      DB Requests Quota not set
      Schema Requests Quota not set

    The quota limits for each of the attributes would be determined based on all the roles to which a user directly belongs. For example, if a user has 3 roles with quota setup for each role as shown in the table below:

    The quota is calculated as the absolute maximum across the roles for each attribute value. For the user who belongs to the Dev, Test, and PM Role, the Quota is calculated as:

    Value for Memory = MAX (Dev, Test, PM) = MAX (2, 5, NA) = 5 GB

    Value for Storage = MAX (Dev, Test, PM) = MAX (15, 10, NA) = 15 GB

    Value for DB Requests = MAX (Dev, Test, PM) = MAX (10, 12, NA) = 12 Databases

    Value for DB Requests = MAX (Dev, Test, PM) = MAX (2, 3, NA) = 5 Database Services

    A sample quota validation log generated by the user request follows:

    ************** UserName - SSA_USER
    ******* Quota Limits:
    *** Memory: 10
    *** Storage: 10
    *** Instances: 10
    *** Services: 3
    ******* Current Usage:
    *** Memory Used: 6.732421875
    *** Storage Used: 5.28
    *** Instances Used: 5
    *** Services Used: 1
    

12.8 Setting Up Profiles and Service Templates

A database provisioning profile is an entity that captures source database information for provisioning. A profile can represent a complete database or a set of related schemas that form an application. A single profile can be used to create multiple service templates. See Section 12.8.1, "Creating a Database Provisioning Profile".

A service template is a standardized service definition that is offered to self service users to create databases or schemas. Self service users can create one or databases or schemas based on the service template definition. You can create a service template for:

The following figure shows a list of database profiles and service templates that have been created.

Figure 12-5 Profiles and Service Templates

Profiles and Service Templates

12.8.1 Creating a Database Provisioning Profile

A Database Provisioning Profile is an entity which contains software bits and configuration.

When a provisioning profile is created from an existing installation, it provides the flexibility to clone Grid Infrastructure (with software or configuration) and Oracle Database (with software or configuration).

An administrator can create a database provisioning profile as a one-time activity, which can be used by operators for mass deployments.

Using provisioning profile enables standardization in deployments and reduces need for rescheduling deployments by avoiding errors while configuring deployment procedures.

You can create a database provisioning profile, by using any of the following methods:

Note:

Before you create a provisioning profile, follow these prerequisites:
  • Ensure that the host has a reference database installed on it, for creating a database provisioning profile.

  • Ensure that the host is connected to a Management Agent installed and monitored in Enterprise Manager Cloud Control for communication.

12.8.1.1 Creating a Database Provisioning Profile Using Snapshots

Prerequisites for Creating a Database Provisioning Profile Using Snapshots

Before you create a database provisioning profile, follow these prerequisites:

  • Ensure that the storage server you want to register for storage is available on the network.

    Note:

    Only NetApp and SunZFS storage servers are supported in Enterprise Manager Cloud Control 12c.
  • Ensure that the storage server is connected to a Management Agent installed and monitored in Enterprise Manager Cloud Control for communication.

  • Ensure that the storage server is registered, and at least one database should be present which is enabled for Snap Clone.

Creating a Database Provisioning Profile Using Snapshots

To create a database provisioning profile, follow these steps:

  1. You can access the Database Provisioning page using either of the following ways:

    • From the Setup menu, select Cloud, and then select Database. On the Database Cloud Self Service Portal Setup, select Profiles and Service Templates. In the Profiles section, click Create.

    • From the Enterprise menu, select Provisioning and Patching, and then select Database Provisioning. On the Database Provisioning page, in the Profiles section, click Create.

  2. On the Reference Target page, click the search icon to select a target.

    Reference Target page
  3. In the Search and Select:Targets display box, select the database you want to create a profile for, and then, click Select.

    Search and Select Targets display box

    Note:

    Ensure that the database you select is enabled for Snap Clone. For information refer to Enabling or Disabling Snap Clone.
  4. On the Reference Target page, select the following:

    • Data Content

    • Structure and Data to include physical and structural files from the database

    • Create

    • Snapshots

    Reference Target page for Snapshot for Snap Clone
  5. In the Credentials section, select the database. In the Credentials column, you can select Named Credentials and then select a credential name from the Credential Name column (or) select Preferred Credentials. Click Next.

    Credentials
  6. On the Profile page, do the following:

    • In the Profile Information section, enter a unique profile name of your choice.

      For example:
      Snap Clone Profile for HR database 
      

      You can also enter a description of the profile, and notes for your reference.

    • In the Schedule section, you can choose to start the profile creation immediately, or you can schedule it for a later time.

    • Click Next.

    Profile Page for Snap Clone profile
  7. On the Review page, ensure that the selections you have made in the previous pages are correctly displayed and click Submit. Otherwise, click Back repeatedly till you reach the page where you want to make changes. Click Cancel to abort the provisioning profile creation.

    Review page for Snap Clone Profile

    Once you have submitted the provisioning profile creation job, the provisioning profile appears in the Database Provisioning page.The Database Provisioning page displays all the procedure steps.

12.8.1.2 Creating a Database Provisioning Profile Using RMAN Backup

To create a database provisioning profile, follow these steps:

  1. You can access the Database Provisioning page using either of the following ways:

    • From the Setup menu, select Cloud, and then select Database. On the Database Cloud Self Service Portal Setup, select Profiles and Service Templates. In the Profiles section, click Create.

    • From the Enterprise menu, select Provisioning and Patching, and then select Database Provisioning. On the Database Provisioning page, in the Profiles section, click Create.

  2. On the Reference Target page, click the search icon to select a target.

    Reference Target page for RMAN Backup
  3. In the Search and Select:Targets display box, select the database you want to create a profile for, and then, click Select.

    Search and Select Targets display box
  4. On the Reference Target page, select the following:

    • Data Content

    • Structure and Data to include physical and structural files from the database.

    • Create

    • RMAN Backup

    Reference Target page
  5. In the Credentials section, select the database. In the Credentials column, you can select Named Credentials and then select a credential name from the Credential Name column (or) select Preferred Credentials. Click Next.

    Credentials
  6. On the Content Options page, do the following:

    • Select Online Backup or Offline Backup.

    • Enter the number of channels.

    • (optional) Select Compress files and then select High, Medium, or Low strength of compression.

    • (optional) Select Use File Encryption and then, enter the password and confirm the password.

    • Select Directory for the Backup location, and enter the directory path (or) select Fast Recovery Area, which already contains a backup location.

      Note:

      Ensure that the given location is accessible to the nodes in the database pool.
    • Enter the backup file name format. This will be used to generate backup files.

      backup file tag, control file name, and control file tag.

    • Enter the backup file tag. Backup files will be tagged with this tag.

    • Enter the control file name. The control file backup will be generated with this name.

    • Click Next.

    Content Options page
  7. On the Profile page, do the following:

    • In the Profile Information section, enter a unique profile name of your choice.

      For example:
      RMAN Provisioning Profile for HR database
      

      You can also enter a description of the profile, and notes for your reference.

    • In the Schedule section, you can choose to start the profile creation immediately, or you can schedule it for a later time.

    • Click Next.

    Profile page for RMAN Backup
  8. On the Review page, ensure that the selections you have made in the previous pages are correctly displayed and click Submit. Otherwise, click Back repeatedly till you reach the page where you want to make changes. Click Cancel to abort the provisioning profile creation.

    Review page for RMAN Backup

    Once you have submitted the provisioning profile creation job, the provisioning profile appears in the Database Provisioning page.The Database Provisioning page displays all the procedure steps.

12.8.1.3 Creating a Database Provisioning Profile Using Existing RMAN Backup

To create a database provisioning profile, follow these steps:

  1. You can access the Database Provisioning page using either of the following ways:

    • From the Setup menu, select Cloud, and then select Database. On the Database Cloud Self Service Portal Setup, select Profiles and Service Templates. In the Profiles section, click Create.

    • From the Enterprise menu, select Provisioning and Patching, and then select Database Provisioning. On the Database Provisioning page, in the Profiles section, click Create.

  2. On the Reference Target page, click the search icon to select a target.

    Reference Target page
  3. In the Search and Select:Targets display box, select the database you want to create a profile for, and then, click Select.

    Search and Select Targets display box
  4. On the Reference Target page, select the following:

    • Data Content

    • Structure and Data to include physical and structural files from the database or Structure Only to include only the structural files in the template.

    • Create

    • Use Existing RMAN Backup

    Reference Target page for existing RMAN backup
  5. In the Credentials section, select the database. In the Credentials column, you can select Named Credentials and then select a credential name from the Credential Name column (or) select Preferred Credentials. Click Next.

    Credentials
  6. On the Content Options page, select an existing RMAN backup from the list provided.

    Note:

    The list of existing RMAN backups are fetched from the database.

    Click Next.

  7. On the Profile page, do the following:

    • In the Profile Information section, enter a unique profile name of your choice.

      For example:
      Existing RMAN Provisioning Profile mydb.example.com
      

      You can also enter a description of the profile, and notes for your reference.

    • In the Schedule section, you can choose to start the profile creation immediately, or you can schedule it for a later time.

    • Click Next.

    Profile page
  8. On the Review page, ensure that the selections you have made in the previous pages are correctly displayed and click Submit. Otherwise, click Back repeatedly till you reach the page where you want to make changes. Click Cancel to abort the provisioning profile creation.

    Review page for existing RMAN backup

    Once you have submitted the provisioning profile creation job, the provisioning profile appears in the Database Provisioning page.The Database Provisioning page displays all the procedure steps.

12.8.1.4 Creating a Database Provisioning Profile Using DBCA Template

To create a database provisioning profile, follow these steps:

  1. You can access the Database Provisioning page using either of the following ways:

    • From the Setup menu, select Cloud, and then select Database. On the Database Cloud Self Service Portal Setup, select Profiles and Service Templates. In the Profiles section, click Create.

    • From the Enterprise menu, select Provisioning and Patching, and then select Database Provisioning. On the Database Provisioning page, in the Profiles section, click Create.

  2. On the Reference Target page, click the search icon to select a target.

    Reference Target page
  3. In the Search and Select:Targets display box, select the database you want to create a profile for, and then, click Select.

    Search and Select Targets display box
  4. On the Reference Target page, select the following:

    • Data Content

    • Structure Only to include only the structural files in the template.

    • Create

    • DBCA Template

    • Convert to Oracle Flexible Architecture (OFA) structure to ensure that discrepancy in directory structure in the reference host will not affect the database template creation.

    Reference Target page for DBCA Template
  5. In the Credentials section, select the database. In the Credentials column, you can select Named Credentials and then select a credential name from the Credential Name column (or) select Preferred Credentials. Click Next.

    Credentials
  6. On the Profile page, do the following:

    • In the Profile Information section, enter a unique profile name of your choice.

      For example:
      DBCA Provisioning Profile for HR database
      

      You can also enter a description of the profile, and notes for your reference.

    • In the Schedule section, you can choose to start the profile creation immediately, or you can schedule it for a later time.

    • Click Next.

    Profile page
  7. On the Review page, ensure that the selections you have made in the previous pages are correctly displayed and click Submit. Otherwise, click Back repeatedly till you reach the page where you want to make changes. Click Cancel to abort the provisioning profile creation.

    Once you have submitted the provisioning profile creation job, the provisioning profile appears in the Database Provisioning page.The Database Provisioning page displays all the procedure steps.

12.8.1.5 Creating a Database Provisioning Profile Using Export Schema Objects

To create a database provisioning profile, follow these steps:

  1. You can access the Database Provisioning page using either of the following ways:

    • From the Setup menu, select Cloud, and then select Database. On the Database Cloud Self Service Portal Setup, select Profiles and Service Templates. In the Profiles section, click Create.

    • From the Enterprise menu, select Provisioning and Patching, and then select Database Provisioning. On the Database Provisioning page, in the Profiles section, click Create.

  2. On the Reference Target page, click the search icon to select a target.

    Reference Target page
  3. In the Search and Select:Targets display box, select the database you want to create a profile for, and then, click Select.

    Search and Select Targets display box
  4. On the Reference Target page, select the following:

    • Data Content

    • Structure and Data to include physical and structural files from the database or Structure Only to include only the structural files in the template.

    • Export Schema Objects

    Reference Target page for Export Schema Objects
  5. In the Credentials section, select the database. In the Credentials column, you can select Named Credentials and then select a credential name from the Credential Name column (or) select Preferred Credentials. Click Next.

    Credentials
  6. On the Content Options page, do the following:

    • Select the schema you want to include in the profile by clicking on a schema in the Available Schema list and moving it to the Selected Schema list.

      Note:

      When one or more schemas are selected, the end user has to ensure the dependent schemas are also selected for export. If the dependent schemas are not exported, the import operation will fail.
      Content Options page

      Note:

      The Available Schemas section displays only the user created schemas that has data content in it. All the empty schemas are filtered out by default.

      Note:

      System schemas such as SYS, SYSTEM, and DBSNMP will not be exported.

      The user schemas which do not have their own tablespace are not shown in left side of the shuttle.

    • In the Degree of Parallelism section, enter the number of threads required to perform the export operation.

      Degree of Parallelism section

      Note:

      Increasing the number of threads helps reduce the time required to create the profile at the cost of using system resources.
    • In the Directory Locations section, click on Add. In the Select Directory window, select a directory object listed to perform the export operation, and then click Select.

      Select Directory window

      In the Log subsection, click on the search icon. In the Select Directory window, select the directory object you require to perform the export operation, and then click Select.

      In the Log subsection, enter the file name, and then click on Next.

      Log subsection
  7. On the Profile page, do the following:

    • In the Profile Information section, enter a unique profile name of your choice.

      For example:
      Schema Objects Provisioning Profile for HR database
      
      

      You can also enter a description of the profile, and notes for your reference.

    • In the Schedule section, you can choose to start the profile creation immediately, or you can schedule it for a later time.

    • Click Next.

  8. On the Review page, ensure that the selections you have made in the previous pages are correctly displayed and click Submit. Otherwise, click Back repeatedly till you reach the page where you want to make changes. Click Cancel to abort the provisioning profile creation.

    Once you have submitted the provisioning profile creation job, the provisioning profile appears in the Database Provisioning page.The Database Provisioning page displays all the procedure steps.

12.8.2 Creating a Database Service Template

Service templates are standardized service definitions that allow self service users to create databases or schemas. Self service users can create one or more databases based on the service template definition. The service template can be based on:

  • Snap Clone Based Profile

  • RMAN Backup Based Profile

  • DBCA Template Based Profile

12.8.2.1 Creating Service Template Using Snap Clone Profile

To create a snap clone based service template, follow these steps:

  1. Log into Enterprise Manager as a user with the EM_SSA_ADMINISTRATOR. role.

  2. From the Setup menu, select Cloud, then select Database. The Database Cloud Self Service Portal Setup page appears.

  3. Click Profiles and Service Templates. From the Create menu, select For Database. The Create Service Template: General page appears.

    Figure 12-6 Create Service Template: General (Snap Clone)

    Create Service Template: General (Snap Clone)
  4. Enter a name and description for the service template. The description must be unique and provide information on the type of service template being created.

  5. Click the Search icon next to the Profile field and select a snap clone profile from the list.

  6. Select the Database Type which can be Single Instance or Real Application Cluster (RAC). If you select RAC, specify the Number of Nodes.

  7. In the Zones region, click Add to select a PaaS Infrastructure Zone into which the database instance is to be provisioned. Click Assign Pool. Select a pool from the list and assign this pool to the PaaS Infrastructure Zone. The database will be provisioned into this pool.

  8. After you have selected the zone and the pool, the host target is populated in the Reference Host field.

  9. In the Identification region, specify the following:

    • SID Prefix: Enter a prefix that is to be used to generate a unique System Identifier (SID) at the time of database creation. The prefix helps to identify databases created using this service template. The prefix can be a maximum of 6 characters.

      The new database name generated will be based on the SID Prefix specified here. For example, if the prefix is specified as MYDB, the SID for the new database is generated as MYDB0000, MYDB0001, MYDB0002, and so on.

      For existing databases (running databases and in progress requests), a unique SID name is generated for single instance databases, or a unique name is generated for real application cluster databases. For example, if the existing SIDs running on a host are MYDB0000, MYDB0001, MYDB0002 And In progress are MYDB0003, MYDB0004, the new SID or database name generated for the new request is MYDB0005.

    • Domain Name: Enter a Domain Name to be used for the new database being created. You must ensure that the domain name does not contain a preceding "." (dot).

  10. In the Listener Port field, specify listener port number that is to be associated with the new database. If you have selected a 11.2 or later RAC database, you must specify the scan port number. Click Next. The Create Service Template: Database page appears.

  11. In the Reference Host region, the name of the PaaS Infrastructure zone, the database pool, and the reference host you have selected in the Database Cloud Self Service Portal Setup: General page are displayed.

    The database values such as a Automatic Storage Management (ASM) disk group, location of the file system, and listener port you select must be available on the reference host.

  12. Specify the following details:

    • Storage Size: The volumes defined in the profile you have selected are displayed. Select a volume and click Edit to configure the volumes that will be used by the database:

      • Mount Point Prefix: The prefix for the new mount point for the database being provisioned. The volume will be mounted on /<mount-prefix>_<unique-suffix-generated-by-EM>/<source-path>.

      • Writable Space: The amount of writable space available on the database. The value specified here cannot exceed the Storage Ceiling specified for the server.

    • Snapshot Policy: Snapshots are sets of historical data for specific time periods. By default, Oracle Database automatically generates snapshots of the performance data once every hour and retains the statistics in the workload repository for 8 days. Select the Allow the user to take snapshots for the new database checkbox and specify the Maximum Number of Snapshots that can be taken.

    • Working Directory: Specify the directory in which the files are temporarily stored.

    • Administrator Credentials: Specify passwords for the system schemas of the new database. These schemas will not be available to the EM_SSA_USERS. You can choose to use the same password for all the schemas or different passwords for each schema. If these values are not specified, default values will be used and the EM_ADMINISTRATOR can change them.

    • Non Administrator Credentials: Apart from the system schemas, if you want to restrict access to other schemas, you can select them in the Non-Administrator Credentials region and specify the password.

  13. Click Next. The Create Service Template: Initialization Parameters page appears.

    Figure 12-7 Create Service Template: Initialization Parameters (Snap Clone)

    Create Service Template: Initialization Parameters
  14. In this page, you can configure the values of various initialization parameters that affect the operation of the database instance. Select the parameter and click the Set icon to modify the value of the parameter.

  15. Click Next. The Create Service Template: Scripts page appears. Specify the custom scripts that need to be executed before and after the database is created. See Section 12.12, "Pre and Post Request Creation / Deletion Scripts" for details.

  16. Click Next. The Create Service Template: Roles page appears.

    Figure 12-8 Create Service Template: Roles (Snap Clone)

    Create Service Template: Roles
  17. Click Add to select the SSA user roles to which this service template will be available. All users belonging to the selected role can use this service template. Click Next.

  18. The Create Service Template: Review page appears. Click Submit. The newly created service template will appear in the Database Cloud Self Service Portal Setup: Service Templates page.

12.8.2.2 Create Service Template Using RMAN Backup Profile

  1. Log into Enterprise Manager as a user with the EM_SSA_ADMINISTRATOR role.

  2. From the Setup menu, select Cloud, then select Database. The Database Cloud Self Service Portal Setup page appears.

  3. Click Profiles and Service Templates. From the Create menu, select For Database. The Create Service Template: General page appears.

    Figure 12-9 Create Service Template: General (RMAN Backup)

    Create Service Template: General (RMAN Backup)
  4. Enter a name and description for the service template. The description must be unique and provide information on the type of service template being created.

  5. Click the Search icon next to the Profile field and select a snap clone profile from the list.

  6. Select the Database Type which can be Single Instance or Real Application Cluster (RAC). If you select RAC, specify the Number of Nodes.

  7. In the Zones region, click Add to select a PaaS Infrastructure Zone into which the database instance is to be provisioned. Click Assign Pool. Select a pool from the list and assign this pool to the PaaS Infrastructure Zone. The database will be provisioned into this pool.

  8. After you have selected the zone and the pool, the host target is populated in the Reference Host field.

  9. In the Identification region, specify the following:

    • SID Prefix: Enter a prefix that is to be used to generate a unique System Identifier (SID) at the time of database creation. The prefix helps to identify databases created using this service template. The prefix can be a maximum of 6 characters.

      The new database name generated will be based on the SID Prefix specified here. For example, if the prefix is specified as MYDB, the SID for the new database is generated as MYDB0000, MYDB0001, MYDB0002, and so on.

      For existing databases (running databases and in progress requests), a unique SID name is generated for single instance databases, or a unique name is generated for real application cluster databases. For example, if the existing SIDs running on a host are MYDB0000, MYDB0001, MYDB0002 And In progress are MYDB0003, MYDB0004, the new SID or database name generated for the new request is MYDB0005.

    • Domain Name: Enter a Domain Name to be used for the new database being created. You must ensure that the domain name does not contain a preceding "." (dot).

  10. In the Listener Port field, specify listener port number that is to be associated with the new database. If you have selected a 11.2 or later RAC database, you must specify the scan port number. Click Next. The Create Service Template: Database page appears.

    Figure 12-10 Create Service Template: Database (RMAN Backup)

    Create Service Template: Database (RMAN Backup)
  11. In the Reference Host region, the name of the PaaS Infrastructure zone, the database pool, and the reference host you have selected in the Database Cloud Self Service Portal Setup: General page are displayed.

    The database values such as a Automatic Storage Management (ASM) disk group, location of the file system, and listener port you select must be available on the reference host.

  12. Specify the following:

    • Storage Type: This can be:

      • Automatic Storage Management: The Oracle Automatic Storage Management (ASM) is a volume manager and a file system for database files that supports single-instance and RAC configurations. ASM groups the disks in your storage system into one or more disk groups. If you select ASM, select the Disk Group here.

      • File System: The Oracle Database File System creates a standard file system interface on top of files and directories that are stored in database tables. If you select this option, you must specify or select the Location of the File System.

    • Fast Recovery (Optional): To simplify the management of backup and recovery files, you can create a fast recovery area for your database. Select the Enable Fast Recovery Area checkbox to specify the location in which recovery related files must be stored. The fast recovery area can be a ASM disk group or a file system that provides a centralized disk location for backup and recovery file. Specify the location of the Fast Recovery Area and the Fast Recovery Size. The amount of disk space to allocate for the fast recovery area depends on the size and activity levels of your database.

      Select the Enable Archiving check box if the backups are to be archived.

  13. In the Listener Port field, specify listener port number that is to be associated with the new database. If you have selected a 11.2 or later RAC database, you must specify the scan port number.

  14. Specify the Administrator Credentials. Specify passwords for the system schemas of the new database. These schemas will not be available to the EM_SSA_USERS. You can choose to use the same password for all the schemas or different passwords for each schema. If these values are not specified, default values will be used and the EM_ADMINISTRATOR can change them.

  15. Apart from the system schemas, if you want to restrict access to other schemas, you can select them in the Non-Administrator Credentials region and specify the password. These schemas will be locked and the EM_SSA_USERS cannot access them. Click Next.

  16. Follow steps 10 to 17 in the Section 12.8.2.1, "Creating Service Template Using Snap Clone Profile" section to create the RMAN Backup based service template.

12.8.2.3 Create Service Template Using DBCA Template Profile

  1. Log into Enterprise Manager as a user with the EM_SSA_ADMINISTRATOR role.

  2. From the Setup menu, select Cloud, then select Database. The Database Cloud Self Service Portal Setup page appears.

  3. Click Profiles and Service Templates. From the Create menu, select For Database. The Create Service Template: General page appears.

    Figure 12-11 Create Service Template: General (DBCA Template)

    Create Service Template: General (DBCA Template)
  4. Enter a name and description for the service template. The description must be unique and provide information on the type of service template being created.

  5. Click the Search icon next to the Profile field and select a DBCA template based profile from the list.

  6. Select the Database Type which can be Single Instance or Real Application Cluster (RAC). If you select RAC, specify the Number of Nodes.

  7. In the Zones region, click Add to select a PaaS Infrastructure Zone into which the database instance is to be provisioned. Click Assign Pool. Select a pool from the list and assign this pool to the PaaS Infrastructure Zone. The database will be provisioned into this pool.

  8. After you have selected the zone and the pool, the host target is populated in the Reference Host field.

  9. In the Identification region, specify the following:

    • SID Prefix: Enter a prefix that is to be used to generate a unique System Identifier (SID) at the time of database creation. The prefix helps to identify databases created using this service template. The prefix can be a maximum of 6 characters. The new database name generated will be based on the SID Prefix specified here. For example, if the prefix is specified as MYDB, the SID for the new database is generated as MYDB0000, MYDB0001, MYDB0002, and so on.

      For existing databases (running databases and in progress requests), a unique SID name is generated for single instance databases, or a unique name is generated for real application cluster databases. For example, if the existing SIDs running on a host are MYDB0000, MYDB0001, MYDB0002 And In progress are MYDB0003, MYDB0004, the new SID or database name generated for the new request is MYDB0005.

    • Domain Name: Enter a Domain Name to be used for the new database being created. You must ensure that the domain name does not contain a preceding "." (dot).

  10. Click Next. The Create Service Template: Database page appears.

    Figure 12-12 Create Service Template: Database (DBCA Template)

    Create Service Template: Database (DBCA Template)
  11. In the Reference Host region, the name of the PaaS Infrastructure zone, the database pool, and the reference host you have selected in the Database Cloud Self Service Portal Setup: General page are displayed.

    The database values such as a Automatic Storage Management (ASM) disk group, location of the file system, and listener port you select must be available on the reference host.

  12. Specify the following:

    • Storage Type: This can be:

      • Automatic Storage Management: The Oracle Automatic Storage Management (ASM) is a volume manager and a file system for database files that supports single-instance and RAC configurations. ASM groups the disks in your storage system into one or more disk groups. If you select ASM, select the Disk Group here.

      • File System: The Oracle Database File System creates a standard file system interface on top of files and directories that are stored in database tables. If you select this option, you must specify or select the Location of the File System.

    • Fast Recovery (Optional): To simplify the management of backup and recovery files, you can create a fast recovery area for your database. Select the Enable Fast Recovery Area checkbox to specify the location in which recovery related files must be stored. The fast recovery area can be a ASM disk group or a file system that provides a centralized disk location for backup and recovery file. Specify the location of the Fast Recovery Area and the Fast Recovery Size. The amount of disk space to allocate for the fast recovery area depends on the size and activity levels of your database.

      Select the Enable Archiving check box if the backups are to be archived.

  13. In the Listener Port field, specify listener port number that is to be associated with the new database. If you have selected a 11.2 or later RAC database, you must specify the scan port number.

  14. Specify the Administrator Credentials. Specify passwords for the system schemas of the new database. These schemas will not be available to the EM_SSA_USERS. You can choose to use the same password for all the schemas or different passwords for each schema. If these values are not specified, default values will be used and the EM_ADMINISTRATOR can change them.

  15. Apart from the system schemas, if you want to restrict access to other schemas, you can select them in the Non-Administrator Credentials region and specify the password. These schemas will be locked and the EM_SSA_USERS cannot access them. Click Next.

  16. Follow steps 10 to 17 in the Section 12.8.2.2, "Create Service Template Using RMAN Backup Profile" section to create the DBCA service template.

12.9 Configuring Chargeback

Click the Chargeback tab to add the database pools to the Chargeback Application. On this page, you can determine chargeback zones, services, items and prices. After the Chargeback is setup, you can view charges and plan details. For more details on setting up the Chargeback Service, see Section 22, "Chargeback Administration".

12.10 Creating a Database Pool for PDB as a Service

A Pluggable Database (PDB) is portable set of schemas, schema objects, and related structures that appears logically to an application as a separate database. This self-contained collection is called a pluggable database (PDB). Every PDB is owned by a SYS user.

A container is a collection of schemas, objects, and related structures in a container database (CDB) that appears logically to an application as a separate database. A container database (CDB) is an Oracle database that includes zero, one, or many user-created PDBs.

A database pool for PDB as a Service must contain a set of container databases. The container databases must meet the following guidelines:

  • All CDBs in a database pool must be of the same version and platform.

  • All CDBs in a database pool must either be single instance databases or RAC databases. Mix and match of database types is not supported.

To create a database pool for PDB as a service, follow these steps:

  1. Log into Enterprise Manager as a user with the EM_SSA_ADMINISTRATOR role.

  2. From the Setup menu, select Cloud, then select Database. The Database Cloud Self Service Portal Setup page appears.In the Database Pools page, select For Pluggable Database from the Create menu.

    Figure 12-13 Create Database Pool: Setup Page (PDB)

    Surrounding text describes Figure 12-13 .
  3. Enter a name and description for the database pool.

  4. In the Credentials region, specify the credentials that will be used for performing database operations. Specify the following credentials:

    • Host: Required for performing remote host operations.

    • Grid Infrastructure: Required for cluster databases.

    • Database: Required for creating the pluggable database.

    • Container Database Wallet Password: If the PDB is to be encrypted, you must specify the password required to open the wallet from the keystore.

  5. Specify the following details:

    • PaaS Infrastructure Zone: Select a PaaS Infrastructure Zone in which the container databases are present. The PDBs will be created on the databases selected for the pool. For details on creating container databases, see Section 11.6, "Creating a Container Database".

    • Target Type: Specify the configuration of the target database on which the PDB is being deployed. This can be Single Instance or Cluster Database (RAC).

    • Platform and Version: Specify the platform and version of the database being deployed.

  6. Click Add and select one or more container databases to be added to the pool. All databases you select must be present in the same PaaS Infrastructure Zone.

    Note:

    You can search for database groups that meet your requirements by specifying a search string in the Groups field.
  7. Click Next. The Create New Pool: Policies page appears.

    Figure 12-14 Create Database Pool: Policies (PDB)

    Surrounding text describes Figure 12-14 .

    Specify the placement policy constraints to set maximum ceilings for resource utilization on each database. Placement policy constraints for each database can be defined by services or workloads as follows:

    • Pluggable Database: Select the Pluggable Database checkbox and specify the Maximum Number of Pluggable Databases that can be created inside each CDB.

    • Workloads Associated with Service Requests: The amount of resources (such as CPU and memory) to manage the workload can be specified here. Specify the total workload for each database.

      • Maximum CPU Allocation: Specify the maximum CPU that can be allocated to each database.

      • Maximum Memory Allocation: Specify the maximum memory that can be allocated for each database.

  8. If you have chosen to set the placement constraints by Workloads Associated with Service Requests, you can choose to enable the resource manager by selecting the Enable Resource Manager for CPU check box. You can use the resource manager to manage the CPU resource and create Consumer Groups. A Consumer Group is used to ensure that the service gets the requested CPU cycles on a fully loaded system.

  9. Click Submit to create a database pool for PDB as a service. The newly created database pool will appear in the Database Cloud Self Service Portal Setup: Database Pools page.

12.11 Creating a Service Template for PDB as a Service

One or more pluggable databases can be created based on the service template definition. To create a service template for PDB as a service, follow these steps:

  1. Log into Enterprise Manager as a user with the EM_SSA_ADMINISTRATOR role.

  2. From the Setup menu, select Cloud, then select Database. The Database Cloud Self Service Portal Setup page appears.

  3. Click Profiles and Service Templates. In the Service Templates region, select For Pluggable Database from the Create menu. The Create Service Template: Name page appears.

    Figure 12-15 Create Service Template: General (PDB)

    Surrounding text describes Figure 12-15 .
  4. Enter a name and description for the service template. The description must be unique and provide information on the type of service template being created.

  5. In the Pluggable Databases region, you can choose to:

    • Create Empty Pluggable Database: Select this option to create an empty PDB that can be configured by the user.

    • Create Pluggable Databases from Profile: Select a database provisioning profile from which the schema is to be imported. Click the Search icon next to the Profile field and select an export schema objects based profile from the list. If a profile does not exist, you must create one. See Creating a Database Provisioning Profile.

  6. In the Zones region, click Add to select a PaaS Infrastructure Zone into which the pluggable database instance is to be provisioned. Click Assign Pool to add a Database Pool (for Pluggable Databases) for the zone.

    Note:

    A database pool (for PDBs) must be present in the PaaS Infrastructure Zone that you select here.
  7. After the database pool has been assigned, the container database into which the pluggable database is to be added is displayed in the Reference Container Database field. All the validations for the service template will be performed against this database.

  8. If you have selected Create Pluggable Databases from Profile in the Pluggable Database region, in the Shared Location field, specify the Path or the shared location on all hosts in which the schema dumps are present. The Dump File Location must be accessible by all the databases. The location must be specified only if the schema dumps have been moved to a different location since the profile was created.

  9. In the Pluggable Database Prefix Name field, specify the prefix that is to be used to generate a unique Pluggable Database name at the time of database creation. The prefix helps to identify the PDBs that are created using this service template.

  10. Click Next. The Create New Service Template: Configurations page appears.

    Figure 12-16 Create Service Template: Configurations (PDB)

    Surrounding text describes Figure 12-16 .

    Specify the following details:

    • Workload Size: Workload represents the total CPU, memory, and storage requirements for each service. You can define workload sizes such as small, medium, and large. Click Create and in the Create Workload window, enter the name, CPU, Memory, and Storage limit for each service.

    • Pluggable Database Administrator Privileges: You can assign privileges to the Pluggable Database Administrator by:

      • From Existing Database Roles: If you select this option, click Add Roles to add an existing role from which the privileges will be assigned to the Pluggable Database Administrator.

      • Creating a new Database Role: If you select this option, you must specify the Role Name, Description, and the Privileges such as CREATE_SESSION, ALTER_SESSION, CREATE ANY OPERATOR, CREATE ANY PROCEDURE and so on that will be assigned to the administrator.

    • Pluggable Database Storage: The maximum size of the PDB storage can either be Unlimited or Specified by the workload size selected at request time.

    • Tablespace: If you have selected the Create Pluggable Databases from Profile option, the list of tablespaces are displayed.

  11. Click Next. The Create Service Template: Initialization Parameters page appears. In this page, you can configure the values of various initialization parameters that affect the operation of the database instance. Select the parameter and click the Set icon to modify the value of the parameter.

    Figure 12-17 Create Service Template: Initialization Parameters (PDB)

    Surrounding text describes Figure 12-17 .
  12. Click Next. The Create Service Template: Scripts page appears. On this page, you can optionally specify the following:

    • Custom scripts that need to be executed before or after the PDB has been created.

    • Custom scripts that need to be executed before or after the PDB has been deleted.

    See Section 12.12, "Pre and Post Request Creation / Deletion Scripts" for details.

  13. Click Next. The Create Service Template: Roles page appears. Click Add to select the EM_SSA_USER roles to which this service template will be available. All users belonging to the selected role can use this service template.

  14. Click Next. The Create Service Template: Review page appears where you can review the details entered so far.

  15. Click Submit. The newly created service template will appear in the Database Cloud Self Service Portal Setup: Service Templates page. You can click on the Service Template Name link to view additional details.

12.12 Pre and Post Request Creation / Deletion Scripts

You can run custom scripts before and after a service instance has been created. These requests can range from some additional host commands on the machine on which the database was created or commands to perform additional book activities and other operations on the newly provisioned database.

Similarly, you can run scripts after a service instance has been deleted if you need to undo the changes made during service cleanup.

The custom script must follow certain guidelines and consists of four parts:

  • Response File: The response file contains the service template and request specific information. Before the custom script is executed, the request procedure, the request procedure generates a response file (file with name-value pairs) containing the data from the service template as well as the request-specific data such as the SID that is auto computed, the hosts on which the database will be deployed, and so on.

  • Driver Script: This is the key driver script that will be invoked by the request procedure. The driver script accepts only one argument which specifies the location of the response file.

  • Other Scripts: Apart from the driver script, you can specify other perl or sql scripts. These scripts must be invoked from the driver script.

  • Additional Variables: You can include a file containing additional variables that can used by the custom script as applicable.

After the scripts have been created, they must be uploaded as a directive into the Software Library. The directive details are shown below:

Figure 12-18 Pre or Post Database Script: Describe

Pre or Post Database Script: Describe Page

In the Describe page, the name of the directive and the description is displayed. Click the Configure tab.

Figure 12-19 Pre or Post Database Script: Configure

Pre or Post Database Script: Configure Page

The driver script accepts one command line argument which must be in the INPUT_FILE format. This variable will be used at run-time to specify the location of the generated response file. Click the Select Files tab.

Figure 12-20 Pre or Post Database Script: Select Files

Pre or Post Database Script: Select Files Page

Specify any additional files that are required by the custom script. You can run the script from the same host on which the database instance or the database service was created or deleted.

Note:

if you need to change the content of the script, you must upload a newer version of the script to the Software Library. To use the latest version of the script, you must launch the Edit Service Template wizard and select the updated version of the script and save the template. This ensures that the latest version of the script will be used.

12.12.1 Sample Scripts

Sample scripts are available in the Software Library. To view the sample scripts, from the Enterprise menu, select Provisioning and Patching, then select Software Library. Select the DBaaS folder, then select Directives, and click the Samples folder to see the custom scripts.

Figure 12-21 Sample Scripts

Sample Scripts