VMware Configuration File Storage Best Practices

Posted on 2012-09-06
Last Modified: 2012-09-16

For vSphere 4.0 Can anyone point me in the right direction for what is storage best practice for VMDK and VMX Configuration files. The main question I have is:

Is it wise to have VMDK and VMX files on a different datastore?

The reason I ask is yesterday a snapshot after replication didn't close properly so datastore ran out of space and VM went into a suspended state. What a nightmare that was since VM was on it's own 50GB datastore so there was no other VM I could migrate off to gain space.

To prevent this happening again, I thought of moving VMX files to a dedicated datastore. Are there any gotcha's to doing this?

Question by:ams_group
    LVL 116

    Expert Comment

    by:Andrew Hancock (VMware vExpert / EE MVE)
    The VMX configuration files are very small.

    It's really best practice to keep them together, or ensure you have good documentation  so you know which datastores the VMX and VMDK (virtual disks) reside on.

    You can create a dedicated fast datastore for the snapshots, so the snapshots can be on a different datastore.

    see here

    Always ensure that your datastores are 20% free, to allow for snapshots.

    Also see my other articles

    HOW TO: VMware Snapshots :- Be Patient

    Author Comment

    Thanks for your response and the articles. I read that one about changing the location of snapshots a few days ago but I involves turning off the virtual machine to edit the VMX file. I didn't want to cause any down time.

    Since the VMX file were so small my plan was to have two Datastores for VMX files on fast storage. These would be labled LUNXX_VMX and would be 100GB each (to allow for snapshots). There are only 12 VMs that are replicated so 6 VMX files on each. These VMX files would also be backed up seprately. The VMDK files for OS drives are on LUNXX_OS with one VM per 50GB datastore. Data drives are on LUNXX_DATA (500GB) with multiple VMs on each Datastore.

    If I am thinking of this correctly, since VMX files would be on the separate datastore to VMDK, there should be no risk of a VM outage if snapshot fills up disk space. Am I correct in suggesting the VMX file is not critical to the running of a VM and just holds config information only? Also, are snapshots always created where the VMX file is?

    Thanks and look forward to hearing your thoughts.
    LVL 116

    Accepted Solution

    Snapshots are created by default where the first virtual disk is created, which is usually where the machine configuration files (vmx) is stored.

    If the snapshot fills up the datastore, the VM will fail, and you will have an outage.

    It's bad practice to leave VMs running on snapshots, performance is also affected as well.

    Author Comment

    Ok thanks.. We do not leave VMs running on snapshots and it's our over-night replication software vRanger that uses snapshots to ensure a consistent replica image in our DR site. A couple of times it has failed to commit the snapshot and the datastore quickly fills up.

    Thought I'd do a test and migrated a test server configuration file to my VMX datastore and created a test snapshot. The Snapshot went on the VMX datastore. The SWAP files was here too so will need to make datastore bigger to allow for this.

    On another note, for the VM that had issues last week I cannot migrate to another datastore while powered on. It says the VM is in "linked clone mode". In snapshot manager it shows no snapshots also. Do you know how to get a VM out of linked clone mode?

    [root@ESX3 ~]# vmware-cmd /vmfs/volumes/4f87a35c-4abbf28d-c68e-001e4ffce634/SV-SQLREPORT/SV-SQLREPORT.vmx hassnapshot
    hassnapshot() = 0

    LVL 116

    Expert Comment

    by:Andrew Hancock (VMware vExpert / EE MVE)
    Okay, if your snapshots are being used for this purpose, that's okay, Most Third Party Backup software uses Snapshots in this way.

    It's best if we deal with the linked clone issues, under a different question.

    Author Comment

    Ok thanks, VMX files are now on separate datastore to VMDK so that snapshots created by 3rd party replication software can't cause the disk with VMDK files to fill up resulting in an outage.

    Working well so far. Also resolved linked clone problem by creating a snapshot then deleting all snapshots. Must've been a uncommited snapshot causing the issue.

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    What Security Threats Are You Missing?

    Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

    Storage devices are generally used to save the data or sometime transfer the data from one computer system to another system. However, sometimes user accidentally erased their important data from the Storage devices. Users have to know how data reco…
    For Backups Guest OS files and indexing(and application awareness), Veeam needs Admin rights in Guest OS(Windows and Linux). In Windows a Domain Administrator account, and in Linux root access to perform this type of Backups and also Restore.
    This tutorial will show how to configure a single USB drive with a separate folder for each day of the week. This will allow each of the backups to be kept separate preventing the previous day’s backup from being overwritten. The USB drive must be s…
    The viewer will learn how to start File History, a MACINTOSH like backup utility built into windows 8, on your Windows 8 computer. To open the File History control panel swipe from the right  side to get the search menu or position the cursor in the…

    737 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    18 Experts available now in Live!

    Get 1:1 Help Now