我剛剛開始使用流浪和廚師,但我得到了我認爲很奇怪的錯誤。配置失敗廚師,Mac上的流浪漢10.7.2
任何事情都可以用一個簡單的VM和沒有廚師,但是當我堅持幾個接受者在它失敗。
這是我從vagrantfile調用的主要配方的當前default.rb。它主要是從這個blog/tutorial
r = execute "apt-get update" do
user "root"
command "apt-get update"
action :nothing
end
r.run_action(:run)
include_recipe "php"
include_recipe "apache2"
include_recipe "mysql"
的Apache2的PHP和MySQL的食譜是直接從Opscode公司社區網站。
如果我只是把這些食譜之一,然後它加載罰款。 有時候兩個都很好,但是如果我把所有三個都放在最後,那麼最後一個似乎會導致錯誤。我已經改變了順序,它總是最後一個導致錯誤。以下是錯誤 - 每天同一時間,但在這種情況下,PHP是最後三個,你可以看到它安裝失敗的:
[default] [Fri, 06 Jan 2012 10:01:33 -0800] INFO: Processing package[php5] action install (php::package line 32)
: stdout
[default] [Fri, 06 Jan 2012 10:04:52 -0800] ERROR: package[php5] (php::package line 32) has had an error
: stdout
[default] [Fri, 06 Jan 2012 10:04:52 -0800] ERROR: Running exception handlers
: stdout
[default] [Fri, 06 Jan 2012 10:04:52 -0800] ERROR: Exception handlers complete
: stdout
[default] /opt/ruby/lib/ruby/gems/1.8/gems/chef-0.10.2/bin/../lib/chef/file_cache.rb:54:in `initialize': stderr
[default] : : stderr
[default] Read-only file system - /tmp/vagrant-chef-1/chef-stacktrace.out: stderr
[default] (: stderr
[default] Errno::EROFS: stderr
[default])
: stderr
[default] from /opt/ruby/lib/ruby/gems/1.8/gems/chef-0.10.2/bin/../lib/chef/file_cache.rb:54:in `open'
: stderr
[default] from /opt/ruby/lib/ruby/gems/1.8/gems/chef-0.10.2/bin/../lib/chef/file_cache.rb:54:in `store'
: stderr
[default] from /opt/ruby/lib/ruby/gems/1.8/gems/chef-0.10.2/bin/../lib/chef/application.rb:133:in `debug_stacktrace'
: stderr
[default] from /opt/ruby/lib/ruby/gems/1.8/gems/chef-0.10.2/bin/../lib/chef/application/solo.rb:210:in `run_application'
: stderr
[default] from /opt/ruby/lib/ruby/gems/1.8/gems/chef-0.10.2/bin/../lib/chef/application/solo.rb:183:in `loop'
: stderr
[default] from /opt/ruby/lib/ruby/gems/1.8/gems/chef-0.10.2/bin/../lib/chef/application/solo.rb:183:in `run_application'
: stderr
[default] from /opt/ruby/lib/ruby/gems/1.8/gems/chef-0.10.2/bin/../lib/chef/application.rb:66:in `run'
: stderr
[default] from /opt/ruby/lib/ruby/gems/1.8/gems/chef-0.10.2/bin/chef-solo:25
from /opt/ruby/bin/chef-solo:19:in `load'
from /opt/ruby/bin/chef-solo:19
: stderr
The following SSH command responded with a non-zero exit status.
Vagrant assumes that this means the command failed!
chef-solo -c /tmp/vagrant-chef-1/solo.rb -j /tmp/vagrant-chef-1/dna.json
The output of the command prior to failing is outputted below:
[no output]
通常我破壞了虛擬機和做無業遊民爲每一個新的嘗試,但有幾次我嘗試了流浪漢重新加載和流浪漢提供相同的結果。
此外,我不知道這是否正常,但我的Mac幾乎完全鎖定,而它的供應。我通常可以同時運行2個或3個vmware虛擬機,而不會覺得它掙扎太多,所以它完全鎖定是......奇怪。
確認,爲我工作 - 我得到'只讀文件系統 - /var/chef/cache/chef-stacktrace.out(Errno :: EROFS)'錯誤,'sudo gem update'使它們消失。謝謝! – 2014-05-20 15:18:29