VMware Cloud Community
Gladio
Contributor
Contributor

Revert automatically to snapshot on restart

Hi all,


I would like to know if it's possible that the guest OS on ESXi 5 could revert to a snapshot on restart automatically .


Thanks in advance

0 Kudos
2 Replies
vCloud9
Enthusiast
Enthusiast

Not sure what you are trying to achieve, but did you considered using non-persistent disk, so that everytime you reboot, VM would get back to the original  state.

Also, there is another thread that I came across which could be helpful in reverting back the snapshot through powercli scripting http://communities.vmware.com/thread/152654

-vCloud9

Please don't forget to award point for 'Correct' or 'Helpful', if you found the comment useful.
jalavic
Contributor
Contributor

Hi;

Here is my understanding, to achieve an automatic revert to a snapshot each time the VM is halted (in purpose), you can either use a non-persistent disk (as vCloud9 mentioned) or the advanced configuration parameter snapshot.action = "autoRevert".

I had once a related problem, after a power outage occured on all my cluster's hosts, a VM reverted to a snapshot automatically and not intentionally (use of a persistent disk and snapshot.action = "keep").

Not sure if it's what you're asking about Gladio.

Anyway, I noticed something strange in the vCenter events, a session has been opened from the VM (IP_@=172.16.1.185) which was reverted

info      15/04/2012 20:16:04     Administrateur          Tâche : Restaurer le snapshot
info      15/04/2012 20:16:03     Administrateur          L’utilisateur Administrateur@172.16.1.185 est connecté
info      15/04/2012 20:16:03     Administrateur          L’utilisateur Administrateur est déconnecté
info      15/04/2012 20:16:03     Administrateur          L’utilisateur Administrateur@172.16.1.185 est connecté
info      15/04/2012 20:15:44     Administrateur          L’utilisateur Administrateur est déconnecté
info      15/04/2012 20:15:44     Administrateur          L’utilisateur Administrateur@172.16.1.185 est connecté
info      15/04/2012 20:15:44     Administrateur          L’utilisateur Administrateur est déconnecté
info      15/04/2012 20:15:44     Administrateur          L’utilisateur Administrateur@172.16.1.185 est connecté

And what is more strange is that this scenario occured only on this particular VM !!!!!

0 Kudos