When using template to deploy VM's, if you click the [Customize this virtual machine's hardware] option, and then click NEXT, the wizard will get stuck. After a while, vCenter UI hangs with "out of memory" error and we have to reload the webpage. This happens only for particular VM templates only.
We can attempt the below given workarounds for resolving this issue:
Method 1: When deploying through these affected templates, do not check the custom hardware first. We can choose to edit it after creation.
Method 2: We can convert the Template back to a virtual machine and change it back again to a Template. Afterwards, test deploying VM's from the template with "Customize hardware" option selected.
Method 3: Reduce the Memory configuration of the template to half the initial value. For example if it's configured with 16 GB Memory, change the same to 8GB and then try creating the virtual machine.