modify shardgroup

Modify shardgroup attributes.

Syntax

modify shardgroup -shardgroup shardgroup_name
                 [-region region_name]
                 [-shardspace shardspace_name]
                 [-repfactor number]
                 [-deploy_as {PRIMARY | STANDBY | ACTIVE_STANDBY}]

Options

Table 64 GDSCTL modify shardgroup Options

Option Description
-shardgroupshardgroup_name Specify the name of the shardgroup to be modified.
-regionregion_name Specify the region the shardgroup resides in.
-shardspaceshardspace_name Specify the shardspace this shardgroup belongs to.
-repfactornumber Specify the number of replicas for each piece of data stored in this shardgroup.
-deploy_as {PRIMARY | STANDBY | ACTIVE_STANDBY} Specify the initial role for a newly deployed database: PRIMARY, STANDBY, or ACTIVE_STANDBY.

Usage Notes

All shardgroup attributes, except for DEPLOY_AS, can only be modified when the shardgroup does not contain any deployed shards. DEPLOY_AS can be modified at any time because it does not affect shards that were already added to the shardgroup.

To change the read-write or read-only mode of deployed replication units, use switchmode.

Examples

Modify the GROUP1 shardgroup to have a replication factor of 3.

GDSCTL> modify SHARDGROUP -SHARDGROUP group1 -REPFACTOR 3