Which statement should you run?

Posted by: Pdfprep Category: DP-300 Tags: , ,

You have an Always On availability group deployed to Azure virtual machines. The availability group contains a database named DB1 and has two nodes named SQL1 and SQL2. SQL1 is the primary replica.

You need to initiate a full backup of DB1 on SQL2.

Which statement should you run?
A . BACKUP DATABASE DB1 TO URL=’https://mystorageaccount.blob.core.windows.net/mycontainer/DB1.bak’ with (Differential, STATS=5, COMPRESSION);
B . BACKUP DATABASE DB1 TO URL=’https://mystorageaccount.blob.core.windows.net/mycontainer/DB1.bak’ with (COPY_ONLY, STATS=5, COMPRESSION);
C . BACKUP DATABASE DB1 TO URL=’https://mystorageaccount.blob.core.windows.net/mycontainer/DB1.bak’ with (File_Snapshot, STATS=5, COMPRESSION);
D . BACKUP DATABASE DB1 TO URL=’https://mystorageaccount.blob.core.windows.net/mycontainer/DB1.bak’ with (NoInit, STATS=5, COMPRESSION);

Answer: B

Explanation:

BACKUP DATABASE supports only copy-only full backups of databases, files, or filegroups when it’s executed on secondary replicas. Copy-only backups don’t impact the log chain or clear the differential bitmap.

Reference: https://docs.microsoft.com/en-us/sql/database-engine/availability-groups/windows/active-secondaries-backup-on-secondary-replicas-always-on-availability-groups

Leave a Reply

Your email address will not be published.