Giter Site home page Giter Site logo

Installation fails with ERROR: service[consul] (consul::_service line 112) had an error: Chef::Exceptions::Service: service[consul]: unable to locate the init.d script! about consul HOT 4 CLOSED

sous-chefs avatar sous-chefs commented on May 28, 2024
Installation fails with ERROR: service[consul] (consul::_service line 112) had an error: Chef::Exceptions::Service: service[consul]: unable to locate the init.d script!

from consul.

Comments (4)

brandocorp avatar brandocorp commented on May 28, 2024

I also just ran into this issue on CenOS 6.5. Here are my Vagrant logs:

==> bootstrap: Chef 11.14.6 Omnibus package is already installed.
==> bootstrap: Running provisioner: chef_solo...
Generating chef JSON and uploading...
==> bootstrap: Running chef-solo...
==> bootstrap: [2014-08-20T19:11:47+00:00] INFO: Forking chef instance to converge...
==> bootstrap: [2014-08-20T19:11:47+00:00] WARN:
==> bootstrap: * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
==> bootstrap: SSL validation of HTTPS requests is disabled. HTTPS connections are still
==> bootstrap: encrypted, but chef is not able to detect forged replies or man in the middle
==> bootstrap: attacks.
==> bootstrap:
==> bootstrap: To fix this issue add an entry like this to your configuration file:
==> bootstrap:
==> bootstrap: ```
==> bootstrap:   # Verify all HTTPS connections (recommended)
==> bootstrap:   ssl_verify_mode :verify_peer
==> bootstrap:
==> bootstrap:   # OR, Verify only connections to chef-server
==> bootstrap:   verify_api_cert true
==> bootstrap: ```
==> bootstrap:
==> bootstrap: To check your SSL configuration, or troubleshoot errors, you can use the
==> bootstrap: `knife ssl check` command like so:
==> bootstrap:
==> bootstrap: ```
==> bootstrap:   knife ssl check -c /tmp/vagrant-chef-3/solo.rb
==> bootstrap: ```
==> bootstrap:
==> bootstrap: * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
==> bootstrap: [2014-08-20T19:11:47+00:00] INFO: *** Chef 11.14.6 ***
==> bootstrap: [2014-08-20T19:11:47+00:00] INFO: Chef-client pid: 4266
==> bootstrap: [2014-08-20T19:11:54+00:00] INFO: Setting the run_list to ["recipe[consul::default]", "recipe[consul::ui]"] from CLI options
==> bootstrap: [2014-08-20T19:11:54+00:00] INFO: Run List is [recipe[consul::default], recipe[consul::ui]]
==> bootstrap: [2014-08-20T19:11:54+00:00] INFO: Run List expands to [consul::default, consul::ui]
==> bootstrap: [2014-08-20T19:11:54+00:00] INFO: Starting Chef Run for localhost
==> bootstrap: [2014-08-20T19:11:54+00:00] INFO: Running start handlers
==> bootstrap: [2014-08-20T19:11:54+00:00] INFO: Start handlers complete.
==> bootstrap: [2014-08-20T19:12:09+00:00] INFO: remote_file[/var/chef/cache/consul.zip] backed up to /var/chef/backup/var/chef/cache/consul.zip.chef-20140820191209.776259
==> bootstrap: [2014-08-20T19:12:09+00:00] INFO: remote_file[/var/chef/cache/consul.zip] updated file contents /var/chef/cache/consul.zip
==> bootstrap: [2014-08-20T19:12:10+00:00] INFO: remote_file[/var/chef/cache/consul.zip] sending run action to execute[unpack /var/chef/cache/consul.zip] (delayed)
==> bootstrap: [2014-08-20T19:12:10+00:00] INFO: execute[unpack /var/chef/cache/consul.zip] ran successfully
==> bootstrap: [2014-08-20T19:12:10+00:00] INFO: execute[unpack /var/chef/cache/consul.zip] sending run action to execute[set owner on /usr/local/bin] (delayed)
==> bootstrap: [2014-08-20T19:12:10+00:00] INFO: execute[set owner on /usr/local/bin] ran successfully
==> bootstrap: [2014-08-20T19:12:10+00:00] INFO: file[/usr/local/bin/consul] updated atime and mtime to 2014-08-20 19:12:10 +0000
==> bootstrap: [2014-08-20T19:12:10+00:00] INFO: directory[/etc/consul.d] created directory /etc/consul.d
==> bootstrap: [2014-08-20T19:12:10+00:00] INFO: directory[/etc/consul.d] owner changed to 0
==> bootstrap: [2014-08-20T19:12:10+00:00] INFO: directory[/etc/consul.d] group changed to 0
==> bootstrap: [2014-08-20T19:12:10+00:00] INFO: directory[/etc/consul.d] mode changed to 755
==> bootstrap: [2014-08-20T19:12:10+00:00] INFO: directory[/var/lib/consul] created directory /var/lib/consul
==> bootstrap: [2014-08-20T19:12:10+00:00] INFO: directory[/var/lib/consul] owner changed to 0
==> bootstrap: [2014-08-20T19:12:10+00:00] INFO: directory[/var/lib/consul] group changed to 0
==> bootstrap: [2014-08-20T19:12:10+00:00] INFO: directory[/var/lib/consul] mode changed to 755
==> bootstrap: [2014-08-20T19:12:10+00:00] INFO: file[/etc/consul.d/default.json] created file /etc/consul.d/default.json
==> bootstrap: [2014-08-20T19:12:10+00:00] INFO: file[/etc/consul.d/default.json] updated file contents /etc/consul.d/default.json
==> bootstrap: [2014-08-20T19:12:10+00:00] INFO: file[/etc/consul.d/default.json] owner changed to 0
==> bootstrap: [2014-08-20T19:12:10+00:00] INFO: file[/etc/consul.d/default.json] group changed to 0
==> bootstrap: [2014-08-20T19:12:10+00:00] INFO: file[/etc/consul.d/default.json] mode changed to 600
==> bootstrap: [2014-08-20T19:12:10+00:00] INFO: file[/etc/consul.d/default.json] sending reload action to service[consul] (immediate)
==> bootstrap:
==> bootstrap: ================================================================================
==> bootstrap: Error executing action `reload` on resource 'service[consul]'
==> bootstrap: ================================================================================
==> bootstrap:
==> bootstrap:
==> bootstrap: Chef::Exceptions::Service
==> bootstrap: -------------------------
==> bootstrap: service[consul]: unable to locate the init.d script!
==> bootstrap:
==> bootstrap:
==> bootstrap: Resource Declaration:
==> bootstrap: ---------------------
==> bootstrap: # In /tmp/vagrant-chef-3/chef-solo-1/cookbooks/consul/recipes/_service.rb
==> bootstrap:
==> bootstrap:
==> bootstrap:
==> bootstrap: 112:   service 'consul' do
==> bootstrap:
==> bootstrap: 113:     supports status: true, restart: true, reload: true
==> bootstrap:
==> bootstrap: 114:     action [:enable, :start]
==> bootstrap:
==> bootstrap: 115:     subscribes :reload, "file[#{node[:consul][:config_dir]}/default.json]", :immediately
==> bootstrap: 116:     subscribes :restart, "template[/etc/init.d/consul]", :immediately
==> bootstrap: 117:   end
==> bootstrap: 118: when 'runit'
==> bootstrap:
==> bootstrap: Compiled Resource:
==> bootstrap: ------------------
==> bootstrap: # Declared in /tmp/vagrant-chef-3/chef-solo-1/cookbooks/consul/recipes/_service.rb:112:in `from_file'
==> bootstrap:
==> bootstrap: service("consul") do
==> bootstrap:   action [:enable, :start]
==> bootstrap:   supports {:status=>true, :restart=>true, :reload=>true}
==> bootstrap:   retries 0
==> bootstrap:   retry_delay 2
==> bootstrap:   guard_interpreter :default
==> bootstrap:   service_name "consul"
==> bootstrap:   pattern "consul"
==> bootstrap:   cookbook_name :consul
==> bootstrap:   recipe_name "_service"
==> bootstrap: end
==> bootstrap:
==> bootstrap: [2014-08-20T19:12:10+00:00] INFO: Running queued delayed notifications before re-raising exception
==> bootstrap: [2014-08-20T19:12:10+00:00] ERROR: Running exception handlers
==> bootstrap: [2014-08-20T19:12:10+00:00] ERROR: Exception handlers complete
==> bootstrap: [2014-08-20T19:12:10+00:00] FATAL: Stacktrace dumped to /var/chef/cache/chef-stacktrace.out
==> bootstrap: [2014-08-20T19:12:10+00:00] ERROR: service[consul] (consul::_service line 112) had an error: Chef::Exceptions::Service: service[consul]: unable to locate the init.d script!
==> bootstrap: [2014-08-20T19:12:10+00:00] FATAL: Chef::Exceptions::ChildConvergeError: Chef run process exited unsuccessfully (exit code 1)
Chef never successfully completed! Any errors should be visible in the
output above. Please fix your recipes so that they properly complete.

And the subsequent run was successful because default.json was not modified.

==> bootstrap: Chef 11.14.6 Omnibus package is already installed.
==> bootstrap: Running provisioner: chef_solo...
Generating chef JSON and uploading...
==> bootstrap: Running chef-solo...
==> bootstrap: [2014-08-20T19:20:16+00:00] INFO: Forking chef instance to converge...
==> bootstrap: [2014-08-20T19:20:16+00:00] WARN:
==> bootstrap: * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
==> bootstrap: SSL validation of HTTPS requests is disabled. HTTPS connections are still
==> bootstrap: encrypted, but chef is not able to detect forged replies or man in the middle
==> bootstrap: attacks.
==> bootstrap:
==> bootstrap: To fix this issue add an entry like this to your configuration file:
==> bootstrap:
==> bootstrap: ```
==> bootstrap:   # Verify all HTTPS connections (recommended)
==> bootstrap:   ssl_verify_mode :verify_peer
==> bootstrap:
==> bootstrap:   # OR, Verify only connections to chef-server
==> bootstrap:   verify_api_cert true
==> bootstrap: ```
==> bootstrap:
==> bootstrap: To check your SSL configuration, or troubleshoot errors, you can use the
==> bootstrap: `knife ssl check` command like so:
==> bootstrap:
==> bootstrap: ```
==> bootstrap:   knife ssl check -c /tmp/vagrant-chef-3/solo.rb
==> bootstrap: ```
==> bootstrap:
==> bootstrap: * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
==> bootstrap: [2014-08-20T19:20:16+00:00] INFO: *** Chef 11.14.6 ***
==> bootstrap: [2014-08-20T19:20:16+00:00] INFO: Chef-client pid: 5241
==> bootstrap: [2014-08-20T19:20:23+00:00] INFO: Setting the run_list to ["recipe[consul::default]", "recipe[consul::ui]"] from CLI options
==> bootstrap: [2014-08-20T19:20:23+00:00] INFO: Run List is [recipe[consul::default], recipe[consul::ui]]
==> bootstrap: [2014-08-20T19:20:23+00:00] INFO: Run List expands to [consul::default, consul::ui]
==> bootstrap: [2014-08-20T19:20:23+00:00] INFO: Starting Chef Run for localhost
==> bootstrap: [2014-08-20T19:20:23+00:00] INFO: Running start handlers
==> bootstrap: [2014-08-20T19:20:23+00:00] INFO: Start handlers complete.
==> bootstrap: [2014-08-20T19:20:25+00:00] INFO: file[/usr/local/bin/consul] updated atime and mtime to 2014-08-20 19:20:25 +0000
==> bootstrap: [2014-08-20T19:20:25+00:00] INFO: template[/etc/init.d/consul] created file /etc/init.d/consul
==> bootstrap: [2014-08-20T19:20:25+00:00] INFO: template[/etc/init.d/consul] updated file contents /etc/init.d/consul
==> bootstrap: [2014-08-20T19:20:25+00:00] INFO: template[/etc/init.d/consul] mode changed to 755
==> bootstrap: [2014-08-20T19:20:25+00:00] INFO: template[/etc/init.d/consul] sending restart action to service[consul] (immediate)
==> bootstrap: [2014-08-20T19:20:25+00:00] INFO: service[consul] restarted
==> bootstrap: [2014-08-20T19:20:25+00:00] INFO: service[consul] enabled
==> bootstrap: [2014-08-20T19:20:25+00:00] INFO: directory[/var/lib/consul/ui/] created directory /var/lib/consul/ui/
==> bootstrap: [2014-08-20T19:20:26+00:00] INFO: remote_file[/var/chef/cache/.zip] created file /var/chef/cache/.zip
==> bootstrap: [2014-08-20T19:20:32+00:00] INFO: remote_file[/var/chef/cache/.zip] updated file contents /var/chef/cache/.zip
==> bootstrap: [2014-08-20T19:20:32+00:00] INFO: remote_file[/var/chef/cache/.zip] not queuing delayed action run on execute[unpack /var/chef/cache/.zip] (delayed), as it's already been queued
==> bootstrap: [2014-08-20T19:20:32+00:00] INFO: directory[/var/lib/consul/ui/] sending run action to execute[unpack /var/chef/cache/.zip] (delayed)
==> bootstrap: [2014-08-20T19:20:32+00:00] INFO: execute[unpack /var/chef/cache/.zip] ran successfully
==> bootstrap: [2014-08-20T19:20:32+00:00] INFO: execute[unpack /var/chef/cache/.zip] sending run action to execute[set owner on /var/lib/consul/ui/] (delayed)
==> bootstrap: [2014-08-20T19:20:32+00:00] INFO: execute[set owner on /var/lib/consul/ui/] ran successfully
==> bootstrap: [2014-08-20T19:20:32+00:00] INFO: Chef Run complete in 9.266289617 seconds
==> bootstrap: [2014-08-20T19:20:32+00:00] INFO: Running report handlers
==> bootstrap: [2014-08-20T19:20:32+00:00] INFO: Report handlers complete

from consul.

johnbellone avatar johnbellone commented on May 28, 2024

This fix the issue you were seeing?

from consul.

brandocorp avatar brandocorp commented on May 28, 2024

The default-centos-65 kitchen run worked for me. Thanks!

from consul.

lock avatar lock commented on May 28, 2024

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

from consul.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.