Closed ghost closed 9 years ago
Hey @DarshanMurthy it looks like there is an issue with the sles11sp3.box
box you are using. Where did that come from? Do you get the same error if you use the precise64
error that is in the examples?
hi @tyler-ball
Its our own box. Now its working... but I have other issues:
[2015-07-02T15:27:10-07:00] INFO: Started chef-zero at chefzero://localhost:8889 with repository at /Users/dtumkursreeni/chef
One version per cookbook
[2015-07-02T15:27:10-07:00] INFO: Forking chef instance to converge...
Starting Chef Client, version 12.4.0.rc.0
[2015-07-02T15:27:10-07:00] INFO: *** Chef 12.4.0.rc.0 ***
[2015-07-02T15:27:10-07:00] INFO: Chef-client pid: 54288
[2015-07-02T15:27:12-07:00] INFO: Run List is []
[2015-07-02T15:27:12-07:00] INFO: Run List expands to []
[2015-07-02T15:27:12-07:00] INFO: Starting Chef Run for dtumkursreeni
[2015-07-02T15:27:12-07:00] INFO: Running start handlers
[2015-07-02T15:27:12-07:00] INFO: Start handlers complete.
[2015-07-02T15:27:12-07:00] INFO: HTTP Request Returned 404 Not Found: Object not found:
resolving cookbooks for run list: []
[2015-07-02T15:27:12-07:00] INFO: Loading cookbooks []
Synchronizing Cookbooks:
Compiling Cookbooks...
[2015-07-02T15:27:12-07:00] WARN: Class Chef::Resource::VagrantBox does not declare 'provides :vagrant_box'.
[2015-07-02T15:27:12-07:00] WARN: This will no longer work in Chef 13: you must use 'provides' to provide DSL.
[2015-07-02T15:27:12-07:00] WARN: Chef::Resource::VagrantBox is marked as providing DSL vagrant_box, but provides :vagrant_box was never called!
[2015-07-02T15:27:12-07:00] WARN: In Chef 13, this will break: you must call provides to mark the names you provide, even if you also override provides? yourself.
[2015-07-02T15:27:12-07:00] WARN: Class Chef::Resource::VagrantBox does not declare 'provides :vagrant_box'.
[2015-07-02T15:27:12-07:00] WARN: This will no longer work in Chef 13: you must use 'provides' to provide DSL.
[2015-07-02T15:27:12-07:00] WARN: Node dtumkursreeni has an empty run list.
Converging 1 resources
Recipe: @recipe_files::/Users/dtumkursreeni/Tryitspossible/chef-provisioning/docs/examples/vagrant_linux.rb
* vagrant_box[sles11sp3] action create[2015-07-02T15:27:12-07:00] INFO: Processing vagrant_box[sles11sp3] action create (@recipe_files::/Users/dtumkursreeni/Tryitspossible/chef-provisioning/docs/examples/vagrant_linux.rb line 77)
[2015-07-02T15:27:12-07:00] WARN: Class Chef::Provider::VagrantBox does not declare 'provides :vagrant_box'.
[2015-07-02T15:27:12-07:00] WARN: This will no longer work in Chef 13: you must use 'provides' to provide DSL.
(up to date)
[2015-07-02T15:27:13-07:00] INFO: Chef Run complete in 1.316378 seconds
Running handlers:
[2015-07-02T15:27:13-07:00] INFO: Running report handlers
Running handlers complete
[2015-07-02T15:27:13-07:00] INFO: Report handlers complete
Chef Client finished, 0/1 resources updated in 3.336512 seconds
dtumkursreeni-mac:examples dtumkursreeni$ chef-client -z vagrant_linux.rb vagrant_linux.rb
[2015-07-02T15:27:32-07:00] INFO: Started chef-zero at chefzero://localhost:8889 with repository at /Users/dtumkursreeni/chef
One version per cookbook
[2015-07-02T15:27:32-07:00] INFO: Forking chef instance to converge...
Starting Chef Client, version 12.4.0.rc.0
[2015-07-02T15:27:32-07:00] INFO: *** Chef 12.4.0.rc.0 ***
[2015-07-02T15:27:32-07:00] INFO: Chef-client pid: 54405
[2015-07-02T15:27:34-07:00] INFO: Run List is []
[2015-07-02T15:27:34-07:00] INFO: Run List expands to []
[2015-07-02T15:27:34-07:00] INFO: Starting Chef Run for dtumkursreeni
[2015-07-02T15:27:34-07:00] INFO: Running start handlers
[2015-07-02T15:27:34-07:00] INFO: Start handlers complete.
[2015-07-02T15:27:34-07:00] INFO: HTTP Request Returned 404 Not Found: Object not found:
resolving cookbooks for run list: []
[2015-07-02T15:27:34-07:00] INFO: Loading cookbooks []
Synchronizing Cookbooks:
Compiling Cookbooks...
[2015-07-02T15:27:34-07:00] WARN: Class Chef::Resource::VagrantBox does not declare 'provides :vagrant_box'.
[2015-07-02T15:27:34-07:00] WARN: This will no longer work in Chef 13: you must use 'provides' to provide DSL.
[2015-07-02T15:27:34-07:00] WARN: Chef::Resource::VagrantBox is marked as providing DSL vagrant_box, but provides :vagrant_box was never called!
[2015-07-02T15:27:34-07:00] WARN: In Chef 13, this will break: you must call provides to mark the names you provide, even if you also override provides? yourself.
[2015-07-02T15:27:34-07:00] WARN: Class Chef::Resource::VagrantBox does not declare 'provides :vagrant_box'.
[2015-07-02T15:27:34-07:00] WARN: This will no longer work in Chef 13: you must use 'provides' to provide DSL.
[2015-07-02T15:27:34-07:00] WARN: Class Chef::Resource::VagrantBox does not declare 'provides :vagrant_box'.
[2015-07-02T15:27:34-07:00] WARN: This will no longer work in Chef 13: you must use 'provides' to provide DSL.
[2015-07-02T15:27:34-07:00] WARN: Cloning resource attributes for vagrant_box[sles11sp3] from prior resource (CHEF-3694)
[2015-07-02T15:27:34-07:00] WARN: Previous vagrant_box[sles11sp3]: /Users/dtumkursreeni/.rbenv/versions/2.1.3/lib/ruby/gems/2.1.0/gems/chef-12.4.0.rc.0/lib/chef/dsl/recipe.rb:77:in `method_missing'
[2015-07-02T15:27:34-07:00] WARN: Current vagrant_box[sles11sp3]: /Users/dtumkursreeni/Tryitspossible/chef-provisioning/docs/examples/vagrant_linux.rb:3:in `from_file'
[2015-07-02T15:27:34-07:00] WARN: Node dtumkursreeni has an empty run list.
Converging 2 resources
Recipe: @recipe_files::/Users/dtumkursreeni/Tryitspossible/chef-provisioning/docs/examples/vagrant_linux.rb
* vagrant_box[sles11sp3] action create[2015-07-02T15:27:34-07:00] INFO: Processing vagrant_box[sles11sp3] action create (@recipe_files::/Users/dtumkursreeni/Tryitspossible/chef-provisioning/docs/examples/vagrant_linux.rb line 77)
[2015-07-02T15:27:34-07:00] WARN: Class Chef::Provider::VagrantBox does not declare 'provides :vagrant_box'.
[2015-07-02T15:27:34-07:00] WARN: This will no longer work in Chef 13: you must use 'provides' to provide DSL.
(up to date)
* vagrant_box[sles11sp3] action create[2015-07-02T15:27:35-07:00] INFO: Processing vagrant_box[sles11sp3] action create (@recipe_files::/Users/dtumkursreeni/Tryitspossible/chef-provisioning/docs/examples/vagrant_linux.rb line 3)
[2015-07-02T15:27:35-07:00] WARN: Class Chef::Provider::VagrantBox does not declare 'provides :vagrant_box'.
[2015-07-02T15:27:35-07:00] WARN: This will no longer work in Chef 13: you must use 'provides' to provide DSL.
(up to date)
[2015-07-02T15:27:36-07:00] INFO: Chef Run complete in 2.487808 seconds
Running handlers:
[2015-07-02T15:27:36-07:00] INFO: Running report handlers
Running handlers complete
[2015-07-02T15:27:36-07:00] INFO: Report handlers complete
Chef Client finished, 0/2 resources updated in 4.515791 seconds
dtumkursreeni-mac:examples dtumkursreeni$ chef-client -z vagrant_linux.rb simple.rb
[2015-07-02T15:27:52-07:00] INFO: Started chef-zero at chefzero://localhost:8889 with repository at /Users/dtumkursreeni/chef
One version per cookbook
[2015-07-02T15:27:52-07:00] INFO: Forking chef instance to converge...
Starting Chef Client, version 12.4.0.rc.0
[2015-07-02T15:27:52-07:00] INFO: *** Chef 12.4.0.rc.0 ***
[2015-07-02T15:27:52-07:00] INFO: Chef-client pid: 54533
[2015-07-02T15:27:54-07:00] INFO: Run List is []
[2015-07-02T15:27:54-07:00] INFO: Run List expands to []
[2015-07-02T15:27:54-07:00] INFO: Starting Chef Run for dtumkursreeni
[2015-07-02T15:27:54-07:00] INFO: Running start handlers
[2015-07-02T15:27:54-07:00] INFO: Start handlers complete.
[2015-07-02T15:27:54-07:00] INFO: HTTP Request Returned 404 Not Found: Object not found:
resolving cookbooks for run list: []
[2015-07-02T15:27:54-07:00] INFO: Loading cookbooks []
Synchronizing Cookbooks:
Compiling Cookbooks...
[2015-07-02T15:27:54-07:00] WARN: Class Chef::Resource::VagrantBox does not declare 'provides :vagrant_box'.
[2015-07-02T15:27:54-07:00] WARN: This will no longer work in Chef 13: you must use 'provides' to provide DSL.
[2015-07-02T15:27:54-07:00] WARN: Chef::Resource::VagrantBox is marked as providing DSL vagrant_box, but provides :vagrant_box was never called!
[2015-07-02T15:27:54-07:00] WARN: In Chef 13, this will break: you must call provides to mark the names you provide, even if you also override provides? yourself.
[2015-07-02T15:27:54-07:00] WARN: Class Chef::Resource::VagrantBox does not declare 'provides :vagrant_box'.
[2015-07-02T15:27:54-07:00] WARN: This will no longer work in Chef 13: you must use 'provides' to provide DSL.
[2015-07-02T15:27:54-07:00] WARN: Class Chef::Resource::Machine does not declare 'provides :machine'.
[2015-07-02T15:27:54-07:00] WARN: This will no longer work in Chef 13: you must use 'provides' to provide DSL.
[2015-07-02T15:27:54-07:00] WARN: Chef::Resource::Machine is marked as providing DSL machine, but provides :machine was never called!
[2015-07-02T15:27:54-07:00] WARN: In Chef 13, this will break: you must call provides to mark the names you provide, even if you also override provides? yourself.
[2015-07-02T15:27:54-07:00] WARN: Class Chef::Resource::Machine does not declare 'provides :machine'.
[2015-07-02T15:27:54-07:00] WARN: This will no longer work in Chef 13: you must use 'provides' to provide DSL.
[2015-07-02T15:27:54-07:00] WARN: Node dtumkursreeni has an empty run list.
Converging 2 resources
Recipe: @recipe_files::/Users/dtumkursreeni/Tryitspossible/chef-provisioning/docs/examples/vagrant_linux.rb
* vagrant_box[sles11sp3] action create[2015-07-02T15:27:54-07:00] INFO: Processing vagrant_box[sles11sp3] action create (@recipe_files::/Users/dtumkursreeni/Tryitspossible/chef-provisioning/docs/examples/vagrant_linux.rb line 77)
[2015-07-02T15:27:54-07:00] WARN: Class Chef::Provider::VagrantBox does not declare 'provides :vagrant_box'.
[2015-07-02T15:27:54-07:00] WARN: This will no longer work in Chef 13: you must use 'provides' to provide DSL.
(up to date)
Recipe: @recipe_files::/Users/dtumkursreeni/Tryitspossible/chef-provisioning/docs/examples/simple.rb
* machine[Test] action converge[2015-07-02T15:27:55-07:00] INFO: Processing machine[Test] action converge (@recipe_files::/Users/dtumkursreeni/Tryitspossible/chef-provisioning/docs/examples/simple.rb line 77)
[2015-07-02T15:27:55-07:00] WARN: Class Chef::Provider::Machine does not declare 'provides :machine'.
[2015-07-02T15:27:55-07:00] WARN: This will no longer work in Chef 13: you must use 'provides' to provide DSL.
[2015-07-02T15:27:55-07:00] INFO: HTTP Request Returned 404 Not Found: Object not found: chefzero://localhost:8889/nodes/Test
[2015-07-02T15:27:55-07:00] WARN: Class Chef::Resource::VagrantCluster does not declare 'provides :vagrant_cluster'.
[2015-07-02T15:27:55-07:00] WARN: This will no longer work in Chef 13: you must use 'provides' to provide DSL.
[2015-07-02T15:27:55-07:00] WARN: Chef::Resource::VagrantCluster is marked as providing DSL vagrant_cluster, but provides :vagrant_cluster was never called!
[2015-07-02T15:27:55-07:00] WARN: In Chef 13, this will break: you must call provides to mark the names you provide, even if you also override provides? yourself.
[2015-07-02T15:27:55-07:00] WARN: Class Chef::Resource::VagrantCluster does not declare 'provides :vagrant_cluster'.
[2015-07-02T15:27:55-07:00] WARN: This will no longer work in Chef 13: you must use 'provides' to provide DSL.
[2015-07-02T15:27:55-07:00] INFO: Processing vagrant_cluster[/Users/dtumkursreeni/.chef/vms] action create (basic_chef_client::block line 77)
[2015-07-02T15:27:55-07:00] WARN: Class Chef::Provider::VagrantCluster does not declare 'provides :vagrant_cluster'.
[2015-07-02T15:27:55-07:00] WARN: This will no longer work in Chef 13: you must use 'provides' to provide DSL.
[2015-07-02T15:27:55-07:00] INFO: Processing directory[/Users/dtumkursreeni/.chef/vms] action create (basic_chef_client::block line 15)
[2015-07-02T15:27:55-07:00] INFO: Processing file[/Users/dtumkursreeni/.chef/vms/Vagrantfile] action create (basic_chef_client::block line 16)
[2015-07-02T15:27:55-07:00] INFO: Processing file[/Users/dtumkursreeni/.chef/vms/Test.vm] action create (basic_chef_client::block line 232)
[2015-07-02T15:27:55-07:00] INFO: file[/Users/dtumkursreeni/.chef/vms/Test.vm] created file /Users/dtumkursreeni/.chef/vms/Test.vm
- create new file /Users/dtumkursreeni/.chef/vms/Test.vm[2015-07-02T15:27:55-07:00] INFO: file[/Users/dtumkursreeni/.chef/vms/Test.vm] updated file contents /Users/dtumkursreeni/.chef/vms/Test.vm
- update content in file /Users/dtumkursreeni/.chef/vms/Test.vm from none to 36cb7c
- --- /Users/dtumkursreeni/.chef/vms/Test.vm 2015-07-02 15:27:55.000000000 -0700
- +++ /Users/dtumkursreeni/.chef/vms/.Test.vm20150702-54533-fnkcn1 2015-07-02 15:27:55.000000000 -0700
- @@ -1 +1,9 @@
- +Vagrant.configure('2') do |outer_config|
- + outer_config.vm.define "Test" do |config|
- + config.vm.box = "sles11sp3"
- + config.vm.box_url = "http://jenkins-hzn.eng.vmware.com/tools/vagrant/sles11sp3.box"
- + config.vm.hostname = "default-sles11sp3.vagrantup.com"
- + config.vm.synced_folder ".", "/vagrant", disabled: true
- + end
- +end[2015-07-02T15:27:55-07:00] WARN: Class Chef::Resource::ChefNode does not declare 'provides :chef_node'.
[2015-07-02T15:27:55-07:00] WARN: This will no longer work in Chef 13: you must use 'provides' to provide DSL.
[2015-07-02T15:27:55-07:00] WARN: Chef::Resource::ChefNode is marked as providing DSL chef_node, but provides :chef_node was never called!
[2015-07-02T15:27:55-07:00] WARN: In Chef 13, this will break: you must call provides to mark the names you provide, even if you also override provides? yourself.
[2015-07-02T15:27:55-07:00] WARN: Class Chef::Resource::ChefNode does not declare 'provides :chef_node'.
[2015-07-02T15:27:55-07:00] WARN: This will no longer work in Chef 13: you must use 'provides' to provide DSL.
[2015-07-02T15:27:55-07:00] INFO: Processing chef_node[Test] action create (basic_chef_client::block line 77)
[2015-07-02T15:27:55-07:00] WARN: Class Chef::Provider::ChefNode does not declare 'provides :chef_node'.
[2015-07-02T15:27:55-07:00] WARN: This will no longer work in Chef 13: you must use 'provides' to provide DSL.
[2015-07-02T15:27:55-07:00] INFO: HTTP Request Returned 404 Not Found: Object not found: chefzero://localhost:8889/nodes/Test
- create node Test at chefzero://localhost:8889
- add normal.tags = ["itsa_me"]
- add normal.chef_provisioning = {"reference"=>{"driver_url"=>"vagrant:/Users/dtumkursreeni/.chef/vms", "driver_version"=>"0.8.3", "vm_name"=>"Test", "vm_file_path"=>"/Users/dtumkursreeni/.chef/vms/Test.vm", "allocated_at"=>"2015-07-02 22:27:55 UTC", "host_node"=>"chefzero://localhost:8889/nodes/", "needs_reload"=>true}}
- run vagrant up Test (status was 'not created')[2015-07-02T15:28:58-07:00] WARN: Class Chef::Resource::ChefNode does not declare 'provides :chef_node'.
[2015-07-02T15:28:58-07:00] WARN: This will no longer work in Chef 13: you must use 'provides' to provide DSL.
[2015-07-02T15:28:58-07:00] INFO: Processing chef_node[Test] action create (basic_chef_client::block line 57)
[2015-07-02T15:28:58-07:00] WARN: Class Chef::Provider::ChefNode does not declare 'provides :chef_node'.
[2015-07-02T15:28:58-07:00] WARN: This will no longer work in Chef 13: you must use 'provides' to provide DSL.
- update node Test at chefzero://localhost:8889
- update normal.chef_provisioning.reference.needs_reload from true to false
- add normal.chef_provisioning.reference.forwarded_ports = {"22"=>"2222"}[2015-07-02T15:28:58-07:00] INFO: Executing sudo cp /etc/chef/client.pem /tmp/client.pem.1180258582 on vagrant@172.16.127.172
[2015-07-02T15:28:59-07:00] INFO: Completed cp /etc/chef/client.pem /tmp/client.pem.1180258582 on vagrant@172.16.127.172: exit status 1
[2015-07-02T15:28:59-07:00] ERROR: Unable to download /etc/chef/client.pem to /tmp/client.pem.1180258582 on vagrant@172.16.127.172 -- Error: command 'cp /etc/chef/client.pem /tmp/client.pem.1180258582' exited with code 1.
[2015-07-02T15:28:59-07:00] INFO: Executing sudo rm /tmp/client.pem.1180258582 on vagrant@172.16.127.172
[2015-07-02T15:28:59-07:00] INFO: Completed rm /tmp/client.pem.1180258582 on vagrant@172.16.127.172: exit status 1
[2015-07-02T15:28:59-07:00] WARN: Unable to clean up /tmp/client.pem.1180258582 on vagrant@172.16.127.172 -- Error: command 'rm /tmp/client.pem.1180258582' exited with code 1.
[2015-07-02T15:28:59-07:00] WARN: Class Chef::Resource::PrivateKey does not declare 'provides :private_key'.
[2015-07-02T15:28:59-07:00] WARN: This will no longer work in Chef 13: you must use 'provides' to provide DSL.
[2015-07-02T15:28:59-07:00] WARN: Chef::Resource::PrivateKey is marked as providing DSL private_key, but provides :private_key was never called!
[2015-07-02T15:28:59-07:00] WARN: In Chef 13, this will break: you must call provides to mark the names you provide, even if you also override provides? yourself.
[2015-07-02T15:28:59-07:00] WARN: Class Chef::Resource::PrivateKey does not declare 'provides :private_key'.
[2015-07-02T15:28:59-07:00] WARN: This will no longer work in Chef 13: you must use 'provides' to provide DSL.
[2015-07-02T15:28:59-07:00] INFO: Processing private_key[in_memory] action create (basic_chef_client::block line 77)
[2015-07-02T15:28:59-07:00] WARN: Class Chef::Provider::PrivateKey does not declare 'provides :private_key'.
[2015-07-02T15:28:59-07:00] WARN: This will no longer work in Chef 13: you must use 'provides' to provide DSL.
- generate private key (2048 bits)[2015-07-02T15:28:59-07:00] INFO: Executing sudo ls -d /etc/chef/client.pem on vagrant@172.16.127.172
[2015-07-02T15:28:59-07:00] INFO: Completed ls -d /etc/chef/client.pem on vagrant@172.16.127.172: exit status 2
[2015-07-02T15:28:59-07:00] INFO: Executing sudo ls -d /etc/chef on vagrant@172.16.127.172
[2015-07-02T15:28:59-07:00] INFO: Completed ls -d /etc/chef on vagrant@172.16.127.172: exit status 2
[2015-07-02T15:28:59-07:00] INFO: Executing sudo mkdir -p /etc/chef on vagrant@172.16.127.172
[2015-07-02T15:28:59-07:00] INFO: Completed mkdir -p /etc/chef on vagrant@172.16.127.172: exit status 0
- create directory /etc/chef on Test[2015-07-02T15:28:59-07:00] INFO: Executing sudo mkdir -p /etc/chef on vagrant@172.16.127.172
[2015-07-02T15:28:59-07:00] INFO: Completed mkdir -p /etc/chef on vagrant@172.16.127.172: exit status 0
[2015-07-02T15:28:59-07:00] INFO: Executing sudo mv /tmp/client.pem.250111036 /etc/chef/client.pem on vagrant@172.16.127.172
[2015-07-02T15:28:59-07:00] INFO: Completed mv /tmp/client.pem.250111036 /etc/chef/client.pem on vagrant@172.16.127.172: exit status 0
- write file /etc/chef/client.pem on Test[2015-07-02T15:28:59-07:00] WARN: Class Chef::Resource::ChefClient does not declare 'provides :chef_client'.
[2015-07-02T15:28:59-07:00] WARN: This will no longer work in Chef 13: you must use 'provides' to provide DSL.
[2015-07-02T15:28:59-07:00] WARN: Chef::Resource::ChefClient is marked as providing DSL chef_client, but provides :chef_client was never called!
[2015-07-02T15:28:59-07:00] WARN: In Chef 13, this will break: you must call provides to mark the names you provide, even if you also override provides? yourself.
[2015-07-02T15:28:59-07:00] WARN: Class Chef::Resource::ChefClient does not declare 'provides :chef_client'.
[2015-07-02T15:28:59-07:00] WARN: This will no longer work in Chef 13: you must use 'provides' to provide DSL.
[2015-07-02T15:28:59-07:00] WARN: Class Chef::Resource::ChefNode does not declare 'provides :chef_node'.
[2015-07-02T15:28:59-07:00] WARN: This will no longer work in Chef 13: you must use 'provides' to provide DSL.
[2015-07-02T15:28:59-07:00] INFO: Processing chef_client[Test] action create (basic_chef_client::block line 77)
[2015-07-02T15:28:59-07:00] WARN: Class Chef::Provider::ChefClient does not declare 'provides :chef_client'.
[2015-07-02T15:28:59-07:00] WARN: This will no longer work in Chef 13: you must use 'provides' to provide DSL.
[2015-07-02T15:28:59-07:00] INFO: HTTP Request Returned 404 Not Found: Object not found: chefzero://localhost:8889/clients/Test
- create client Test at clients
- add public_key = "-----BEGIN PUBLIC KEY-----\nMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAyWlRqS4S8E0fU1w0lRXs\nQRcCm5Ayn5ZFrn7Q3lQGd8RJ5e2a8ddi32F6H9dt4QnBTf+zxoGq/Y8xnHnj5udV\nbCTVwggkvBxW1mmtufbcBVD+bdIH1QaSSq3cvlN/tkBLjsNLxdF8HsJ5WDER/Ek+\napAXXATyxUyDM/9KptlcX3Gwv8LFyog5+0iUM0u9qdDlAh/wqFOYDA9nJQ82g3ej\ndB5Mld54AFAIPnUIl0WMFy6kd70LVAJfyGCkGAnqszK+aj0z+QMHDlU9kBYK60Do\nlZciA8iNsSRIQbny80h7/FZ95CDs+npptDaVYcoZ0q/vn/iIpn3BI4vagaNKdRF7\nGwIDAQAB\n-----END PUBLIC KEY-----\n"[2015-07-02T15:28:59-07:00] INFO: Processing chef_node[Test] action create (basic_chef_client::block line 143)
[2015-07-02T15:28:59-07:00] WARN: Class Chef::Provider::ChefNode does not declare 'provides :chef_node'.
[2015-07-02T15:28:59-07:00] WARN: This will no longer work in Chef 13: you must use 'provides' to provide DSL.
================================================================================
Error executing action `converge` on resource 'machine[Test]'
================================================================================
RuntimeError
------------
Error forwarding port: could not forward 8889 or 0
Resource Declaration:
---------------------
# In /Users/dtumkursreeni/.rbenv/versions/2.1.3/lib/ruby/gems/2.1.0/gems/chef-12.4.0.rc.0/lib/chef/dsl/recipe.rb
77: return send(method_symbol, *args, &block)
78: end
Compiled Resource:
------------------
# Declared in /Users/dtumkursreeni/.rbenv/versions/2.1.3/lib/ruby/gems/2.1.0/gems/chef-12.4.0.rc.0/lib/chef/dsl/recipe.rb:77:in `method_missing'
machine("Test") do
action [:converge]
retries 0
retry_delay 2
default_guard_interpreter :default
chef_server {:chef_server_url=>"chefzero://localhost:8889", :options=>{:client_name=>"dtumkursreeni", :signing_key_filename=>"/Users/dtumkursreeni/.chef/dtumkursreeni.pem"}}
driver "vagrant"
machine_options {:vagrant_config=>" config.vm.synced_folder \".\", \"/vagrant\", disabled: true\n", :vagrant_options=>{"vm.box"=>"sles11sp3", "vm.box_url"=>"http://jenkins-hzn.eng.vmware.com/tools/vagrant/sles11sp3.box", "vm.hostname"=>"default-sles11sp3.vagrantup.com"}}
declared_type :machine
cookbook_name "@recipe_files"
recipe_name "/Users/dtumkursreeni/Tryitspossible/chef-provisioning/docs/examples/simple.rb"
attribute_modifiers [["tags", #<Proc:0x007f8342ad7510@/Users/dtumkursreeni/.rbenv/versions/2.1.3/lib/ruby/gems/2.1.0/gems/cheffish-1.2/lib/cheffish.rb:149>]]
converge true
end
[2015-07-02T15:29:00-07:00] INFO: Running queued delayed notifications before re-raising exception
Running handlers:
[2015-07-02T15:29:00-07:00] ERROR: Running exception handlers
Running handlers complete
[2015-07-02T15:29:00-07:00] ERROR: Exception handlers complete
[2015-07-02T15:29:00-07:00] FATAL: Stacktrace dumped to /Users/dtumkursreeni/.chef/local-mode-cache/cache/chef-stacktrace.out
Chef Client failed. 0 resources updated in 67.978502 seconds
[2015-07-02T15:29:00-07:00] ERROR: machine[Test] (@recipe_files::/Users/dtumkursreeni/Tryitspossible/chef-provisioning/docs/examples/simple.rb line 77) had an error: RuntimeError: Error forwarding port: could not forward 8889 or 0
[2015-07-02T15:29:00-07:00] FATAL: Chef::Exceptions::ChildConvergeError: Chef run process exited unsuccessfully (exit code 1)
dtumkursreeni-mac:examples dtumkursreeni$
Okay, this looks like a valid issue now - its an error forwarding the port. Can you include the output of /Users/dtumkursreeni/.chef/local-mode-cache/cache/chef-stacktrace.out as a gist so we can see the stacktrace? Do you know if there is a configuration on your workstation that would prevent forwarding 8889
from your vagrant instance to your workstation? Does SLES have some kind of firewalling or port restrction turned on by default? What happens if you try to use precise64
instead of SLES?
Hey @tyler-ball , Now, I am trying with VSphere as provider; I have hit with the same error (unfortunately). can you please, tell us why it is forwarding the port?
This is my config file: https://gist.github.com/DarshanMurthy/c4227990c45eacd8c398
Here's log: https://gist.github.com/DarshanMurthy/c0d61b883bf482ba35e6#file-log. Thanks, Darshan
@tyler-ball see #392 for a stacktrace.
@DarshanMurthy - I think you managed to get my blog example on vagrant working with a ubuntu VM? If so it is more likely something about the network or the client VM's setup than your workstation. Are you using the same client VM in both the vagrant and vsphere cases? As tyler said above, is there anything about their setup which could be restricting ports?
@christinedraper : I followed your blog with this config file(https://gist.github.com/DarshanMurthy/38e1516fe003f0c78d7e)
Yes I'm using same client VM
Nothing restrictions as such we tested all the way to prevent firewall issues.
I'm running into the same error on a centos 7 box with chef server running locally. I think it has something to do with services already listening on those ports. It might be possible to have chef-provisioning check to see what other ports are available if it can't create on on 443 for example.
@hh is this the error: Error forwarding port: could not forward 8889 or 0 ?
I have a stanza like this where the chef server is actually running on this box:
with_chef_server 'https://chef.customer.com/organizations/customer',
:client_name => Chef::Config[:node_name],
:signing_key_filename => Chef::Config[:client_key]
machine 'foo'
The code has worked fine before on boxes that are not also running chef-server 12
The stacktrace:
RuntimeError: machine[admin-2015-07-22-1] (@recipe_files::/home/prov/customer/code/provisioning/sync_server.rb line 77) had an error: RuntimeError: Error forwarding port: could not forward 443 or 0
/opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-provisioning-1.1.1/lib/chef/provisioning/transport/ssh.rb:147:in `make_url_available_to_remote'
/opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-provisioning-1.1.1/lib/chef/provisioning/machine/basic_machine.rb:75:in `make_url_available_to_remote'
/opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-provisioning-1.1.1/lib/chef/provisioning/convergence_strategy/precreate_chef_objects.rb:22:in `setup_convergence'
/opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-provisioning-1.1.1/lib/chef/provisioning/convergence_strategy/install_sh.rb:40:in `setup_convergence'
/opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-provisioning-1.1.1/lib/chef/provisioning/machine/basic_machine.rb:17:in `setup_convergence'
/opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-provisioning-1.1.1/lib/chef/provider/machine.rb:57:in `block in <class:Machine>'
/opt/chefdk/embedded/apps/chef/lib/chef/provider/lwrp_base.rb:60:in `instance_eval'
/opt/chefdk/embedded/apps/chef/lib/chef/provider/lwrp_base.rb:60:in `recipe_eval_with_update_check'
/opt/chefdk/embedded/apps/chef/lib/chef/provider/lwrp_base.rb:45:in `block in action'
/opt/chefdk/embedded/apps/chef/lib/chef/provider.rb:130:in `run_action'
/opt/chefdk/embedded/apps/chef/lib/chef/resource.rb:562:in `run_action'
/opt/chefdk/embedded/apps/chef/lib/chef/runner.rb:49:in `run_action'
/opt/chefdk/embedded/apps/chef/lib/chef/runner.rb:81:in `block (2 levels) in converge'
/opt/chefdk/embedded/apps/chef/lib/chef/runner.rb:81:in `each'
/opt/chefdk/embedded/apps/chef/lib/chef/runner.rb:81:in `block in converge'
/opt/chefdk/embedded/apps/chef/lib/chef/resource_collection/resource_list.rb:83:in `block in execute_each_resource'
/opt/chefdk/embedded/apps/chef/lib/chef/resource_collection/stepable_iterator.rb:116:in `call'
/opt/chefdk/embedded/apps/chef/lib/chef/resource_collection/stepable_iterator.rb:116:in `call_iterator_block'
/opt/chefdk/embedded/apps/chef/lib/chef/resource_collection/stepable_iterator.rb:85:in `step'
/opt/chefdk/embedded/apps/chef/lib/chef/resource_collection/stepable_iterator.rb:104:in `iterate'
/opt/chefdk/embedded/apps/chef/lib/chef/resource_collection/stepable_iterator.rb:55:in `each_with_index'
/opt/chefdk/embedded/apps/chef/lib/chef/resource_collection/resource_list.rb:81:in `execute_each_resource'
/opt/chefdk/embedded/apps/chef/lib/chef/runner.rb:80:in `converge'
/opt/chefdk/embedded/apps/chef/lib/chef/client.rb:339:in `block in converge'
/opt/chefdk/embedded/apps/chef/lib/chef/client.rb:334:in `catch'
/opt/chefdk/embedded/apps/chef/lib/chef/client.rb:334:in `converge'
/opt/chefdk/embedded/apps/chef/lib/chef/client.rb:353:in `converge_and_save'
/opt/chefdk/embedded/apps/chef/lib/chef/client.rb:457:in `run'
/opt/chefdk/embedded/apps/chef/lib/chef/application.rb:271:in `block in fork_chef_client'
/opt/chefdk/embedded/apps/chef/lib/chef/application.rb:259:in `fork'
/opt/chefdk/embedded/apps/chef/lib/chef/application.rb:259:in `fork_chef_client'
/opt/chefdk/embedded/apps/chef/lib/chef/application.rb:225:in `block in run_chef_client'
/opt/chefdk/embedded/apps/chef/lib/chef/local_mode.rb:39:in `with_server_connectivity'
/opt/chefdk/embedded/apps/chef/lib/chef/application.rb:213:in `run_chef_client'
/opt/chefdk/embedded/apps/chef/lib/chef/application/client.rb:402:in `block in interval_run_chef_client'
/opt/chefdk/embedded/apps/chef/lib/chef/application/client.rb:392:in `loop'
/opt/chefdk/embedded/apps/chef/lib/chef/application/client.rb:392:in `interval_run_chef_client'
/opt/chefdk/embedded/apps/chef/lib/chef/application/client.rb:382:in `run_application'
/opt/chefdk/embedded/apps/chef/lib/chef/application.rb:60:in `run'
/opt/chefdk/embedded/apps/chef/bin/chef-client:26:in `<top (required)>'
/usr/bin/chef-client:51:in `load'
I have been facing similar problem :( .... I didnt find solution or work around.
btw why dont you try chef-zero server? (for others it is working)
machine "Test17" do chef_server( :chef_server_url => 'http://MAC_OS_IP:8889') # explicitly specify the chef server url in chef_vsphere_config.rb. The IP is the server where you run 'chef-client -z chef_vsphere_config.rb' run_list [''] end
@hh Can you try with version 1.2 of chef-provisioning and see if you get the same error? Looking at the code though, I'm guessing that won't fix it.d
Running chef-client on the same machine thats running the Chef Server shouldn't be an issue... It is the provisioned machine that is having its ports forwarded so it can communicate with the chef server. My guess is that the is_local_machine
is succeeding on the chef.customer.com
host, but when it tries to forward 443
on the provisioned machine that fails because it is a port less than 1000. Can you try updating your with_chef_server
url to include the real port the chef service is running on? I would be curious to see if that still fails.
When the chef server is not the same machine as the provisioning node, then the is_local_machine
check fails and no port-forwarding is attempted. We could also make that forwarding toggleable, or make it only look for localhost
or 127.0.0.1
Hey @DarshanMurthy its been a while since we heard from you - I'm going to close this but please re-open or file a new issue if you want to continue troubleshooting!
I think for me this had to do with running the chef-client (running the chef-provisioning machine resource) on the chef-server itself. I have since moved to a provisioning that was not running on the chef server itself and the issue went away.
Hi All,
I am new to CHEF. I just tried using the examples in CHEF Provisioning library. Steps I followed: Step 1: Cloned the Git code (https://github.com/chef/chef-provisioning.git) Step 2: gem install chef-provisioning chef-provisioning-vagrant Step 3: export CHEF_DRIVER=vagrant
Step 4: export VAGRANT_DEFAULT_PROVIDER=virtualbox Step 5: chef-client -z vagrant_linux.rb simple.rb
I am getting bellow attached error.
Please, help
Thanks, Darshan