# Error using chef provisioner \[Terraform\] while bootstrapping a node

**URL:** <https://discourse.chef.io/t/error-using-chef-provisioner-terraform-while-bootstrapping-a-node/9268>\
**Category:** Chef Infra (archive)\
**Created:** [August 29, 2016, 11:55am UTC](https://discourse.chef.io/t/error-using-chef-provisioner-terraform-while-bootstrapping-a-node/9268 "2016-08-29T11:55:35Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![waseemahammed](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.chef.io/waseemahammed/32/1708_2.png) [@waseemahammed](https://discourse.chef.io/u/waseemahammed)\
**Post date:** [August 29, 2016, 11:55am UTC](https://discourse.chef.io/t/error-using-chef-provisioner-terraform-while-bootstrapping-a-node/9268/1 "2016-08-29T11:55:36Z")

</div>

I’ve been trying to bootstrap a node with terraform EC2 instance, but I keep getting the following error.

aws\_instance.XXX (chef): curl: (7) Failed to connect to www.chef  
aws\_instance.XXX (chef): .io port 443: Connection timed out  
aws\_instance.XXX (chef): curl: (7) Failed to connect to [www.ch](http://www.ch)  
aws\_instance.XXX (chef): [ef.io](http://ef.io) port 443: Connection timed out  
Error applying plan:

3 error(s) occurred:

- Command “sudo curl -LO [https://www.chef.io/chef/install.sh](https://www.chef.io/chef/install.sh)” exited with non-zero exit status: 7
- Command “sudo curl -LO [https://www.chef.io/chef/install.sh](https://www.chef.io/chef/install.sh)” exited with non-zero exit status: 7
- Command “sudo curl -LO [https://www.chef.io/chef/install.sh](https://www.chef.io/chef/install.sh)” exited with non-zero exit status: 7

---

<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:** [August 29, 2016, 4:26pm UTC](https://discourse.chef.io/t/error-using-chef-provisioner-terraform-while-bootstrapping-a-node/9268/2 "2016-08-29T16:26:16Z")

</div>

> [@waseemahammed](#):
>
> Failed to connect to [www.chef.io](http://www.chef.io) port 443: Connection timed out

If this was a one-time thing, it could've been a short outage (I'm not aware that we have had one recently, though). If this happens consistently, something is dropping the outbound packets from your nodes. In that case, you need to check your network configuration.

---

<div class="post-metadata">

**Author:** ![majormoses](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.chef.io/majormoses/32/1999_2.png) [@majormoses](https://discourse.chef.io/u/majormoses)\
**Post date:** [August 30, 2016, 4:14pm UTC](https://discourse.chef.io/t/error-using-chef-provisioner-terraform-while-bootstrapping-a-node/9268/3 "2016-08-30T16:14:29Z")

</div>

Does the subnet you specified have a route to the world? If memory serves me correctly I believe that terraforms default behavior in aws vpc is to remove all default routes. I will see if I can dig up some supporting documentation.

---

<div class="post-metadata">

**Author:** ![ravibhure](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.chef.io/ravibhure/32/1255_2.png) [@ravibhure](https://discourse.chef.io/u/ravibhure)\
**Post date:** [August 30, 2016, 5:21pm UTC](https://discourse.chef.io/t/error-using-chef-provisioner-terraform-while-bootstrapping-a-node/9268/4 "2016-08-30T17:21:01Z")

</div>

This is something about the was vocal networking thing where the teraform  
launched ec2 instance does not have internet world route. (Verify your  
outbound rules which is attached with instance and also make sure it on if  
there any bastion between.  
Have you checked to install chef-client on instance even after teraform  
failed?
