I’m probably not the only one that has noticed that as the volume of data gets bigger in out databases, the time taken to preform maintenance increases.

This seems to be a simple fact of life for the DBA. But as our maintenance time increases, we need to be aware of if we are still able to meet out SLA’s.

For example, a database that too 20 minutes to restore 6 months ago may now be so full of data that it now takes 45 minutes to restore. If our SLA’s say 30 minutes then it was fine 6 months ago, but now we’ll definitely be breaking that contract. This probably means that your boss will not be too happy should you need to restore that database now.

Another thing that happens is that as data in tables gets bigger, so too do the indexes, and consequently the time to rebuild / reorganize will increase. In fact the time to rebuild / reorganize may be so long that doing ONLINE rebuilds may be your only option to maintain your SLA’s. For example, if you rebuild an index OFFLINE then any data associated with the index will be inaccessible for the period of the rebuild, possibly taking your downtime past any acceptable metric defined in your SLA’s.

To start with, you’ll either need the enterprise or datacenter version of SQL SERVER.

Assuming you’re got that, you’re going to have to be aware of certain criteria that exist around rebuilding indexes on line.

The table can’t contain a lob type, if it does then you’ll recieve the following error message.

Msg 2725, Level 16, State 2, Line 2

An online operation cannot be performed for index ‘PK_TESTLOB’ because the index contains column ‘FULLNAME’