Remove puppet node license

If you are using Puppet Enterprise, you are limited to 10 nodes before you have to start paying for each node you provision. When you terminate a puppet node, it won’t de-register itself from the node license. To remove puppet node license you need to manually deactivate the node from the PuppetDB and the way to do that is:

puppet node deactivate node-name

Where ‘node-name’ is the name of the node you terminated. Refresh your Puppet Enterprise console, and you should get your license back.

It’s also a good idea to clean up the certs as well

sudo puppet cert --clean {node certname}

If you’ve re-installed the instance remove the entire SSL directory of the client machine

sudo rm -r /etc/puppet/ssl; sudo rm -r /var/lib/puppet/ssl)

If you can’t remember your node name, you can look inside your PuppetDB log file to find it:

tail -f -n 1000 /var/log/pe-puppetdb/pe-puppetdb.log