我已经设置了Puppet Master / Agent,并且已经成功在Master上签署了代理的证书。但是,当我运行时,出现如下puppet agent --test
错误:
Warning: Unable to fetch my node definition, but the agent run will continue:
Warning: SSL_connect returned=1 errno=0 state=SSLv3 read server certificate B: certificate verify failed: [certificate signature failure for /CN=hostname.domain.com]
Info: Retrieving plugin
Error: /File[/var/lib/puppet/lib]: Failed to generate additional resources using 'eval_generate: SSL_connect returned=1 errno=0 state=SSLv3 read server certificate B: certificate verify failed: [certificate signature failure for /CN=hostname.domain.com]
Error: /File[/var/lib/puppet/lib]: Could not evaluate: SSL_connect returned=1 errno=0 state=SSLv3 read server certificate B: certificate verify failed: [certificate signature failure for /CN=hostname.domain.com] Could not retrieve file metadata for puppet://hostname.domain.com/plugins: SSL_connect returned=1 errno=0 state=SSLv3 read server certificate B: certificate verify failed: [certificate signature failure for /CN=hostname.domain.com]
Error: Could not retrieve catalog from remote server: SSL_connect returned=1 errno=0 state=SSLv3 read server certificate B: certificate verify failed: [certificate signature failure for /CN=hostname.domain.com]
Warning: Not using cache on failed catalog
Error: Could not retrieve catalog; skipping run
Error: Could not send report: SSL_connect returned=1 errno=0 state=SSLv3 read server certificate B: certificate verify failed: [certificate signature failure for /CN=hostname.domain.com]
那hostname.domain.com
是主人
我该如何解决?我确保两个时钟都在相同时区中的正确时间,我已经删除了代理/var/lib/puppet/ssl
目录中的所有内容并辞职,我不知道该怎么办。
您的主人似乎使用的证书与客户信任的证书不同?船长的证书有变更吗?
—
Shane Madden 2013年
@ShaneMadden我不这么认为...我应该清理并吊销船长和客户证书吗?我根本没有弄过master证书,但是“ puppet cert list --all”的输出看起来像这样:+“ masterhost.domain.com”(SHA1)E1:F7:6A:21:CB: CD:xx:xx:xx:xx ... +“ agenthost.domain.com”(SHA256)5A:D9:7B:96:0B:FF:E4:87:58:AF:00:xx:xx:xx:xx :xx ..
—
John Smith
那
—
Shane Madden
masterhost.domain.com
与hostname.domain.com
您的问题相同,对吗?让我们尝试一下,我们将查看证书是否手动验证。运行openssl s_client -connect masterhost.domain.com:8140 -showcerts
,然后将证书数据(以开头-----BEGIN CERTIFICATE-----
,包括该行和结束证书行)复制到一个新文件中,然后运行openssl verify -CAfile /var/lib/puppet/ssl/certs/ca.pem /path/to/file/from/last/command
,看看是否可以验证。
@ShaneMadden似乎有些不对劲...。当我运行“ -showcerts”命令时,它给了我两个“ begin”和“ end”证书,因此我尝试首先将其中一个添加到新文件中,并得到这:/ var / lib / puppet / ssl / ca / test:/CN=masterhost.domain.com错误7在0深度查找:证书签名失败22297:错误:0407006A:RSA例程:RSA_padding_check_PKCS1_type_1:块类型不是01: rsa_pk1.c:100:22297:错误:04067072:rsa例程:RSA_EAY_PUBLIC_DECRYPT:填充检查失败:rsa_eay.c:697:22297:错误:0D0C5006:asn1编码例程:ASN1_item_verify:EVP lib:a_verify.c:173:
—
约翰Smith Smith
真奇怪。听起来好像在发送连接中除了服务器证书之外的根证书,因此也许只需将第二个证书
—
Shane Madden 2013年
-showcerts
的内容与的内容进行比较/var/lib/puppet/ssl/certs/ca.pem
-它们应该相同?