I'm using for the first time chef solo for provisioning a Windows box created with Vagrant.

While trying to apply the sql_server cookbook I get the following error:

[2013-11-14T09:41:24+01:00] ERROR: Running exception handlers
[2013-11-14T09:41:24+01:00] ERROR: Exception handlers complete
[2013-11-14T09:41:24+01:00] FATAL: Stacktrace dumped to C:/var/chef/cache/chef-stacktrace.out
[2013-11-14T09:41:24+01:00] FATAL: Chef::Exceptions::RedirectLimitExceeded:
windows_package[Microsoft SQL Server 2008 R2 (32-bit)] (sql_server::server line 39)
had an error: Chef::Exceptions::RedirectLimitExceeded:
remote_file[/var/chef/cache/SQLEXPR32_x86_ENU.exe] (dynamically defined)
had an error: Chef::Exceptions::RedirectLimitExceeded:

Appreciate any advice.


The RedirectLimitExceeded Exception is a result of there being too many DNS redirects between the original URL that remote_file is trying to retrieve and the final URL. I had the same issue and resolved it by changing the origional URL to the URL that it was redirecting to thus eliminating a redirect which got me under the redirect count.

You can see the change that was made here in to resolve the same issue:

-default['openresty']['pcre']['url']      = "http://sourceforge.net/projects/pcre/files/pcre/#{node['openresty']['pcre']['version']}/pcre-#{node['openresty']['pcre']['version']}.tar.bz2/download"
+default['openresty']['pcre']['url']      = "http://downloads.sourceforge.net/project/pcre/pcre/#{node['openresty']['pcre']['version']}/pcre-#{node['openresty']['pcre']['version']}.tar.bz2/download"

You can set it somehow with the redirect_limit var but I've not attempted to do that yet.

Hope this helps...

Edit: Also, you can find out the URL further down the redirection line by doing something like this...

$ wget http://sourceforge.net/projects/adium/files/Adium_1.5.7.dmg/download
    --2014-02-25 19:09:04--  http://sourceforge.net/projects/adium/files/Adium_1.5.7.dmg/download
    Resolving sourceforge.net...
    Connecting to sourceforge.net||:80... connected.
    HTTP request sent, awaiting response... 302 Found
    Location: http://downloads.sourceforge.net/project/adium/Adium_1.5.7.dmg?r=&ts=1393373344&use_mirror=hivelocity [following]
    --2014-02-25 19:09:04--  http://downloads.sourceforge.net/project/adium/Adium_1.5.7.dmg?r=&ts=1393373344&use_mirror=hivelocity
    Resolving downloads.sourceforge.net...
    Connecting to downloads.sourceforge.net||:80... connected.
    HTTP request sent, awaiting response... 302 Found
    Location: http://hivelocity.dl.sourceforge.net/project/adium/Adium_1.5.7.dmg [following]
    --2014-02-25 19:09:04--  http://hivelocity.dl.sourceforge.net/project/adium/Adium_1.5.7.dmg
    Resolving hivelocity.dl.sourceforge.net...
    Connecting to hivelocity.dl.sourceforge.net||:80... connected.
    HTTP request sent, awaiting response... 200 OK
    Length: 23999416 (23M) [application/x-apple-diskimage]
    Saving to: ‘download’

    100%[===================================================================================================================================>] 23,999,416  1014KB/s   in 25s

    2014-02-25 19:09:29 (941 KB/s) - ‘download’ saved [23999416/23999416]

This led me to find that I could use this URL instead: http://hivelocity.dl.sourceforge.net/project/adium/Adium_1.5.7.dmg

| improve this answer | |
  • FYI I changed http to htte because I could not post more than two linmks... – Philip Feb 26 '14 at 0:13

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.