I'm writing a script that will check to see if the server is in PRIMARY state. If it is, then perform the nightly backup beased upon what day it is (full vs incremental delta). This script will be running on both the PRIMARY/STANDBY servers at the same time. If the database is in STANDBY, it will do nothing.
If the PRIMARY server fails over at any point BEFORE the backup takes place, and the BACKUP database performs the backup, will there be a disruption of data if/when I need to restore? They, theoretically, should contain the same data/logfiles thus the incremental backup made on the standby server 'should' match up with the other incremental backups on the PRIMARY server.
Is this correct?