How to deal with the download error and retry

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
*
*
*
*
*
*
*
*

If the issue is a flaky upstream, you can configure a resource to retry on failure: Common Resource Functionality

--
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

Hi Daniel,

That is cool, thank you so much.

BTW, is there any way to change default value of retry times for a specific
resource?

Thanks,
Sam

On Sat, Sep 28, 2013 at 1:30 AM, Daniel DeLeo dan@kallistec.com wrote:

If the issue is a flaky upstream, you can configure a resource to retry
on failure: Common Resource Functionality

--
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
*
*
*
*
*
*
*
*

There’s a retries attribute that all of the built-in resources can use. For this and other common attributes see:

http://docs.opscode.com/resource_common.html

On September 27, 2013 at 7:08:19 PM, Sam Su (sam.debian@gmail.com) wrote:

Hi Daniel,

That is cool, thank you so much.

BTW, is there any way to change default value of retry times for a specific resource?

Thanks,
Sam

On Sat, Sep 28, 2013 at 1:30 AM, Daniel DeLeo dan@kallistec.com wrote:
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

Hi Tim,

Thank you for your help.

Sorry, I don't describe my demand clearly, let me explain a little bit.
Actually I have so many resources with the same situation. As my
understanding, I need to add the "retry times" for each resource code
block, it means a lot of repeat work for me. I try to change a default
"retry" value once but it can be shared by all resources, if that is
possible, it will be great.

Thanks,
Sam

On Sat, Sep 28, 2013 at 7:18 AM, Tim Green tgreen@opscode.com wrote:

There's a retries attribute that all of the built-in resources can use.
For this and other common attributes see:

Common Resource Functionality

On September 27, 2013 at 7:08:19 PM, Sam Su (sam.debian@gmail.com//sam.debian@gmail.com)
wrote:

Hi Daniel,

That is cool, thank you so much.

BTW, is there any way to change default value of retry times for a
specific resource?

Thanks,
Sam

On Sat, Sep 28, 2013 at 1:30 AM, Daniel DeLeo dan@kallistec.com wrote:

If the issue is a flaky upstream, you can configure a resource to retry
on failure: Common Resource Functionality

--
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
*
*
*
*
*
*
*
*

i'll give you a recipe on 30.09.2013
but i'm getting confused that will i give it in english or in roman hindi??

plz give me reply

Shilpa Behera
Cuttack

On Sat, Sep 28, 2013 at 6:25 PM, Sam Su sam.debian@gmail.com wrote:

Hi Tim,

Thank you for your help.

Sorry, I don't describe my demand clearly, let me explain a little bit.
Actually I have so many resources with the same situation. As my
understanding, I need to add the "retry times" for each resource code
block, it means a lot of repeat work for me. I try to change a default
"retry" value once but it can be shared by all resources, if that is
possible, it will be great.

Thanks,
Sam

On Sat, Sep 28, 2013 at 7:18 AM, Tim Green tgreen@opscode.com wrote:

There's a retries attribute that all of the built-in resources can use.
For this and other common attributes see:

Common Resource Functionality

On September 27, 2013 at 7:08:19 PM, Sam Su (sam.debian@gmail.com//sam.debian@gmail.com)
wrote:

Hi Daniel,

That is cool, thank you so much.

BTW, is there any way to change default value of retry times for a
specific resource?

Thanks,
Sam

On Sat, Sep 28, 2013 at 1:30 AM, Daniel DeLeo dan@kallistec.com wrote:

If the issue is a flaky upstream, you can configure a resource to retry
on failure: Common Resource Functionality

--
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
*
*
*
*
*
*
*
*

Hi Shilpa,

Thank you for your timely response.

The link 30.09.2013 looks like a calender not a sharing place for your
recipe, could you tell me how to see your recipe?

Thanks,
Sam

On Sat, Sep 28, 2013 at 9:00 PM, shilpa behera shilpafeb1991@gmail.comwrote:

i'll give you a recipe on 30.09.2013
but i'm getting confused that will i give it in english or in roman hindi??

plz give me reply

Shilpa Behera
Cuttack

On Sat, Sep 28, 2013 at 6:25 PM, Sam Su sam.debian@gmail.com wrote:

Hi Tim,

Thank you for your help.

Sorry, I don't describe my demand clearly, let me explain a little bit.
Actually I have so many resources with the same situation. As my
understanding, I need to add the "retry times" for each resource code
block, it means a lot of repeat work for me. I try to change a default
"retry" value once but it can be shared by all resources, if that is
possible, it will be great.

Thanks,
Sam

On Sat, Sep 28, 2013 at 7:18 AM, Tim Green tgreen@opscode.com wrote:

There's a retries attribute that all of the built-in resources can use.
For this and other common attributes see:

Common Resource Functionality

On September 27, 2013 at 7:08:19 PM, Sam Su (sam.debian@gmail.com//sam.debian@gmail.com)
wrote:

Hi Daniel,

That is cool, thank you so much.

BTW, is there any way to change default value of retry times for a
specific resource?

Thanks,
Sam

On Sat, Sep 28, 2013 at 1:30 AM, Daniel DeLeo dan@kallistec.com wrote:

If the issue is a flaky upstream, you can configure a resource to retry
on failure: Common Resource Functionality

--
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
*
*
*
*
*
*
*
*