Resetting ESXi Evaluation License

#!/bin/sh
## remove license
echo 'Removing License'
rm -r /etc/vmware/license.cfg
## get a new trial license
echo 'Copying new license'
cp /etc/vmware/.#license.cfg /etc/vmware/license.cfg
## restart services
echo 'Restarting VPXA'
/etc/init.d/vpxa restart

Edit /etc/rc.local.d/local.sh and add:

/bin/kill $(cat /var/run/crond.pid)
/bin/echo "**59** /vmfs/volumes/ZFS0/reset-eval.sh" >> /var/spool/cron/crontabs/root
crond

This will reset the license via cron job every 59 days (eval license expires 60 days).

This was confirmed working in ESXI v7.0 U1.

Leave a Reply

Your email address will not be published. Required fields are marked *