locked
Moving Indexes to new drive RRS feed

  • Question

  • Hi All,

    I want to move all indexes into new separate drive for this I need to create new .ndf file in particular drive.

    Mirroring has configured for the DB but the principal and mirror servers do not have same drives.
    In principal I want to move indexes to new I:/ drive and the I:/ derive is not present in mirror server Please suggest.


    • Edited by ImranKazi Wednesday, September 2, 2015 2:54 AM
    Wednesday, September 2, 2015 2:53 AM

Answers

  • The way we used to do this when we still had mirroring around was:

    1) Add the file (Mirror goes to suspended)

    2) Make a Log Backup on Primary

    3) Break mirror (disclaimer: I am not sure if you really need to do that or if the next steps runs without it as well... It has been too long...)

    4) Restore the one Log Backup on the Mirror WITH MOVE clause (and NORECOVERY)

    5) Reestablish the mirror


    The whole process takes about 5 minutes to do and generates very little traffic overhead.
    Wednesday, September 2, 2015 4:47 PM
  • Moving the index itself does not impact the mirror, as long as you don't create new files.
    Thursday, September 3, 2015 3:57 AM

All replies