VMware vSphere

 View Only
  • 1.  Deleting Snapshots from LinkedClone Corrupts other LinkedClones

    Posted Jul 18, 2012 04:40 PM

    Hi,

    I am currently having a problem in which I have 3 LinkedClones created from the same parent snapshot.

    The tasks I do consists of creating a lot of snapshots per virtual machine, therefore having the need of deleting snapshots after a period of time.

    Because I only need the most recent snapshots, I always delete the oldest one (the one at the top of the tree).

    This action ends up changing the ID in the VMX file of the Parent VM, causing the other 2 VMs to become unusable.

    An example.

    Parent creates snapshot 0, which will be used to bring clones A, B,and C.

    Using these 3 clones, I keep taking snapshots over a period of time until the snapshot tree is full.

    Let's take A, with snapshots: 1. 2. 3. 4. 5. 6. 7. 8.

    I delete 1 to make more room. This changes the Parent's ID.

    What can I do to solve this problem?

    On a side note, vSphere Client tells me that it needs consolidation for VMs B and C.



  • 2.  RE: Deleting Snapshots from LinkedClone Corrupts other LinkedClones

    Posted Jul 18, 2012 04:42 PM

    Correction: I meant the VMDK file instead of VMX.



  • 3.  RE: Deleting Snapshots from LinkedClone Corrupts other LinkedClones

    Posted Jul 18, 2012 05:57 PM

    Welcome to the Community,

    how do you create these linked clones? Please let me know the exact steps to see whether there's something you can do to prevent the base virtual disk from being modified.


    André



  • 4.  RE: Deleting Snapshots from LinkedClone Corrupts other LinkedClones

    Posted Jul 18, 2012 06:09 PM

    Thank you for the quick reply Andre.

    Since I am using ESX instead of vCenter or other solutions, I create a snapshot from the parent VM. Then I copy the VM-000001.vmdk and VM.vmx into a separate folder. I manually edit the VMDK to show the full path of the parent VMDK and edit the VMX to display a new name. After that, I added the VMX to the inventory.

    I followed instructions from this link http://www.sanbarrow.com/linkedcloneswithesxi.html



  • 5.  RE: Deleting Snapshots from LinkedClone Corrupts other LinkedClones
    Best Answer

    Posted Jul 18, 2012 06:26 PM

    I discussed the same issue with another user a few days ago. What's missing in the description you mentioned, is the creation of a .vmsd file for the linked clone. Either add a .vmsd file like the one I attached when you create a linked clone or add the two lines to the existing .vmsd file. Make sure you reload (remove from inventory/add to inventory) the VM after this.

    André



  • 6.  RE: Deleting Snapshots from LinkedClone Corrupts other LinkedClones

    Posted Jul 18, 2012 06:39 PM

    Would you please explain to me what does this do?

    Also, the part it says sentinel0 = "LinkedClone.vmdk" do I replace with "VM-000001.vmdk" if that's the disk I used?



  • 7.  RE: Deleting Snapshots from LinkedClone Corrupts other LinkedClones

    Posted Jul 18, 2012 06:52 PM
    Would you please explain to me what does this do?

    The two lines in the .vmdk file tell the host (ESXi) to consider the "sentinel0" as the "base" file for this VM and not it's parent virtual disk.

    Also, the part it says sentinel0 = "LinkedClone.vmdk" do I replace with "VM-000001.vmdk" if that's the disk I used?

    Yes, you have to rename the .vmsd file to the VM's name (same as the .vmx file name) and replace the "sentinel0" with your linked clone's "base" snapshot .vmdk file.

    André



  • 8.  RE: Deleting Snapshots from LinkedClone Corrupts other LinkedClones

    Posted Jul 18, 2012 07:01 PM

    Thank you Andre. You are a lifesaver!



  • 9.  RE: Deleting Snapshots from LinkedClone Corrupts other LinkedClones

    Posted Jul 18, 2012 08:51 PM

    Hi Andre
    at the time I wrote that howto the sentinel0 keyword for vmsd-files did not exist.
    If I remember right it was added when View appeared.

    Do you have any suggestions what I should add ?

    Ulli



  • 10.  RE: Deleting Snapshots from LinkedClone Corrupts other LinkedClones

    Posted Jul 18, 2012 09:18 PM

    Hi Ulli,

    I actually took a closer look at this a few days ago, while discussing how to get rid of a large number of snapshots for a linked clone which was created following your description (see Merge delta.vmdk files to its parent(s)). Since I was too lazy to rebuild the .vmsd file in this case, I created a linked clone in VMware Workstation to see how the parent disk was protected and tested this on my ESXi host.

    I think it would be helpful for users if you'd add a sample .vmsd file to your description at http://sanbarrow.com/linkedcloneswithesxi.html.

    André