Return-Path: X-Original-To: apmail-couchdb-user-archive@www.apache.org Delivered-To: apmail-couchdb-user-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 50D4510B94 for ; Wed, 12 Feb 2014 18:05:23 +0000 (UTC) Received: (qmail 71300 invoked by uid 500); 12 Feb 2014 18:05:21 -0000 Delivered-To: apmail-couchdb-user-archive@couchdb.apache.org Received: (qmail 71203 invoked by uid 500); 12 Feb 2014 18:05:21 -0000 Mailing-List: contact user-help@couchdb.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@couchdb.apache.org Delivered-To: mailing list user@couchdb.apache.org Received: (qmail 71195 invoked by uid 99); 12 Feb 2014 18:05:21 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 12 Feb 2014 18:05:21 +0000 X-ASF-Spam-Status: No, hits=-0.7 required=5.0 tests=NORMAL_HTTP_TO_IP,RCVD_IN_DNSWL_LOW,SPF_PASS,WEIRD_PORT X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of kxepal@gmail.com designates 74.125.82.180 as permitted sender) Received: from [74.125.82.180] (HELO mail-we0-f180.google.com) (74.125.82.180) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 12 Feb 2014 18:05:16 +0000 Received: by mail-we0-f180.google.com with SMTP id u57so6290341wes.39 for ; Wed, 12 Feb 2014 10:04:55 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type:content-transfer-encoding; bh=lnzVLQgEsPCnYZ6EQ/HFXV9NV09yi4Q1fTuCKihAXx8=; b=tecmKAvTPfkmMVYt+DT4IxEjNe6nWNoRpFvXZrbhAqJ8dRlAG9ff4cHZCNFLOlSy2R AsGceVkinzfGj/qCeVXOcBMCSvKRPjw9gIY7Fd0IYtL2/MGMdtyTBBBAhLPa5EhErl2+ X5NJaywj/KDaqFU+GplpOo7ZdNVSJgRxpKpaH6Mt4UvO6LqXwYSWB4/ZM1nF1RhqwzUC 3AZZ/aq/0dDsSGhUpETXRrxfeHDTQisbfSv9R+48768Y67Ch4vmdRI8BvhsMvzAK+Aut rArf8FS8hW7kfo+Gigh/kyIsPPKj368TQjmZUeOd4u+OW9axuekb7mWp/3I2IxQIQttQ yuTg== MIME-Version: 1.0 X-Received: by 10.194.119.168 with SMTP id kv8mr2393443wjb.41.1392228295636; Wed, 12 Feb 2014 10:04:55 -0800 (PST) Received: by 10.180.20.135 with HTTP; Wed, 12 Feb 2014 10:04:55 -0800 (PST) In-Reply-To: References: <9C42F4BD-2761-43EC-BDE5-947493650618@jasonwinshell.com> Date: Wed, 12 Feb 2014 22:04:55 +0400 Message-ID: Subject: Re: Super slow attachment upload speed on localhost From: Alexander Shorin To: "user@couchdb.apache.org" Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Virus-Checked: Checked by ClamAV on apache.org I believe this issue has the same reasons as COUCHDB-1986 does. -- ,,,^..^,,, On Wed, Feb 12, 2014 at 9:43 PM, Robert Samuel Newson wrote: > Try -T myrandom.dat instead of =E2=80=94data-binary @ to stream it withou= t loading it into ram. > > B. > > On 12 Feb 2014, at 17:32, Jason Winshell wrote: > >> Hello, >> >> I am finding that uploading an attachment to CouchDB 1.5 is incredibly s= low when transferring from curl. Both curl and Couch are running on localho= st (no network). I switched to a curl test after seeing the same problem wi= th Futon and the Ektorp framework. I tried the loopback address, 127.0.0.1 = too. >> >> For a 3MB file with curl I'm seeing a 22-25 second upload. curl says the= average upload speed is 146K/sec. What's going on? Why is Couch taking so = long to process the attachment stream? >> >> HELP! >> >> Thanks >> >> Jason >> >> Platform: Mac OS X 10.9.1 (Mavericks), CouchdB 1.5, 16GB ram, 1TB disk, = 2.2ghz i7 >> >> curl command: >> >> ~ > curl -vX PUT 'http://127.0.0.1:5984/justfiles/doc1/myrandom.dat' --d= ata-binary @myrandom.dat -H "Content-Type: application/octet-stream" > resp= onse >> * About to connect() to 127.0.0.1 port 5984 (#0) >> * Trying 127.0.0.1... >> * Adding handle: conn: 0x7fedaa004000 >> * Adding handle: send: 0 >> * Adding handle: recv: 0 >> * Curl_addHandleToPipeline: length: 1 >> * - Conn 0 (0x7fedaa004000) send_pipe: 1, recv_pipe: 0 >> % Total % Received % Xferd Average Speed Time Time Time C= urrent >> Dload Upload Total Spent Left S= peed >> 0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- = 0* Connected to 127.0.0.1 (127.0.0.1) port 5984 (#0) >>> PUT /justfiles/doc1/myrandom.dat HTTP/1.1 >>> User-Agent: curl/7.30.0 >>> Host: 127.0.0.1:5984 >>> Accept: */* >>> Content-Type: application/octet-stream >>> Content-Length: 3145728 >>> Expect: 100-continue >>> >> < HTTP/1.1 100 Continue >> } [data not shown] >> 84 3072k 0 0 84 2608k 0 125k 0:00:24 0:00:20 0:00:04 = 125k< HTTP/1.1 201 Created >> * Server CouchDB/1.5.0 (Erlang OTP/R16B01) is not blacklisted >> < Server: CouchDB/1.5.0 (Erlang OTP/R16B01) >> < Location: http://127.0.0.1:5984/justfiles/doc1/myrandom.dat >> < ETag: "10-05bebacc7fc5273e6164a1d32e188b05" >> < Date: Wed, 12 Feb 2014 17:28:34 GMT >> < Content-Type: text/plain; charset=3Dutf-8 >> < Content-Length: 68 >> < Cache-Control: must-revalidate >> < >> { [data not shown] >> 100 3072k 100 68 100 3072k 3 146k 0:00:22 0:00:20 0:00:02= 112k >> * Connection #0 to host 127.0.0.1 left intact >> ~ > cat response >> {"ok":true,"id":"doc1","rev":"10-05bebacc7fc5273e6164a1d32e188b05"} >> ~ > >