Offline defrag a replica database…

Let’s leave the “why would you? ” to one side for the moment but is it actually possible or supported to defrag a continuous replication target database?  Well not surprisingly er ‘No’.  An offline defrag creates a new database with a new signature (“When defragmentation is complete, the original database is deleted or saved to a user-specified location, and the new version is renamed as the original.”) and therefore whilst it will be possible to defrag the database you’ll break replication.

So if you know that you have a large amount of whitespace that it is possible to claw back (maybe you have just reorganised your mailboxes across a larger set of mailbox databases?) and you want to run an offline defrag then you need to defrag the active database and reseed a replica…

In my experience there aren’t many reasons to perform an offline defrag and so the relative pain of this process should not be one that many administrators have to follow.  And of course if your LUNs and disk set up allows it might be preferable to create a new database, seed it and then move all the mailboxes from the original database to this new one.

Try this article on Technet for the steps to see a CCR database; How to Seed a Cluster Continuous Replication Copy

Comments

  • Anonymous
    March 03, 2009
    PingBack from http://www.anith.com/?p=15312

  • Anonymous
    March 04, 2009
    ..and thinking about it be careful of differencing bloat with your VSS backup as a result of an offline defrag..!

  • Anonymous
    July 01, 2010
    We have been performaing offline backup from years and no problem encountered so far.

  • Anonymous
    July 01, 2010
    We have been performing offline backup from years and no problem encountered so far.

  • Anonymous
    July 04, 2010
    Lots of Exchange admins do without problem.  Personally I wouldn't, as long as I had good monitoring in place...

  • Anonymous
    July 25, 2010
    Creating a new database and moving mailboxes will break single-instance storage. Offline defrag does not.