VMware Cloud Community
rhmahfuz
Contributor
Contributor
Jump to solution

About Snapshot Deleting

Hi,

I've a ESXi 4.1 host with a guest OS (CestOS). The total space of the VMFS(data store) partition is 550 GB. Out of 550 only 25 GB is available now. There are 4 snap shot of that guest OS (the last one is 250 GB and the first one 45 GB). I want to delete the 1st snapshot.

1. Which is the best way to delete this snapshot?

2. If I want to delete the snapshot using vSphere Client, what are the negetive impact.

The Guest is a hosting server with 200 client so I can't bare the down time. Please give me a best way to do this. If possible please provide links to perform this steps.

Thanks in advance.

0 Kudos
1 Solution

Accepted Solutions
a_p_
Leadership
Leadership
Jump to solution

Basically I agree with continuum and cloning would be safest way to clean this up. However if I understand the situation correctly you should be able to delete the snapshots with the VM without downtime. What I understood is:

  • you are running ESXi 4.1
  • datastore size 550GB, 25GB free
  • all snapshots show up in the Snapshot Manager
  • the VM is the only VM on this datastore
  • VM has a thick provisioned disk (adding the file sizes, this should be the case)

can you confirm this?

In this case you can delete the first snapshot (the one closest to the base disk) without the need of additional disk space, except for the changes that go to the newest snapshot. With 25GB free disk space this should be ok!? After the first snapshot has been merged to the base disk, you should have additional 80GB free disk space (according to the time stamps, snapshot file 000002.vmdk is the oldest snapshot, the file names do not necessarily be in an ascending order), in which case you can now decide to continue cleaning up the snapshots one-by-one or using "Delete All" to get rid of all snapshots.

André

View solution in original post

0 Kudos
14 Replies
JCMorrissey
Expert
Expert
Jump to solution

Hi,

Take a look at (v.good tips for snapshot removal):

http://communities.vmware.com/thread/283021

and more of an overview of snapshots

http://kb.vmware.com/kb/1015180

Many tx

Please consider marking as "helpful", if you find this post useful. Thanks!... http://johncmorrissey.wordpress.com/
0 Kudos
continuum
Immortal
Immortal
Jump to solution

post a filelist of the vmdks of this VM
Is the basedisk of that VM thick or thin provisioned ? - that is the most important question at the moment


________________________________________________
Do you need support with a VMFS recovery problem ? - send a message via skype "sanbarrow"
I do not support Workstation 16 at this time ...

0 Kudos
rhmahfuz
Contributor
Contributor
Jump to solution

Hi Continuum,

Thanks for your reply. I am attaching the screen shoot of the following command from the ESXi 4 host.

# df -h

# ls -l /path-to/datastore-dir/

esxi-1.png

# ls -l /path-to/datastore-dir/my-vm-dir/

esxi-3.png

Here I also attaching the screenshot of disk properties and snapshot manager

esxi-4.png

Thank you once again for your reply.

Message was edited by: rhmahfuz

0 Kudos
continuum
Immortal
Immortal
Jump to solution

Hi
You should think about the way you use snapshots.
If you were using version 4.0 you would need to add more storage - to get rid of them.
As you have 4.1 it should be safe to delete the first snapshot - the one that directly points to the basedisk.
Deleting any other snapshot would result in a desaster.

If possible do this in a downtime - if that is not possible use the nightime when the server is less busy.


________________________________________________
Do you need support with a VMFS recovery problem ? - send a message via skype "sanbarrow"
I do not support Workstation 16 at this time ...

rhmahfuz
Contributor
Contributor
Jump to solution

Hi Continuum,

Thanks for the Reply. Please make me clear delete "The first Snapshot"

Untitled.png

If this is the scenario. The first snapshot mean the SnapShot 01 that is red marked in the image?

0 Kudos
continuum
Immortal
Immortal
Jump to solution

Yes - snapshot 01 - the one that directly links to the basedisk (the vmdk which uses a flat.vmdk) is the only one that can be deleted without filling up the volume.

And that is only because the basedisk is thick provisioned.
If you had a thin provisioned basedisk delting snapshots may not be possible at all without adding extra space.

Delete means using the Snapshotmanager button - do not use rm or Datastorebrowser to delete the name-000001.vmdk manually !!!


________________________________________________
Do you need support with a VMFS recovery problem ? - send a message via skype "sanbarrow"
I do not support Workstation 16 at this time ...

rhmahfuz
Contributor
Contributor
Jump to solution

Hi,

You are really helpful

Can you please tell me that what could be the negetive impact/risk while I delete snapshot using VMware vSphere Client (snapshot size is 43 GB).

Thanks.

0 Kudos
continuum
Immortal
Immortal
Jump to solution

If you fill up the datastore while deleting a snapshot you will get into trouble.

If I were in your shoes I would add another datastore with at least 270 GB and then I would use vmkfstools to create a full clone - I would do this in a scheduled downtime.


________________________________________________
Do you need support with a VMFS recovery problem ? - send a message via skype "sanbarrow"
I do not support Workstation 16 at this time ...

0 Kudos
a_p_
Leadership
Leadership
Jump to solution

Basically I agree with continuum and cloning would be safest way to clean this up. However if I understand the situation correctly you should be able to delete the snapshots with the VM without downtime. What I understood is:

  • you are running ESXi 4.1
  • datastore size 550GB, 25GB free
  • all snapshots show up in the Snapshot Manager
  • the VM is the only VM on this datastore
  • VM has a thick provisioned disk (adding the file sizes, this should be the case)

can you confirm this?

In this case you can delete the first snapshot (the one closest to the base disk) without the need of additional disk space, except for the changes that go to the newest snapshot. With 25GB free disk space this should be ok!? After the first snapshot has been merged to the base disk, you should have additional 80GB free disk space (according to the time stamps, snapshot file 000002.vmdk is the oldest snapshot, the file names do not necessarily be in an ascending order), in which case you can now decide to continue cleaning up the snapshots one-by-one or using "Delete All" to get rid of all snapshots.

André

0 Kudos
rhmahfuz
Contributor
Contributor
Jump to solution

Hi Continuum,

Thanks for your Suggestion and guidance.

Hi André,

Thanks for your answer. The current status of the host is:

  • you are running ESXi 4.1 

Untitled.png

  • datastore size 550GB, 24GB free
  • all snapshots show up in the Snapshot Manager  YES
  • the VM is the only VM on this datastore    YES
  • VM has a thick provisioned disk  YES  (adding the file sizes, this should be the case)  

Should I take a backup of *000001.vmdk & *000002.vmdk before perform the delete process? Or what should I backup before start delete process?

Regards,

rh.mahfuz

0 Kudos
a_p_
Leadership
Leadership
Jump to solution

Basically you should - independent of this issue - have an up-to-date backup of the VM/important data. Anyway, I do not expect issues with deleting the snapshots one-by-one with the VM powered off.

André

0 Kudos
rhmahfuz
Contributor
Contributor
Jump to solution

Hi André,

Thanks. Can you please tell me the approx time to delete the 1st snapshot (42 GB) when vm is powered off.

rhmahfuz

0 Kudos
a_p_
Leadership
Leadership
Jump to solution

This depends on the speed of your storage/RAID system. Assuming a (conservative) speed of ~30MB/s, 1GB would require ~30 sec. In order to delete the first snapshot (which IMO is the one with 80 GB) this would be result in something between 30-45 min.

André

0 Kudos
rhmahfuz
Contributor
Contributor
Jump to solution

Thanks to Continuum & André. Specially greatful to Continuum to find out the correct Answer.

0 Kudos