Article View: news.software.nntp
Article #18249Re: INN Performance Patch
From: Ugly Boy
Date: Wed, 04 Jun 1997 00:00
Date: Wed, 04 Jun 1997 00:00
124 lines
7096 bytes
7096 bytes
On Wed, 4 Jun 1997, Jeff Garzik wrote: Hmmmm, optimizations to err on the safe side, perhaps (or pessimizations depending on how you look at it): > The logic is like this: > > IHAVE > if (pre-committed) > Refuse At this point and below, instead of refusing it (since the transfer is not yet complete and there is a very slight danger you won't get the article), you could return the Defer (431/436) code, to force the other peer to try again. The situation could arise where all but one of your peers has the article with winternet in the path, and that one peer from which you would accept the article offers it at the time one of the other sites has caused the message-ID to be in your pre-commit cache. Granted, it's highly unlikely, but you're always taking a risk if you refuse an article before it's completely transferred. I usually see a couple dozen or so articles which somehow get mangled in transit each day and thus need to be transferred a second time for success. And we all know what happens when part 175 of a multi-part post is missing. > otherwise (check history, etc.) > otherwise > We don't have the article, > Mark article in pre-commit cache > go to 'get article' state > > CHECK > if (pre-committed) > Refuse > otherwise (check history, etc.) This is another window of vulnerability when an article can be duplicated, when several peers have given you the CHECKs simultaneously, you've responded affirmatively to them, since nobody has actually gotten around to the low-latency IHAVE or reached the point of beginning the transfer with the TAKETHIS. Depending on the number of CHECKs the peers are giving you and the latency and bandwidth between you and size of articles to be transferred, there can easily be several seconds or more from the time the first CHECK is given, until one of the peers actually starts the transfer and effectively locks it out for any further peers offering it. This is one of the bandwidth-wasting drawbacks of streaming when one has multiple peers, particularly when they are well-synchronized and thus getting affirmative responses to their CHECKs within a second or two of each other. As noted earlier in this newsgroup, while non-streaming connections to INN and TAKETHIS commands are able to cause these messages to be locked out or deferred from delivery by other peers, no comparable optimization has been made for streaming connections. As I've noted, a greater number of CHECKs makes things worse by increasing the delay from ACK to transfer, so more connections with fewer CHECKs at a time is one way to reduce the number of rejected articles from multiple peers. Just how one would treat a situation like this is dependent on your concern and/or greed. If your biggest worry is how much fame, wealth, and fortune you will receive in exponential proportion to your status in the top 1000, you want to take the article from whoever gets it to you first, so you probably would dispense with refusing or deferring articles based on the promise that they're on their way. Then, if you want to absolutely minimize the amount of bandwidth wasted by multiple transfers of the same article, you're going to want to add it to the pre-commit cache as soon as the first peer mentions it to you, even though it would be possible for another peer to offer a CHECK and receive a Roger and get the article to you before your first peer clears out previously acknowledged articles and finally gets around to the TAKETHIS. And this is where a further bandwidth optimization can take place, where the first mention of an article loads it into the pre-commit cache, where it remains until timing-out/cycling-out, and again is refreshed when the TAKETHIS is reached. Again, I'd really rather give a 431/436 Try again in a sec' response rather than a 438 Negatory, Good Buddy, simply because for any number of reasons, an article which is CHECKed can disappear or otherwise not be transferred successfully. Remember, a CHECK is even more like saying that the CHECK, er, I mean, the check is in the mail. Such an optimization would result in a drastic reduction of most of the remaining wasted bandwidth of duplicates, with only a slight increase in the number of CHECKs having to be given multiple times if deferred. The drawback would be a possible delay of up to a few minutes in the arrival time of some articles later than when they would arrive if other peers wasted bandwidth by sending them as well. > TAKETHIS > Mark article in pre-commit cache This is the point at which INN by default returns its 431/436 Wait jes' a minute thar response to additional CHECKs/IHAVEs, based on observing the responses to innxmit, and the statistics given by innfeed. I didn't write or study the code, so I'm not one to speak authoritatively on this. Another thing to note, for sites such as myself with multiple news servers, is that pre-commit caches are spiffy when all feeds point to a single, sometimes overburdened machine. But when a site chooses to split incoming feeds among multiple machines for redundancy, and particularly when these machines are not perfectly synchronized, two or more sites can easily be sending the same articles at the same times as there's no way for the two servers getting the article to know that it's already coming in to the other. I see ten or so thousand duplicated articles this way with just two supplementary feeds to my secondary server, which is less than 5% of incoming articles, but possibly a significant volume if many of these are large binaries. I could reduce this by asking those two sites to aim at my overworked incoming server, and then have only the slowest sites feed the other machine as backup. > Almost mind-numbingly simple. :) Yeah, and I twist it into this overly-long drivel. Ah, well, I've written enough for this time of day, with the clarity of what I write proportional and the quantity inversely proportional to the hour of the day. Barry Bouwsma http://www.netscum.net/bouwsmb0.html news.radio.cz admin in scenic sorta sunny Brno, Czechia
Technical Details
Message-ID:
<Pine.BSF.3.96.970604101700.4250A-100000@super-xenu.radio.cz>Path:
mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.nntp.mbox.zip!not-for-mailReferences:
<5mt7et$s52$1@turing.mathworks.com> <5mtdlr$ndu$1@hammer.msfc.nasa.gov> <82bu5ogp8s.fsf@manic.eecs.umich.edu> <5n15ar$9md$1@drum.msfc.nasa.gov> <33948068.4F305FB8@spinne.com> <Pine.BSF.3.96.970604010244.3585A-100000@super-xenu.radio.cz> <3395099D.1A6AB61@spinne.com>Show Full Headers
Complete Article Headers
Message-ID: <Pine.BSF.3.96.970604101700.4250A-100000@super-xenu.radio.cz> Subject: Re: INN Performance Patch Date: Wed, 04 Jun 1997 00:00:00 +0000 From: Ugly Boy <dogface@Radio.CZ> References: <5mt7et$s52$1@turing.mathworks.com> <5mtdlr$ndu$1@hammer.msfc.nasa.gov> <82bu5ogp8s.fsf@manic.eecs.umich.edu> <5n15ar$9md$1@drum.msfc.nasa.gov> <33948068.4F305FB8@spinne.com> <Pine.BSF.3.96.970604010244.3585A-100000@super-xenu.radio.cz> <3395099D.1A6AB61@spinne.com> Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.nntp.mbox.zip!not-for-mail X-Deja-AN: 246018804 Organization: Gigz o' \/\/@R3Z for the masses: ftp://warez.radio.cz Reply-To: ag786@yfn.ysu.edu Newsgroups: news.software.nntp