The Impact of Logical and Physical Fragmentation in a

Download Report

Transcript The Impact of Logical and Physical Fragmentation in a

The Impact of Logical and
Physical Fragmentation in a
Virtual Environment
Presented by
Raxco Software, Inc.
February, 2010
What The Experts Say
“
Like physical disk drives, virtual disks
can become fragmented.
Defragmenting disks rearranges files,
programs and unused space on the
virtual disk so that programs run faster
and files open more quickly.”
VMware Defragmenting Virtual Disks
http://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 ACE
https://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 Connell
Former MS Share Point Developer
Microsoft MVP-Content Management Server
What is Fragmentation?
?
?
?
?
?
?
?
?
?
?
?
?
?
?
?
?
??
?
?
?
?
?
?
?
?
?
?
?
?
Sample Fragmentation Problems
• 10-15 minutes to launch Notes
• Users locked out of servers
• 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
• Physical fragmentation
• File fragmentation
• Free space fragmentation
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 “sees” the disk
• Cannot distinguish between physical disk
types
• MFT is created along with metadata files
NTFS
File Allocation
•
•
•
•
Create MFT record (one or more)
Bitmap accessed to locate free space
MFT record is updated with content
NTFS passes LCN’s to disk driver
Create
Bitmap
Access
MFT
Update
LCN’s to
Disk
Driver
Anatomy of the MFT
(vcn, lcn, run length): (8a85, 9189a, 7)
File Access
• 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
Load
Locate
File
# LCN’s
#
Physical
Seeks
Wasted Seeks
Partition State
Total Number
of I/O Requests
Sent to the File
System
Total Number
of Resulting
Disk
Accesses/Seeks
Net Wasted
Seeks When
Running
SYSmark
Percent Net
Wasted Seeks
When Running
SYSmark
Fragmented
1,320,686
2,090,649
769,963
58.30%
After
PerfectDisk
1,434,454
1,616,847
182,393
12.72%
After Diskeeper
1,341,262
1,961,954
620,692
After Built-In
1,411,613
1,931,395
519,782
46.28%
36.82%
NTFS Expert Concludes…
• Free space fragmentation
slows down writes
• Free space fragmentation
blocks on write
• File and free space
fragmentation
causes needless seeks
• Slower the disk the
greater the bottleneck
The Physical Level
• NTFS reports starting LCN and
length to the disk controller
• Disk controller maps LCN to
PCN based on its
software/firmware
• Data written to disk
File Fragmentation and Free Space
•
•
•
•
Data files — most numerous
System files — Page file and hibernate file
Metadata files — $logfile, $bitmap, $badclus
Free space — the real enemy!
Fragmentation and VM’s
• Windows guests have all the same NTFS
behavior
• Resource contention between Windows
guests
• Resource contention between guests and the
host (Hyper-V and vSphere)
• Free space fragmentation not good for
dynamic vmdk, vhd
Possible Solutions
• More hardware
• Windows Defragmenter –
not enterprise solution
• Perfect Disk vSphere Bundle
• Perfect Disk Hyper-V Bundle
How Does Defragmentation Help?
• File defragmentation speeds up disk
reads
• Free space defragmentation speeds up
disk writes
• Reduces unnecessary physical disk seeks
• Reduces resource contention for VM’s
• Fastest possible logical and physical I/O
No Virtual Awareness
Virtual Machine and Status
VM1 Idle
VM1 Idle
VM1 Busy
VM1 Busy
Basic Automatic Defragmentation
Defrag
Status
0
Remaining Resources (CPU & I/O) For Busy Machines
100
Virtualization Awareness
Virtual Machine and Status
VM1 Idle
VM1 Idle
VM1 Busy
VM1 Busy
Automatic Defragmentation with Virtualization Awareness
Dynamic
Monitor
Defrag
Status
0
Remaining Resources (CPU & I/O) For Busy Machines
100
PerfectDisk Virtual Solutions
• Virtually Aware for vSphere and Hyper-V
• vSphere console snap-in
• Enterprise console for Hyper-V
• Host & Guest solutions for Hyper-V
• Support for vMotion and Live Migration
• Fully automated compaction for Hyper-V
• Automated shrink & re-indexing for
VMware Workstation
Win a Free PerfectDisk
Virtualization
Bundle Today!
Just Register.
For more information:
• Ask a question
• See me after this presentation
• Go to www.perfectdisk.com