Managing Oracle Globally Distributed Database with Enterprise Manager Cloud Control

Oracle Enterprise Manager Cloud Control lets you discover, monitor, and manage an Oracle Globally Distributed Database and its components.

See the following topics for information about Oracle Globally Distributed Database discovery, monitoring, and management using Enterprise Manager Cloud Control:

Prerequisite: Enable Oracle Globally Distributed Database Metrics

By default Oracle Globally Distributed Database performance metrics are disabled. They can be enabled from the Enterprise Manager Cloud Console or the monitoring template.

There are two methods of gathering metrics, which require you to follow different setup steps as explained in each section below.

Using Default Enterprise Manager Database Metrics

By default metrics shown in the Enterprise Manager Cloud Console Sharded Database pages are the default database metrics, require that you create a metrics query user, and are only gathered on the shard databases discovered in Enterprise Manager.

The default database metrics do not give you data as frequently as the enhanced sharded database metrics described later.

Because multi-shard queries are used to gather metrics, you must also create a user that can access all shards in the sharded database to run the queries.

To use default metrics:

  1. Create a new metrics query account on every shard and the shard catalog manually.

    create user SHARD_SYS identified by password;
    grant connect, create session, gsmadmin_role to SHARD_SYS;
    GRANT ALL PRIVILEGES TO SHARD_SYS; /*Needed to get all the schemas stats*/
    GRANT SELECT ANY DICTIONARY TO SHARD_SYS; /*Needed to get all the schemas stats*/
  2. Use the same metrics query account credentials to discover the shard catalog and all shard databases in Enterprise Manager.

    See Prerequisite: Discovering the Sharded Database Topology

  3. To enable the default metrics:

    $emctl set property
     -sysman_pwd password
     -name oracle.sysman.db.ha.sdb.dd.usesdbmetrics
     -value false 

Using Enhanced Sharded Database Metrics

With Sharded Database enhanced metrics you can gather information about the shards from the shard catalog, so it is not required that you discover all of the shard databases in Enterprise Manager to get complete metrics for the sharded database topology.

To use enhanced metrics:

  1. Discover the shard catalog in Enterprise Manager.

    See Prerequisite: Discovering the Sharded Database Topology

  2. Enable the Sharded Database metrics using the Console or using the monitoring template.

    $emctl set property
     -sysman_pwd password
     -name oracle.sysman.db.ha.sdb.dd.usesdbmetrics
     -value true

Prerequisite: Discover the Oracle Globally Distributed Database Topology

In Enterprise Manager Cloud Control, you can discover the shard catalog and optionally the shard databases, then add the shard directors, sharded databases, shardspaces, and shardgroups using guided discovery.

As a prerequisite to managing the sharded database in Cloud Control, you must first discover at minimum the shard director hosts and the shard catalog database. Optionally to manage all of the shards in the sharded database, you must also discover the shard databases.

Because the shard catalog database and each of the shards is a database itself, you can use standard database discovery procedures.

Managing the shards is only possible when the individual shards are discovered using database discovery. Discovering the shards is optional to discovering a sharded database, because you can have a sharded database configuration without the shards.

  1. In Enterprise Manager Cloud Control, select Setup, choose Add Target, then choose Add Target Manually.
  2. In the Add Targets Manually page, click Add Using Guided Process in the Add Non-Host Target Using Guided Process panel.
  3. In the Add Using Guided Process dialog, locate and select Sharded Database, and click Add.
  4. In the Add Sharded Database: Catalog Database page, click the browse icon next to Catalog Database to locate the shard catalog database.
  5. In the Select Targets dialog, click the target name corresponding to the catalog database and click Select.

    The Catalog Database and Monitoring Credentials fields are filled in if they exist. The monitoring credential is used to query the shard catalog database to get the configuration information.

    The monitoring user (usually DBSNMP) should be granted the GDS_CATALOG_SELECT role and has read only privileges on the shard catalog repository tables.

    SQL> grant GDS_CATALOG_SELECT to dbsnmp;

    Click Next to proceed to the next step.

    In the Add Sharded Database: Components page you are shown information about the sharded database that is managed by the catalog database, including the sharded database name, its domain name, the sharding method employed on the sharded database, and a list of discovered shard directors.

  6. To set monitoring credentials on a shard director, click the plus sign icon on the right side of the list entry.

    A dialog opens allowing you to set the credentials.

    Click OK to close the dialog, and click Next to proceed to the next step.

  7. In the Add Sharded Database: Review page, verify that all of the shard directors, shardspaces, and shardgroups were discovered.
  8. Click Submit to finalize the steps.

    An Enterprise Manager Deployment Procedure is submitted and you are returned to the Add Targets Manually page.

    At the top of the page you will see information about the script that was submitted to add all of the discovered components to Cloud Control.

  9. Click the link to view the provisioning status of the sharded database components.

    In another browser window you can go to the Cloud Control All Targets page to observe the status of the sharded database.

When the target discovery procedure is finished, sharded database targets are added in Cloud Control. You can open the sharded database in Cloud Control to monitor and manage the components.

Oracle Globally Distributed Database Management with Oracle Enterprise Manager Cloud Control

Your sharded database can be configured, deployed, monitored, and managed using Oracle Enterprise Manager Cloud Control

Targets

Any discovered sharded database objects can be found in the All Targets page in Enterprise Manager.

Shard Director and Sharded Database objects are found in the Databases target type category.

Shardgroup and Shardspace objects are found in the Groups, Systems and Services target type category.

Sharded Database Home Page

You can access the Sharded Database home page from All Targets. Click the Sharded Database object in All Targets, and choose the sharded database to view from the list.

On the Sharded Database home page, you can access most of the management tools from the Sharded Database menu, such as Add Primary Shards, Add Standby Shards, and Deploy Shards.

Management tools for other sharded database objects are located in the menus of other Sharded Database object pages, which are described in the following topics

For more information about the Sharded Database Home page, see Monitoring a Sharded Database with Enterprise Manager Cloud Control