View Full Version : graceful restart messes up downloads in progress
anewday
04-09-2008, 12:25 AM
Server running on 3.3.9. I start a download of a 175M multimedia file with firefox, about 5 seconds later, I restarted the web server gracefully via the GUI. And then about 15 seconds later, the download "finishes" (firefox progress bar says 100% done) but the file is partially downloaded only. :eek: I tested it on other multimedia files too and the same thing happens.
Now, I know why every time I gracefully restart the server, the overal outgoing speed decreases shortly afterwards. Hope you can find a fix soon.
mistwang
04-09-2008, 09:51 AM
To be stopped lshttpd process will linger about 30 seconds to try to finish requests being processed, the large download takes more than 30 seconds will be cut off as designed.
We can make it stay longer, but there has to be a cut off time. The statistics is not very accurate during a restart as it does not count the number from to-be stopped process any more.
anewday
04-09-2008, 10:14 AM
Ok, can you make a setting to specify the cut off time? Why does there have to be one anyway? Many users are still on dialup. I think it's better to just interrupt the download instead of showing that it's at 100% so at least the user knows that the download got interrupted.
mistwang
04-09-2008, 10:17 AM
Yes, the download was interrupted, it is a browser bug if it shows 100%.
anewday
04-09-2008, 11:25 AM
I see, the apache graceful restart doesnt interrupt long downloads. Litespeed should behave the same way. ;)
mistwang
04-09-2008, 11:34 AM
It has pros and cons, Apache graceful restart just reload the configuration file, it cannot be used when apache binary has been updated. cPanel does not use graceful restart as it may not able to apply all configuration changes properly, it always do stop then start, so I am pretty sure that the large file download will be affected when you change anything in cPanel.
LiteSpeed does genuine process restart which starts a new process from scratch to make sure the latest LSWS binary is used.
anewday
04-09-2008, 12:01 PM
so I am pretty sure that the large file download will be affected when you change anything in cPanel.
Yeah, that's why I think litespeed should offer 2 restart options. :) Most of the time, I restart due to config changes anyway, if I updated a binary, then I'll use a regular restart....