So I am seeing below captioned error when I am trying to connect to a puppet master.
err: Could not retrieve catalog from remote server: SSL_connect returned=1 errno=0 state=SSLv3 read server certificate B: certificate verify failed
The reason for above error is because the agent node is trying to connect to a different master and then it failed to validate the certificate. To solve the problem, we have to execute below command and retry.
find /var/lib/puppet -type f | xargs rm -rf