Enabling Raft Replication

You enable Raft replication when you configure the shard catalog.

To enable Raft replication, specify the native replication option in the create shardcatalog command when you create the shard catalog.

gdsctl> create shardcatalog ... -repl native

For example

GDSCTL> create shardcatalog -database catalog_connect_string
 -user mysdbadmin/mysdbadmin_password -repl native -region region1,region2

See Create the Shard Catalog for shard catalog configuration details.

After the shard catalog is created, you can add shards to the configuration and run the DEPLOY command.

Note:

You must have at least 3 shards in your distributed database to use Raft replication.

Specifying Replication Unit Attributes

By default, Oracle Globally Distributed Database determines the number of replication units (RUs) in a shardspace and the number of chunks in an RU.

You can specify the number of primary RUs using the -repunit option when you create the shard catalog. Specify a value greater than zero (0).

gdsctl> create shardcatalog ... -repunit number

The RU value cannot be modified after the first DEPLOY command is run on the distributed database configuration. Before you run DEPLOY, you can modify the number of RUs using the MODIFY SHARDSPACE command.

gdsctl> modify shardspace -shardspace shardspaceora -repunit number

Note that in system-managed sharding there is one shardspace named shardspaceora.

If the -repunit parameter is not specified, the default number of RUs is determined at the time of execution of the first DEPLOY command.