# Recipes run order versus resource usage/cloning

**URL:** <https://discourse.chef.io/t/recipes-run-order-versus-resource-usage-cloning/5205>\
**Category:** Chef Infra (archive)\
**Created:** [April 1, 2014, 3:06pm UTC](https://discourse.chef.io/t/recipes-run-order-versus-resource-usage-cloning/5205 "2014-04-01T15:06:53Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![johnnym](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.chef.io/johnnym/32/339_2.png) [@johnnym](https://discourse.chef.io/u/johnnym)\
**Post date:** [April 1, 2014, 3:06pm UTC](https://discourse.chef.io/t/recipes-run-order-versus-resource-usage-cloning/5205/1 "2014-04-01T15:06:53Z")

</div>

Hi All,

I am new to chef so sorry if I misuse some words but I have a question.  
As I tested it if a node has 2 recipes and these recipes work on the  
same resource (a file or a package…or user) how can I prevent the node  
from rebuilding and restarting services all the time.

In this case I make a base system with the minimal packages services and  
users, but with a specific base config file. On this base system I want  
to create a backend so I apply B::backend but this recipe installs  
packages, adds users and modifies a config file.

If I run chef-client (below) I can see that the users, packages and  
files are removing and reinstalling all the time and the services are  
restarting during every chef-client run.

Can I compile the recipes into one recipe in order to allow them to  
overwrite the same resource in the order of the run\_list?

{  
“name”: “javatest03xd.origo.t-online.private”,  
“chef\_environment”: “test”,  
…  
“run\_list”: [  
“recipe[A::base]”,  
“recipe[B::backend]”  
]  
}

_A/base.rb_  
package “nfs-common” do  
action :remove  
end

service ‘ntp’ do  
action [:enable, :start]  
end

file “/tmp/very\_important\_service.conf” do  
content "BASE data"  
notifies :restart, 'service[ntp]'  
end

user ‘extra’ do  
action [:remove]  
end

_B/backend.rb_  
package “nfs-common” do  
action :remove  
end  
service ‘ntp’ do  
action [:enable, :start]  
end

file “/tmp/very\_important\_service.conf” do  
content "BACKEND data"  
notifies :restart, 'service[ntp]'  
end

user ‘extra’ do  
action [:create, :lock]  
end

[2014-04-01T16:59:55+02:00] INFO: Forking chef instance to converge…  
[2014-04-01T16:59:55+02:00] INFO: \*\*\* Chef 11.10.4 \*\*\*  
[2014-04-01T16:59:55+02:00] INFO: Chef-client pid: 7730  
[2014-04-01T16:59:56+02:00] INFO: Run List is [recipe[A::base], recipe[B::backend]]  
[2014-04-01T16:59:56+02:00] INFO: Run List expands to [A::base, B::backend]  
[2014-04-01T16:59:56+02:00] INFO: Starting Chef Run for javatest03xd.origo.t-online.private  
[2014-04-01T16:59:56+02:00] INFO: Running start handlers  
[2014-04-01T16:59:56+02:00] INFO: Start handlers complete.  
[2014-04-01T16:59:56+02:00] INFO: HTTP Request Returned 404 Object Not Found:  
[2014-04-01T16:59:56+02:00] INFO: Loading cookbooks [A, B]  
[2014-04-01T16:59:56+02:00] WARN: Cloning resource attributes for package[nfs-common] from prior resource (CHEF-3694)  
[2014-04-01T16:59:56+02:00] WARN: Previous package[nfs-common]: /var/chef/cache/cookbooks/A/recipes/base.rb:1:in `from_file' [2014-04-01T16:59:56+02:00] WARN: Current package[nfs-common]: /var/chef/cache/cookbooks/B/recipes/backend.rb:1:in`from\_file’  
[2014-04-01T16:59:56+02:00] WARN: Cloning resource attributes for service[ntp] from prior resource (CHEF-3694)  
[2014-04-01T16:59:56+02:00] WARN: Previous service[ntp]: /var/chef/cache/cookbooks/A/recipes/base.rb:5:in `from_file' [2014-04-01T16:59:56+02:00] WARN: Current service[ntp]: /var/chef/cache/cookbooks/B/recipes/backend.rb:5:in`from\_file’  
[2014-04-01T16:59:56+02:00] WARN: Cloning resource attributes for file[/tmp/very\_important\_service.conf] from prior resource (CHEF-3694)  
[2014-04-01T16:59:56+02:00] WARN: Previous file[/tmp/very\_important\_service.conf]: /var/chef/cache/cookbooks/A/recipes/base.rb:9:in `from_file' [2014-04-01T16:59:56+02:00] WARN: Current file[/tmp/very_important_service.conf]: /var/chef/cache/cookbooks/B/recipes/backend.rb:9:in`from\_file’  
[2014-04-01T16:59:56+02:00] WARN: Cloning resource attributes for user[extra] from prior resource (CHEF-3694)  
[2014-04-01T16:59:56+02:00] WARN: Previous user[extra]: /var/chef/cache/cookbooks/A/recipes/base.rb:14:in `from_file' [2014-04-01T16:59:56+02:00] WARN: Current user[extra]: /var/chef/cache/cookbooks/B/recipes/backend.rb:14:in`from\_file’  
[2014-04-01T16:59:56+02:00] INFO: Processing package[nfs-common] action remove (A::base line 1)  
[2014-04-01T16:59:57+02:00] INFO: package[nfs-common] removed  
[2014-04-01T16:59:57+02:00] INFO: Processing service[ntp] action enable (A::base line 5)  
[2014-04-01T16:59:57+02:00] INFO: Processing service[ntp] action start (A::base line 5)  
[2014-04-01T16:59:57+02:00] INFO: Processing file[/tmp/very\_important\_service.conf] action create (A::base line 9)  
[2014-04-01T16:59:57+02:00] INFO: file[/tmp/very\_important\_service.conf] backed up to /var/chef/backup/tmp/very\_important\_service.conf.chef-20140401165957.690683  
[2014-04-01T16:59:57+02:00] INFO: file[/tmp/very\_important\_service.conf] updated file contents /tmp/very\_important\_service.conf  
[2014-04-01T16:59:57+02:00] INFO: file[/tmp/very\_important\_service.conf] not queuing delayed action restart on service[ntp] (delayed), as it’s already been queued  
[2014-04-01T16:59:57+02:00] INFO: Processing user[extra] action remove (A::base line 14)  
[2014-04-01T16:59:57+02:00] INFO: user[extra] removed  
[2014-04-01T16:59:57+02:00] INFO: Processing package[nfs-common] action install (B::backend line 1)  
[2014-04-01T17:00:00+02:00] INFO: Processing service[ntp] action enable (B::backend line 5)  
[2014-04-01T17:00:00+02:00] INFO: Processing service[ntp] action start (B::backend line 5)  
[2014-04-01T17:00:00+02:00] INFO: Processing file[/tmp/very\_important\_service.conf] action create (B::backend line 9)  
[2014-04-01T17:00:00+02:00] INFO: file[/tmp/very\_important\_service.conf] backed up to /var/chef/backup/tmp/very\_important\_service.conf.chef-20140401170000.881799  
[2014-04-01T17:00:00+02:00] INFO: file[/tmp/very\_important\_service.conf] updated file contents /tmp/very\_important\_service.conf  
[2014-04-01T17:00:00+02:00] INFO: file[/tmp/very\_important\_service.conf] not queuing delayed action restart on service[ntp] (delayed), as it’s already been queued  
[2014-04-01T17:00:00+02:00] INFO: file[/tmp/very\_important\_service.conf] not queuing delayed action restart on service[ntp] (delayed), as it’s already been queued  
[2014-04-01T17:00:00+02:00] INFO: Processing user[extra] action create (B::backend line 14)  
[2014-04-01T17:00:00+02:00] INFO: user[extra] created  
[2014-04-01T17:00:00+02:00] INFO: Processing user[extra] action lock (B::backend line 14)  
[2014-04-01T17:00:01+02:00] INFO: file[/tmp/very\_important\_service.conf] sending restart action to service[ntp] (delayed)  
[2014-04-01T17:00:01+02:00] INFO: Processing service[ntp] action restart (B::backend line 5)  
[2014-04-01T17:00:02+02:00] INFO: service[ntp] restarted  
[2014-04-01T17:00:02+02:00] INFO: Chef Run complete in 6.074158866 seconds  
[2014-04-01T17:00:02+02:00] INFO: Running report handlers  
[2014-04-01T17:00:02+02:00] INFO: Report handlers complete

I hope I could explain my question clearly.

Best, Balint!

---

<div class="post-metadata">

**Author:** ![Lamont\_Granquist\_OLD](https://avatars.discourse-cdn.com/v4/letter/l/7feea3/32.png) [@Lamont\_Granquist\_OLD](https://discourse.chef.io/u/Lamont_Granquist_OLD)\
**Post date:** [April 1, 2014, 4:37pm UTC](https://discourse.chef.io/t/recipes-run-order-versus-resource-usage-cloning/5205/2 "2014-04-01T16:37:04Z")

</div>

you probably want to pull out all the common resources into a new  
recipe like "\_common.rb" or something and then

include\_recipe "#{cookbook\_name}::\_common"

in both base.rb and backend.rb recipes, then only include one or the  
other recipe in your run\_list for any given server. also probably want  
to keep the concerns together and use one cookbook with multiple  
recipes rather than your 'A' and 'B' cookbooks.

if you really want the 'base' recipe to be included everywhere and the  
'backend' to override it then you probably want to include an attribute  
somewhere. you could push this attribute up into roles if you like.  
then it looks like you can have a single 'thing::default' recipe that  
has a conditional:

my\_content = if node['thing']['type'] == "base"  
"BASE data"  
else  
"BACKEND data"  
end

file "/tmp/very\_important\_service.conf" do  
content my\_content  
notifies :restart, 'service[ntp]'  
end

for more complicated code you can use an if that wraps include\_recipe  
so that you switch on the attribute to do two different things so  
default.rb might look like:

include\_recipe "#{cookbook\_name}::\_common"

if node['thing']['type'] == "base"  
include\_recipe "#{cookbook\_name}::\_base"  
else  
include\_recipe "#{cookbook\_name}::\_backend"  
end

and you can set node['thing']['type'] either in a role or a role  
cookbook (in this case you'll want to keep  
one-cookbook-per-role-cookbook, so you'd have something like  
role\_base::default and role\_backend::default recipes, for now just  
trust me and don't do role::backend and role::base because you want to  
set the role attribute in attribute files and in the latter case you'll  
get surprised when all the attribute files in a cookbook always get  
parsed -- but start playing with vanilla roles first before moving on  
to role cookbooks, then read this again later if you start going down  
the role cookbook route).

On Tue Apr 1 08:06:53 2014, johnnym wrote:

> Hi All,
> 
> I am new to chef so sorry if I misuse some words but I have a  
> question. As I tested it if a node has 2 recipes and these recipes  
> work on the same resource (a file or a package...or user) how can I  
> prevent the node from rebuilding and restarting services all the time.
> 
> In this case I make a base system with the minimal packages services  
> and users, but with a specific base config file. On this base system I  
> want to create a backend so I apply B::backend but this recipe  
> installs packages, adds users and modifies a config file.
> 
> If I run chef-client (below) I can see that the users, packages and  
> files are removing and reinstalling all the time and the services are  
> restarting during every chef-client run.
> 
> Can I compile the recipes into one recipe in order to allow them to  
> overwrite the same resource in the order of the run\_list?
> 
> {  
> "name": "javatest03xd.origo.t-online.private",  
> "chef\_environment": "test",  
> ...  
> "run\_list": [  
> "recipe[A::base]",  
> "recipe[B::backend]"  
> ]  
> }
> 
> _A/base.rb_  
> package "nfs-common" do  
> action :remove  
> end
> 
> service 'ntp' do  
> action [:enable, :start]  
> end
> 
> file "/tmp/very\_important\_service.conf" do  
> content "BASE data"  
> notifies :restart, 'service[ntp]'  
> end
> 
> user 'extra' do  
> action [:remove]  
> end
> 
> _B/backend.rb_  
> package "nfs-common" do  
> action :remove  
> end  
> service 'ntp' do  
> action [:enable, :start]  
> end
> 
> file "/tmp/very\_important\_service.conf" do  
> content "BACKEND data"  
> notifies :restart, 'service[ntp]'  
> end
> 
> user 'extra' do  
> action [:create, :lock]  
> end
> 
> [2014-04-01T16:59:55+02:00] INFO: Forking chef instance to converge...  
> [2014-04-01T16:59:55+02:00] INFO: \*\*\* Chef 11.10.4 \*\*\*  
> [2014-04-01T16:59:55+02:00] INFO: Chef-client pid: 7730  
> [2014-04-01T16:59:56+02:00] INFO: Run List is [recipe[A::base], recipe[B::backend]]  
> [2014-04-01T16:59:56+02:00] INFO: Run List expands to [A::base, B::backend]  
> [2014-04-01T16:59:56+02:00] INFO: Starting Chef Run for javatest03xd.origo.t-online.private  
> [2014-04-01T16:59:56+02:00] INFO: Running start handlers  
> [2014-04-01T16:59:56+02:00] INFO: Start handlers complete.  
> [2014-04-01T16:59:56+02:00] INFO: HTTP Request Returned 404 Object Not Found:  
> [2014-04-01T16:59:56+02:00] INFO: Loading cookbooks [A, B]  
> [2014-04-01T16:59:56+02:00] WARN: Cloning resource attributes for package[nfs-common] from prior resource (CHEF-3694)  
> [2014-04-01T16:59:56+02:00] WARN: Previous package[nfs-common]: /var/chef/cache/cookbooks/A/recipes/base.rb:1:in `from_file' [2014-04-01T16:59:56+02:00] WARN: Current package[nfs-common]: /var/chef/cache/cookbooks/B/recipes/backend.rb:1:in `from\_file'  
> [2014-04-01T16:59:56+02:00] WARN: Cloning resource attributes for service[ntp] from prior resource (CHEF-3694)  
> [2014-04-01T16:59:56+02:00] WARN: Previous service[ntp]: /var/chef/cache/cookbooks/A/recipes/base.rb:5:in `from_file' [2014-04-01T16:59:56+02:00] WARN: Current service[ntp]: /var/chef/cache/cookbooks/B/recipes/backend.rb:5:in `from\_file'  
> [2014-04-01T16:59:56+02:00] WARN: Cloning resource attributes for file[/tmp/very\_important\_service.conf] from prior resource (CHEF-3694)  
> [2014-04-01T16:59:56+02:00] WARN: Previous file[/tmp/very\_important\_service.conf]: /var/chef/cache/cookbooks/A/recipes/base.rb:9:in `from_file' [2014-04-01T16:59:56+02:00] WARN: Current file[/tmp/very_important_service.conf]: /var/chef/cache/cookbooks/B/recipes/backend.rb:9:in `from\_file'  
> [2014-04-01T16:59:56+02:00] WARN: Cloning resource attributes for user[extra] from prior resource (CHEF-3694)  
> [2014-04-01T16:59:56+02:00] WARN: Previous user[extra]: /var/chef/cache/cookbooks/A/recipes/base.rb:14:in `from_file' [2014-04-01T16:59:56+02:00] WARN: Current user[extra]: /var/chef/cache/cookbooks/B/recipes/backend.rb:14:in `from\_file'  
> [2014-04-01T16:59:56+02:00] INFO: Processing package[nfs-common] action remove (A::base line 1)  
> [2014-04-01T16:59:57+02:00] INFO: package[nfs-common] removed  
> [2014-04-01T16:59:57+02:00] INFO: Processing service[ntp] action enable (A::base line 5)  
> [2014-04-01T16:59:57+02:00] INFO: Processing service[ntp] action start (A::base line 5)  
> [2014-04-01T16:59:57+02:00] INFO: Processing file[/tmp/very\_important\_service.conf] action create (A::base line 9)  
> [2014-04-01T16:59:57+02:00] INFO: file[/tmp/very\_important\_service.conf] backed up to /var/chef/backup/tmp/very\_important\_service.conf.chef-20140401165957.690683  
> [2014-04-01T16:59:57+02:00] INFO: file[/tmp/very\_important\_service.conf] updated file contents /tmp/very\_important\_service.conf  
> [2014-04-01T16:59:57+02:00] INFO: file[/tmp/very\_important\_service.conf] not queuing delayed action restart on service[ntp] (delayed), as it's already been queued  
> [2014-04-01T16:59:57+02:00] INFO: Processing user[extra] action remove (A::base line 14)  
> [2014-04-01T16:59:57+02:00] INFO: user[extra] removed  
> [2014-04-01T16:59:57+02:00] INFO: Processing package[nfs-common] action install (B::backend line 1)  
> [2014-04-01T17:00:00+02:00] INFO: Processing service[ntp] action enable (B::backend line 5)  
> [2014-04-01T17:00:00+02:00] INFO: Processing service[ntp] action start (B::backend line 5)  
> [2014-04-01T17:00:00+02:00] INFO: Processing file[/tmp/very\_important\_service.conf] action create (B::backend line 9)  
> [2014-04-01T17:00:00+02:00] INFO: file[/tmp/very\_important\_service.conf] backed up to /var/chef/backup/tmp/very\_important\_service.conf.chef-20140401170000.881799  
> [2014-04-01T17:00:00+02:00] INFO: file[/tmp/very\_important\_service.conf] updated file contents /tmp/very\_important\_service.conf  
> [2014-04-01T17:00:00+02:00] INFO: file[/tmp/very\_important\_service.conf] not queuing delayed action restart on service[ntp] (delayed), as it's already been queued  
> [2014-04-01T17:00:00+02:00] INFO: file[/tmp/very\_important\_service.conf] not queuing delayed action restart on service[ntp] (delayed), as it's already been queued  
> [2014-04-01T17:00:00+02:00] INFO: Processing user[extra] action create (B::backend line 14)  
> [2014-04-01T17:00:00+02:00] INFO: user[extra] created  
> [2014-04-01T17:00:00+02:00] INFO: Processing user[extra] action lock (B::backend line 14)  
> [2014-04-01T17:00:01+02:00] INFO: file[/tmp/very\_important\_service.conf] sending restart action to service[ntp] (delayed)  
> [2014-04-01T17:00:01+02:00] INFO: Processing service[ntp] action restart (B::backend line 5)  
> [2014-04-01T17:00:02+02:00] INFO: service[ntp] restarted  
> [2014-04-01T17:00:02+02:00] INFO: Chef Run complete in 6.074158866 seconds  
> [2014-04-01T17:00:02+02:00] INFO: Running report handlers  
> [2014-04-01T17:00:02+02:00] INFO: Report handlers complete
> 
> I hope I could explain my question clearly.
> 
> Best, Balint!

---

<div class="post-metadata">

**Author:** ![johnnym](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.chef.io/johnnym/32/339_2.png) [@johnnym](https://discourse.chef.io/u/johnnym)\
**Post date:** [April 7, 2014, 2:59pm UTC](https://discourse.chef.io/t/recipes-run-order-versus-resource-usage-cloning/5205/3 "2014-04-07T14:59:36Z")

</div>

Thank you for your answer!

As I understand it you suggest not to write recipes as roles (like  
role\_recipe::backend, role\_recipe::base), but play with roles and use  
if/case statements inside the cookbooks (I don't know what does "vanilla  
roles" mean). Somehow like this:

my\_type = search(:node, "name:#{node.name}")

Chef::Log.info("My type: #{my\_type[0]['roles']}")  
if my\_type[0].role?("java")  
package "nfs-common" do  
action :install  
end  
else  
package "nfs-common" do  
action :remove  
end  
end

Do I understand your suggestion correctly?

On 04/01/2014 06:37 PM, Lamont Granquist wrote:

> you probably want to pull out all the common resources into a new  
> recipe like "\_common.rb" or something and then
> 
> include\_recipe "#{cookbook\_name}::\_common"
> 
> in both base.rb and backend.rb recipes, then only include one or the  
> other recipe in your run\_list for any given server. also probably  
> want to keep the concerns together and use one cookbook with multiple  
> recipes rather than your 'A' and 'B' cookbooks.
> 
> if you really want the 'base' recipe to be included everywhere and the  
> 'backend' to override it then you probably want to include an  
> attribute somewhere. you could push this attribute up into roles if  
> you like. then it looks like you can have a single 'thing::default'  
> recipe that has a conditional:
> 
> my\_content = if node['thing']['type'] == "base"  
> "BASE data"  
> else  
> "BACKEND data"  
> end
> 
> file "/tmp/very\_important\_service.conf" do  
> content my\_content  
> notifies :restart, 'service[ntp]'  
> end
> 
> for more complicated code you can use an if that wraps include\_recipe  
> so that you switch on the attribute to do two different things so  
> default.rb might look like:
> 
> include\_recipe "#{cookbook\_name}::\_common"
> 
> if node['thing']['type'] == "base"  
> include\_recipe "#{cookbook\_name}::\_base"  
> else  
> include\_recipe "#{cookbook\_name}::\_backend"  
> end
> 
> and you can set node['thing']['type'] either in a role or a role  
> cookbook (in this case you'll want to keep  
> one-cookbook-per-role-cookbook, so you'd have something like  
> role\_base::default and role\_backend::default recipes, for now just  
> trust me and don't do role::backend and role::base because you want to  
> set the role attribute in attribute files and in the latter case  
> you'll get surprised when all the attribute files in a cookbook always  
> get parsed -- but start playing with vanilla roles first before moving  
> on to role cookbooks, then read this again later if you start going  
> down the role cookbook route).
> 
> On Tue Apr 1 08:06:53 2014, johnnym wrote:
> 
> > Hi All,
> > 
> > I am new to chef so sorry if I misuse some words but I have a  
> > question. As I tested it if a node has 2 recipes and these recipes  
> > work on the same resource (a file or a package...or user) how can I  
> > prevent the node from rebuilding and restarting services all the time.
> > 
> > In this case I make a base system with the minimal packages services  
> > and users, but with a specific base config file. On this base system I  
> > want to create a backend so I apply B::backend but this recipe  
> > installs packages, adds users and modifies a config file.
> > 
> > If I run chef-client (below) I can see that the users, packages and  
> > files are removing and reinstalling all the time and the services are  
> > restarting during every chef-client run.
> > 
> > Can I compile the recipes into one recipe in order to allow them to  
> > overwrite the same resource in the order of the run\_list?
> > 
> > {  
> > "name": "javatest03xd.origo.t-online.private",  
> > "chef\_environment": "test",  
> > ...  
> > "run\_list": [  
> > "recipe[A::base]",  
> > "recipe[B::backend]"  
> > ]  
> > }
> > 
> > _A/base.rb_  
> > package "nfs-common" do  
> > action :remove  
> > end
> > 
> > service 'ntp' do  
> > action [:enable, :start]  
> > end
> > 
> > file "/tmp/very\_important\_service.conf" do  
> > content "BASE data"  
> > notifies :restart, 'service[ntp]'  
> > end
> > 
> > user 'extra' do  
> > action [:remove]  
> > end
> > 
> > _B/backend.rb_  
> > package "nfs-common" do  
> > action :remove  
> > end  
> > service 'ntp' do  
> > action [:enable, :start]  
> > end
> > 
> > file "/tmp/very\_important\_service.conf" do  
> > content "BACKEND data"  
> > notifies :restart, 'service[ntp]'  
> > end
> > 
> > user 'extra' do  
> > action [:create, :lock]  
> > end
> > 
> > [2014-04-01T16:59:55+02:00] INFO: Forking chef instance to converge...  
> > [2014-04-01T16:59:55+02:00] INFO: \*\*\* Chef 11.10.4 \*\*\*  
> > [2014-04-01T16:59:55+02:00] INFO: Chef-client pid: 7730  
> > [2014-04-01T16:59:56+02:00] INFO: Run List is [recipe[A::base],  
> > recipe[B::backend]]  
> > [2014-04-01T16:59:56+02:00] INFO: Run List expands to [A::base,  
> > B::backend]  
> > [2014-04-01T16:59:56+02:00] INFO: Starting Chef Run for  
> > javatest03xd.origo.t-online.private  
> > [2014-04-01T16:59:56+02:00] INFO: Running start handlers  
> > [2014-04-01T16:59:56+02:00] INFO: Start handlers complete.  
> > [2014-04-01T16:59:56+02:00] INFO: HTTP Request Returned 404 Object  
> > Not Found:  
> > [2014-04-01T16:59:56+02:00] INFO: Loading cookbooks [A, B]  
> > [2014-04-01T16:59:56+02:00] WARN: Cloning resource attributes for  
> > package[nfs-common] from prior resource (CHEF-3694)  
> > [2014-04-01T16:59:56+02:00] WARN: Previous package[nfs-common]:  
> > /var/chef/cache/cookbooks/A/recipes/base.rb:1:in `from_file' [2014-04-01T16:59:56+02:00] WARN: Current package[nfs-common]: /var/chef/cache/cookbooks/B/recipes/backend.rb:1:in `from\_file'  
> > [2014-04-01T16:59:56+02:00] WARN: Cloning resource attributes for  
> > service[ntp] from prior resource (CHEF-3694)  
> > [2014-04-01T16:59:56+02:00] WARN: Previous service[ntp]:  
> > /var/chef/cache/cookbooks/A/recipes/base.rb:5:in `from_file' [2014-04-01T16:59:56+02:00] WARN: Current service[ntp]: /var/chef/cache/cookbooks/B/recipes/backend.rb:5:in `from\_file'  
> > [2014-04-01T16:59:56+02:00] WARN: Cloning resource attributes for  
> > file[/tmp/very\_important\_service.conf] from prior resource (CHEF-3694)  
> > [2014-04-01T16:59:56+02:00] WARN: Previous  
> > file[/tmp/very\_important\_service.conf]:  
> > /var/chef/cache/cookbooks/A/recipes/base.rb:9:in `from_file' [2014-04-01T16:59:56+02:00] WARN: Current file[/tmp/very_important_service.conf]: /var/chef/cache/cookbooks/B/recipes/backend.rb:9:in `from\_file'  
> > [2014-04-01T16:59:56+02:00] WARN: Cloning resource attributes for  
> > user[extra] from prior resource (CHEF-3694)  
> > [2014-04-01T16:59:56+02:00] WARN: Previous user[extra]:  
> > /var/chef/cache/cookbooks/A/recipes/base.rb:14:in `from_file' [2014-04-01T16:59:56+02:00] WARN: Current user[extra]: /var/chef/cache/cookbooks/B/recipes/backend.rb:14:in `from\_file'  
> > [2014-04-01T16:59:56+02:00] INFO: Processing package[nfs-common]  
> > action remove (A::base line 1)  
> > [2014-04-01T16:59:57+02:00] INFO: package[nfs-common] removed  
> > [2014-04-01T16:59:57+02:00] INFO: Processing service[ntp] action  
> > enable (A::base line 5)  
> > [2014-04-01T16:59:57+02:00] INFO: Processing service[ntp] action  
> > start (A::base line 5)  
> > [2014-04-01T16:59:57+02:00] INFO: Processing  
> > file[/tmp/very\_important\_service.conf] action create (A::base line 9)  
> > [2014-04-01T16:59:57+02:00] INFO:  
> > file[/tmp/very\_important\_service.conf] backed up to  
> > /var/chef/backup/tmp/very\_important\_service.conf.chef-20140401165957.690683  
> > [2014-04-01T16:59:57+02:00] INFO:  
> > file[/tmp/very\_important\_service.conf] updated file contents  
> > /tmp/very\_important\_service.conf  
> > [2014-04-01T16:59:57+02:00] INFO:  
> > file[/tmp/very\_important\_service.conf] not queuing delayed action  
> > restart on service[ntp] (delayed), as it's already been queued  
> > [2014-04-01T16:59:57+02:00] INFO: Processing user[extra] action  
> > remove (A::base line 14)  
> > [2014-04-01T16:59:57+02:00] INFO: user[extra] removed  
> > [2014-04-01T16:59:57+02:00] INFO: Processing package[nfs-common]  
> > action install (B::backend line 1)  
> > [2014-04-01T17:00:00+02:00] INFO: Processing service[ntp] action  
> > enable (B::backend line 5)  
> > [2014-04-01T17:00:00+02:00] INFO: Processing service[ntp] action  
> > start (B::backend line 5)  
> > [2014-04-01T17:00:00+02:00] INFO: Processing  
> > file[/tmp/very\_important\_service.conf] action create (B::backend line 9)  
> > [2014-04-01T17:00:00+02:00] INFO:  
> > file[/tmp/very\_important\_service.conf] backed up to  
> > /var/chef/backup/tmp/very\_important\_service.conf.chef-20140401170000.881799  
> > [2014-04-01T17:00:00+02:00] INFO:  
> > file[/tmp/very\_important\_service.conf] updated file contents  
> > /tmp/very\_important\_service.conf  
> > [2014-04-01T17:00:00+02:00] INFO:  
> > file[/tmp/very\_important\_service.conf] not queuing delayed action  
> > restart on service[ntp] (delayed), as it's already been queued  
> > [2014-04-01T17:00:00+02:00] INFO:  
> > file[/tmp/very\_important\_service.conf] not queuing delayed action  
> > restart on service[ntp] (delayed), as it's already been queued  
> > [2014-04-01T17:00:00+02:00] INFO: Processing user[extra] action  
> > create (B::backend line 14)  
> > [2014-04-01T17:00:00+02:00] INFO: user[extra] created  
> > [2014-04-01T17:00:00+02:00] INFO: Processing user[extra] action lock  
> > (B::backend line 14)  
> > [2014-04-01T17:00:01+02:00] INFO:  
> > file[/tmp/very\_important\_service.conf] sending restart action to  
> > service[ntp] (delayed)  
> > [2014-04-01T17:00:01+02:00] INFO: Processing service[ntp] action  
> > restart (B::backend line 5)  
> > [2014-04-01T17:00:02+02:00] INFO: service[ntp] restarted  
> > [2014-04-01T17:00:02+02:00] INFO: Chef Run complete in 6.074158866  
> > seconds  
> > [2014-04-01T17:00:02+02:00] INFO: Running report handlers  
> > [2014-04-01T17:00:02+02:00] INFO: Report handlers complete
> > 
> > I hope I could explain my question clearly.
> > 
> > Best, Balint!
