VMware Cloud Community
ccaltacc
Contributor
Contributor

Defragmenting VM within VI 3.5 and using snapshots

I have seen loads of documentation explaining that defragmenting a VM within the guest OS is fine as long as your not using snapshots (or do it before creating snapshots) within VI 1.x.

However, I cannot find any info on the same situation applied to snapshots in VI 3.x. I have seen some message boards where people have said that it has changed in VI 3

I recently had a problem with running an auto defragging utility on a few VM's only to have them not able to boot after a few days. The error was about the redo logs.

Can anyone shed some light on this, and/or point me to where some solid documentation is?

Thanks!

Reply
0 Kudos
7 Replies
cody_bunch
Hot Shot
Hot Shot

I am interested in the answer to this as well.

-Cody Bunch http://professionalvmware.com
Reply
0 Kudos
PhilipArnason
Enthusiast
Enthusiast

Because the storage is virtualized, (I'm guessing you keep your VMs on a RAID set), it makes little sense to defragment the VMs at all. Defragging makes most sense on a single hard drive. Now you will get defragment software companies that tell you otherwise, and newsgroups are full disagreement on this subject, but please read the following link which hopefully clears it all up:

Please mark answered if this helps.

Philip

Reply
0 Kudos
ccaltacc
Contributor
Contributor

This is good information to know. However, I would like to know what VMware has to say on the issue via documentation. If my VMs crash because they are using snapshots and someone accidently runs defrag, then that is a huge problem and needs to be addressed plainly and clearly.

Reply
0 Kudos
touimet
Enthusiast
Enthusiast

We have Diskeeper installed, by default, in all our VM images/templates. I too would like to get the "official" word from VMware on defragmentation of VM's vmdk drives.

Reply
0 Kudos
mowgus
Enthusiast
Enthusiast

Has anyone else noticed the "defragment all disks" permission in virtual center 2.5 (when configuring specific virtual machine interaction permissions)? I don't recall it being there before but perhaps I just over-looked it. Anyhow, it would lead me to believe that there is a defragment tool in VC 2.5...but I don't see one. Maybe it's an upcoming feature? Anyone?

M.

Reply
0 Kudos
depping
Leadership
Leadership

this is not an official statement. but as far as i know snapshot(delta vmdk) contains a bitmap of the original disk. so if anything is changed this will be written to the snapshot file. in other words a defragmentation, moving parts of files, will not do you much good when you delete the snapshot. but i can't think of a reason why this would cause the vm to crash.

Duncan

My virtualisation blog:

Reply
0 Kudos
depping
Leadership
Leadership

h3. Performance Impact of Defragmenting Snapshots and Linked Clones
There may be a performance impact when you defragment a linked clone or
a virtual machine with a snapshot. Exact performance degradation
depends on:<div style="margin-bottom: 4pt; margin-left: 19pt; margin-top: 0pt">

The fragmentation of the parent virtual machine disk when you created the snapshot or linked clone.


The nature of the subsequent updates to the parent virtual machine disk.

Defragmentation tends to make the redo file
grow. The redo file itself can become defragmented with respect to the
host file system. If your use of virtual machines is strongly
performance oriented, you should avoid defragmenting — or using —
linked clones and snapshots.

that's taken from a vmware workstation article: http://www.vmware.com/support/ws55/doc/ws_performance_defrag.html

Duncan

My virtualisation blog:

Reply
0 Kudos