I have a chef cookbook (for apache2). It fails to work on one node. So I'm trying to tweak it and update it, but the node doesn't seem to download the new version. I have been able to upload everything to the chef server from my local machine with knife upload .
, that succeeds, and prints out that it uploaded the apache2 cookbook bits that I changed.
When I manually run (as root) chef-client
on the node, I can see it contacting the server, getting the run list, etc. However the recipe files in /var/cache/chef/cookbooks/apache2
are the old files. And the recipe fails (because it doesn't have the changes I made).
How do I get the chef client on the node to use the new updated version of the apache2 cookbook? Do I need to bump the version number in the cookbook (I haven't been doing this)?
chef-client -l debug
output:
[2015-01-30T10:51:31+01:00] DEBUG: Synchronizing cookbook apache2
[2015-01-30T10:51:31+01:00] DEBUG: Not storing cookbooks/apache2/recipes/mod_ldap.rb, as the cache is up to date.
[2015-01-30T10:51:31+01:00] DEBUG: Not storing cookbooks/apache2/recipes/mod_xsendfile.rb, as the cache is up to date.
[2015-01-30T10:51:31+01:00] DEBUG: Not storing cookbooks/apache2/recipes/mod_auth_openid.rb, as the cache is up to date.
[2015-01-30T10:51:31+01:00] DEBUG: Not storing cookbooks/apache2/recipes/mod_setenvif.rb, as the cache is up to date.
[2015-01-30T10:51:31+01:00] DEBUG: Not storing cookbooks/apache2/recipes/mod_python.rb, as the cache is up to date.
[2015-01-30T10:51:31+01:00] DEBUG: Not storing cookbooks/apache2/recipes/mod_authz_host.rb, as the cache is up to date.
[2015-01-30T10:51:31+01:00] DEBUG: Not storing cookbooks/apache2/recipes/mod_proxy_ajp.rb, as the cache is up to date.
[2015-01-30T10:51:31+01:00] DEBUG: Not storing cookbooks/apache2/recipes/mod_expires.rb, as the cache is up to date.
(lots of this for all files)
I am new to chef, so I might have made a beginner mistake.