[chef] Re: how to deal with the download error and retry


Chronological Thread 
  • From: Daniel DeLeo < >
  • To:
  • Subject: [chef] Re: how to deal with the download error and retry
  • Date: Fri, 27 Sep 2013 10:30:02 -0700

If the issue is a flaky upstream, you can configure a resource to retry on failure: http://docs.opscode.com/resource_common.html

-- 
Daniel DeLeo

On Friday, September 27, 2013 at 9:26 AM, Sam Su wrote:

Hi,

I am running an openstack cookbooks, however the chef-client cannot run very smoothly most of the time. some error information as below comes out when running the cookbook:
Recipe: openstack-network::openvswitch
  * service[quantum-server] action restart
    - restart service service[quantum-server]

  * service[quantum-plugin-openvswitch-agent] action restart
    * service[quantum-plugin-openvswitch-agent]: unable to locate the init.d script!
================================================================================
Error executing action `restart` on resource 'service[quantum-plugin-openvswitch-agent]'
================================================================================


Chef::Exceptions::Service
-------------------------
service[quantum-plugin-openvswitch-agent]: unable to locate the init.d script!


The log information is listed as follows:
* Chef::Exceptions::Exec occurred in chef run: package[openstack-nova-console] (openstack-compute::vncproxy line 35) had an error: Chef::Exceptions::Exec:  returned 1, expected 0
---- Begin output of  ----
STDOUT: STDERR:

Error Downloading Packages:
  openstack-nova-console-2013.1.3-2.el6.noarch: failure: openstack-nova-console-2013.1.3-2.el6.noarch.rpm from openstack: [Errno 256] No more mirrors to try.

---- End output of  ----
* Chef::Exceptions::Service occurred in delayed notification: service[nova-console] (openstack-compute::vncproxy line 50) had an error: Chef::Exceptions::Service: service[nova-console]: unable to locate the init.d script!
* Chef::Exceptions::Service occurred in delayed notification: service[nova-consoleauth] (openstack-compute::vncproxy line 57) had an error: Chef::Exceptions::Service: service[nova-consoleauth]: unable to locate the init.d script!


From the above log file, the chef client sometimes cannot download the specific package successfully, then the cookbooks failed.

I am wondering what is the best way to handle this situation in the chef world. 
If someone can give me some hints, it will be much appreciated.

Thanks,
Sam








Archive powered by MHonArc 2.6.16.

§