VMware Cloud Community
mahmn
Enthusiast
Enthusiast

Setting expiry date for VM

I would like to know if it is possible to set an expiry date for an VM or not?

I don't want to automatically delete the VM from disk after the expiration. Some softer methods, such powering down or suspending the machine or even disconnecting the network is also good ways at the first step.

Any idea for that? I didn't find such things in the documents.

0 Kudos
3 Replies
daphnissov
Immortal
Immortal

No, not possible out of the box. This is something vRealize Automation will do for you, however.

0 Kudos
IRIX201110141
Champion
Champion

You can add a Tag or Customfield with a Date/Timestamp and fire up an external Powershell Script through Windows scheduling Tasks, which crawls trough your VMs and compare the timestamp.   I think its a 30min scripting job.

Some notes: IIRC you can fetch the infos when a VM is startet or how long a VM is up and running.  Also placing a Script within in thenGuestOS and checking every hour maybe a solution for you.

Regards,
Joerg

0 Kudos
mahmn
Enthusiast
Enthusiast

Can you explain about the Tag and Customfield?

Where are they? During the creation of VM? I haven't noticed about them.

0 Kudos