LOG RESTORE AFTER DB. restore on new server with MOVE, NORECOVERY

  • Restore from server 1 db. name A, to server 2 db. renamed B, recovery: FULL so .bak + 10 log files

    ----- on server 2----

    RESTORE DATABASE B

    FROM DISK='D:\.BAK'

    WITH REPLACE,NORECOVERY,

    MOVE 'b_sql_Data' TO 'E:\mssqldata\b.mdf',

    MOVE 'b_sql_Log' TO 'F:\gwlra_mssqllog\b.ldf', STATS=20 - new filename too as db.

    ----- Restoring log files -----

    RESTORE LOG <db name> FROM DISK = 'D:\xxx_1.TRN' WITH NORECOVERY .. use norecovery till all trn. files are restored

    GO

    RESTORE LOG <dbname> FROM DISK = 'D:\xxx_10.TRN'

    GO

    ------

    What <dbname> to use for log restore - A or B since the name was changed while restoring to server 2 ?

    TIA

    🙂

    (Still think like an Oracle DBA)

  • B

    🙂

  • TX - Shall try it out and see what gives.

    🙂

Viewing 3 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic. Login to reply