Restoring Log Files

  • Hi,

    I got a question. Its been asked during an Inteview to me but

    Scenario is

    On Sunday I took a full Backup of Database.

    Mon and Tue I have a automatic diffrential back up

    and Wed Morning 4. AM DB Crashes.

    Now I have One Full Back up, 2 Diffrenial backups and the Transaction Log File which holds data for three Hours. How Do I Make the database again functional with using all three resources ?

    Thanks in Advance

    --Jeswanth

    --------------------------------

  • You've been asked this in an interview for a DBA position I would assume?  If that assumption is not true, please ignore the rest of this message.  If it's true:

    1.  You need to go spend some money on SQL Server books and begin reading.  Don't stop until you have read at least 20 of them and taken notes.

    2.  You need to read Books Online.  Everything in Books Online.  Take notes.

    3.  Perform some backups.  Try to restore from them.  Do this based on what you have read in steps 1 and 2.

    4.  If you can't get 3 to work, find another line of work.

    5.  Go back to line 1, replacing 3 with something else you've hopefully learned in 1 and 2. 

    Derrick Leggett
    Mean Old DBA
    When life gives you a lemon, fire the DBA.

  • Hi,

     

     

  • Thanks. Derrick Leggett, I will do that for sure.

    --------------------------------

  • Assuming the crash isn't recoverable on re-start.

    Depending on the type of failure you may/may not be able to dump the current on-line log to  bring you right upto date

    To get a 'working database' simply restore the last full backup.

    To get an up-to-date 'working database', restore the last full backup without recovery, restore the last differential without recovery, restore subsequent tran logs without recovery until the last available log which needs to be restored with recovery or restored without recovery and the 'restore database <db name> with recovery statement executed afterward.

    That's principally it in a nutshell.

    Rick -

    Slightly less mean, old(a perspective thing)  DBA.

  • Thanks for the information and the guidance Rick.

    --------------------------------

Viewing 6 posts - 1 through 5 (of 5 total)

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