[chef] Re: Re: Re: Re: 403 "Forbidden" when uploading cookbooks with large files


Chronological Thread 
  • From: Tomasz Chmielewski < >
  • To:
  • Cc: ,
  • Subject: [chef] Re: Re: Re: Re: 403 "Forbidden" when uploading cookbooks with large files
  • Date: Tue, 22 Apr 2014 11:04:45 +0100
  • Domainkey-signature: a=rsa-sha1; c=nofws; d=wpkg.org; h=date:from:to:cc :subject:message-id:in-reply-to:references:mime-version :content-type:content-transfer-encoding; q=dns; s=default; b=3YP QiQeFAuOPTxfIAEzIIdx5KRF7cHaOOLzIZFaCzLVR1GkDyMaau9MxbyZkxvdp7jy T+mbZ/b6iShJlpcEY7U9nQ3a7K9FXddM3xZgoW85ja9M3vuO+bUlpcbijsgyfhTT RGCcLuSG89HEv/sVXnFJMqj/aIaOrhNGb+MUwUK8=

On Mon, 21 Apr 2014 21:00:54 -0700
Lamont Granquist 
< >
 wrote:

> On 4/21/14, 6:00 PM, Tomasz Chmielewski wrote:
> > ERROR: Chef::Exceptions::ContentLengthMismatch: Response body
> > length 0 does not match HTTP Content-Length header 206.
> >
> >
> try updating chef on your desktop.  if you're running 11.12.2 and
> seeing this, then you'd need to cut a bug report, but we'd need more 
> information like output of knife cookbook upload -V and as much
> context as you can give.

Hi,

I'm running 11.12.2 already:

$ dpkg -l|grep chef
ii  chef                                                  11.12.2-1           
                                amd64        The full stack of chef

Here is the output with -V:

$ time knife cookbook upload mmaww-staging -V
Uploading mmaww-staging  [1.0.0]
INFO: Validating ruby files
INFO: Validating templates
INFO: Syntax OK
INFO: Saving mmaww-staging
INFO: Uploading files
INFO: Uploading 
/home/tch/Desktop/.../chef-repo/cookbooks/mmaww-staging/files/default/mysql-setup.sh
 (checksum hex = 4160124bf8a905a0e5dc1aa419135909) to 
https://chef01.sys:443/bookshelf/organization-00000000000000000000000000000000/checksum-4160124bf8a905a0e5dc1aa419135909?AWSAccessKeyId=...&Expires=1398159865&Signature=YNVBVPwN82OPwmiOgy41VmQB1jw%3D
INFO: Uploading 
/home/tch/Desktop/.../chef-repo/cookbooks/mmaww-staging/files/default/mongo-setup.sh
 (checksum hex = 8abcd332a3bb0d3d284dbe0d83322fde) to 
https://chef01.sys:443/bookshelf/organization-00000000000000000000000000000000/checksum-8abcd332a3bb0d3d284dbe0d83322fde?AWSAccessKeyId...&Expires=1398159865&Signature=DBHn7Bp8fo16o9CQ%2Bg8gDdIQhH0%3D
INFO: Uploading 
/home/tch/Desktop/.../chef-repo/cookbooks/mmaww-staging/files/default/mongo-td_stage.tar.xz
 (checksum hex = 95d55edf3a75d5358a424d843c3e8463) to 
https://chef01.sys:443/bookshelf/organization-00000000000000000000000000000000/checksum-95d55edf3a75d5358a424d843c3e8463?AWSAccessKeyId=...&Expires=1398159865&Signature=kXJpijoKemcQZA96ZVJydQG1JVc%3D
INFO: Uploading 
/home/tch/Desktop/.../chef-repo/cookbooks/mmaww-staging/recipes/default.rb 
(checksum hex = 9cb5ef6dbb6db3811a1108ac5f990efc) to 
https://chef01.sys:443/bookshelf/organization-00000000000000000000000000000000/checksum-9cb5ef6dbb6db3811a1108ac5f990efc?AWSAccessKeyId=...&Expires=1398159865&Signature=GgeSQKQ373PW1lWTpWOE%2BC3RfkU%3D
INFO: HTTP Request Returned 403 Forbidden:
ERROR: Chef::Exceptions::ContentLengthMismatch: Response body length 0 does 
not match HTTP Content-Length header 206.

real    21m55.991s
user    0m5.937s
sys     0m1.698s


The only logs on chef-server side, in /var/log/chef-server/, are these for 
nginx: access.log and error.log.

access.log:

188.37.253.127 - - [22/Apr/2014:09:51:17 +0000]  "PUT 
/bookshelf/organization-00000000000000000000000000000000/checksum-95d55edf3a75d5358a424d843c3e8463?AWSAccessKeyId=...&Expires=1398159865&Signature=kXJpijoKemcQZA96ZVJydQG1JVc%3D
 HTTP/1.1" 403 "1310.623" 0 "-" "Chef Knife/11.12.2 (ruby-1.9.3-p484; 
ohai-7.0.2; x86_64-linux; +http://opscode.com)" "127.0.0.1:4321" "403" 
"0.002" "11.12.2" "algorithm=sha1;version=1.0;" "tch" "2014-04-22T09:29:25Z" 
"WCBVdNihGqn06wwwcqjsjzwCAPw=" 164108882


error.log:

2014/04/22 09:51:16 [error] 22184#0: *40 readv() failed (104: Connection 
reset by peer) while reading upstream, client: 188.37.253.127, server: 
chef01.sys, request: "PUT 
/bookshelf/organization-00000000000000000000000000000000/checksum-95d55edf3a75d5358a424d843c3e8463?AWSAccessKeyId=...&Expires=1398159865&Signature=kXJpijoKemcQZA96ZVJydQG1JVc%3D
 HTTP/1.1", upstream: 
"http://127.0.0.1:4321/bookshelf/organization-00000000000000000000000000000000/checksum-95d55edf3a75d5358a424d843c3e8463?AWSAccessKeyId=...&Expires=1398159865&Signature=kXJpijoKemcQZA96ZVJydQG1JVc%3D";,
 host: "chef01.sys:443"


The link speed to the chef server from my laptop is around 150 kB/s.

Let me know what other information do you may need.


-- 
Tomasz Chmielewski
http://wpkg.org





Archive powered by MHonArc 2.6.16.

§