As high performing storage solutions based on block protocols (e.g. iSCSI, FC), SANs excel at optimizing block access. SANs work at a storage layer underneath the operating systems file system; usually NTFS when discussing Microsoft Windows®. That dictates that a SAN is unaware of “file” fragmentation and unable to solve this issue.
Fig 1.0: Diagram of Disk I/O as it travels from Operating System to SAN LUN.
With file fragmentation causing the host operating system to generate additional unnecessary disk I/Os (more overhead on CPU and RAM) performance suffers. In most cases the randomness of I/O requests, due to fragmentation and concurrent data requests, the blocks that make up the file will be physically scattered in uneven stripes across a SAN LUN/aggregate. This causes even greater degradation in performance.
Fig 1.1: Sample Windows Performance Monitor Report from fragmented SAN-attached NTFS volume.
Fortunately there are simple solutions to NTFS file system fragmentation; fragmentation prevention and defragmentation. Both approaches solve file fragmentation at the source, the local disk file system.
IntelliWrite® “The only way to prevent fragmentation before it happens™”
IntelliWrite is an advanced file system driver that leverages and improves upon modern Windows’ file system “Best Fit” file write design in order to write a file in a non-fragmented state on the initial write. Intelligently writing contiguous files to the disk provides four principal benefits above and beyond defragmentation, including:
- Prevents most fragmentation before it happens
- Better file write performance
- An energy friendly approach to improving performance, as defragmentation is not required for files handled by IntelliWrite
- 100% compatibility with copy-on-write technologies used in advanced storage management solutions (e.g. snapshots)
While eliminating fragmentation improves performance. it is important to properly configure and account for advanced SAN features.
With the increasing popularity of SANs, we've included instructions in the Diskeeper installation to ensure users properly configure Diskeeper:
We suggest reading this full document before executing any of the recommended configurations. These instructions apply to V-locity (used on VMs as well).
Implementing Diskeeper on a SAN is simple and straightforward. There are two principal concepts to ensuring proper configuration and optimal results:
- Ensure IntelliWrite is enabled for all volumes.
- Find a time to schedule Automatic Defragmentation (more details below)
If you are implementing any of the following SAN based technologies such as Thin Provisioning, Replication, Snapshots, Continuous Data Protection (CDP) or Deduplication, it is recommended to follow these guidelines.
Defragmentation can cause unwanted side effects when any of the above referenced technologies are employed. These side effects include:
With SAN replication:
Likelihood of additional data replication traffic.
Likelihood of additional storage requirements for data that defragmented/moved and snapshot-related performance lag.
With Thin Provisioning:
Likelihood of additional storage requirements for data that defragmented/moved.
Potential for additional deduplication overhead. Also note that deduplication can be used to remove duplicate blocks incorrectly allocated due to defragmentation. This process can therefore be used to reclaim over-provisioned space.
This is why it is important to enable the fragmentation prevention (IntelliWrite) and change the Automatic Defragmentation to occur during non-production periods to address the pre-existing fragmentation:
During Installation, disable Automatic Defragmentation;
Uncheck the “Enable Automatic Defragmentation” option during installation.
Upon installation ensure IntelliWrite is enabled on all volumes (default). IntelliWrite was specifically designed to be 100% compatible with all advanced SAN features, and should be enabled on all SAN LUNs. IntelliWrite configuration is enabled or disabled per volume, and can be used in conjunction with Automatic Defragmentation, or exclusively.
To ensure IntelliWrite is enabled, right click a volume(s) and select the feature.
Then confirm “Prevent Fragmentation on this volume” is selected, and click “OK” to complete.
Once installed, enable Automatic Defragmentation for any volumes that are not mapped to a SAN LUN. This may include the System Partition (e.g. C:\).
To enable Automatic Defragmentation, right click a volume(s) and select the feature.
Then check “Enable Automatic Defragmentation on the selected volumes” and click “OK” to complete.
If you are not using any advanced SAN features, it is recommended to enable Automatic Defragmentation for all days/times. However, note that pre-existing fragmentation will require significant effort from Diskeeper to clean up. This effort will generate disk I/O activity within the SAN.
Therefore, if existing fragmentation is significant, initially schedule Diskeeper to run during off-peak hours. As Diskeeper has robust scheduling capability, this is easily configured.
To enable Automatic Defragmentation during non-production periods, right click a volume(s) and select the feature.
Then check “Enable Automatic Defragmentation on the selected volumes”. Diskeeper is then scheduled by using your mouse to highlight over the 30 minute blocks in the interactive weekly calendar.
The above example disables defragmentation Monday through Friday. It also disables defragmentation Saturdays and Sundays except between 7pm until 3:30am the following morning. This would afford 17 hours of defragmentation availability per week. Immediately following these scheduled defragmentation periods is when SAN maintenance for advanced features should be addressed (e.g. thin reclamation, deduplication).
Should accommodating SAN maintenance be difficult (e.g. limited maintenance windows)using a weekly optimization process, very granular scheduling is also available with Diskeeper. Note, maintenance windows are not required in order to implement and benefit from IntelliWrite.
To schedule for specific non-reoccurring dates and times in the future, select the “Turn Automatic Defragmentation on or off based on specific dates” option. Click any multitude of dates and times using Shift-Select or Ctrl-Select. Once done, click OK to complete.
If you are implementing the above mentioned advanced technologies and your SAN provides hot block optimization / data tiering, it is also recommended to disable I-FAAST® (Intelligent File Access Acceleration Sequencing technology). I-FAAST sequences hot “files” (not blocks) in a Windows volume, after determining hardware performance characteristics. The sequencing process creates additional movement of data for those advanced SAN features, and is therefore generally recommended to disable when similar SAN solutions are in place.
To disable I-FAAST, right click a volume(s) and select the feature.
Note, I-FAAST requires Automatic Defragmentation be enabled. Also note that I-FAAST is disabled by default in Diskeeper 2011 in certain cases. Also note that I-FAAST generates additional disk I/Os and will therefore cause an increase in the aforementioned Automatic Defragmentation side effects.
Once pre-existing fragmentation has been removed, increase the periods in which Diskeeper actively optimizes the Windows file systems. With real-time defragmentation and InvisiTasking® technology, Diskeeper immediately cleans up fragmentation (that is not prevented by IntelliWrite). This minimal ongoing optimization generates only invisible, negligible I/O activity.
New features in Diskeeper 2011 to improve SAN performance:
Diskeeper 2011 introduces SAN specific solutions. These default solutions automate many of the configurations required for SAN-attached servers.
Diskeeper 2011’s new Instant Defrag™ technology dramatically minimizes I/O activity, and exponentially speeds up defragmentation. The Instant Defrag engine is provided fragmentation information, in real-time, by the IntelliWrite file system filter driver (those fragments that it does not prevent). Without the traditional need to run a time and resource intensive whole-volume fragmentation analysis, Instant Defrag can address the recently fragmented files as they occur. This dynamic approach prevents a buildup of fragmentation, which could incur additional I/O overhead to solve at a later date/time.
Diskeeper 2011’s new Efficiency Mode (default) maximizes performance, while minimizing disk I/O activity. By focusing on efficiency and performance and not on presenting a “pretty disk” visual display, Diskeeper 2011 minimizes negative side effects (e.g. reduce snapshot storage requirements or thin LUN growth, etc..) while maximizing performance benefits. It is a SAN-optimized defrag mode and our recommended solution for SAN-attached Windows volumes.
By default, Efficiency Mode also disables proprietary file placement features such as I-FAAST.
Also, by default, Diskeeper 2010/2011 moves data to lower NTFS clusters, and hence generally “forward” on SAN LUNs.
Best Practices Summary:
- Ensure IntelliWrite is enabled for all volumes.
- Automatic Defragmentation should be enabled at all times for all direct attached storage volumes.
- Use Efficiency Mode of Diskeeper 2011.
- Schedule Automatic Defragmentation on SAN LUNs, based on use of advanced SAN features.
- Run SAN processes such as space reclamation and/or deduplication on recently defragmented LUNs using advanced SAN features.
Want this in PDF form. Get it here: Best Practices for using Diskeeper on Storage Area Networks.pdf (3.00 mb)