setup

switchover was not sucessful due to some reason and now this is the status
DGMGRL> show configuration
Configuration - broker_config
Protection Mode: MaxPerformance
Databases:
TROY_DR - Primary database
TROY - Physical standby database
Fast-Start Failover: DISABLED
Configuration Status:
ORA-16623: database detected role change
ORA-16625: cannot reach database "TROY_DR"
DGM-17017: unable to determine configuration status
it is not allowing me to remove or disable the configuration
DGMGRL> remove configuration;
Error: ORA-16597: Data Guard broker detects two or more primary databases
Error: ORA-16625: cannot reach database "TROY"
Failed.
DGMGRL> disable configuration;
Error: ORA-16597: Data Guard broker detects two or more primary databases
Error: ORA-16625: cannot reach database "TROY"
to over come this perform below steps on PROD and DR
TROY1@ol6-112-rac1 > alter system set dg_broker_start=false scope=both sid='*';
System altered.
TROY1@ol6-112-dr-rac1 > alter system set dg_broker_start=false scope=both sid='*';
System altered.
now remove the configuration files from both prod and DR
ASMCMD> pwd
+DATA/TROY/DATAGUARDCONFIG
ASMCMD> ls
TROY.2060.1060003087
TROY.387.1060003089
dgbrk_config01.ora
dgbrk_config02.ora
ASMCMD> rm -rf *
ASMCMD> pwd
+DATA/TROY_DR/DATAGUARDCONFIG
ASMCMD> ls
TROY_DR.2019.1060003187
TROY_DR.326.1060003145
dgb_config01.ora
dgb_config02.ora
ASMCMD> rm -rf *
enable the the broker
TROY1@ol6-112-rac1 > alter system set dg_broker_start=true scope=both sid='*';
System altered.
TROY1@ol6-112-dr-rac1 > alter system set dg_broker_start=true scope=both sid='*';
System altered.
now try and you will see configuration is removed
DGMGRL> show configuration
ORA-16532: Data Guard broker configuration does not exist
Configuration details cannot be determined by DGMGRL
now you can add the configuration again.
DGMGRL> create configuration 'broker_config' as primary database is 'TROY' connect identifier is TROY;
Configuration "broker_config" created with primary database "TROY"
DGMGRL> ADD DATABASE 'TROY_DR' AS CONNECT IDENTIFIER IS TROY_DR MAINTAINED AS PHYSICAL;
Database "TROY_DR" added
DGMGRL> show configuration
Configuration - broker_config
Protection Mode: MaxPerformance
Databases:
TROY - Primary database
TROY_DR - Physical standby database
Fast-Start Failover: DISABLED
Configuration Status:
DISABLED
enable the configuration
DGMGRL> enable configuration;
Enabled.
DGMGRL> show configuration
Configuration - broker_config
Protection Mode: MaxPerformance
Databases:
TROY - Primary database
TROY_DR - Physical standby database
Fast-Start Failover: DISABLED
Configuration Status:
SUCCESS