cURL / Mailing Lists / curl-users / Single Mail

curl-users

Problems using cURLl to Form Post a file above 50K

From: Meyer, Aaron <Aaron.Meyer_at_ONSTAR.com>
Date: Mon, 4 Oct 2004 17:09:48 -0400

I am trying to use cURL, via command line, to fill out an asp form to post a
file.

The form requires the following fields:

txtUserName
txtDomain
file1 - this being a file type on the form
fileType

I execute the following statement (from a Windows 2000 machine):
"C:\CURL\"curl -v --proxy 155.55.555.1:80 --proxy-user id:passwd -u
id2:passwd2 -F "txtUserName=user_name" -F "txtPassword=password" -F
"txtDomain=xxx" -F "file1=@Customer.txt" -F "fileType=CUSTOMER"
https://staging/upload.asp

The Customer.txt file is an ascii, csv file containing customer records.
When the file called Customer.txt is less than 80K, it seems to post fine.
However, when the file is over 80K, I receive:

----------Start of Error------------------------------
* About to connect() to 155.55.555.1 port 80
* Connected to 155.55.555.1 (155.55.555.1 ) port 80
* Proxy auth using Basic with user 'id'
* Server auth using Basic with user 'id2'
> POST http://curl HTTP/1.1
Proxy-Authorization: Basic bnp6YzZyOnQwdGFsYmF0Mg==
Authorization: Basic b25zdGFyX2F1dGg6MjIyQkdIcA==
User-Agent: curl/7.12.0 (i386-pc-win32) libcurl/7.12.0 OpenSSL/0.9.7d
zlib/1.2.1

Host: curl
Pragma: no-cache
Accept: */*
Content-Length: 98045
Expect: 100-continue
Content-Type: multipart/form-data;
boundary=----------------------------1eaae7e3
c81c

< HTTP/1.1 502 Bad Gateway
< Date: Mon, 04 Oct 2004 18:34:52 GMT
< Content-Length: 333
< Content-Type: text/html
< Server: NetCache appliance (NetApp/5.3.1R2)
<HTML>
<HEAD><TITLE>502 Bad Gateway</TITLE></HEAD>
<BODY>
<H1>Bad Gateway</H1>
<H4>
The following error occurred:<P>
The host name was not found during the DNS lookup. Contact your system
administr
ator if the problem is.not found by retrying the URL. (DNS_HOST_NOT_FOUND)
</H4>
<HR>
Please contact the administrator.
</BODY>
</HTML>
* Closing connection #0
curl: (55) failed sending data to the peer
----------End of Error------------------------------

The error message itself makes no reference to the file being too big. I
don't believe it is truly a DNS lookup problem, because when the file is
under 80K, it works.
When manually using the asp form, file size never seems to cause a problem.

Any help is appreciated.
Received on 2004-10-04