Log shipping failed after change the database recovery model

  • I implement the log shipping and in the source server,

    I am doing the following step in the source database.

    1.Alter database set recovery simple

    2.Reindex the database

    3.Alter database set recovery full

    After change the recovery model, log shipping recovery is failed in the destination server.

    Please advice, how to solve this issue?

  • by putting the database into simple mode you have broken the log chain. there are now missing lsns (they were truncated from the tran log) so you will not be able to restore log backups now. If you are log shipping you cannot truncate the log in any way, putting it into simple mode does this. If you want to reduce log usage during the dbreindex, use bulk-logged, take tran log backuips more frequently while it runs, or break up the dbreindex into smaller chunks.

    Could also set up an alert to run the tran log backup job if it log gets say 60% full

    You will have to take a new full backup and re-initialise log shipping

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

  • Why would you set the recovery model to simple?

    The above advice is correct. Log shipping requires logs to send to the destination server. If you move away from full recovery mode, you don't get logs.

  • Thanks for u r advice. But the recovery model is full,log file size is reach around 25GB. and move the log file to another system also failed.

    Is any other menthod to create a standby server without logshipping and replication

  • recovery mode is full now but you said yourself you set it to simple to do the reindex. Set it to simple for any length of time and log shipping will be broken.

    Use tips I gave you to control growth of log, but if its 25GB maybe it needs to be and if you have the space its not a problem. You can shrink the log file whilst log shipping, just never truncate it.

    So way out remains take nother full backup and re-initialise log shipping.

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

  • You might want to add the following to your routine, plus you might want to re-sync your stand by server every weekend. Before starting your maint, you disable logshipping. Once your maint completes, you makes a full backup, copy it and restore into stand-by server. Then Enable Log-Shipping. Once you define it, it should work like a breeze. About 4 years ago, when we didnt flip database into simple recovery mode after reindexing on one of the weekends, our tran Log was over 60GB. Imagine to copy it to Stand-by server! Plus you might want to add some compression software to it as well.

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

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