Posts

Showing posts with the label revoke

Featured Post

Directory environments in Puppet

Environments are individual groups of Puppet agents each environment have there own completely different manifests and module-paths. This basically is useful for testing changes to our Puppet code before implementing them on production machines. There are two types of implementation of environments structure in Puppet one if directory based and another is config file based here we will see bit of an insight about directory based. As usual for more information about this you can visit puppetlabs official website. On the master node: Append following details in puppet.conf which is placed under /etc/puppet or /etc/puppetlabs/puppet:     Under [main] section add a variable called confdir with value as /etc/puppet or /etc/puppetlabs/puppet     confdir=/etc/puppet Then add information regarding environments/manifests and modulepath in it.      #environments     environmentpath = $confdir/environments  ...

Un-revoke the revoked certificate in Puppet

If you revoked or deleted the puppet agent’s certificate accidentally. Basically it is nearly impossible un-revoke a certificate. The solution is to recover all revoked certificates then revoke other certificates which don’t need to be recovered. But if in-case you have thousands of revoked certificates then its a bit lengthy process. Second one is to generate a new certificate for the client/agent and get that signed by the puppet master.  List of all the certificates which are signed at the moment:  [root@puppet requests]# puppet cert list --all + "fedora20"            (AE:57:40:F6:FC:E1:CD:DD:ED:EE:1E:8C:A7:81:0D:76) + "kubuntu14.sunny.com" (20:6B:A1:E2:A3:DE:B1:95:C8:80:4C:B4:27:2B:C0:A2) + "puppet.sunny.com"    (68:12:76:3C:D0:F8:0D:2D:8B:2B:40:E7:49:2D:55:5B) (alt names: "DNS:puppet", "DNS:puppet.sunny.com") + "rhel6.sunny.com"     (DC:6E:B1:FC:27:1D:7A:2A:85:E7:3E:3A:2...

puppet cert???

*Cert sub-command in Puppet "puppet cert"* It is a utility that manage certificates and requests related to it. The main purpose of this utility are: 1. Generating certificates. 2. Signing certificate requests from puppet clients/agents. As not a single client/agent can communicate with the puppet master with out a signed certificate this is the most important thing. If in-case you want the revoke the certificate for the node you can use the option as clean this will remove all the information related to that particular host from the puppet cert's storage. Make sure you are revoking the correct certificate because it is nearly impossible to un-revoke the certificate but there is a other other way around[will discuss this is later part]. [root@puppet ~]# puppet cert clean rhel6.sunny.com notice: Revoked certificate with serial 4 notice: Removing file Puppet::SSL::Certificate rhel6.sunny.com at '/var/lib/puppet/ssl/ca/signed/rhel6.sunny.com.pem' notice:...