the impact of logical and physical fragmentation in a virtual environment presented by raxco...
Post on 29-Mar-2015
225 Views
Preview:
TRANSCRIPT
The Impact of Logical and Physical Fragmentation in a
Virtual Environment
Presented byRaxco Software, Inc.
October 29, 2009
What The Experts Say
“Like physical disk drives, virtual disks canbecome fragmented. Defragmenting disksrearranges files, programs and unused space on the virtual disk so that programs run faster and files open more quickly.”VMware Defragmenting Virtual Diskshttp://www.vmware.com/support/ws55/doc/ws_performance_defrag.html
Experts…
“Performance in Windows guest operating systems may also be affected by disk fragmentation”VMware ACEhttps://www.vmware.com/support/ace/doc/disks_ntperf_ace.html
Experts…
“The two biggest reasons I see virtual machines get slower over time is due to (1) incorrect virtual machine additions installed and (2) disk fragmentation.”
Andrew ConnellFormer MS Share Point Developer Microsoft MVP-Content Management Server
What is Fragmentation?
Sample Fragmentation Problems
• 10-15 minutes to launch Notes on laptops• Users locked out of servers due to insufficient
contiguous free space• Servers won’t boot• Application hangs and crashes• System errors due to metadata fragmentation• Video/audio “flickers”• Prolonged backup
Cost of Fragmentation
• Productivity• Support • Unnecessary hardware• Longer backups• Opportunity
The Fragmentation Issue
• Logical fragmentation -How NTFS “sees” the disk• Physical fragmentation -How the disk controller “sees” the disk• Free space
The Logical Level• To format a partition Windows needs to know
if it is NTFS/FAT, cluster size and disk size• Bitmap file is how NTFS views the disk• Cannot distinguish between physical disk
types• MFT is created along with metadata files NTFS
NTFS and the MFTComponent Description
NTFS Boot Sector The BIOS parameter block that stores information about the layout of the volume and file system structures, plus the boot code that loads Windows Server.
Master File Table (MFT) The information necessary to retrieve files from the NTFS partition, such as the attributes of a file.
File System Data Stores data that is not contained within the Master File Table
MFT Copy Copies of the records essential for the recovery of the file system if there is a problem with the original.
File Allocation (Writes)
• Create MFT record (one or more) name, parent dir, security, allocation, pointers to other records
• Bitmap accessed to locate free (blocks all) • MFT record is updated with content• NTFS passes LCN’s to disk driver
Anatomy of the MFT
File Access (Reads)
• Load portion of MFT with correct record via directory
• Locate file in the MFT• Pass starting LCN and run length to disk
controller• Number of physical disk seeks determined by
the number of logical fragments
Wasted Seeks
NTFS Expert Concludes…• Free space fragmentation slows down writes• Free space fragmentation blocks on write• File fragmentation causes needless seeks• Slower the disk the greater the bottleneck
The Physical Level
• NTFS reports VCN the starting LCN and its length to the disk controller
• Disk controller maps LCN to PCN based on its software/firmware
• Data written to disk• RAID or other disk configurations may
physically fragment the file for faster access
Fragmentation and VM’s• Windows guests have all the same NTFS
behavior• Resource contention between Windows
guests can be an issue• Resource contention between guests and the
host (Windows-based host)
• Free space fragmentation not good for dynamic vmdk, vhd
How Defragmentation Helps
• All defragmentation is at the logical cluster level
• Defragmentation puts files in strings of contiguous logical clusters ($Bitmap)
• Controller will work faster • Fewer unnecessary seeks to the disk • Fastest possible logical and physical I/O
Advantages• Centralized management
via console• Offline defragmentation of
system and metadata• Consolidates free space • Optimized boot files and
MFT• Requires only 1% free space
• Fast and light on resources• Flexible scheduling• Windows Certified• Full integration with AD• VSS Compatible• Integrated with vSphere 4• Virtualization Aware
No Virtual Awareness
Virtualization Awareness
The Choices
Disk A
• Chaos• Slow • Short Life Cycle • Inefficient• Messy
Disk B
• Orderly• Fast• Long Life Cycle• Efficient• Perfect
For vSphereFor Hyper-VFor VMware WorkstationFor Server and WorkstationFor Exchange
top related