Re-bootstrap a Chef node

chef

I've got a Chef node, bootstrapped with

knife bootstrap my.example.com --ssh-user USER --ssh-password 'PASSWORD' --sudo --use-sudo-password --node-name my.example.com

If I then format the node, how can I get Chef running on it again?
I don't want to do knife client delete my.example.com as that will delete all the data from knife node edit my.example.com

Best Answer

If you bring client.pem across to the new installation and use the same node_name in your /etc/chef/client.rb file then the new installation should inherit the client registration on chef server, so you don't need to deregister and re-register the node from the server.