Less Than Dot is a community of passionate IT professionals and enthusiasts dedicated to sharing technical knowledge, experience, and assistance. Inside you will find reference materials, interesting technical discussions, and expert tips and commentary. Once you register for an account you will have immediate access to the forums and all past articles and commentaries.
Restore DB and Replication will not start
From Wiki
When you restore a database that was part of replication on the originating SQL Server and then try to set replication back up on the restore point and make a new publisher you need to clear the logs by running the follow
- EXEC SP_REPLDONE @xactid = NULL, @xact_segno = NULL, @numtrans = 0,
- @TIME = 0, @reset = 1
why?
sp_repldone will mark transactions as distributed. Tis should only be done if you are restoring a database and are setting up replication fresh on the database in the new location. You should completely reinitialize the publications once clearing the error logs after executing repldone to ensure you are consistant
Associated error when trying to set publishers up from a restored database that was a publisher will typically be
The log was not truncated because records at the beginning of the log are pending replication. Ensure the Log Reader Agent is running or use sp_repldone to mark transactions as distributed.



LTD Social Sitings
Note: Watch for social icons on posts by your favorite authors to follow their postings on these and other social sites.