Dissolving Sharding Configuration

Particularly, in test environments during the POC phase in order to perform various levels of testing the sharding configuration may need to dissolve and again re-deploy. The dissolving of the sharding configuration is not a regular method of dropping the databases. If we remove all shards then the command won’t allow us to do until unless we complete few of the prior steps.

GDSCTL>remove shard -shard all
GSM-45029: SQL error
ORA-02659: cannot remove a shard which contains chunks
ORA-06512: at "GSMADMIN_INTERNAL.DBMS_GSM_POOLADMIN", line 10700
ORA-06512: at "SYS.DBMS_SYS_ERROR", line 79
ORA-06512: at "GSMADMIN_INTERNAL.DBMS_GSM_POOLADMIN", line 10511
ORA-06512: at "GSMADMIN_INTERNAL.DBMS_GSM_POOLADMIN", line 10311
ORA-06512: at line 1

GDSCTL>

It consists of some special steps, in order to dissolve.

  • Remove Shard Groups
GDSCTL>remove shardgroup -shardgroup primary_east_shg
The operation completed successfully
GDSCTL>remove shardgroup -shardgroup standby_west_shg
The operation completed successfully
GDSCTL>
  • Remove shard(s)
GDSCTL>remove shard -shardgroup primary_east_shg -force
GSM Warnings:
CATALOG:ORA-03713: Shard 'sh1' contained 12 chunks.
CATALOG:ORA-02660: Shard 'sh2' was also removed.
CATALOG:ORA-03713: Shard 'sh2' contained 12 chunks.
GDSCTL>remove shard -shardgroup standby_west_shg
The operation completed successfully
GDSCTL>
  • Verify configuration
GDSCTL>config shard
Name Shard Group Status State Region Availability
---- ----------- ------ ----- ------ ------------
GDSCTL>
GDSCTL>databases
GDSCTL>services
GDSCTL>
  • Disable FSFO
  • Drop Databases.

Review and Inputs By – Syed Jaffar Hussain