# Chef-client slow on Windows

**URL:** https://discourse.chef.io/t/chef-client-slow-on-windows/3206
**Category:** Chef Infra (archive)
**Created:** [October 18, 2012, 5:26pm UTC](https://discourse.chef.io/t/chef-client-slow-on-windows/3206 "2012-10-18T17:26:50Z")
**Posts on this page:** 14
**Page:** 1

<div class="post-metadata">

### Author: ![Madhurranjan\_Mohaan](https://avatars.discourse-cdn.com/v4/letter/m/5f9b8f/32.png) [@Madhurranjan\_Mohaan](https://discourse.chef.io/u/Madhurranjan_Mohaan)
#### Post date: [October 18, 2012, 5:26pm UTC](https://discourse.chef.io/t/chef-client-slow-on-windows/3206/1 "2012-10-18T17:26:50Z")

</div>

Hi,

We’ve had a couple of other threads last year around this . Now that I am  
working with a bigger team with chef on windows, one constant complaint has  
been the slowness of running chef-client . It takes around 20seconds to  
show “Chef client run started” ( the starting line ) and then another  
10-15 seconds where the plugins are loaded and the recipes are cached and  
then the actual client run happens. Based on the other threads ,we’ve  
disabled a whole bunch of plugins but we’re facing this issue. Running  
knife commands are also very slow. We’re on Windows 2008 server or Windows  
7 machines.

Any help here would be greatly appreciated.

Ranjan

---

<div class="post-metadata">

### Author: ![dcondomitti](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.chef.io/dcondomitti/32/104_2.png) [@dcondomitti](https://discourse.chef.io/u/dcondomitti)
#### Post date: [October 18, 2012, 5:31pm UTC](https://discourse.chef.io/t/chef-client-slow-on-windows/3206/2 "2012-10-18T17:31:36Z")

</div>

Which version are you using? There was an issue with a recent release that used a version of rubygems that caused extremely long initial load times like what you're seeing.

On Thursday, October 18, 2012 at 1:26 PM, Madhurranjan Mohaan wrote:

> Hi,
> 
> We've had a couple of other threads last year around this . Now that I am working with a bigger team with chef on windows, one constant complaint has been the slowness of running chef-client . It takes around 20seconds to show "Chef client run started" ( the starting line ) and then another 10-15 seconds where the plugins are loaded and the recipes are cached and then the actual client run happens. Based on the other threads ,we've disabled a whole bunch of plugins but we're facing this issue. Running knife commands are also very slow. We're on Windows 2008 server or Windows 7 machines.
> 
> Any help here would be greatly appreciated.
> 
> Ranjan

---

<div class="post-metadata">

### Author: ![Madhurranjan\_Mohaan](https://avatars.discourse-cdn.com/v4/letter/m/5f9b8f/32.png) [@Madhurranjan\_Mohaan](https://discourse.chef.io/u/Madhurranjan_Mohaan)
#### Post date: [October 19, 2012, 3:18am UTC](https://discourse.chef.io/t/chef-client-slow-on-windows/3206/3 "2012-10-19T03:18:51Z")

</div>

Hi Daniel,

We are using 10.12.0 client and server versions.

Ranjan

On Thu, Oct 18, 2012 at 11:01 PM, Daniel Condomitti  
[daniel@condomitti.com](mailto:daniel@condomitti.com)wrote:

> Which version are you using? There was an issue with a recent release  
> that used a version of rubygems that caused extremely long initial load  
> times like what you're seeing.
> 
> On Thursday, October 18, 2012 at 1:26 PM, Madhurranjan Mohaan wrote:
> 
> Hi,
> 
> We've had a couple of other threads last year around this . Now that I am  
> working with a bigger team with chef on windows, one constant complaint has  
> been the slowness of running chef-client . It takes around 20seconds to  
> show "Chef client run started" ( the starting line ) and then another  
> 10-15 seconds where the plugins are loaded and the recipes are cached and  
> then the actual client run happens. Based on the other threads ,we've  
> disabled a whole bunch of plugins but we're facing this issue. Running  
> knife commands are also very slow. We're on Windows 2008 server or Windows  
> 7 machines.
> 
> Any help here would be greatly appreciated.
> 
> Ranjan

---

<div class="post-metadata">

### Author: ![Madhurranjan\_Mohaan](https://avatars.discourse-cdn.com/v4/letter/m/5f9b8f/32.png) [@Madhurranjan\_Mohaan](https://discourse.chef.io/u/Madhurranjan_Mohaan)
#### Post date: [October 19, 2012, 6:14am UTC](https://discourse.chef.io/t/chef-client-slow-on-windows/3206/4 "2012-10-19T06:14:40Z")

</div>

The other bit is that [Ohai windows kernel by sbates · Pull Request #81 · chef/ohai · GitHub](https://github.com/opscode/ohai/pull/81) is not  
included in 10.12 . I see that it was merged in the mainline 3 months ago.  
Just curious whether this is in 10.14 and if it improves the issue, we can  
upgrade.

On Fri, Oct 19, 2012 at 8:48 AM, Madhurranjan Mohaan \<  
[maadhuuranjan.m@gmail.com](mailto:maadhuuranjan.m@gmail.com)\> wrote:

> Hi Daniel,
> 
> We are using 10.12.0 client and server versions.
> 
> Ranjan
> 
> On Thu, Oct 18, 2012 at 11:01 PM, Daniel Condomitti \<[daniel@condomitti.com](mailto:daniel@condomitti.com)
> 
> > wrote:
> 
> > Which version are you using? There was an issue with a recent release  
> > that used a version of rubygems that caused extremely long initial load  
> > times like what you're seeing.
> > 
> > On Thursday, October 18, 2012 at 1:26 PM, Madhurranjan Mohaan wrote:
> > 
> > Hi,
> > 
> > We've had a couple of other threads last year around this . Now that I am  
> > working with a bigger team with chef on windows, one constant complaint has  
> > been the slowness of running chef-client . It takes around 20seconds to  
> > show "Chef client run started" ( the starting line ) and then another  
> > 10-15 seconds where the plugins are loaded and the recipes are cached and  
> > then the actual client run happens. Based on the other threads ,we've  
> > disabled a whole bunch of plugins but we're facing this issue. Running  
> > knife commands are also very slow. We're on Windows 2008 server or Windows  
> > 7 machines.
> > 
> > Any help here would be greatly appreciated.
> > 
> > Ranjan

---

<div class="post-metadata">

### Author: ![Jeremiah\_Snapp](https://avatars.discourse-cdn.com/v4/letter/j/3bc359/32.png) [@Jeremiah\_Snapp](https://discourse.chef.io/u/Jeremiah_Snapp)
#### Post date: [October 19, 2012, 8:19am UTC](https://discourse.chef.io/t/chef-client-slow-on-windows/3206/5 "2012-10-19T08:19:50Z")

</div>

10.12 was the slow version Daniel mentioned earlier so upgrading to 10.14  
should fix the speed issue for you. At least it did for me with my Linux  
servers.

---

<div class="post-metadata">

### Author: ![bjunity](https://avatars.discourse-cdn.com/v4/letter/b/e9bcb4/32.png) [@bjunity](https://discourse.chef.io/u/bjunity)
#### Post date: [October 19, 2012, 2:17pm UTC](https://discourse.chef.io/t/chef-client-slow-on-windows/3206/6 "2012-10-19T14:17:09Z")

</div>

Unfortunately 10.14.2 is also affected.

Please see my ticket:

[http://tickets.opscode.com/browse/CHEF-3485](http://tickets.opscode.com/browse/CHEF-3485)

---

<div class="post-metadata">

### Author: ![Tim\_Smith](https://avatars.discourse-cdn.com/v4/letter/t/8dc957/32.png) [@Tim\_Smith](https://discourse.chef.io/u/Tim_Smith)
#### Post date: [October 19, 2012, 8:17pm UTC](https://discourse.chef.io/t/chef-client-slow-on-windows/3206/7 "2012-10-19T20:17:48Z")

</div>

I can confirm that 10.14.4 is still impacted

From: "bjunity@gmail.com[mailto:bjunity@gmail.com](mailto:bjunity@gmail.com)" \<[bjunity@gmail.com](mailto:bjunity@gmail.com)[mailto:bjunity@gmail.com](mailto:bjunity@gmail.com)\>  
Reply-To: "chef@lists.opscode.com[mailto:chef@lists.opscode.com](mailto:chef@lists.opscode.com)" \<[chef@lists.opscode.com](mailto:chef@lists.opscode.com)[mailto:chef@lists.opscode.com](mailto:chef@lists.opscode.com)\>  
Date: Friday, October 19, 2012 7:17 AM  
To: "chef@lists.opscode.com[mailto:chef@lists.opscode.com](mailto:chef@lists.opscode.com)" \<[chef@lists.opscode.com](mailto:chef@lists.opscode.com)[mailto:chef@lists.opscode.com](mailto:chef@lists.opscode.com)\>  
Subject: [chef] Re: Re: Re: Chef-client slow on Windows

Unfortunately 10.14.2 is also affected.

Please see my ticket:

[http://tickets.opscode.com/browse/CHEF-3485](http://tickets.opscode.com/browse/CHEF-3485)

---

<div class="post-metadata">

### Author: ![Madhurranjan\_Mohaan](https://avatars.discourse-cdn.com/v4/letter/m/5f9b8f/32.png) [@Madhurranjan\_Mohaan](https://discourse.chef.io/u/Madhurranjan_Mohaan)
#### Post date: [October 20, 2012, 6:48pm UTC](https://discourse.chef.io/t/chef-client-slow-on-windows/3206/8 "2012-10-20T18:48:10Z")

</div>

Can we , the windows users, ( unfortunately I guess we don't have a  
choice!) request for some help on the platform ? The 100% CPU thing is  
interesting as I just noticed the same on Win 2008 . Thanks for pointing  
that out. We are going live in Production in a month's time and I am afraid  
all the work we have done might be rejected by the Ops folks of the  
customer due to these reasons.

Ranjan

On Sat, Oct 20, 2012 at 1:47 AM, Tim Smith [Tim.Smith@webtrends.com](mailto:Tim.Smith@webtrends.com) wrote:

> I can confirm that 10.14.4 is still impacted
> 
> From: "[bjunity@gmail.com](mailto:bjunity@gmail.com)" [bjunity@gmail.com](mailto:bjunity@gmail.com)  
> Reply-To: "[chef@lists.opscode.com](mailto:chef@lists.opscode.com)" [chef@lists.opscode.com](mailto:chef@lists.opscode.com)  
> Date: Friday, October 19, 2012 7:17 AM  
> To: "[chef@lists.opscode.com](mailto:chef@lists.opscode.com)" [chef@lists.opscode.com](mailto:chef@lists.opscode.com)
> 
> Subject: [chef] Re: Re: Re: Chef-client slow on Windows
> 
> Unfortunately 10.14.2 is also affected.
> 
> Please see my ticket:
> 
> [http://tickets.opscode.com/browse/CHEF-3485](http://tickets.opscode.com/browse/CHEF-3485)

---

<div class="post-metadata">

### Author: ![Sascha\_Bates](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.chef.io/sascha_bates/32/504_2.png) [@Sascha\_Bates](https://discourse.chef.io/u/Sascha_Bates)
#### Post date: [October 20, 2012, 9:50pm UTC](https://discourse.chef.io/t/chef-client-slow-on-windows/3206/9 "2012-10-20T21:50:09Z")

</div>

I noticed knife hanging for one of my  
windows devs the other day too. I haven't had a chance to follow  
up on it and I don't currently have a way to easily debug it. I'm  
pretty sure he's running the latest available version as he just  
started working with chef last week.

Sascha Bates  
| [sascha.bates@gmail.com](mailto:sascha.bates@gmail.com) | 612 850 0444 | sascha.bates@skype |  
sascha\_bates@yahoo |  
On 10/20/12 1:48 PM, Madhurranjan Mohaan wrote:

> Can we , the windows users, ( unfortunately I guess we don't have a choice!) request for some help on the platform ? The 100% CPU thing is interesting as I just noticed the same on Win 2008 . Thanks for pointing that out. We are going live in Production in a month's time and I am afraid all the work we have done might be rejected by the Ops folks of the customer due to these reasons.
> 
> Ranjan
> 
> On Sat, Oct 20, 2012 at 1:47 AM, Tim  
> Smith \<[Tim.Smith@webtrends.com](mailto:Tim.Smith@webtrends.com)\>  
> wrote:
> 
> > I can confirm that 10.14.4 is still impacted
> > 
> > From: "[bjunity@gmail.com](mailto:bjunity@gmail.com)"  
> > \<[bjunity@gmail.com](mailto:bjunity@gmail.com)\>
> > 
> > Reply-To: "[chef@lists.opscode.com](mailto:chef@lists.opscode.com)"  
> > \<[chef@lists.opscode.com](mailto:chef@lists.opscode.com)\>
> > 
> > Date: Friday,  
> > October 19, 2012 7:17 AM
> > 
> > To: "[chef@lists.opscode.com](mailto:chef@lists.opscode.com)"  
> > \<[chef@lists.opscode.com](mailto:chef@lists.opscode.com)\>
> > 
> > Subject: [chef]  
> > Re: Re: Re: Chef-client slow on Windows
> > 
> > ```
> > Unfortunately 10.14.2 is also affected.
> > 
> > Please see my ticket:
> > 
> > ```
> > 
> > [http://tickets.opscode.com/browse/CHEF-3485](http://tickets.opscode.com/browse/CHEF-3485)

---

<div class="post-metadata">

### Author: ![Christopher\_Brown](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.chef.io/christopher_brown/32/559_2.png) [@Christopher\_Brown](https://discourse.chef.io/u/Christopher_Brown)
#### Post date: [October 20, 2012, 11:01pm UTC](https://discourse.chef.io/t/chef-client-slow-on-windows/3206/10 "2012-10-20T23:01:44Z")

</div>

Yes, this is something I've asked the team to prioritize. We'll be taking a close look at Windows support in general between now and the end of the year.

Chris

* * *

Christopher Brown  
Chief Technology Officer,  
Opscode, Inc.

> **[Chef: Enabling the Coded Enterprise through Infrastructure, Security and...](https://www.chef.io/)**
>
> Automation for all of your technology. Overcome the complexity and rapidly ship your infrastructure and apps anywhere with automation.

  
Twitter: @skeptomai
* * *

From: Madhurranjan Mohaan [maadhuuranjan.m@gmail.com]  
Sent: Saturday, October 20, 2012 11:48 AM  
To: [chef@lists.opscode.com](mailto:chef@lists.opscode.com)  
Subject: [chef] Re: Re: Re: Re: Re: Chef-client slow on Windows

Can we , the windows users, ( unfortunately I guess we don't have a choice!) request for some help on the platform ? The 100% CPU thing is interesting as I just noticed the same on Win 2008 . Thanks for pointing that out. We are going live in Production in a month's time and I am afraid all the work we have done might be rejected by the Ops folks of the customer due to these reasons.

Ranjan

On Sat, Oct 20, 2012 at 1:47 AM, Tim Smith \<[Tim.Smith@webtrends.com](mailto:Tim.Smith@webtrends.com)[mailto:Tim.Smith@webtrends.com](mailto:Tim.Smith@webtrends.com)\> wrote:  
I can confirm that 10.14.4 is still impacted

From: "[bjunity@gmail.com](mailto:bjunity@gmail.com)[mailto:bjunity@gmail.com](mailto:bjunity@gmail.com)" \<[bjunity@gmail.com](mailto:bjunity@gmail.com)[mailto:bjunity@gmail.com](mailto:bjunity@gmail.com)\>  
Reply-To: "[chef@lists.opscode.com](mailto:chef@lists.opscode.com)[mailto:chef@lists.opscode.com](mailto:chef@lists.opscode.com)" \<[chef@lists.opscode.com](mailto:chef@lists.opscode.com)[mailto:chef@lists.opscode.com](mailto:chef@lists.opscode.com)\>  
Date: Friday, October 19, 2012 7:17 AM  
To: "[chef@lists.opscode.com](mailto:chef@lists.opscode.com)[mailto:chef@lists.opscode.com](mailto:chef@lists.opscode.com)" \<[chef@lists.opscode.com](mailto:chef@lists.opscode.com)[mailto:chef@lists.opscode.com](mailto:chef@lists.opscode.com)\>

Subject: [chef] Re: Re: Re: Chef-client slow on Windows

Unfortunately 10.14.2 is also affected.

Please see my ticket:

[http://tickets.opscode.com/browse/CHEF-3485](http://tickets.opscode.com/browse/CHEF-3485)

---

<div class="post-metadata">

### Author: ![Madhurranjan\_Mohaan](https://avatars.discourse-cdn.com/v4/letter/m/5f9b8f/32.png) [@Madhurranjan\_Mohaan](https://discourse.chef.io/u/Madhurranjan_Mohaan)
#### Post date: [January 9, 2013, 5:31am UTC](https://discourse.chef.io/t/chef-client-slow-on-windows/3206/11 "2013-01-09T05:31:54Z")

</div>

Hi ,

We wanted to know if there has been any significant improvement around this  
. I feel this pain day in and day out and have had a lot of complaints from  
various users around the slowness.

Thanks,  
Madhurranjan

On Sun, Oct 21, 2012 at 4:31 AM, Christopher Brown [cb@opscode.com](mailto:cb@opscode.com) wrote:

> Yes, this is something I've asked the team to prioritize. We'll be  
> taking a close look at Windows support in general between now and the end  
> of the year.
> 
> ## Chris
> 
> Christopher Brown  
> Chief Technology Officer,  
> Opscode, Inc.  
> [http://www.opscode.com](http://www.opscode.com)  
> Twitter: @skeptomai
> 
> * * *
> 
> _From:_ Madhurranjan Mohaan [maadhuuranjan.m@gmail.com]  
> _Sent:_ Saturday, October 20, 2012 11:48 AM  
> _To:_ [chef@lists.opscode.com](mailto:chef@lists.opscode.com)  
> _Subject:_ [chef] Re: Re: Re: Re: Re: Chef-client slow on Windows
> 
> Can we , the windows users, ( unfortunately I guess we don't have a  
> choice!) request for some help on the platform ? The 100% CPU thing is  
> interesting as I just noticed the same on Win 2008 . Thanks for pointing  
> that out. We are going live in Production in a month's time and I am afraid  
> all the work we have done might be rejected by the Ops folks of the  
> customer due to these reasons.
> 
> Ranjan
> 
> On Sat, Oct 20, 2012 at 1:47 AM, Tim Smith [Tim.Smith@webtrends.com](mailto:Tim.Smith@webtrends.com)wrote:
> 
> > I can confirm that 10.14.4 is still impacted
> > 
> > From: "[bjunity@gmail.com](mailto:bjunity@gmail.com)" [bjunity@gmail.com](mailto:bjunity@gmail.com)  
> > Reply-To: "[chef@lists.opscode.com](mailto:chef@lists.opscode.com)" [chef@lists.opscode.com](mailto:chef@lists.opscode.com)  
> > Date: Friday, October 19, 2012 7:17 AM  
> > To: "[chef@lists.opscode.com](mailto:chef@lists.opscode.com)" [chef@lists.opscode.com](mailto:chef@lists.opscode.com)
> > 
> > Subject: [chef] Re: Re: Re: Chef-client slow on Windows
> > 
> > Unfortunately 10.14.2 is also affected.
> > 
> > Please see my ticket:
> > 
> > [http://tickets.opscode.com/browse/CHEF-3485](http://tickets.opscode.com/browse/CHEF-3485)

---

<div class="post-metadata">

### Author: ![kallistec](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.chef.io/kallistec/32/23_2.png) [@kallistec](https://discourse.chef.io/u/kallistec)
#### Post date: [January 9, 2013, 9:22pm UTC](https://discourse.chef.io/t/chef-client-slow-on-windows/3206/12 "2013-01-09T21:22:30Z")

</div>

On Tuesday, January 8, 2013 at 9:31 PM, Madhurranjan Mohaan wrote:

> Hi ,
> 
> We wanted to know if there has been any significant improvement around this . I feel this pain day in and day out and have had a lot of complaints from various users around the slowness.
> 
> Thanks,  
> Madhurranjan

We're continuing to investigate. In the meantime, we've learned that Ruby 1.9.3 has some significant performance benefits over Ruby 1.9.2, so we've released an updated Chef 10.16.4 MSI which includes Ruby 1.9.3. You can get it here:

> **[Download Chef Infra Client | Chef](https://www.chef.io/downloads/tools/infra-client)**
>
> Chef Infra Client is an agent that runs locally on every node that is under management by Chef Infra.

--  
Daniel DeLeo

---

<div class="post-metadata">

### Author: ![Pete\_Cheslock1](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.chef.io/pete_cheslock1/32/610_2.png) [@Pete\_Cheslock1](https://discourse.chef.io/u/Pete_Cheslock1)
#### Post date: [January 9, 2013, 9:59pm UTC](https://discourse.chef.io/t/chef-client-slow-on-windows/3206/13 "2013-01-09T21:59:30Z")

</div>

Wow - this is awesome. Been waiting for this for a while as well.

I wonder if that solves this ticket:  
[http://tickets.opscode.com/browse/CHEF-3569](http://tickets.opscode.com/browse/CHEF-3569)

I'll do a test on an R2 node on Rackspace to see if we're seeing better  
performance with 2008 R2

In a quick test on EC2 - Windows 2008 (non r2)

Same set of cookbooks & configs, a chef run finishes in 28sec vs 75sec  
using the 10.16.2 msi package.

Great work guys!

-Pete

On Wed, Jan 9, 2013 at 4:22 PM, Daniel DeLeo [dan@kallistec.com](mailto:dan@kallistec.com) wrote:

> On Tuesday, January 8, 2013 at 9:31 PM, Madhurranjan Mohaan wrote:
> 
> Hi ,
> 
> We wanted to know if there has been any significant improvement around  
> this . I feel this pain day in and day out and have had a lot of complaints  
> from various users around the slowness.
> 
> Thanks,  
> Madhurranjan
> 
> We're continuing to investigate. In the meantime, we've learned that Ruby  
> 1.9.3 has some significant performance benefits over Ruby 1.9.2, so we've  
> released an updated Chef 10.16.4 MSI which includes Ruby 1.9.3. You can get  
> it here:
> 
> [http://www.opscode.com/chef/install/](http://www.opscode.com/chef/install/)
> 
> --  
> Daniel DeLeo

---

<div class="post-metadata">

### Author: ![Warren\_Bain](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.chef.io/warren_bain/32/538_2.png) [@Warren\_Bain](https://discourse.chef.io/u/Warren_Bain)
#### Post date: [January 9, 2013, 10:37pm UTC](https://discourse.chef.io/t/chef-client-slow-on-windows/3206/14 "2013-01-09T22:37:46Z")

</div>

I am trying to use the information here [1] to have a recipe run before any resource convergence. We are using this to modify any gem package resources to use a http\_proxy (to eliminate or at least reduce the FetchErrors that we often experience with [rubygems.org](http://rubygems.org). We also want to ensure that only one ‘apt-get update’ occurs in the Chef run as these are relatively expensive and we need as rapid a convergence as possible. These are peppered amongst a variety of community cookbooks that we are using (use case: deploying Rails apps on MySQL or PostgreSQL).

When my code runs, some resources have already converged. I put the recipe as the last item in the runlist which obviously doesn’t work.

The key words in [1] are “This can be done today by simply making the recipes that include your ‘after’ hooks run at the end of the compilation”. Any advice from folks on how to “simply” make this happen?

Regards,  
Wazza

[1] [http://wiki.opscode.com/display/chef/After+hooks](http://wiki.opscode.com/display/chef/After+hooks)
