【问题标题】:Error: Could not retrieve catalog from remote server: Error 500 on SERVER:错误:无法从远程服务器检索目录:服务器上的错误 500:
【发布时间】:2021-11-03 11:03:14
【问题描述】:

收到错误 500

傀儡代理-t

信息:使用配置的环境“生产” 信息:检索插件事实 信息:检索插件 信息:加载事实 错误:无法从远程服务器检索目录:服务器上的错误 500:服务器错误:在节点 client.domain.com 上找不到名称为“default”或“client.domain.com”的节点语句 警告:不在失败的目录上使用缓存 错误:无法检索目录;跳过跑步

Puppet.conf 内容如下:

[master]
dns_alt_names = master.domain.com,server
certname = master.domain.com

[agent]
server = master.domain.com
ca_server = master.domain.com
certname = client.domain.com
use_cached_catalog = true

【问题讨论】:

  • 在 master.domain.com 上你能做一个'cat /etc/puppetlabs/code/environments/production/manifests/site.pp'吗?
  • node 'master.domain.com' { package { 'httpd': ensure => "installed", } service { 'httpd': ensure => running, enable => true } file { ' /tmp/puppetdir':确保 => '目录',所有者 => '系统管理员',组 => '轮子',模式 => '0755' } }

标签: puppet


【解决方案1】:

清单文件夹下的 site.pp 文件需要包含 node 'client.domain.com'(因为 client.domain.com 是您的代理证书名称)或 node default。

例如:

node default {

  file { '/tmp/puppetdir':
    ensure => 'directory',
    owner => 'sysadmin',
    group => 'wheel',
    mode => '0755'
  }

}

node 'client.domain.com' {
  package { 'httpd':
    ensure => "installed",
  }
      
  service { 'httpd':
    ensure => running,
    enable => true
  }

  file { '/tmp/puppetdir':
    ensure => 'directory',
    owner => 'sysadmin',
    group => 'wheel',
    mode => '0755'
  }

}

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2015-03-27
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多