Skip to content
This repository has been archived by the owner on Dec 27, 2022. It is now read-only.

remote_file fails on response body length check #439

Open
mlanin opened this issue Dec 22, 2015 · 0 comments
Open

remote_file fails on response body length check #439

mlanin opened this issue Dec 22, 2015 · 0 comments

Comments

@mlanin
Copy link

mlanin commented Dec 22, 2015

Every time I try to download logstash agent, I get this error.

10.250.70.44     * remote_file[/var/chef/cache/agent.tar.gz] action create
10.250.70.44
10.250.70.44       ================================================================================
10.250.70.44       Error executing action `create` on resource 'remote_file[/var/chef/cache/agent.tar.gz]'
10.250.70.44       ================================================================================
10.250.70.44
10.250.70.44       Chef::Exceptions::ContentLengthMismatch
10.250.70.44       ---------------------------------------
10.250.70.44       Response body length 12025356 does not match HTTP Content-Length header 85619205.
10.250.70.44
10.250.70.44       Resource Declaration:
10.250.70.44       ---------------------
10.250.70.44       # In /var/chef/cache/cookbooks/ark/providers/default.rb
10.250.70.44
10.250.70.44       121:   remote_file new_resource.release_file do
10.250.70.44       122:     source new_resource.url
10.250.70.44       123:     checksum new_resource.checksum if new_resource.checksum
10.250.70.44       124:     action :create
10.250.70.44       125:     notifies :run, "execute[unpack #{new_resource.release_file}]"
10.250.70.44       126:   end
10.250.70.44       127:
10.250.70.44       Compiled Resource:
10.250.70.44       ------------------
10.250.70.44       # Declared in /var/chef/cache/cookbooks/ark/providers/default.rb:121:in `block in class_from_file'
10.250.70.44
10.250.70.44       remote_file("/var/chef/cache/agent.tar.gz") do
10.250.70.44         provider Chef::Provider::RemoteFile
10.250.70.44         action [:create]
10.250.70.44         retries 0
10.250.70.44         retry_delay 2
10.250.70.44         default_guard_interpreter :default
10.250.70.44         path "/var/chef/cache/agent.tar.gz"
10.250.70.44         backup 5
10.250.70.44         atomic_update true
10.250.70.44         source ["https://download.elasticsearch.org/logstash/logstash/logstash-1.4.2.tar.gz"]
10.250.70.44         use_etag true
10.250.70.44         use_last_modified true
10.250.70.44         declared_type :remote_file
10.250.70.44         cookbook_name "msp_log"
10.250.70.44         checksum "d5be171af8d4ca966a0c731fc34f5deeee9d7631319e3660d1df99e43c5f8069"
10.250.70.44       end

Response body length is always different. I tried it on different chef versions and problem preserved.

May be someone faced with such problem?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant