[Solved] Uploading files to lightty server fails
Added by calvinpm almost 7 years ago
Hi friends,
I am running into an issue with file uploading to lightty server (file size > 1GB). My java program using HTTP PUT method to upload a file to lightty server, and it has been working fine with lighttpd-1.4.37; but after I upgraded to lighttpd-1.4.41, file uploading failed intermittently. I am running RedHat on the client and my lightty servers run on FC12, FC16, FC20. It fails on all platforms, although on FC12 it fails more often. I observed that with version 1.4.37, as soon as temp files created in /var/tmp it seemed lightty started creating the uploaded files in /var/www/lighttpd/dropbox/ as the temp files came in /var/tmp/; with version 1.4.41, it looks like lightty waits until all the temp files are there in /var/tmp (I observed there are around 1100 temp files ) then it starts creating the uploaded file in dropbox. When it failed, the number of temp files came in less than that in successfull uploading. I did tcpdump to see what's going on network, why the client stopped sending, and I found the server sent TCP ZERO_WINDOW packets to the clients as a response when receive buffer was full. After a while the server then sent RESET packet and connection terminated. As a result the client may have stopped sending until the server cleared up the receive buffer. I checked syslog and found no errors. I enabled debug in lightty, and error.log showed suspicious.
I am stuck here, don't know to troubleshoot further. Any help is really appreciated. Attached is the Java code uploading a file from the client. Thank you all for your help!
Calvin
Connection.java (3.33 KB) Connection.java |
Replies (4)
RE: Uploading files to lightty server fails - Added by gstrauss almost 7 years ago
Please test with lighttpd 1.4.45, as the issue you are seeing has probably already been fixed. GetLighttpd
Separately, see Server_stream-request-bodyDetails if you want lighttpd to stream the request body to your backend as the file is uploaded.
RE: Uploading files to lightty server fails - Added by calvinpm almost 7 years ago
Thank you very much! I will try and post the results.
RE: Uploading files to lightty server fails - Added by gstrauss almost 7 years ago
calvinpm, any update?
RE: Uploading files to lightty server fails - Added by calvinpm almost 7 years ago
I've upgraded to version 1.4.45 and it resolve the problem.
Thanks a lot for your help!
Calvin