fetch: multiple choices
What on earth does this mean? >> mrtg-2.9.26b.tar.gz doesn't seem to exist in /tmp/distfiles/. >> Attempting to fetch from http://people.ee.ethz.ch/~oetiker/webtools/mrtg/pub/. fetch: mrtg-2.9.26b.tar.gz: Multiple Choices Kris msg47036/pgp0.pgp Description: PGP signature
RE: fetch: multiple choices
Howdy, The webserver is returning a status code of 300 for the file. The webserver response should be including one or more locations from which the file is available. I'd imagine that libfetch/fetch ignores this and moves on to the next available site. Regards, Chris Knight Systems Administrator AIMS Independent Computer Professionals Tel: +61 3 6334 6664 Fax: +61 3 6331 7032 Mob: +61 419 528 795 Web: http://www.aims.com.au > -Original Message- > From: On Behalf Of Kris Kennaway > Sent: Thursday, 21 November 2002 12:31 > To: [EMAIL PROTECTED] > Subject: fetch: multiple choices > > > What on earth does this mean? > > >> mrtg-2.9.26b.tar.gz doesn't seem to exist in /tmp/distfiles/. > >> Attempting to fetch from > http://people.ee.ethz.ch/~oetiker/webtools/mrtg/pub/. > fetch: mrtg-2.9.26b.tar.gz: Multiple Choices > > Kris To Unsubscribe: send mail to [EMAIL PROTECTED] with "unsubscribe freebsd-current" in the body of the message
Re: fetch: multiple choices
In the last episode (Nov 20), Kris Kennaway said: > What on earth does this mean? > > >> mrtg-2.9.26b.tar.gz doesn't seem to exist in /tmp/distfiles/. > >> Attempting to fetch from http://people.ee.ethz.ch/~oetiker/webtools/mrtg/pub/. > fetch: mrtg-2.9.26b.tar.gz: Multiple Choices According to RFC 2616, an HTTP 300 (Multiple Choices) return code means that the requested URL is available at multiple locations to be listed in the returned document. The requested file actually does _not_ exist, and people.ee.ethz.ch is broken in that it is returning an HTTP 300, and then listing similar filenames in the same directory. I don't believe this is the correct behaviour; the file really does not exist. It should have returned HTTP 404. HTTP 300 is meant for places like the sourceforge download farm, where one primary URL ends up directing you to multiple alternate locations all serving the identical file. In an ideal world, the 300 response would have pointed to mirror sites, and fetch would have just picked one (possibly multiple ones for segmented downloading) and downloaded it. In the current world, it's just as well that fetch didn't try anything, as all the of the listed urls were wrong anyway. -- Dan Nelson [EMAIL PROTECTED] To Unsubscribe: send mail to [EMAIL PROTECTED] with "unsubscribe freebsd-current" in the body of the message
Re: fetch: multiple choices
On Thu, Nov 21, 2002 at 12:47:22PM +1100, Chris Knight wrote: > Howdy, > > The webserver is returning a status code of 300 for the file. > The webserver response should be including one or more locations > from which the file is available. I'd imagine that libfetch/fetch > ignores this and moves on to the next available site. Thanks for clarifying. fetch does indeed move on to other sites (none of which carry the file in question, which is why I noticed this), it just puzzled me as to why such a HTTP feature would exist. Kris msg47049/pgp0.pgp Description: PGP signature
Re: fetch: multiple choices
>What on earth does this mean? > >>> mrtg-2.9.26b.tar.gz doesn't seem to exist in /tmp/distfiles/. >>> Attempting to fetch from >http://people.ee.ethz.ch/~oetiker/webtools/mrtg/pub/. >fetch: mrtg-2.9.26b.tar.gz: Multiple Choices It means the web server is behaving oddly. Here's a patch that gives you a chance of understanding what's going on; it makes fetch -v display the returned page in this case. Index: http.c === RCS file: /home/ncvs/src/lib/libfetch/http.c,v retrieving revision 1.64 diff -u -r1.64 http.c --- http.c 30 Oct 2002 15:01:29 - 1.64 +++ http.c 21 Nov 2002 17:46:39 - @@ -1005,10 +1005,15 @@ /* all other cases: we got a redirect */ e = conn->err; need_auth = 0; + if (!new) { + DEBUG(fprintf(stderr, "redirect with no new location\n")); + if ((f = _http_funopen(conn, chunked)) != NULL) { + _http_print_html(stderr, f); + } + } _fetch_close(conn); conn = NULL; if (!new) { - DEBUG(fprintf(stderr, "redirect with no new location\n")); break; } if (url != URL) Bill