chef-boneyard / push-jobs-cookbook

Development repository for Chef Cookbook push-jobs
https://supermarket.chef.io/cookbooks/push-jobs
Apache License 2.0
21 stars 43 forks source link

Timeout::Error on Windows Server #111

Closed tpetchel closed 7 years ago

tpetchel commented 7 years ago

Cookbook version

3.3.0, included by using delivery-base 0.2.2

Chef-client version

12.18.31

Platform Details

Windows Server 2012 R2 on EC2

Scenario:

I'm bootstrapping infrastructure environments (Windows Server instances on EC2) that run cookbooks during the Acceptance, Union, Rehearsal, and Delivered stages from the Chef Automate pipeline.

I've been able to do this using Linux instances (tried CentOS 7 and Ubuntu 14.04) without issue. However, when I tried Windows, 2 of my 4 environments failed due to Timeout::Error:

https://gist.github.com/tpetchel/c0624428d4859e6d6704655beb181dd3#file-knife-bootstrap

Running chef-client a second time on the node is unable to patch the system.

https://gist.github.com/tpetchel/c0624428d4859e6d6704655beb181dd3#file-knife-winrm

My concern is that this happened two times out of four. Setting up push jobs client on Windows Server is part of an upcoming Learn Chef tutorial, and I fear this issue will affect tutorial users.

Because running chef-client does not repair the system, I've needed to spin up brand new instances in order to continue. This is not an acceptable work-around for users.

Can this issue be fixed? If not, is there a reasonable workaround?

Steps to Reproduce:

You can likely reproduce this in a local environment, but here are the steps I'm using:

Expected Result:

Push jobs should be set up on the Windows Server node.

Actual Result:

For me, more than 50% of the time the bootstrap process fails due to Timeout::Error, and chef-client is unable to repair the configuration.

tpetchel commented 7 years ago

After debugging with @sersut and @markan, we've identified a potential fix. Will update this issue after I verify the fix.

tpetchel commented 7 years ago

Fixed by https://github.com/chef-cookbooks/delivery-base/pull/16