Fork us on GitHub Follow us on Facebook Follow us on Twitter

Opened 8 years ago

Closed 5 years ago

#602 closed defect (fixed)

Cannot download a 1M file from HelenOS over http/tcp.

Reported by: Jakub Jermář Owned by: Jiri Svoboda
Priority: critical Milestone: 0.7.1
Component: helenos/net/tcp Version: mainline
Keywords: Cc:
Blocker for: Depends on:
See also:

Description (last modified by Jakub Jermář)

With the current mainline (2264, default amd64 build), the following steps will lead to a stalled download of a 1M file at about 340K:

In HelenOS (tools/ew.py):

# websrv
# cd /data/web
# mount tmpfs /data/web
# mkfile -s 1m foo

In a browser running on the same machine as QEMU with HelenOS go to: http://localhost:8080/foo.

The download will start, but after several hundreds of kilobytes it will stall.

Change History (10)

comment:1 Changed 8 years ago by Jakub Jermář

Description: modified (diff)

comment:2 Changed 8 years ago by Vojtech Horky

I am unable to reproduce this: download finishes without any problems (both when I created the file in uspace/dist/data/web and when I used your approach). I even tried to download the file from inside HelenOS and that looks okay too.

I am using QEMU 2.2.1 on x86_64 3.16.3 Linux.

comment:3 Changed 8 years ago by Martin Decky

Milestone: 0.6.00.7.1

comment:4 Changed 8 years ago by Jiri Svoboda

Can you try this again? I could not reproduce it before or after mainline,2343.

comment:5 Changed 8 years ago by Jakub Jermář

Neither I can reproduce this now. The download proceeds okay, but webserv coughs out two error messages (EIO) after the transmission is over:

tcp_conn_recv() failed (-265)

and:

recv_line() failed
Error processing request (Unknown error code -265)

comment:6 Changed 8 years ago by Jiri Svoboda

Curious, I cannot reproduce that. I do get an error message at end of transmission from download - need to look into that. But nothing from websrv.

comment:7 Changed 6 years ago by Jiri Svoboda

This ticket has gone a little bit off track. The download stall is no longer reproducible. The error message from download was fixed in mainline,2719. Can you still reproduce the error messages from websrv? It works for me.

comment:8 Changed 6 years ago by Jakub Jermář

I can confirm that the stalls do not happen anymore. I tried downloading 1M, 10M and 34M files repeatedly. However, I can still reproduce the websrv messages:

recv_line() failed
Error processing request (Limit exceeded)

The message is usually displayed when one download ends and another one is started or when another download is started while the first one is still in progress.

comment:9 Changed 5 years ago by Jiri Svoboda

This problem could occur when two HTTP requests arrived close to each other and were handled by websrv concurrently. Websrv used global buffers for receiving requests and for reading/sending files.

comment:10 Changed 5 years ago by Jiri Svoboda

Resolution: fixed
Status: newclosed

Fixed in mainline,2756 by having separate receive and transfer buffers for each connection.

Note: See TracTickets for help on using tickets.