尝试在我的 Oracle Linux Box 上安装 Chef。完全按照以下说明进行操作后,我到达了以下位置:
运行 Chef 独奏:
(在网址中): http://wiki.opscode.com/display/chef/Bootstrap+Chef+RubyGems+Installation
...我收到以下错误:
[root@chefmaster ~]# chef-solo -c /etc/chef/solo.rb -j ~/chef.json -r http://s3.amazonaws.com/chef-solo/bootstrap-latest.tar.gz
[Mon, 20 Jun 2011 13:53:01 -0700] INFO: *** Chef 0.10.0 ***
[Mon, 20 Jun 2011 13:53:02 -0700] INFO: Setting the run_list to ["recipe[chef- server::rubygems-install]"] from JSON
[Mon, 20 Jun 2011 13:53:02 -0700] INFO: Run List is [recipe[chef-server::rubygems-install]]
[Mon, 20 Jun 2011 13:53:02 -0700] INFO: Run List expands to [chef-server::rubygems-install]
[Mon, 20 Jun 2011 13:53:02 -0700] INFO: Starting Chef Run for localhost
[Mon, 20 Jun 2011 13:53:03 -0700] INFO: Processing user[chef] action create (chef-server::rubygems-install line 30)
[Mon, 20 Jun 2011 13:53:03 -0700] INFO: Processing package[erlang] action install (erlang::default line 26)
[Mon, 20 Jun 2011 13:53:04 -0700] ERROR: package[erlang] (erlang::default line 26) has had an error
[Mon, 20 Jun 2011 13:53:04 -0700] ERROR: Running exception handlers
[Mon, 20 Jun 2011 13:53:04 -0700] ERROR: Exception handlers complete
[Mon, 20 Jun 2011 13:53:04 -0700] FATAL: Stacktrace dumped to /tmp/chef-solo/chef-stacktrace.out
[Mon, 20 Jun 2011 13:53:04 -0700] FATAL: Chef::Exceptions::Package: package[erlang] (erlang::default line 26) had an error: No version specified, and no candidate version available for erlang
我检查了 Google,他们通过 RPM 引用了一个过时的 Chef 链接,该链接已经有几年了。我安装了 erlang:
[root@chef ~]# erl --version Erlang R14B03 (erts-5.8.4) [来源] [64 位] [rq:1] [async-threads:0] [hipe] [kernel-poll:false]
欢迎任何想法
最佳答案
我也遇到这个问题了。问题是 centos 附带的默认 yum 存储库(我假设你正在使用)不包括 couch。您必须像这样添加 epel yum 存储库:
rpm -Uvh http://download.fedora.redhat.com/pub/epel/5/i386/epel-release-5-4.noarch.rpm
完成此操作后,一切都会顺利进行。
关于chef-infra - Chef : Strange Erlang Error when Trying to Run Chef-Solo,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/6421149/