Yes, you can switch the roles without a backup/restore.
You will need to make your RSS an HDR before doing the switch.
If you already have an HDR, then you will need to make this an RSS first:
On Primary: onmode -d add RSS <hdr instance>
On HDR: onmode -d RSS <primary instance>
You'll then have a Primary and 1 or more RSS.
Then make your RSS (that you want to become the primary) an HDR:
On RSS: onmode -d secondary <primary instance>
On Primary: onmode -d delete RSS <rss instance>
Once you have the RSS changed to the HDR then you can do the switch.
You can run the individual commands (which includes oninit-PHY), or just use the supplied scripts to perform the operation:
On Primary: onmode -kuy
On HDR: hdrmkpri.sh <original primary instance>
On original Primary: hdrmksec.sh <hdr instance>
On HDR (now new primary): oninit -v
xDB Systems, Incwww.xdbsystems.com
Sent: Fri November 11, 2022 11:47 AM
From: Hal Maner
Subject: Swapping Primary and RSS roles in HDR Replication Without A Backup/Restore
I have not had to swap primary and RSS secondary roles in a while (years) and I have never used the "oninit -PHY" option.
Whenever I swapped the roles of such servers in the past, I always went through the usual synching involving a level zero backup and restore.
My question is: can I swap the roles of a primary and an RSS using simply the onmode/oninit (PHY) etc. commands and without a level zero backup/restore these days (version 12.10)? Are there ifs and buts and conditions where one can only do this under certain scenarios? Again, it is not an HDR secondary but an RSS secondary I am talking about here.
M Systems International, Inc.