木偶大师/代理人基本设置

我正在尝试使用代理服务器和主服务器设置一个基本的puppet代理/主用例。 我已经分别设置了两个木偶和木偶主机的服务器。

在两台服务器的以下设置之后:

puppet master --no-daemonize --verbose puppet agent --test puppet cert --list to get the list, puppet cert --sign <certname> to sign it. puppet agent --test 

我收到消息:

 err: Could not retrieve catalog from remote server: hostname was not match with the server certificate warning: Not using cache on failed catalog err: Could not retrieve catalog; skipping run err: Could not send report: hostname was not match with the server certificate 

为了让代理人/主人能够相互交谈,我需要做些什么?

确保你的客户可以解决“傀儡”。 正向和反向DNS条目是重要的。 作为一个快速testing,在你的木偶大师的IP地址和名字后添加一个入口到/etc/hosts ,然后重试。

同时检查你的parsing器文件,并删除两个区域中的ssl目录,然后重新启动同步过程。 显然你知道puppetca –list命令来检查证书是否需要签名。 您也可以尝试closures您的防火墙,看看是否允许连接。 看看/ etc / hosts以确保它在那里。

确保你的傀儡大师和你的客户的时钟有相同的时间。
我有客户没有得到他们的证书,因为这两个系统的时间太遥远了。

确保你在puppet主configuration文件中有这个名字:certname =“你的客户端的puppet.conf中的服务器名称”

例如。 certname = puppet.cakeservers.com,如果你在你的客户端有server = puppet.cakeservers.com。


最好的祝福
埃斯彭Fjellvær奥尔森

你是否在你的configuration中的任何地方设置服务器的名称? 在/etc/puppet/puppet.conf[master]块中,应该将ca_name和certname设置为如下所示:

 ca_name = Puppet CA: puppetmaster.example.com certname = puppetmaster.example.com 

确保服务器的证书与此名称匹配。 您可以从实际机器的主机名拥有不同的证书名称。

在你的[agent] bock中,你可以用下面的方法指定服务器:

 server = puppetmaster.example.com 

从客户端,你应该能够运行puppet agent --test没有问题的testing,当然,假设puppetmaster.example.com是在DNS和可达。