VMware Cloud Community
Thash
Contributor
Contributor

running out of disk space on VM


Hi all

I`ve got a VM that is out of space and the challenge now I can`t logon on it so that I can free up some space and I can`t expand the disk because that option its inactive "Greyed out" and I can`t migrate the VM to another Datastore because there is no other datastores can accommodate this VM in terms of space. its got the following error "msg hbacommon.outospace: there is no more space for virtual disk tash-file 1-000002.vmdk. you might be able to continue this session by freeing disk space on the relevant volume." I`m in a crisis because my terminal users can`t work now because this VM its file server

Reply
0 Kudos
16 Replies
a_p_
Leadership
Leadership

According to the file name you mentioned the VM ran with one or more active snapshots, which grew over time and filled up the datastore. To find out how to resove this, please provide some details about

  • the datastore (size, free size, shared storage or local)
  • the VM (a screen shot of the files in the datastore browser, showing full names, sizes, time stamps)
  • the VM's latest vmware.log file (located in the VM's folder on the datastore), please attach this file to a reply post using the advanced editor
  • whether other VM's are running on the same datstore which could temporarily be shut down

André

Reply
0 Kudos
Thash
Contributor
Contributor


I deleted the Snapshot not unless its stored on the datastore,  the datastore capacity its 1.86 TB, free space its 6.33 GB, this VM its only one running on the Datastore.

Reply
0 Kudos
a_p_
Leadership
Leadership

This answers the first and the last detail I asked for. However, there's definitely a snapshot involved (even if it may not show up in the Snapshot Manager), so please provide the other details I asked for.

André

Reply
0 Kudos
Thash
Contributor
Contributor

Ok send it to you tomorrow morning when I`m in the office , surely I think its a snapshot for veambackup. is not safe to just remove it on the datastore browser?, how to identify a snapshop.

Reply
0 Kudos
a_p_
Leadership
Leadership

Don't try to remove a snapshot in the datastore browser!!! This will break your VM, i.e. you will loose all current changes!

You can identify VMs  with snapshots by checking their current virtual disk name as it shows up in the VM's settings. If the name is something like <vmname>-00000x.vmdk, then the VM runs on an active snapshot. You may also want to take a look at RVTools, which provides an excellent overview of your virtual environment, including VMs with snapshots.


André

Reply
0 Kudos
Thash
Contributor
Contributor

Anyway Thankx Andre for your advice and  I feel like I can just go to my office now because I need this to be resolved.

Reply
0 Kudos
gajuambi
Enthusiast
Enthusiast

  • if u run out of disk space in a VM then the easiest way to power on a VM is to reduce the memory of the VM to its minimum. ex:- if it is 8gb then edit the vm settings to make it 1gb and power on the vm and it will power on now since u have 7gb free space now. once u power it on, empty as much space as u can from inside the VM.
  • you need approximately 15% of the VM's size space to be free in the datastore to consolidate or remove the snaphost. the best&easiest way to remove snapshots in such scenario is to storage migration or svmotion.
  • if u delete snapshot then the data in that will be lost and u cant power on the vm since the vm will give u an error saying it cant find the snapshot. if u dont care abt what u have in the snapshot then delete the snapshot, edit the vm settings>select the hard disk for which u deleted the snapshot>remove the disk. now click add>hard drive>choose existing disk and select the parent disk of that snapshot.
---------------------- Gajendra D Ambi [pardon my chat lingo]
Reply
0 Kudos
gajuambi
Enthusiast
Enthusiast

reduce the memory to 1gb or less to power it on temporarily.

or

increase the datastore space and then power on the vm

kb.vmware.com/kb/1017662

or

if u dont care abt the data in the snapshots then

vm settings

select the vmdk/disk

click remove

click ok

then again

vm settings

add

hard disk

existing disk/vmdk

browse to the datastore and the vm folder

select the parent vmdk
click ok
delete the snapshot files
power on the vm

---------------------- Gajendra D Ambi [pardon my chat lingo]
Thash
Contributor
Contributor

but what do you mean when you say if I don`t care about the data on the snapshot?.  more than increasing the Datastore I just want to get rid of the snapshot but my worry by deleting its not gonna crash my vm. the other thing when I look under the existing disk of this vm I`ve got 6 disks which include snapshots. the fisrt one its vmname_1.vmdk 800GB,  vmname_1-000002.vmdk 9GB,  vmname.vmdk 783GB,  vmname-000001.vmdk  7GB,  vmname_1-000001.vmdk 81GB,  vmname-000002.vmdk 2GB.  I think I`m getting lost with this snapshot scenario its now that my VM its pointing to the snapshot it means when I delete the snapshot its gonna be safe to do so and add the parent disk without any information being lost. 

Reply
0 Kudos
gajuambi
Enthusiast
Enthusiast

when i said if u dont care abt the data in the snapshot i meant if u delete the snapshot then all the data that has been changed or written to that disk from the time of the snapshot creation will be lost. if u delete vmname-000001.vmdk  then u will lose 7gb of data. if u delete vmname_1-000002.vmdk then u will lose 9GB of data.if u delete vmname_1-000001.vmdk 81GB,  vmname-000002.vmdk 2GB then u will lose 81+2 gb of data. so all u have to do is point the vm to the parent disk instead of the snapshot disks.

---------------------- Gajendra D Ambi [pardon my chat lingo]
Reply
0 Kudos
a_p_
Leadership
Leadership

Does this host run in a HA enabled cluster? If not, you could - at least temporarily - set the memory reservation for the VM to the provisioned memory. This will reduce the swap file size to zero Bytes and allow you to power on the VM to see whether it works. However, once you checked that everything is ok, shut down the VM to avoid running out of disk space again. What you have to do next depends on the ESXi version you are running. If it is ESXi 4.0 Update 2 or later you may open the Snapshot Manager and use "Delete All" to merge all snapshots into the base disks. If "Delete All" is grayed out, create a new snapshot and then click "Delete All". Caution: If you are running an older version, please report back to see what can be done!

Due to the size of the snapshots, deleting them might take a couple of hours - depending on your storage - so please be patient!


André

Thash
Contributor
Contributor

Ohk Thankx now my VM its on and the users can work but the problem its not yet resolved because its still pointing on the snapshots secondly the "delete all" option is not active and to create another snapshot its complaining about insufficient space. what I want to check I can`t download the snapshot on the datastore and save it somewhere for in case and delete it directly on the datastore or remove it on vm settings and change the vm to point on the parent disk. I think I`ll have to do it after hours to avoid disturbance on users. about my ESXi version is 4.0.1

Reply
0 Kudos
a_p_
Leadership
Leadership

DON'T DO THIS! Snapshots are used in chains. This means that all of the .vmdk files are in use and removingg one of them woud break the snapshot chain.

I assume you tried to create the snapshot with the VM powered on? Anyway, please attach one of the latest vmware*.log files as well as the .vmsd file to which can be downloaded from the VM's folder to a reply post and let me know which .vmdk filenames show up for the virtual disks in the VM's settings (to ensure we don't make a mistake). With this information it should be possible to recreate the .vmsd file (this file contains the information for the Snapshot Manager) to allow you to delete the snapshots one-by-one.

André

Reply
0 Kudos
Thash
Contributor
Contributor

Both of my Virtual Disks are pointing on the Snapshots. then first one on vmname-000002.vmdk "which 2GB in size"and the second one on vmname_1-000002.vmdk. "11GB in size". Yes I created the snapshot while my VM was powered on so I have to power it off before I can create the snapshot?.

Reply
0 Kudos
a_p_
Leadership
Leadership

Please provide the files I asked for. The steps are different depending on the exact version and doing the wrong things could make things worse!

André

Reply
0 Kudos
Sajadasd
Contributor
Contributor

You must shrink the disk, AFAIK the "shrink" function is not available via GUI.

For ubuntu virtual machine, Run this command and it takes about an hour (with SSD hard disk) and it needs root permission.

vmware-toolbox-cmd disk shrinkonly

for this command, you must first install vmware-tools package.

and it will work and the storage start freeing up during running of that commands.1

Reply
0 Kudos