Get on the Fast Track to DBaaS with EM12c - Part I
Database-as-a-Service (DBaaS) has now become a buzzword in the IT industry. Organizations are starting to realize the benefits of database as a service thanks to the ubiquity of "The Cloud".
Companies relying on Oracle databases for managing their data can also get on the DBaaS fast track thanks to Oracle Enterprise Manager Cloud Control 12c. Using EM12c you can enable self-service and rapid provisioning of Oracle databases and enjoy all the benefits (well most) of Cloud computing. EM12c supports both IaaS and PaaS models. These are also tightly integrated with Oracle VM Server along with their engineered systems including Oracle Exadata Database Machine.
Setting up and configuring DBaaS requires several steps. While these are well-documented, it seems like a daunting task for those who are unfamiliar with process. A list of steps required to setup DBaaS include the following:
■Create Roles and Users
■Setup Privilege Delegation
■Add Hosts
■Configure Software Library
■Create PaaS Infrastructure Zone
■Setup Software Pools
■Setup Quotas
■Create Provisioning Profiles
■Create Service Templates
Thanks to the Rapid Start Kit we can setup a fully configured DBaaS environment in minutes.
Rapid Start Kit
The Rapid Start Kit consists of a set of Python scripts which call EMCLI commands and a setup of XML config files. The RSK is located in MW_HOME/plugins/oracle.sysman.ssa.oms.plug_12.1.0.7.0/dbaas/setup
cd /u01/app/oracle/Middleware/plugins/oracle.sysman.ssa.oms.plugin_12.1.0.7.0/dbaas/setup
$ ls
config database_cloud_setup.py exadata_cloud_setup.py
[oracle@gridoms01 setup]$ emcli @exadata_cloud_setup.py
-help
====================================================================================================
Cloud Setup Tool
====================================================================================================
Usage: emcli @exadata_cloud_setup.py
-pdbaas
This flag is used to setup Cloud for Pluggable Database
-dbaas
This flag is used to setup Cloud for Database as service
-db_list
comma separated list of 'Target Name'(s) for 'Cluster Database' targets
discovered in Enterprise Manager.
Choose Container Databases for PDbaaS.
Make sure all the Container Databases have same Database credentials and
same Host Credentials and are on same platform
e.g -db_list=CDB1,CDB2,CDB3
-host_list
comma separated list of 'Target Name'(s) for 'Host' targets discovered
in Enterprise Manager.
-db_home_location
Database Home location
e.g -db_home_location=/u01/app/oracle/11.2.0/dbhome1
-cloud_input=
Cloud input XML defines
Enterprise Manager entities created as part of Cloud Setup.
Default file config/dbaas_cloud_input.xml will be used for database setup
Default file config/pdbaas_cloud_input.xml will be used for pluggable
database setup.
Pass custom input xml file to override default input file.
-help
Displays Cloud Setup help
For example:
Setup Cloud on Exadata Machine:
Run script on first node of Exadata Machine:
emcli @exadata_cloud_setup.py : Sets up Cloud for PDBaaS if CDB is
available in Enterprise Manager. Setups up DBaaS otherwise.
emcli @exadata_cloud_setup.py -pdbaas : Sets up Cloud for PDBaaS
emcli @exadata_cloud_setup.py -dbaas : Sets up Cloud for DBaaS
Setup Cloud on Non-Exadata
Cluster Machine: Run script on cluster node or any standalone Machine:
emcli @exadata_cloud_setup.py -pdbaas -db_list=CDB1,CDB2,CDB3 : Sets up Cloud for PDBaaS
using given list of Pluggable
databases
emcli @exadata_cloud_setup.py -dbaas -host_list=host1,host2
-db_home_location= : Sets up Cloud for DBaaS using given list of hosts and oracle home
You should edit the dbaas_cloud_input.xml configuration file to change the default role and credential names as well as default passwords.
[oracle@gridoms01 config]$ vi dbaas_cloud_input.xml
To setup a Pluggable database as a service (PDBaaS) environment, you need to have an existing Oracle 12c RAC or single-instance database using ASM for database storage. To find the the list of container databases we can use the emcli get_targets command as shown below.
$ emcli get_targets
-target="oracle_pdb"
Status
Status Target
Type Target
Name
ID
1 Up
oracle_pdb
racdb_CDBROOT
0 Down
oracle_pdb
racdb_RACPDB
0 Down oracle_pdb
racdb_RAC_PDB1
0 Down
oracle_pdb
racdb_RAC_PDB2
Thanks for sharing this Leighton! Looking forward to your presenting @ Collaborate.
ReplyDelete