opentechinstitute / commotion-router

The build system for the OpenWRT-based Commotion firmware.
https://commotionwireless.net
GNU General Public License v3.0
121 stars 43 forks source link

extend uhttp script timeout from 60 to 300 seconds #131

Closed dismantl closed 10 years ago

dismantl commented 10 years ago

Many times on a poor quality wireless signal, or when upgrading a node over multiple hops, uHTTPd will give a timeout error when it takes more than 60 seconds to upload a firmware image. This will extend the timeout from 1 minute to 5 minutes.

jheretic commented 10 years ago

Do we want script_timeout or network_timeout? According to the docs (http://wiki.openwrt.org/doc/uci/uhttpd), script_timeout governs how long we'll wait for a script to return, whereas network_timeout determines how long we wait for a network connection.

jheretic commented 10 years ago

Apologies for closing it by accident, keyboard slipped.

dismantl commented 10 years ago

pretty sure we want script_timeout. I base this on the error response from the server The CGI script has produced no response, or something like that.

dismantl commented 10 years ago

also, changing that value allowed me to upload a new firmware image over multiple hops, when it was previously giving me that error.

hawkinswnaf commented 10 years ago

I cannot verify the technical correctness of this pull request, but I wholeheartedly support the idea of extending the timeout. This has bitten me on multiple occasions.

jheretic commented 10 years ago

Yes, I can see how this makes sense in the context of updates. Because the limiting factor isn't actually the connection itself, it's the script execution since the script doesn't return until the file is completely transferred. I understand now.