--- title: Chef Clientの12.0.0で後方互換性が失われていたようだ (12.0.0-1で修正済み) author: kazu634 date: 2014-12-09 url: /2014/12/09/chef-client-1200-introduces-backward-incompatibility/ wordtwit_posted_tweets: - 'a:1:{i:0;i:5553;}' wordtwit_post_info: - 'O:8:"stdClass":13:{s:6:"manual";b:0;s:11:"tweet_times";s:1:"1";s:5:"delay";s:1:"0";s:7:"enabled";s:1:"1";s:10:"separation";i:60;s:7:"version";s:3:"3.7";s:14:"tweet_template";b:0;s:6:"status";i:2;s:6:"result";a:0:{}s:13:"tweet_counter";i:2;s:13:"tweet_log_ids";a:1:{i:0;i:5553;}s:9:"hash_tags";a:0:{}s:8:"accounts";a:1:{i:0;s:7:"kazu634";}}' tmac_last_id: - 559360310189236224 categories: - chef --- Chef Danbo Chefを使ってノードの構築を実施していたら、なぜか``NoMethodError: undefined method `path' for Chef::Resource::Execute``というエラーが…なぜ起きているのかを調べていくと、Chef Clientのバージョンアップによって、後方互換性が失われたのが原因と判明。まとめると: ## 事象 ``NoMethodError: undefined method `path' for Chef::Resource::Execute``が表示され、Chefによるノード構築が実施できない。 ## 原因 Chef Clientの最新バージョンで後方互換性が失われるようなバグが混入したため ## 対策 対策を施した Chef Client 12.0.0-1 をインストールする。knife solo でバージョン指定するには、以下のように指定すればいいみたい:
bundle ex knife solo bootstrap ユーザー名@ホスト名 --bootstrap-version 12.0.0-1
## 参考 * NoMethodError: undefined method `path’ for Chef::Resource::Execute · Issue #2545 · opscode/chef * ChefのMySQLクックブックでNoMethodError: undefined method `sensitive' for Chef::Resource::Executeの対処 | Yucchiy's blog