question

sakuraime avatar image
0 Votes"
sakuraime asked ·

Azure sql mi migration Online

for example I will need to migration database online to Azure SQL MI . during the cutover , I but the database into single_user mode and do the log backup


  1. backup log dbname to disk='path'

  2. backup log dbname to disk='path' with norecovery,no_truncate


which one I should use ? and what's the difference ?



azure-sql-database
10 |1000 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

1 Answer

NavtejSaini-MSFT avatar image
0 Votes"
NavtejSaini-MSFT answered ·

@sakuraime

Please check this document for more details. This details the use of these arguments:
92640-image.png

Regards
Navtej S


image.png (99.5 KiB)
· 3 ·
10 |1000 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

so what's the conclusion ?

1 or 2 ?


if I choose option 2 , the original database is in restoring state after backup log dbname to disk='path' with norecovery


and if I would like to resume the database , I need to do 1 or 2 ?

  1. restore database dbname with recovery

  2. restore log dbname from disk ='path to the last logbackup'





0 Votes 0 ·

@sakuraime

As the document says for best effort log back up that skips log truncation and put the database in restoring state, you should be using both No_recovery and No_Truncate when restoring.

Navtej S

0 Votes 0 ·
sakuraime avatar image sakuraime NavtejSaini-MSFT ·

I am talking about backup .
I just wonder if the database already in single_user mode

what's the difference between

backup log with the option norecovery and without norecovery ?

0 Votes 0 ·