File-level Defragmentation of Exchange 2013 Volumes

By default, Windows Server 2012 automatically runs a weekly drive optimization (file-level defragmentation) on all drives. It also automatically optimizes new drives when they are added.

Now that you can install Exchange 2013 on Windows Server 2012 should you disable this feature as part of your server builds?

The latest information I could find from Microsoft on this subject is from Nino Bilic (2004): Do we need to file-level defragment Exchange database drives? and Mike Lagase (2011): How fragmentation on incorrectly formatted NTFS volumes affects Exchange.

Nino writes,

The bottom line really is – you do not HAVE to file-level defrag the Exchange database drives. Exchange reads and writes to it’s databases in very random fashion. Large sequential reads and writes will see much more improvement from file system defrag than Exchange databases will. But if you really WANT to do it – I would do it the old-fashioned way: move the databases off to some other volume, file system defrag the drive and then move the databases back… Or at least make sure you have a good backup, dismount the databases and file-system defrag them.

Mike writes,

Note that it is still not recommended to run disk defragmentation software on Exchange server volumes, but there are times where file level fragmentation can cause significant performance problems on a server merely by the way data is being written to the disk. If optimal and/or recommended settings are not used when creating the volumes, this file fragmentation issue can occur much quicker. The majority of Exchange files are in use so running any regular disk defragmentation programs on the server will not help with this situation. If necessary, the only way to resolve this is to take all Exchange resources offline to ensure none of the files are in use and then defragment the disk to make the files contiguous on the disk once again.

That’s Mike’s emphasis, not mine.

So, while it’s not necessarily going to break anything if you defragment your disks, it’s best practice NOT to do it.  Especially letting Windows Server 2012 do it automatically every Wednesday at midnight, as is the default.  Also consider other workloads that may be running at the same time, such as Exchange backups.

Note that this recommendation normally applies to all local disks on an Exchange server, not just the drives that contain mailbox databases and transaction logs.  That’s because the SMTP queue and temporary files are written to the same drive where the Exchange 2013 binaries are installed, usually the C: drive unless you’ve manually moved them to a different drive.

Here’s how to turn automatic drive optimization off in Windows Server 2012:

  • Using File Explorer, view the properties of the C: drive or any other local drive.
  • On the Tools tab, click Optimize.
  • You will see that all local drives are being optimized automatically every week:
  • Click the Change Settings button.
  • Clear the check box to Run on a schedule, as shown below:
  • Click OK, Close, and OK to save the settings.
Disabling drive optimization in this way will disable optimization for all drives.  It does not disable your ability to manually run a disk optimization on any drive.

New OWA for iPhone and OWA for iPad apps released

The Exchange Team released two new apps in the Apple App Store today, the OWA for iPhone and OWA for iPad  These apps currently only work for Office 365 customers, but on-prem versions are in the works.

The apps provide a familiar OWA-like GUI for email and calendaring to Office 365.  Personally, I prefer the OWA calendaring experience to Apple’s native calendaring.

Here are a couple more screenshots:

Read more about the new apps on the EHLO blog and the Office 365 Technology Blog.

Getting to Know IPv6

My good friend Mark Morowczynski, Microsoft PFE for Active Directory, wrote a three-part series on the Ask Premier Field Engineering (PFE) Platforms blog about IPv6 that is well worth reading.

You can follow Mark on Twitter @markmorow.