|   | ![]() |
|
Can I do an NT defrag on a SQL
Server .DAT device/file? Will it cause any problems or do any good? Yes you can as long as you stop SQL first - NT needs exclusive access to a file in order to defragment it. As long as there are no bugs in the defrag program and the system doesn't crash in the middle of a defrag then there shouldn't be any problems. Will it help? Usually not much as SQL devices don't tend to change in size once they are created, so unless a disk was badly fragmented when the device was created so that NT could not allocate contiguous space for it all then it won't be fragmented. It does nothing for SQL fragmentation of data/index pages it only defragments the actual device. If you create your SQL devices on a freshly formatted drive then you won't get any fragmentation. |
All content on this site, except where noted, represents an original work of Michael R. Hotek and is protected by applicable copyright laws. The SQL Server FAQ is the sole work of Neil Pike. No page, portion of a page, or download may be used for commercial purposes in whole or in part without the express, written permission of the applicable author.