🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: news.software.nntp
51 messages
51 total messages Started by Russ Allbery Mon, 08 Mar 2004 18:39
New NNTP standard in Working Group Last Call
#68474
Author: Russ Allbery
Date: Mon, 08 Mar 2004 18:39
33 lines
2217 bytes
Hello folks,

The replacement standard for the aging RFC 977 (the NNTP protocol) is now
in its two-week internal working group last call period.  You can see the
current version at:

    <http://www.davros.org/nntp-texts/draft21.txt>
    <http://www.davros.org/nntp-texts/draft21.html>

and shortly to be published in the standard Internet Draft locations as
draft-ietf-nntpext-base-21.txt.

I strongly encourage any client or server authors to read over the draft
and send any comments.  You can join the working group mailing list by
going to:

    <https://www.academ.com/mailman/listinfo/ietf-nntp>

if you're not already subscribed, or you can post to news.software.nntp
and I'll summarize for the working group.

This is the first of two last call periods.  After this two week period,
this draft will be forwarded to the IETF for a general last call, after
which it will (hopefully, barring any necessary additional changes) go to
the RFC Editor for publication as a standards-track RFC.

Thank you *very* much to Clive Feather for his patient and excellent work
as the document editor.  There's no way that this draft would be ready
without his work.

-- 
Russ Allbery (rra@stanford.edu)             <http://www.eyrie.org/~eagle/>
Re: New NNTP standard in Working Group Last Call
#68477
Author: Dr.Ruud
Date: Mon, 08 Mar 2004 19:45
17 lines
1615 bytes
Toen ik Russ Allbery kietelde, kwam er dit uit:

>     <http://www.davros.org/nntp-texts/draft21.txt>

8.4  'case sensistive'
-> 'case-sensitive'

8.4.1  'and not including either the "." CRLF terminating the response nor
any "." added for "byte-stuffing" purposes'
-> The meaning is clear, but is "not ... either ... nor any" OK? (I would
use 'or' in stead of 'nor' there.)

-- 
Affijn, Ruud


Re: New NNTP standard in Working Group Last Call
#68479
Author: rone
Date: Mon, 08 Mar 2004 20:08
15 lines
1493 bytes
In article <871xo3w5c6.fsf@windlord.stanford.edu>,
Russ Allbery  <rra@stanford.edu> wrote:
>The replacement standard for the aging RFC 977 (the NNTP protocol) is now
>in its two-week internal working group last call period.

Not that i'm pissing on the efforts of the people who've worked hard
on this... but how long has it taken?  Six or seven years?  Or am i
thinking of USEFOR?

rone
-- 
Light stupidity decays into heavy stupidity.  This violates energy
conservation, but that's stupidity for you.
	- Rich Holmes <rsholmes+usenet@mailbox.syr.edu>
Re: New NNTP standard in Working Group Last Call
#68478
Author: Russ Allbery
Date: Mon, 08 Mar 2004 20:42
20 lines
1798 bytes
rone <^*&#$@ennui.org> writes:
> Russ Allbery  <rra@stanford.edu> wrote:

>> The replacement standard for the aging RFC 977 (the NNTP protocol) is now
>> in its two-week internal working group last call period.

> Not that i'm pissing on the efforts of the people who've worked hard on
> this... but how long has it taken?  Six or seven years?  Or am i
> thinking of USEFOR?

It's taken *way* longer than it had any business taking, including the
last year where I should have pushed things through a lot faster.  I'm
sorry about that.

-- 
Russ Allbery (rra@stanford.edu)             <http://www.eyrie.org/~eagle/>

          Please post questions rather than mailing me directly.
     <http://www.eyrie.org/~eagle/faqs/questions.html> explains why.
Re: New NNTP standard in Working Group Last Call
#68481
Author: Clive D. W. Feather
Date: Tue, 09 Mar 2004 10:05
22 lines
2031 bytes
In article <c2im1m.1p0.1@news.isolution.nl>, Dr.Ruud 
<'t.leven.is.fijn@life.i$.great> writes
>8.4  'case sensistive'
>-> 'case-sensitive'

Argh; I don't know how I missed that one.

>8.4.1  'and not including either the "." CRLF terminating the response nor
>any "." added for "byte-stuffing" purposes'
>-> The meaning is clear, but is "not ... either ... nor any" OK? (I would
>use 'or' in stead of 'nor' there.)

The usage note in <http://dictionary.reference.com/search?q=nor> 
suggests ("However, when a verb is negated ...") that either "nor" or 
"or" is acceptable here.

-- 
Clive D.W. Feather, writing for himself  | Home: <clive@davros.org>
Tel: +44 20 8495 6138 (work)             | Web:  <http://www.davros.org>
Fax: +44 870 051 9937                    | Work: <clive@demon.net>
Written on my laptop; please observe the Reply-To address
Re: New NNTP standard in Working Group Last Call
#68491
Author: rone
Date: Wed, 10 Mar 2004 08:49
14 lines
1644 bytes
In article <87eks3t6ic.fsf@windlord.stanford.edu>,
Russ Allbery  <rra@stanford.edu> wrote:
>It's taken *way* longer than it had any business taking, including the
>last year where I should have pushed things through a lot faster.  I'm
>sorry about that.

Well, i hardly think it's your damn fault...  OR IS IT???

rone
-- 
Light stupidity decays into heavy stupidity.  This violates energy
conservation, but that's stupidity for you.
	- Rich Holmes <rsholmes+usenet@mailbox.syr.edu>
Re: New NNTP standard in Working Group Last Call
#68532
Author: Colin Wilson
Date: Fri, 12 Mar 2004 09:28
39 lines
2466 bytes
Russ Allbery wrote:

> I strongly encourage any client or server authors to read over the
> draft and send any comments.

It's probably too late.

But the only thing I really dislike about it is that it makes official
the bug in many servers where they send '0' as the message bymber in
the 2xx response to STAT <message-id>, ARTICLE <message-id>, etc.

It would be much more useful if they returned the real message number
if the session was 'in a group'.

Obviously I'm not suggesting it should change the current article
pointer or anything.  And if the session was not 'in a group' it would
still return '0'.

Even if it was just the STAT command that enforced this it would be
better than nothing.  After all, the (old) spec says that there's no
practical use for STAT <message-id>.  Doing this would give it one!

It would be particularly useful for servers that Suck from other
servers.  To find the next message to suck you could get the message-id
from the last message you sucked, look up it's number on the server
with STAT <message-id>, and use the message number returned (+1) as the
point to continue from.  Instead you've got to do a 'HEAD' and decode
the Xref to find the message number.

-- 
Colin

Creator of XanaNews & XanaNewz!

web: www.wilsonc.demon.co.uk/delphi.htm
mail: colin@wilsonc.demon.co.uk

Posted with Xananews 1.16.1.12
Re: New NNTP standard in Working Group Last Call
#68533
Author: Colin Wilson
Date: Fri, 12 Mar 2004 09:34
29 lines
1794 bytes
Russ Allbery wrote:

> Hello folks,
> 
> The replacement standard for the aging RFC 977 (the NNTP protocol) is
> now in its two-week internal working group last call period.

Is it practical to replace 977 with this, or is it a spec for a brand
new protocol?

eg. What would the impact on existing newsreaders when they find UTF-8
in message headers, etc.

I guess if it was a brand new protocol it might be better to give it a
new default port (eg. not 119), new URL indicators (eg. not 'news:' or
'nntp:'), etc.

What do people think?

-- 
Colin

Creator of XanaNews & XanaNewz!

web: www.wilsonc.demon.co.uk/delphi.htm
mail: colin@wilsonc.demon.co.uk

Posted with Xananews 1.16.1.12
Re: New NNTP standard in Working Group Last Call
#68534
Author: iMeowbot
Date: Fri, 12 Mar 2004 09:55
18 lines
1916 bytes
In article <xn0dfoms3pkaic005@news.clara.net>,
 "Colin Wilson" <colin@wilsonc.demon.co.uk> wrote:

> Is it practical to replace 977 with this, or is it a spec for a brand
> new protocol?
> 
> eg. What would the impact on existing newsreaders when they find UTF-8
> in message headers, etc.

NNTP only describes what's allowed on the wire, not what's permitted to 
appear in an article.  For that, 1036 (and by extension, [2]822) still 
applies, and 8-bit headers are still undefined there.  Newsreaders can 
continue to cope with malformed headers under the new NNTP revision the 
same way they did before, using semi-random guesswork.

If the defined article format ever changes, hopefully it will happen in 
a compatible and implementable way.
Re: New NNTP standard in Working Group Last Call
#68546
Author: Russ Allbery
Date: Fri, 12 Mar 2004 23:00
29 lines
2409 bytes
Colin Wilson <colin@wilsonc.demon.co.uk> writes:
> Russ Allbery wrote:

>> The replacement standard for the aging RFC 977 (the NNTP protocol) is
>> now in its two-week internal working group last call period.

> Is it practical to replace 977 with this, or is it a spec for a brand
> new protocol?

It is intended to simply replace 977, and that is our goal.  We've tried
to identify and deal with every place where that's not possible.  There
are some commands that one has to support on a legacy basis, such as
XOVER, but for those areas covered by this standard, one should be able to
simply switch to the new behavior.  It is my intention to do exactly that
with INN.

> eg. What would the impact on existing newsreaders when they find UTF-8
> in message headers, etc.

Note that NNTP just *allows for* UTF-8, it doesn't require it.  It also
doesn't update the article format standard.  RFC 1036 messages still could
not contain UTF-8.

-- 
Russ Allbery (rra@stanford.edu)             <http://www.eyrie.org/~eagle/>

          Please post questions rather than mailing me directly.
     <http://www.eyrie.org/~eagle/faqs/questions.html> explains why.
Re: New NNTP standard in Working Group Last Call
#68547
Author: Russ Allbery
Date: Fri, 12 Mar 2004 23:03
43 lines
3218 bytes
Colin Wilson <colin@wilsonc.demon.co.uk> writes:

> It's probably too late.

> But the only thing I really dislike about it is that it makes official
> the bug in many servers where they send '0' as the message bymber in the
> 2xx response to STAT <message-id>, ARTICLE <message-id>, etc.

This is not a bug; this is completely intentional.  Whether it's the
behavior that you *want* is another question.  :)

There are several difficulties in requiring that the server put a real
article number in those responses.  One is that those commands are
independent of group, so it's not clear which article number to return for
a crossposted article, although as you point out it would be arguably
correct to use the currently selected group if there were one *and* if the
article were posted to it.

The much more serious problem, though, is that just supporting this single
function would add a requirement for a completely new type of mapping to
be maintained on the server, namely a mapping from message ID to newsgroup
name and article number pairs.  Currently, the server is not required to
maintain this mapping for any other reason.

While I agree that there are certain circumstances in which this would be
useful, I think that overhead is considerably higher than is warranted.

> It would be particularly useful for servers that Suck from other
> servers.  To find the next message to suck you could get the message-id
> from the last message you sucked, look up it's number on the server with
> STAT <message-id>, and use the message number returned (+1) as the point
> to continue from.  Instead you've got to do a 'HEAD' and decode the Xref
> to find the message number.

It's nearly as easy to store the last article number that you retrieved,
maintaining a local .newsrc style file.

-- 
Russ Allbery (rra@stanford.edu)             <http://www.eyrie.org/~eagle/>

          Please post questions rather than mailing me directly.
     <http://www.eyrie.org/~eagle/faqs/questions.html> explains why.
Re: New NNTP standard in Working Group Last Call
#68551
Author: Colin Wilson
Date: Sat, 13 Mar 2004 11:47
54 lines
3287 bytes
Russ Allbery wrote:

> > But the only thing I really dislike about it is that it makes
> > official the bug in many servers where they send '0' as the message
> > bymber in the 2xx response to STAT <message-id>, ARTICLE
> > <message-id>, etc.
> 
> This is not a bug; this is completely intentional.  Whether it's the
> behavior that you want is another question.  :)

The reason I say it's a bug is that nowhere in RFC 977 does it say it's
valid to return '0' for the article number in a 22x response.  On the
contrary - it specifically says that the article number should be
returned for both forms:

  [the following applies to both forms of the article command.] A
response indicating the current article
   number, a message-id string, and that text is to follow will be
returned.


> The much more serious problem, though, is that just supporting this
> single function would add a requirement for a completely new type of
> mapping to be maintained on the server, namely a mapping from message
> ID to newsgroup name and article number pairs.  Currently, the server
> is not required to maintain this mapping for any other reason.

But surely the server could fish it out of the Xref header - like I
have to do manually.  So there wouldn't be much overhead.  For HEAD and
ARTICLE the server has to load this anyway.  The chances are that for
BODY it's loaded the information anyway, and discarded it in the
response.  There's no other use for STAT <message-id> anyway, so the
overhead of loading the header and parsing the Xref wouldn't impact
anything.

> It's nearly as easy to store the last article number that you
> retrieved, maintaining a local .newsrc style file.

Yes - but it would be better coming from the server.  That way there
would be no danger of 'things getting out of sync.'

I like the rest of the document, BTW.  It's very clear and
comprehensive.  Thanks.

-- 
Colin

Creator of XanaNews & XanaNewz!

web: www.wilsonc.demon.co.uk/delphi.htm
mail: colin@wilsonc.demon.co.uk

Posted with Xananews 1.16.1.12
Re: New NNTP standard in Working Group Last Call
#68558
Author: Guy Middleton
Date: Sat, 13 Mar 2004 20:17
22 lines
2278 bytes
I have recently encounted a news server which drops the connection
immediately, without sending a response, upon being sent any unknown command.
This seems to me to be fragile at best, and a violation of the "be liberal in
what you accept" principle.

The administrators of the server claim that this is correct behaviour.  I
can't find anything in RFC977 that explicitly disallows this, although it
seems obvious to me that this is wrong.

This is annoying because clients (TRN in particular, there may be others),
send non-standard commands (such as XMODE READER and XTHREAD DBINIT).  A
reasonable server would reply with a 500 error, and the client could continue.

I would like to see language disallowing this in the new standard, if
possible.

Section 3.2.1 says this now: "If the command is not recognized, or it is an
optional command or extension that is not implemented by the server, the
response code 500 MUST be returned".  This could be read to prohibit
disconnection, but it would be nice if the standard could make the prohibition
explicit.
Re: New NNTP standard in Working Group Last Call
#68559
Author: Russ Allbery
Date: Sat, 13 Mar 2004 20:24
38 lines
3000 bytes
Colin Wilson <colin@wilsonc.demon.co.uk> writes:
> Russ Allbery wrote:

>> This is not a bug; this is completely intentional.  Whether it's the
>> behavior that you want is another question.  :)

> The reason I say it's a bug is that nowhere in RFC 977 does it say it's
> valid to return '0' for the article number in a 22x response.  On the
> contrary - it specifically says that the article number should be
> returned for both forms:

>   [the following applies to both forms of the article command.] A
>   response indicating the current article number, a message-id string,
>   and that text is to follow will be returned.

Which is nonsensical, since there's obviously no meaningful article number
when the command is used outside of a newsgroup.

> But surely the server could fish it out of the Xref header - like I
> have to do manually.  So there wouldn't be much overhead.

Retrieving by message ID while inside a newsgroup is rather uncommon, and
it doesn't feel to me like something that any time should be spent
optimizing.  I think you're the first person I remember wanting this
(although lots of people have wanted the article number when retrieving
the message by message ID outside of a newsgroup, since they didn't
understand).

I could be wrong.  If anyone else really wants this, please do speak up
(although it is, I think, too late to get it into the standard, it's
certainly something that could be added as an extension).

-- 
Russ Allbery (rra@stanford.edu)             <http://www.eyrie.org/~eagle/>

          Please post questions rather than mailing me directly.
     <http://www.eyrie.org/~eagle/faqs/questions.html> explains why.
Re: New NNTP standard in Working Group Last Call
#68645
Author: Clive D. W. Feather
Date: Tue, 16 Mar 2004 14:17
16 lines
2040 bytes
In article <xn0dfommipc6fs004@news.clara.net>, Colin Wilson 
<colin@wilsonc.demon.co.uk> writes
>Even if it was just the STAT command that enforced this it would be
>better than nothing.  After all, the (old) spec says that there's no
>practical use for STAT <message-id>.  Doing this would give it one!

It might have said so, but that doesn't make it right. An obvious use 
for it is to find out if that message exists in the first place! [E.g. 
is it still on the server or has it expired?]

-- 
Clive D.W. Feather, writing for himself  | Home: <clive@davros.org>
Tel: +44 20 8495 6138 (work)             | Web:  <http://www.davros.org>
Fax: +44 870 051 9937                    | Work: <clive@demon.net>
Written on my laptop; please observe the Reply-To address
Re: New NNTP standard in Working Group Last Call
#68644
Author: Clive D. W. Feather
Date: Tue, 16 Mar 2004 15:40
33 lines
2731 bytes
In article <87u10t4qie.fsf@windlord.stanford.edu>, Russ Allbery 
<rra@stanford.edu> writes
>> But the only thing I really dislike about it is that it makes official
>> the bug in many servers where they send '0' as the message bymber in the
>> 2xx response to STAT <message-id>, ARTICLE <message-id>, etc.
>
>This is not a bug; this is completely intentional.  Whether it's the
>behavior that you *want* is another question.  :)

[...]

I wouldn't have a problem with making it a MAY. No server would have to 
change unless the author wants. A client can't rely on it, but can use 
it if the number is provided.

So the wording covering article numbers - not just for STAT, but 
throughout - would be something like:

     The article number MUST be replaced by "0", except that if there
     is a current group and the relevant article has an article number in
     that group, the server MAY use that number instead.

>While I agree that there are certain circumstances in which this would be
>useful, I think that overhead is considerably higher than is warranted.

Whenever this is the case, the server simply doesn't do it.

-- 
Clive D.W. Feather, writing for himself  | Home: <clive@davros.org>
Tel: +44 20 8495 6138 (work)             | Web:  <http://www.davros.org>
Fax: +44 870 051 9937                    | Work: <clive@demon.net>
Written on my laptop; please observe the Reply-To address
Re: New NNTP standard in Working Group Last Call
#68650
Author: Russ Allbery
Date: Tue, 16 Mar 2004 18:33
17 lines
1880 bytes
Clive D W Feather <clive@on-the-train.demon.co.uk> writes:

> So the wording covering article numbers - not just for STAT, but
> throughout - would be something like:

>      The article number MUST be replaced by "0", except that if there
>      is a current group and the relevant article has an article number in
>      that group, the server MAY use that number instead.

I have no objections to that.

-- 
Russ Allbery (rra@stanford.edu)             <http://www.eyrie.org/~eagle/>

          Please post questions rather than mailing me directly.
     <http://www.eyrie.org/~eagle/faqs/questions.html> explains why.
Re: New NNTP standard in Working Group Last Call
#68658
Author: Colin Wilson
Date: Tue, 16 Mar 2004 20:48
19 lines
1823 bytes
Clive D. W. Feather wrote:

> The article number MUST be replaced by "0", except that if there
> is a current group and the relevant article has an article number in
> that group, the server MAY use that number instead.

Yes - that would be OK.  Things like DNews already do this, so it would
mean that they wouldn't have to change.

-- 
Colin

Creator of XanaNews & XanaNewz!

web: www.wilsonc.demon.co.uk/delphi.htm
mail: colin@wilsonc.demon.co.uk

Posted with Xananews 1.16.1.12
Re: New NNTP standard in Working Group Last Call
#68657
Author: Colin Wilson
Date: Tue, 16 Mar 2004 20:50
18 lines
1651 bytes
Clive D. W. Feather wrote:

> An obvious use for it is to find out if that message exists in the
> first place!

Yes - I can see how that would sometimes be useful.  Though in practice
you'd probably want to do at least a HEAD instead.

-- 
Colin

Creator of XanaNews & XanaNewz!

web: www.wilsonc.demon.co.uk/delphi.htm
mail: colin@wilsonc.demon.co.uk

Posted with Xananews 1.16.1.12
Re: New NNTP standard in Working Group Last Call
#68667
Author: Francois Petillon
Date: Wed, 17 Mar 2004 10:16
11 lines
1606 bytes
On Tue, 16 Mar 2004 20:50:11 +0000, Colin Wilson wrote:
>> An obvious use for it is to find out if that message exists in the
>> first place!
> Yes - I can see how that would sometimes be useful.  Though in practice
> you'd probably want to do at least a HEAD instead.

No, on some NNTP daemon like Diablo, you may get an header even if the
article has been expired.

  Fran�ois
Re: New NNTP standard in Working Group Last Call
#68668
Author: Francois Petillon
Date: Wed, 17 Mar 2004 10:27
15 lines
1915 bytes
On Sat, 13 Mar 2004 11:47:16 +0000, Colin Wilson wrote:
> But surely the server could fish it out of the Xref header - like I
> have to do manually.

And if there is no Xref header ? Diablo architecture uses spoolers (to
store articles, request are done by M-ID) and frontals (to manage users
and overviews, requests should be done by article number, requests by
M-ID are simply forwarded to spoolers, they receive an header feed). For
performance issues and as the numbering is the only unsplitable operation
(meaning the numbering servers have to manage a full-feed), articles may
be numbered on an header feed (and fed to frontals). Thus the spoolers may
have no valid Xref line in the articles...

  Fran�ois
Re: New NNTP standard in Working Group Last Call
#68671
Author: Francois Petillon
Date: Wed, 17 Mar 2004 13:23
11 lines
1698 bytes
On Wed, 17 Mar 2004 13:06:09 +0000, Colin Wilson wrote:
> If Diablo gives a 'Message Has Expired' response to STAT <msgid>, and
> then proceeds to give a '221 - Head follows' response to HEAD <the same
> msgid> then it's faulty.

grmpf, I have read too quickly. You may have an answer with a HEAD
article-number while a STAT <M-ID> may fail (but a stat <M-ID> will
succeed).

  Fran�ois
Re: New NNTP standard in Working Group Last Call
#68670
Author: Francois Petillon
Date: Wed, 17 Mar 2004 13:32
13 lines
1859 bytes
On Wed, 17 Mar 2004 13:21:34 +0000, Colin Wilson wrote:
> Presumably though, after I send it "GROUP groupName", and Diablo
> responds with "211 n f l groupName group selected", it will return
> valid XRef header lines (at least as far as groupname is concerned) for
> all the articles that exist between 'f' and 'l'?

No, not if your request is done by Message-Id. There is a hash of the
Message-ID in dreaderd overview but its use is costy (you have to
check with all entries) and is only used for cancels and will only work
for the cancel "Newsgroups:" groups.

  Fran�ois
Re: New NNTP standard in Working Group Last Call
#68673
Author: Francois Petillon
Date: Wed, 17 Mar 2004 13:32
11 lines
1732 bytes
On Wed, 17 Mar 2004 13:06:09 +0000, Colin Wilson wrote:
> If Diablo gives a 'Message Has Expired' response to STAT <msgid>, and
> then proceeds to give a '221 - Head follows' response to HEAD <the same
> msgid> then it's faulty.

grmpf, I have read too quickly. You may have an answer with a HEAD
article-number while a STAT <M-ID> may fail (but a stat
article-numbre will succeed).

  Fran�ois
Re: New NNTP standard in Working Group Last Call
#68672
Author: Frank Slootweg
Date: Wed, 17 Mar 2004 14:48
16 lines
1874 bytes
Clive D. W. Feather <clive@on-the-train.demon.co.uk> wrote:
> In article <xn0dfommipc6fs004@news.clara.net>, Colin Wilson 
> <colin@wilsonc.demon.co.uk> writes
>>Even if it was just the STAT command that enforced this it would be
>>better than nothing.  After all, the (old) spec says that there's no
>>practical use for STAT <message-id>.  Doing this would give it one!
> 
> It might have said so, but that doesn't make it right. An obvious use 
> for it is to find out if that message exists in the first place! [E.g. 
> is it still on the server or has it expired?]

  Indeed, STAT surely has its uses. I used it to check the propagation
of 'my' articles (i.e. articles posted by the users of 'my' server) to
other News servers in our company. STAT was all I needed. HEAD would be
needlessly complex/expensive.
Re: New NNTP standard in Working Group Last Call
#68674
Author: pdtar
Date: Wed, 17 Mar 2004 16:55
18 lines
1719 bytes
rra@stanford.edu says...
> It's taken *way* longer than it had any business taking, including the
> last year where I should have pushed things through a lot faster.  I'm
> sorry about that.
> 
Russ 

This message would be appropriate in fifty diverse groups but this is as 
good a place as any. Thanks for your long, diligent and often 
unappreciated support of Usenet. 

Thanks as well to all who worked to get this finished. Most folks have 
never seen a Standards Track <http://tinyurl.com/2g35c>
 
-- 
pdtar
xpdtar@att.net
Re: New NNTP standard in Working Group Last Call
#68694
Author: Clive D. W. Feather
Date: Fri, 19 Mar 2004 10:07
16 lines
2009 bytes
In article <xn0dfuqs22sge9002@news.clara.net>, Colin Wilson 
<colin@wilsonc.demon.co.uk> writes
>> The article number MUST be replaced by "0", except that if there
>> is a current group and the relevant article has an article number in
>> that group, the server MAY use that number instead.
>Yes - that would be OK.  Things like DNews already do this, so it would
>mean that they wouldn't have to change.

Appropriate text going into the next draft.

-- 
Clive D.W. Feather, writing for himself  | Home: <clive@davros.org>
Tel: +44 20 8495 6138 (work)             | Web:  <http://www.davros.org>
Fax: +44 870 051 9937                    | Work: <clive@demon.net>
Written on my laptop; please observe the Reply-To address
Re: New NNTP standard in Working Group Last Call
#68709
Author: Curt Welch
Date: Sat, 20 Mar 2004 06:08
57 lines
4489 bytes
"Clive D.W. Feather" <clive@davros.org> wrote:
> In article <xn0dfuqs22sge9002@news.clara.net>, Colin Wilson
> <colin@wilsonc.demon.co.uk> writes
> >> The article number MUST be replaced by "0", except that if there
> >> is a current group and the relevant article has an article number in
> >> that group, the server MAY use that number instead.
> >Yes - that would be OK.  Things like DNews already do this, so it would
> >mean that they wouldn't have to change.
>
> Appropriate text going into the next draft.

I didn't know that dnews did that.  It is of course "broken" for doing
that. :)  Dnews got a lot of little things like that wrong.  At one point
many years back, it was returning the wrong error code for articles looked
up by message-id vs articles looked up by article number. (423 vs 430).  I
understand the confusion because the RFC didn't correctly document the
behavor.  But back in those days, the RFC really wasn't the standard, the
reference NNTP implementation and INN were the standard.  If you didn't do
what INN did, your code was "broken".  INN returned 0 for the article
number when the lookup was by Message-Id so that was, and always has been,
the "real" standard.  Any one who argues what is "right" by making
reference to any past NNTP rfc doesn't understand how Usenet has actually
worked for the past 15 years.

I don't mind the above wording, but I don't like it.  If I had a vote, I'd
vote against alowing the MAY clause to be added.  I would really like to
see a lot of these little difference between servers removed.  If the new
stanard "breaks" dnews, then so be it.  The new standard in fact is going
to break almost all current servers in one minor way or another like this.
The real point with the new RFC is to fix a lot of these problems (minor or
not) so all the servers for the first will have a chance to do the same
thing for all these minor (but not insignificant) points.

If all the servers don't do the same thing, then news reader authors can't
use the paramater.  If some servers return 0, then you can't write a
newsreader that assums the article number from the current group will be
there.  If some return the article number, then newsreaders can't assume
that a 0 is there to flag the fact that the lookup was by Message-id.  It
becomes almost total worthless and even worse, a potential "bug trap" for
news client authors that might make the false assumtion that it will be 0
for all Message-Id look-ups (if they are doing their development on an
INN-like server), or that it might always return the article number (if
they are doing their development on dnews-like servers).

Adding the "MAY return the article number" just allows current "broken"
servers to continue to exist which makes the return value continue to be
mostly worthless.

However, I don't want to see the draft held up any more over this point.
Please, do it either way, but get the RFC done. :)  I only wrote all this
to give people something to think about, not to try and change whatever
path this issue has already taken.

-- 
Curt Welch                                            http://CurtWelch.Com/
curt@kcwc.com                          Webmaster for http://NewsReader.Com/
Re: New NNTP standard in Working Group Last Call
#68711
Author: Curt Welch
Date: Sat, 20 Mar 2004 06:39
49 lines
3784 bytes
Francois Petillon <fantec@proxad.net> wrote:
> And if there is no Xref header ? Diablo architecture uses spoolers (to
> store articles, request are done by M-ID) and frontals (to manage users
> and overviews, requests should be done by article number, requests by
> M-ID are simply forwarded to spoolers, they receive an header feed). For
> performance issues and as the numbering is the only unsplitable operation

It sure would be nice if NNTP didn't use article numbers.  It sure makes
distributed servers harder.

> (meaning the numbering servers have to manage a full-feed),

My server has this problem because I do make sure the Xref is correct in
the spools (my server requires it to be correct for many other things to
work).  And my numbering machine is at it's limits of performance for an
Intel machine with the way my code works so I'm about to have to make some
changes.

One option is to split the feed by group - putting some groups on one
server and some on another.  That will allow the Xref: to remain mostly
valid, but it will break for cross-posts which span my artificial group
divisions.

Another possibility is to do the article numbering only on the headers.
But that's a major re-architecture of my server and it breaks some other
features which I see as important (like the ability to keep the headers and
spools in sync so there is never any protocol inconsistencies about whether
articles exist and don't exist on the server).

What I will probably do is move the number assignment to an external active
file server server which only assigns the numbers, and then split the
article volume between multiple machines, all which use the common number
server to assign article numbers.  The number server will not receive
articles, it will onlty deal with special requests to assign article
numbers for newsgroups.  This allows me to get the Xref: correct in all the
spools, but eliminate the problem of a single machine having to carry a
full feed.

My point of all this is simply that it is possible to get the Xref: correct
in the spools (and for all HEAD and ARTICLE commands) without forcing a
single machine to carry the full feed volume.  It may not be easy or
reasnonable to use this technique for diablo, but it is possible to both
meet the growing usenet volume demands with a distributed system and not
force a single machine to carry the full feed.

-- 
Curt Welch                                            http://CurtWelch.Com/
curt@kcwc.com                          Webmaster for http://NewsReader.Com/
Re: New NNTP standard in Working Group Last Call
#68716
Author: Colin Wilson
Date: Sat, 20 Mar 2004 10:35
33 lines
2453 bytes
Francois Petillon wrote:

> On Wed, 17 Mar 2004 13:21:34 +0000, Colin Wilson wrote:
> > Presumably though, after I send it "GROUP groupName", and Diablo
> > responds with "211 n f l groupName group selected", it will return
> > valid XRef header lines (at least as far as groupname is concerned)
> > for all the articles that exist between 'f' and 'l'?
> 
> No, not if your request is done by Message-Id. There is a hash of the
> Message-ID in dreaderd overview but its use is costy (you have to
> check with all entries) and is only used for cancels and will only
> work for the cancel "Newsgroups:" groups.
> 
>   Fran�ois

So is there any way, if you have a header, to find out it's message
number in a group on a Diablo server?

I suppose as a last resort I'll have to do a binary search on the
date/time - if the message number wasn't in the 22x response or the
XRef.


-- 
Colin

Creator of XanaNews & XanaNewz!

web: www.wilsonc.demon.co.uk/delphi.htm
mail: colin@wilsonc.demon.co.uk

Posted with Xananews 1.16.1.12
Re: New NNTP standard in Working Group Last Call
#68719
Author: Colin Wilson
Date: Sat, 20 Mar 2004 10:47
42 lines
2565 bytes
Curt Welch wrote:

> However, I don't want to see the draft held up any more over this
> point.  Please, do it either way, but get the RFC done. :)

If I had a choice I'd plump for 'MUST' for the STAT response and 'MAY'
for the HEAD & ARTICLE ones.

Seeing as how servers are now much more powerful than they used to be,
a little extra work wouldn't hurt, and it would help Newsreaders no end
in doing things like filling in missing messages by looking at
secondary servers, etc.

Having said that, I understand the problems it would cause clustered
servers.


> If all the servers don't do the same thing, then news reader authors
> can't use the paramater.

News reader authors have to be a bit sneaky, and remember which servers
support which functionality, etc.


> But back in those days, the RFC really wasn't the standard, the
> reference NNTP implementation and INN were the standard.

That may well be true, but it's a dreadful situation! The whole point
of the RFCs is that they're 'standards' - and if they can't be trusted,
then what's the point of having them?  Anarchy rulez!


-- 
Colin

Creator of XanaNews & XanaNewz!

web: www.wilsonc.demon.co.uk/delphi.htm
mail: colin@wilsonc.demon.co.uk

Posted with Xananews 1.16.1.12
Re: New NNTP standard in Working Group Last Call
#68730
Author: Curt Welch
Date: Sun, 21 Mar 2004 07:22
159 lines
10034 bytes
"Colin Wilson" <colin@wilsonc.demon.co.uk> wrote:
> Curt Welch wrote:
>
> > However, I don't want to see the draft held up any more over this
> > point.  Please, do it either way, but get the RFC done. :)
>
> If I had a choice I'd plump for 'MUST' for the STAT response and 'MAY'
> for the HEAD & ARTICLE ones.
>
> Seeing as how servers are now much more powerful than they used to be,
> a little extra work wouldn't hurt,

For text Usenet, that's a valid point.  For for full usenet, including the
binaries, that's just not true.  It's because Usenet has grown faster than
the server performance has grown.  Usenet used to fit nicely into the
corner of a server just like e-mail did.  There was so much extra power in
the machine compared to what you needed to support Usenet that you could be
afford to put each article into it's own file.  You could run an exire
processes each night that scaned the entire spool in minutes and you could
have the expire processes read and parse the header of every article in the
spool.

Those days are long gone.  To support a full feed with a "typical" user
load and typical peering, you must have a network of machines highly
optimized to keep up with the volume.  There is _no_ CPU, or network
bandwidth, or disk bandwidth to spare any more.  If you require the Usenet
server to do 20% more, the racks of servers end up costing at least 20%
more.

However, for something as minor as putting the article number in the
response by forcing the CPU to parse the Xref: line, that amount of load is
trivial.  It's a .00001 % increase in load, _if_ you have a valid Xref:
line to parse.

The far bigger issue with these protocol changes is that the large and
complex set of distributed databases and the protocols these multiple
machines use to talk to one another have all been designed based on what
the author thought was "required" to do NNTP "well enough".  And if you
change something from how it's been done in the past, you run the risk of
adding a requirement which some custom server can't do, because it doesn't
have the right information at the correct time.  If, like Diablo,
message-id lookup is done without the help of the group maping information,
and if the article you end up with when you do a fetch by Message-Id does
not have a valid Xref: header, then the only solution to including the
article number is for the server to search the entire group for a match.
With the volume of usenet and the retention of the servers today, the
largest groups have millions of articles in them, and it's only going to
get worse.  A linear search of a newsgroup with millions of articles just
to allow the server to respond to a STAT command is total unworkable.  To
do it, you can't just add a little more CPU power, you have to make some
fundimential changes to server architecture and do a lot of re-coding.

> and it would help Newsreaders no end
> in doing things like filling in missing messages by looking at
> secondary servers, etc.

What would?  Knowing the article number when you already know the
Message-ID?  I don't get your point.  When checking multiple servers, it's
the Message-ID and not the article number you need.

> Having said that, I understand the problems it would cause clustered
> servers.
>
> > If all the servers don't do the same thing, then news reader authors
> > can't use the paramater.
>
> News reader authors have to be a bit sneaky, and remember which servers
> support which functionality, etc.

The point of having a standard is to allow stuff like that to be removed
from the newsreaders.  The need for anything like that just shows how much
development is driven without a regard for the standards.

> > But back in those days, the RFC really wasn't the standard, the
> > reference NNTP implementation and INN were the standard.
>
> That may well be true, but it's a dreadful situation!

It wasn't dreadful at all.  The source code was a fine standard.  The
dreadful situation are all the programers that started to write servers and
clients that didn't bother to read the standard when they needed to.

> The whole point
> of the RFCs is that they're 'standards' - and if they can't be trusted,
> then what's the point of having them?  Anarchy rulez!

Well, Usenet has always been "Anarchy rulez".  And the lack of any central
control is the true cause of all these "broken" protocol problems.  But,
it's not because there wasn't a standard, it's because too many developers
didn't understand what the standard was.

You have to remember that Usenet, when it started, was a Unix utility.  It
was only avaiable on Unix systems.  At that time, Unix didn't even support
TCP/IP.  The RFCs were not "global computer standards".  The RFCs were how
TCP/IP was documented and Unix, and Usenet, had nothing to do with TCP/IP
or the Arpanet or the Internet.

On Unix, the way the entire system was documented was with unix man pages,
backed up by the source code.  The man pages didn't try to document
everything, because everyone with Unix also had the full source, and to be
a Unix user, you were expected to be able to read C like the original Unix
users (Ken and Dennis).

Usenet started life, and lived, in the Unix/uucp environment for something
like 10 years before the internet became central to Usenet (like '81
through '91).  Checking google, I see Usenet manged to exist for over 5
years before the word NNTP showed up in an article.  And everything Usenet,
was documented the same way everything Unix had always been documented -
with simple man pages that told only 80% of the story, and with C source
code as the ultimate reference.

NNTP was created as a way of moving Usenet articles over TCP/IP for the few
sites that had a version of Unix that supported TCP/IP (BSD I think was the
only version at first that supported it).  With the creation of that, an
RFC was written because that was the standard way to document TPC/IP
protocols.  The RFC was never ment to be the "standard" for what Usenet
was.  It was just one more document to add to the man pages and the source
code to create the complete "Usenet Standard" reference set.  It wasn't
even very important because NNTP wasn't important to Usenet at first.

When NNTP was created, the standard way a newsreader accessed articles was
by reading them directly off the disk on the local machine.  The newsreader
always ran on the same machine that the aticles were stored on.  So NNTP
was not at first the "normal" way newsreaders worked, or the "normal" way
news servers exchanged articles.  It was uucp to move news between servers,
and direct disk access for newsreaders to read the active file and the
newsgroups file and the articles.

But then INN was written, and local TCP/IP networks as well as the Arpanet
started to expand.  Usenet started to transform from a world of UUCP and
direct-read newsreaders, into the client-server design we have today.  But
still, the RFC was written only in the spirt of a Unix man page to give the
basic NNTP overview.  IT was enough for a user to read to understand what
NNTP was, but if you did development, you were expected to open up the
source to find the real facts and all the details left out of the man
pages.

But then the problems happened.  People started to get confused and think
that Usenet was an Internet "thing".  And they started to make the totaly
false assumption that Usenet was documented in the RFCs like the rest of
the TCP/IP world.  All the new-comers to Usenet didn't understand that
Usenet was not part of the "internet".  And they started to assume that if
the RFC didn't say something, they were allowed to do whatever they wanted.
And they assumed that it made no difference what some program like INN did,
because if there code followed the RFC, it was right, and INN was wrong.
Well, they were wrong, and they are still wrong, because as of today, there
still is no RFC which was written in the spirit of being "the" Usenet NNTP
standard to replace the reference implementations like INN.  But that's
exactly what this current work is all about.  To attempt for the first time
to translate all the C code into english.  But now of course, we have to
address all the current "broken" servers that exist in the world because
their developers didn't understand how Usenet was documented and didn't
follow the old standards.  But, that's of course ok here because after all,
Anarchy does rule here. :)

-- 
Curt Welch                                            http://CurtWelch.Com/
curt@kcwc.com                          Webmaster for http://NewsReader.Com/
Re: New NNTP standard in Working Group Last Call
#68732
Author: Curt Welch
Date: Sun, 21 Mar 2004 09:22
46 lines
3504 bytes
"Colin Wilson" <colin@wilsonc.demon.co.uk> wrote:
> The reason I say it's a bug is that nowhere in RFC 977 does it say it's
> valid to return '0' for the article number in a 22x response.  On the
> contrary - it specifically says that the article number should be
> returned for both forms:

I've argued that the source has always been the real "standard" for Usenet
and never the RFC.  And as far as I know, INN has always returned 0 for the
article number on Message-Id look-ups.  But what I didn't really know is
what the older NNTP server software which came before inn did with the
article number.  So I just did a little digging.

I found two version of it.  One version, which seems to be version 1.5.11
from around 1991, did have a hard-coded 0 for all look-ups by Message-ID:

        printf("%d 0 %s Article retrieved, %s.\r\n",
                OK_ARTICLE + method, argv[1], verbiage[method]);

The NNTP code was first written in 1996 by the same people I believe that
wrote RFC 977.  I assume that since this 1991 version had the hard-coded 0,
that all previous version did as well for the 7 years before that, and this
stands as a good example of the difference between the RFC and the "real
standard", (the actual code).

However, I also found version 1.5.12.1 which has this:

         printf("%d %ld %s Article retrieved, %s.\r\n",
                        OK_ARTICLE + method, group_artnum, argv[1],
                        verbiage[method]);

Where group_artnum is set from the data in the history file if the current
group is set and the article is posted to the current group.  i.e., It is
returning the article number like you want when it makes sense to do so.

This version seems to be from 1994.  Version 1.5.12 is the version that
added support for the non-standard "XOVER" command as well.  This change to
the return value was not mentioned in the change log however.

INN I assume copied the orginal behavior, and then after INN was written,
someone changed how the NNTP server code worked to include the article
number when possible.  So servers which work this way pre-dates dnews....

-- 
Curt Welch                                            http://CurtWelch.Com/
curt@kcwc.com                          Webmaster for http://NewsReader.Com/
Re: New NNTP standard in Working Group Last Call
#68734
Author: Colin Wilson
Date: Sun, 21 Mar 2004 17:38
32 lines
2048 bytes
Curt Welch wrote:

> I found two version of it.  One version, which seems to be version
> 1.5.11 from around 1991, did have a hard-coded 0 for all look-ups by
> version 1.5.11 from around 1991
> ...
>
> Message-ID:
> 
>         printf("%d 0 %s Article retrieved, %s.\r\n",
>                 OK_ARTICLE + method, argv[1], verbiage[method]);
> ...
> 
> However, I also found version 1.5.12.1 which has this:
> 
>          printf("%d %ld %s Article retrieved, %s.\r\n",
>                         OK_ARTICLE + method, group_artnum, argv[1],
>                         verbiage[method]);

Thanks for that - it's interesting to see how these things develop.
Doesn't make writing a newsreader any easier though!

-- 
Colin

Creator of XanaNews & XanaNewz!

web: www.wilsonc.demon.co.uk/delphi.htm
mail: colin@wilsonc.demon.co.uk

Posted with Xananews 1.16.1.13
Re: New NNTP standard in Working Group Last Call
#68735
Author: Colin Wilson
Date: Sun, 21 Mar 2004 18:34
98 lines
5335 bytes
Curt Welch wrote:

> To support a full feed with a "typical" user load and typical
peering, > you must have a network of machines highly optimized to keep
up with
> the volume.  There is no CPU, or network bandwidth, or disk bandwidth 
> to spare any more.

Yes, the mind boggles as to how much raw data goes into the newsgroups.
Do you have any statistics?  Like how many messages are posted to
usenet per day?  How many gigabytes? etc.

> However, for something as minor as putting the article number in the
> response by forcing the CPU to parse the Xref: line, that amount of
> load is trivial.  It's a .00001 % increase in load, if you have a
> valid Xref:  line to parse.

I'd like to think that if you're in a group (ie. you've sent a "GROUP
<groupname>" command) and you subsequently retrieve articles, either
with ARTICLE <message no> or ARTICLE <article-id> you'll always get a
valid Xref - with the important *caveat*: so long as you stick to
articles in the range that was returned in the GROUP command's response.

I can accept that sometimes you could do ARTICLE <article-id> on a
message that hadn't yet been digested by the code that dishes out
message numbers, and you wouldn't get an Xref.  But surely that
couldn't apply to messages in the GROUP response's range?

I'm trying to find out whether there are any servers out there that
this isn't true for - with the caveat above.

> search the entire group for a match. ...   A linear search of a 
> newsgroup with millions of articles just to allow the server to 
> respond to a STAT command is total unworkable.

I agree!  But in this particular case you know the date/time for the
article you're trying to find, and messages are (mostly!) in date/time
order, so you can use a binary search to find the message number, based
on this.  At least you'd (probably) find the right area to do a linear
search within.

But I'm not suggesting that it should be down to the server to do this.
As long as it returns an Xref containing the correct message number for
messages that it has given a Number to, that would be good enough.
 
> What would?  Knowing the article number when you already know the
> Message-ID?  I don't get your point.  When checking multiple servers,
> it's the Message-ID and not the article number you need.

Just supposing I want to combine and decode an attachment that's been
split across several messages.  I have part [1/5], part [2/5], part
[3/5] and part [5/5], but part [4/5] is missing from the server.

It occured to me that I could:

1. Look up the Article ID for the first and last part on another server.

2. Find the message numbers for these articles on the other server.

   I'd have to do this because of course they could well have different
   numbers on the other server.

3. Do an XOVER between these two message numbers to try and find the
   missing part.

> > > But back in those days, the RFC really wasn't the standard, the
> > > reference NNTP implementation and INN were the standard.
> > 
> > That may well be true, but it's a dreadful situation!

> It wasn't dreadful at all.  The source code was a fine standard.


??? Like you said in another message, there are several versions of the
source code - some support some functions, others don't.  Where's the
standard??

> People started to get confused and think that Usenet was an Internet 
> "thing".  And they started to make the totaly false assumption that
> Usenet was documented in the RFCs like the rest of the TCP/IP world.

Yes - I too had assumed that. :(

> But that's exactly what this current work is all about.  To attempt
> for the first time to translate all the C code into english.

Thanks to all involved.  It's very welcome and will be much appreciated.

-- 
Colin

Creator of XanaNews & XanaNewz!

web: www.wilsonc.demon.co.uk/delphi.htm
mail: colin@wilsonc.demon.co.uk

Posted with Xananews 1.16.1.13
Re: New NNTP standard in Working Group Last Call
#68739
Author: Curt Welch
Date: Sun, 21 Mar 2004 21:21
205 lines
11953 bytes
"Colin Wilson" <colin@wilsonc.demon.co.uk> wrote:
> Curt Welch wrote:
>
> > To support a full feed with a "typical" user load and typical
> peering, > you must have a network of machines highly optimized to keep
> up with
> > the volume.  There is no CPU, or network bandwidth, or disk bandwidth
> > to spare any more.
>
> Yes, the mind boggles as to how much raw data goes into the newsgroups.
> Do you have any statistics?  Like how many messages are posted to
> usenet per day?  How many gigabytes? etc.

Here's one site you can check recent stats at:

http://newsfeed.visi.com/

Volume is currently around 1TB (yes 1024 GB) per day and about 4 million
articles per day.  The highest volume groups get about 60 GB and 200,000
articles per day.

This means the bandwidth needed to receive a full feed is now over 100
Mbits.

This means that a news server has to receive, store, and index, 45 articles
per second 24x7.  And after it's been down for a few minutes, it needs to
processes them 2 or 3 times faster than that if it's gonig to get caught up
in a resonable amount of time because the Usenet feed never stops.

> > However, for something as minor as putting the article number in the
> > response by forcing the CPU to parse the Xref: line, that amount of
> > load is trivial.  It's a .00001 % increase in load, if you have a
> > valid Xref:  line to parse.
>
> I'd like to think that if you're in a group (ie. you've sent a "GROUP
> <groupname>" command) and you subsequently retrieve articles, either
> with ARTICLE <message no> or ARTICLE <article-id> you'll always get a
> valid Xref - with the important *caveat*: so long as you stick to
> articles in the range that was returned in the GROUP command's response.

I'd like to think you get a valid Xref with every article or header you
retrive with no cavates.  But I think it's going too far to require that
Xref: even be supported let alone force it to always be correct.  I've not
read the new draft to see how or if it addresses the "Xref:" issue (or if
if it even tries to).

> I can accept that sometimes you could do ARTICLE <article-id> on a
> message that hadn't yet been digested by the code that dishes out
> message numbers, and you wouldn't get an Xref.  But surely that
> couldn't apply to messages in the GROUP response's range?

On distributed servers, there is no end of variations on how the unerlying
system works and on almost all variations, you get things you never would
have expected if you have not tried to design and build a distributed
Usenet server yourself.

The problem with Usenet is that there's seldom enough money to "do it
right", so as usenet grows, we all tend to hack together solutions to keep
it working until we have some more time to try and do it right.  Most the
time, the "hacked together" solutions have side effects which didn't exist
in the old system.  Articles showing up out of order is one example of a
common side effect.  Articles that are there one minute, gone the next, and
then return later are another side effect.  Articles which can be retrieved
by one method (group/article-number) but not another (message-id), is
another common side-effect.  Group commands which return a lower high-water
mark than it has in the recent past is another side effect.  There's no end
to the number of unexpected protocol violations what will actually exist on
servers at times these days.

Having the server return a completly different message by Message-Id than
when you fetch it by article number is even a possibility because many
large servers use different back-ends and determine which back-end to get
an article from using different techniques when you fetch by
group/article-number than when you fetch by message-id.  And because
duplicate messages with the same Message-Id do happen on Usenet, it's quite
possible that the two back-ends will have different articles and also have
different Xref: information for them.  The probability is even higher when
the article is cross posted.

Beacuse Usenet data (the articles) have so little real value, everything
about Usenet tends to be very sloppy in order to keep costs low.  The only
real guiding factor is does the entire system work "most the time".  This
is the other end of the scale from an engineering problem like sending a
person to the moon where any small engineering error is likely to kill the
someone.

> I'm trying to find out whether there are any servers out there that
> this isn't true for - with the caveat above.

You can never really trust Xref: completly.  Any code that makes use of it
should assume it could be completly wrong.  You shouldn't do anything with
xref data that would cause the newsreader to crash or corrupt it's
information about other articles if the xref was wrong.

There are so many different servers in use today that it's very hard to say
anything for sure about what a widely used newsreader might run into.  You
just have to do a lot of testing and evolution of your software over time
to address all the problelms you run into.

The real bitch about writting NNTP software is that this knowledge of what
works and what doesn't has never been recorded anywhere other than the
source code of the packages that exist.  This means that whenever someone
new starts to write an NNTP client, they will always make false assumptions
about how things "should" work, which will come back to bite them.  Only
after a few major rewrites and a lot of patching are you likely to end up
with a "good" general purpose nntp client.  Of course it's hoped that the
current project will minimize these problems in the future.

> > search the entire group for a match. ...   A linear search of a
> > newsgroup with millions of articles just to allow the server to
> > respond to a STAT command is total unworkable.
>
> I agree!  But in this particular case you know the date/time for the
> article you're trying to find, and messages are (mostly!) in date/time
> order, so you can use a binary search to find the message number, based
> on this.  At least you'd (probably) find the right area to do a linear
> search within.

Yeah, but when some groups are geting 200,000 articles per day and the date
error on articles can be days old, you still have to search hundreds of
thousands of articles to reduce the probablity of missing an article which
is there but was ciculated with a 2 day old date.  It's just not a very
good solution.

> But I'm not suggesting that it should be down to the server to do this.
> As long as it returns an Xref containing the correct message number for
> messages that it has given a Number to, that would be good enough.
>
> > What would?  Knowing the article number when you already know the
> > Message-ID?  I don't get your point.  When checking multiple servers,
> > it's the Message-ID and not the article number you need.
>
> Just supposing I want to combine and decode an attachment that's been
> split across several messages.  I have part [1/5], part [2/5], part
> [3/5] and part [5/5], but part [4/5] is missing from the server.
>
> It occured to me that I could:
>
> 1. Look up the Article ID for the first and last part on another server.
>
> 2. Find the message numbers for these articles on the other server.
>
>    I'd have to do this because of course they could well have different
>    numbers on the other server.
>
> 3. Do an XOVER between these two message numbers to try and find the
>    missing part.

Articles are not guaranted to be posted in order, and they are pretty much
guaranted not to show up in the order they are posted.  This is because
Usenet article distribution allows for a very large number of parallel and
independent paths for articles to travel - each with different amounts of
delay (and some delays for backlogged binary article queues can be many
hours long).  So it's very likely that part 4 will show up with a higher
article number than part 5 on many servers.  And if the guy decided to
re-post part 4 the next day, it's almost guranteeded not to be in the same
range.

Tricks like the above can help narrow the search.  You can start in that
range and then spread out and on average you will find it faster than
having to download headers for the entire group.  But in the end, if you
want to find multiplart messages and you don't have some way to find the
Message-Id, you just have to download all headers.

> > > > But back in those days, the RFC really wasn't the standard, the
> > > > reference NNTP implementation and INN were the standard.
> > >
> > > That may well be true, but it's a dreadful situation!
>
> > It wasn't dreadful at all.  The source code was a fine standard.
>
> ??? Like you said in another message, there are several versions of the
> source code - some support some functions, others don't.  Where's the
> standard??

Good point.  The real answer is that there isn't one. There are many
standards.

However, back in those days - late '80s and early '90s, there were very few
working NNTP implementations.  There were only two major ones, the "nntp"
server software which was an add-on package for a standard Usenet system,
which from my research looks like it was written around 1986, and then INN,
which was a re-write of news which integrated NNTP support into a server
for the (I assume) first time, which was released in 1992.  So there was
one real NNTP standard from 1986 to 1992, and then INN really took over the
role from 1992 into the mid to late '90s after the commercial internet took
off and other servers started to emerge as dominate players like the
Highwind products, Diablo, and dnews.  There are so many total different
servers in use today you can't even count them from high-end custom servers
to the small personal servers.

Whoever made the change to the old nntp server software to make it return
the article number did so after INN had really taken over the lead as "the
NNTP standard" in my eyes.  And in my eyes, they made a change he never
should have made because even though he probably saw it as an
"improvement", I see it as breaking the standard which has been in use for
8 years.

Lots of people have "broken" the standard in lots more important ways since
then however.

-- 
Curt Welch                                            http://CurtWelch.Com/
curt@kcwc.com                          Webmaster for http://NewsReader.Com/
Re: New NNTP standard in Working Group Last Call
#68738
Author: Colin Wilson
Date: Mon, 22 Mar 2004 08:53
25 lines
2184 bytes
Curt Welch wrote:

> Tricks like the above can help narrow the search.

Yes - and that's all I'm after.  I don't really care that much if
someone can't download a particular porno clip with XanaNews!

Typically though, message parts [3/5], [4/5] and [5/5] will be about
5000 lines, so they will have taken at least a few seconds to post.
And because the server will typically timestamp the messages when they
arrive, and use this timestamp when working out the message numbers,
they will almost always be in correct 'message number' order.

And that's good enough for what I want.

-- 
Colin

Creator of XanaNews & XanaNewz!

web: www.wilsonc.demon.co.uk/delphi.htm
mail: colin@wilsonc.demon.co.uk

Posted with Xananews 1.16.1.13
Re: New NNTP standard in Working Group Last Call
#68742
Author: Francois Petillon
Date: Mon, 22 Mar 2004 11:13
16 lines
1937 bytes
On Sat, 20 Mar 2004 10:35:50 +0000, Colin Wilson wrote:
> So is there any way, if you have a header, to find out it's message
> number in a group on a Diablo server?

_If_ you number articles on an header feed, the answer is _no_.

> I suppose as a last resort I'll have to do a binary search on the
> date/time - if the message number wasn't in the 22x response or the
> XRef.

Why do you need that much the article number ? If you (as newsmaster)
really need to retrieve the Xref line, you may setup your numbering
spooler to increase its retention. 

  Fran�ois
Re: New NNTP standard in Working Group Last Call
#68743
Author: Francois Petillon
Date: Mon, 22 Mar 2004 11:40
14 lines
1972 bytes
On Sat, 20 Mar 2004 06:39:51 +0000, Curt Welch wrote:
> It sure would be nice if NNTP didn't use article numbers.  It sure makes
> distributed servers harder.

Not that much. Using article numbers allow you to use overview
informations to choose which spooler to use (here, I have text spoolers &
binary spoolers with different retentions) but it also means I have to
do I/Os to translate the article number into a M-ID. If I have a chance to
rewrite from scratch NNTP, I would set M-ID as a fixed length field (or at
least allow requests by a hash of the M-ID) to allow storing M-ID (or
their hash) in an array and do light xref/M-ID translation.

  Fran�ois
Re: New NNTP standard in Working Group Last Call
#68745
Author: Francois Petillon
Date: Mon, 22 Mar 2004 11:48
18 lines
2241 bytes
On Sat, 20 Mar 2004 06:39:51 +0000, Curt Welch wrote:
> My point of all this is simply that it is possible to get the Xref: correct
> in the spools (and for all HEAD and ARTICLE commands) without forcing a
> single machine to carry the full feed volume.  It may not be easy or
> reasnonable to use this technique for diablo, but it is possible to both
> meet the growing usenet volume demands with a distributed system and not
> force a single machine to carry the full feed.

As far as I am concerned, I see a drawback in your architecture : the
numbering is done before storing articles on the spooler. Typical news
architecture use external feeders, filtering, internal feeders, spoolers
and readers (yes, I dropped numbering). Usually, feeders have smaller
retention than spoolers (here, I have around 15 hours on internal feeders)
which mean problems on numbering server have to be "quickly" solved to
avoid article loss.

  Fran�ois
Re: New NNTP standard in Working Group Last Call
#68746
Author: Francois Petillon
Date: Mon, 22 Mar 2004 11:57
19 lines
2378 bytes
On Sat, 20 Mar 2004 06:39:51 +0000, Curt Welch wrote:
> My point of all this is simply that it is possible to get the Xref: correct
> in the spools (and for all HEAD and ARTICLE commands) without forcing a
> single machine to carry the full feed volume.  It may not be easy or
> reasnonable to use this technique for diablo, but it is possible to both
> meet the growing usenet volume demands with a distributed system and not
> force a single machine to carry the full feed.

As far as I am concerned, I see a drawback in your architecture : the
numbering is done before storing articles on the spooler. Typical news
architecture use external feeders, filtering, internal feeders, spoolers
and readers (yes, I dropped numbering). Usually, feeders have smaller
retention than spoolers (here, I have around 15 hours on internal feeders)
which mean problems on numbering server have to be "quickly" solved to
avoid article loss. And when the problem is solved, the spoolers have to
receive their fullfeed backlog.

  Fran�ois
Re: New NNTP standard in Working Group Last Call
#68750
Author: Clive D. W. Feather
Date: Mon, 22 Mar 2004 16:49
62 lines
3886 bytes
In article <20040320010803.826$XN@newsreader.com>, Curt Welch 
<curt@kcwc.com> writes
>I don't mind the above wording, but I don't like it.  If I had a vote, I'd
>vote against alowing the MAY clause to be added.

Why?

The current wording says, in essence:
- MUST return article number if the request was by number (including
   "current article"), when it is trivial;
- MAY return article number if the request was by message-ID;
- MUST return 0 if it can't or doesn't want to return a number in the
   latter case.

>I would really like to
>see a lot of these little difference between servers removed.  If the new
>stanard "breaks" dnews, then so be it.  The new standard in fact is going
>to break almost all current servers in one minor way or another like this.

This particular item isn't going to break any servers.

>If all the servers don't do the same thing, then news reader authors can't
>use the paramater.

Not so: if the parameter is not there, *then* you fall back to a slower 
or less reliable approach.

>If some servers return 0, then you can't write a
>newsreader that assums the article number from the current group will be
>there.

True, but we've already decided that it's not practical for some servers 
to return the number.

>If some return the article number, then newsreaders can't assume
>that a 0 is there to flag the fact that the lookup was by Message-id.

I don't see this as an issue. The client will (modulo pipelining) have 
just made the request, so it should know which form of request it made! 
I really don't see this as a problem that needs solving.

>It
>becomes almost total worthless and even worse, a potential "bug trap" for
>news client authors that might make the false assumtion that it will be 0
>for all Message-Id look-ups (if they are doing their development on an
>INN-like server), or that it might always return the article number (if
>they are doing their development on dnews-like servers).

Then they need to RTFM.

>Adding the "MAY return the article number" just allows current "broken"
>servers to continue to exist which makes the return value continue to be
>mostly worthless.

I disagree; I think this last change has added benefit for no cost.

-- 
Clive D.W. Feather, writing for himself  | Home: <clive@davros.org>
Tel: +44 20 8495 6138 (work)             | Web:  <http://www.davros.org>
Fax: +44 870 051 9937                    | Work: <clive@demon.net>
Written on my laptop; please observe the Reply-To address
Re: New NNTP standard in Working Group Last Call
#68757
Author: Curt Welch
Date: Mon, 22 Mar 2004 22:45
32 lines
2908 bytes
Francois Petillon <fantec@proxad.net> wrote:
> On Sat, 20 Mar 2004 06:39:51 +0000, Curt Welch wrote:
> > My point of all this is simply that it is possible to get the Xref:
> > correct in the spools (and for all HEAD and ARTICLE commands) without
> > forcing a single machine to carry the full feed volume.  It may not be
> > easy or reasnonable to use this technique for diablo, but it is
> > possible to both meet the growing usenet volume demands with a
> > distributed system and not force a single machine to carry the full
> > feed.
>
> As far as I am concerned, I see a drawback in your architecture : the
> numbering is done before storing articles on the spooler. Typical news
> architecture use external feeders, filtering, internal feeders, spoolers
> and readers (yes, I dropped numbering). Usually, feeders have smaller
> retention than spoolers (here, I have around 15 hours on internal
> feeders) which mean problems on numbering server have to be "quickly"
> solved to avoid article loss. And when the problem is solved, the
> spoolers have to receive their fullfeed backlog.

I'm a bit confused as to what your point is.

Are you saying numbering should be done on the header feed after the
articles are stored?  And if you do that, how do you return valid Xref:
headers when fetching headers or articles by Message-ID?

Are you also saying that numbering is somehow harder before the spoolers
than after them?  Why is that?

-- 
Curt Welch                                            http://CurtWelch.Com/
curt@kcwc.com                          Webmaster for http://NewsReader.Com/
Re: New NNTP standard in Working Group Last Call
#68762
Author: Curt Welch
Date: Mon, 22 Mar 2004 23:39
154 lines
8614 bytes
"Clive D.W. Feather" <clive@davros.org> wrote:
> In article <20040320010803.826$XN@newsreader.com>, Curt Welch
> <curt@kcwc.com> writes
> >I don't mind the above wording, but I don't like it.  If I had a vote,
> >I'd vote against alowing the MAY clause to be added.
>
> Why?

Well, I thought I had explained why in my message.

> The current wording says, in essence:
> - MUST return article number if the request was by number (including
>    "current article"), when it is trivial;
> - MAY return article number if the request was by message-ID;
> - MUST return 0 if it can't or doesn't want to return a number in the
>    latter case.
>
> >I would really like to
> >see a lot of these little difference between servers removed.  If the
> >new stanard "breaks" dnews, then so be it.  The new standard in fact is
> >going to break almost all current servers in one minor way or another
> >like this.
>
> This particular item isn't going to break any servers.

If you put a MAY clause in then nothing breaks.  If you leave it out, then
any serevr not returning 0 is broken.

> >If all the servers don't do the same thing, then news reader authors
> >can't use the paramater.
>
> Not so: if the parameter is not there, *then* you fall back to a slower
> or less reliable approach.

If the paramater is not there the server is broken and many clients would
get a parse error on the line.

If the value of the paramater is 0, it is there.  I think this is the
difference between how you and I are looking at it.  You see a 0 value as
meaning "information not available".  I don't see it that way.  I see it as
meaning "lookup was by Message-ID".  If the server returns a value that
says "lookup was not by Message-ID" when in fact it should have returned
"lookup was by Messaeg-ID" the server has broken the standard.  It's
returned the wrong value.

> >If some servers return 0, then you can't write a
> >newsreader that assums the article number from the current group will be
> >there.
>
> True, but we've already decided that it's not practical for some servers
> to return the number.
>
> >If some return the article number, then newsreaders can't assume
> >that a 0 is there to flag the fact that the lookup was by Message-id.
>
> I don't see this as an issue.

I know you don't.  That's why you don't get the point I was making.

> The client will (modulo pipelining) have
> just made the request, so it should know which form of request it made!
> I really don't see this as a problem that needs solving.

You miss the problem I was trying to present.

News servers have been returning 0 for Message-ID lookup for 16 years.  In
that time, some client might have been written to make use of that fact.
If you change the protocol, you risk breaking clients that are using the
information.

Sure, it's trivial for a client to know what type of lookup it just did,
and to use that instead of using the return value.  But if it was written
with the assumption that the value is always 0 for a Message-ID lookup, the
client won't work on servers that sometimes return a non-zero article
number.

My argument is purely one of aesthetics.  It's bad protocol design to allow
_any_ conditional behavior.  It increases the probability that bugs will
exist in the code that tend to crop up at unexpected times.

For example, code could be written which reads the return value, and uses
the fact that a 0 for the article number means the lookup was done by
Message-ID and the data could be sent to a different routine to processes
the Message-ID fetch vs the article number fetch.  This could would work
fine on a server which always returns 0.  It might also work fine on
servers like dnews because just by chance, all Message-ID lookups were
always done before a GROUP was selected.  So the code was writen and tested
on many servers and it works great.

Much later, someone modifies the client, and this new feature they add
causes the client to sometimes select a GROUP before some of the Message-ID
lookups.  They test the new functions on multiple servers and it all works
great.  And it gets a lot of testing on a server which always returns 0,
and that works great.  But them, the software is shipped, and someone uses
it on a dnews-like server, and they find that sometimes, the code does
strange things.

The fact that the article number is _sometimes_ returned based on what
GROUP is selected is bad design to begin with.  The fact that some servers
MAY do it while others don't have to, makes the design even worse.

> >It
> >becomes almost total worthless and even worse, a potential "bug trap"
> >for news client authors that might make the false assumtion that it will
> >be 0 for all Message-Id look-ups (if they are doing their development on
> >an INN-like server), or that it might always return the article number
> >(if they are doing their development on dnews-like servers).
>
> Then they need to RTFM.

Of course.  But if you keep the protocol design simple, they can remeber it
after one reading instead of having to have a printed reference copy on
hand all the time. :)

> >Adding the "MAY return the article number" just allows current "broken"
> >servers to continue to exist which makes the return value continue to be
> >mostly worthless.
>
> I disagree; I think this last change has added benefit for no cost.

Well then, you miss the point I'm making about the true cost of bad
protocol design then.

If no clients have ever been written, and if no programmer ever makes the
mistake of thinking it will always be 0 for a Message-ID lookup, then the
true cost is 0.  But any protocol feature that "sometimes works" has a
value near 0 as well.  If the number is not always returned, then few
clients, if any, will be able to make use of it.  If the client needs to
know the article number, it will have to use some other system to find it.

The original protocol design, where the number 0 was _always_ returned is a
far better design.  By allowing servers to somtimes return 0, and sometimes
return an article number, you have made the return value almost useless.

It's like the design for a power light which which is red to show the
machine is in standby, and green to show the machine is on, and off to show
the machine is off, but then you change the design to say that the light
MAY be red when the machine is off.  You have made the light useless for
telling when the machine is off, just like you have made the return value
useless for telling when the look-up was done by Message-ID.

We do not have enough facts to determine the true value or the true cost,
so we can not prove which is, or would be, better.

But, I think we both agree that the true cost and true value of doing it
either way is insignificant enough as to not be important.  If you feel
it's better with the MAY, cluase, so be it.  I'm happy with that.  If you
still don't understand why I think it's better without it (and want to),
I'm happy to keep writing. :)

-- 
Curt Welch                                            http://CurtWelch.Com/
curt@kcwc.com                          Webmaster for http://NewsReader.Com/
Re: New NNTP standard in Working Group Last Call
#68791
Author: Francois Petillon
Date: Thu, 25 Mar 2004 15:07
23 lines
2161 bytes
On Mon, 22 Mar 2004 22:45:57 +0000, Curt Welch wrote:
> Are you saying numbering should be done on the header feed after the
> articles are stored?  

I am saying if your architecture has a single point of failure, I prefer
to have this single point of failure behind the spooler (ie once the
article has been stored).

> And if you do that, how do you return valid Xref:
> headers when fetching headers or articles by Message-ID?

You do not.

> Are you also saying that numbering is somehow harder before the spoolers
> than after them?  Why is that?

Because if your server fails, you need extra CPU/disks/network to
keep/send the backlogs on your feeders and to store them on your spoolers.

If there is no single point of failure, then I just do not care... :-)

  Fran�ois
Re: New NNTP standard in Working Group Last Call
#68792
Author: Curt Welch
Date: Thu, 25 Mar 2004 16:21
66 lines
4678 bytes
Francois Petillon <fantec@proxad.net> wrote:
> On Mon, 22 Mar 2004 22:45:57 +0000, Curt Welch wrote:
> > Are you saying numbering should be done on the header feed after the
> > articles are stored?
>
> I am saying if your architecture has a single point of failure, I prefer
> to have this single point of failure behind the spooler (ie once the
> article has been stored).

Ok, sure, I understand you point.

> > And if you do that, how do you return valid Xref:
> > headers when fetching headers or articles by Message-ID?
>
> You do not.

I guess it could be done now that I think about it.  You could maintain a
header database indexed by message-id as well as the full article database.
The header-only database would have valid Xref data where as the full
article database would not.  Whenever a user requested an article by
Message-ID, you could fetch both the header with the valid Xref: data from
the header only database and the full article and put the two together.  Or
instead of a full header database (which could be used for HEAD by
Message-ID as well), you could just maintain an xover database by
Message-ID, or just an xref database indexed by Message-Id.

> > Are you also saying that numbering is somehow harder before the
> > spoolers than after them?  Why is that?
>
> Because if your server fails, you need extra CPU/disks/network to
> keep/send the backlogs on your feeders and to store them on your
> spoolers.

Sure, I see your point.  But you always need excess power to deal with
volume spikes as well as down time of any of the componenets so you will
always have some ability to catch up with a backlog.  So you have to look
at the expected MTBF of your single point of failure hardware and your
expected time of repair for any failure, and trade off the cost of those
problems against the cost of not having valid Xref: headers in articles
fetched by Message-ID.  Is it worse to have the service backlogged and
maybe loose some articles one day a year, or to not be able to provide
valid Xref: data on mid article fetches every day of the year?  There is no
one right answer to that question.

The bigger problem I see with having your article numbering system deal
with a full feed is the simple problem that you you must use a single
larger system for that instead of being able to split it up across multiple
smaller and cheaper systems.

> If there is no single point of failure, then I just do not care... :-)

That is the root issue of my comment earlier in this thread about how the
article numbering which the NNTP protcol requires is a problem.  The fact
that you must number the articles sequentially as they show up creates a
single point of failure.  It's impossible to build a completely redundant
usenet server with no single point of failure because of the article
numbering requirement of the protocol.

You have to either make the single point of falure as reliable as possible
to minimize down time, or you make it redundant, and accept the fact that
articles may be lost or duplicated when there's a failure.

-- 
Curt Welch                                            http://CurtWelch.Com/
curt@kcwc.com                          Webmaster for http://NewsReader.Com/
Re: New NNTP standard in Working Group Last Call
#68794
Author: Dr.Ruud
Date: Thu, 25 Mar 2004 18:18
40 lines
3102 bytes
Toen ik Curt Welch kietelde, kwam er dit uit:
> Francois Petillon:

>> If there is no single point of failure, then I just do not care... :-)

> That is the root issue of my comment earlier in this thread about how
> the article numbering which the NNTP protcol requires is a problem.
> The fact that you must number the articles sequentially as they show up
> creates a single point of failure.  It's impossible to build a
> completely redundant usenet server with no single point of failure
> because of the article numbering requirement of the protocol.
>
> You have to either make the single point of falure as reliable as
> possible to minimize down time, or you make it redundant, and accept
> the fact that articles may be lost or duplicated when there's a failure.

(With possibly some lenience) you can have both.

The system that does the numbering, should be redundant in a master/slaves
way: if the master disappears, one of the slaves becomes the new master
(in a predictable order).

Each time a number (or a set or range of numbers) is requested from the
numbering system, the master sends the reply to the requestor and to all
the slaves. These slaves can be daemons on all machines involved.

If you allow for a range of numbers to be requested, the number of
requests
is of course much lower, but articles are no longer numbered absolutely
sequential, unless there is another layer added that translates the (still
unique) local numbering to public numbering.

-- 
Affijn, Ruud   `  -  ?
               + ` ? *
                 ? `
               ?  =  `


Re: New NNTP standard in Working Group Last Call
#68796
Author: Kai Henningsen
Date: Thu, 25 Mar 2004 20:42
21 lines
2226 bytes
colin@wilsonc.demon.co.uk (Colin Wilson)  wrote on 22.03.04 in <xn0dg2nce26igz001@news.clara.net>:

> Typically though, message parts [3/5], [4/5] and [5/5] will be about
> 5000 lines, so they will have taken at least a few seconds to post.
> And because the server will typically timestamp the messages when they
> arrive, and use this timestamp when working out the message numbers,
> they will almost always be in correct 'message number' order.

Where do you get the idea that message numbers have anything to do with  
what's in an article's headers? Any such relation is purely accidental.  
Message numbers are related to the sequence articles *arrive* in, which  
usually is only very loosely related to the sequence they were posted in.  
(And, incidentally, the posting sequence need not be related to the Date:  
headers anyway.)

Kai
-- 
http://www.westfalen.de/private/khms/
"... by God I *KNOW* what this network is for, and you can't have it."
  - Russ Allbery (rra@stanford.edu)
Re: New NNTP standard in Working Group Last Call
#68801
Author: Curt Welch
Date: Fri, 26 Mar 2004 01:47
112 lines
7641 bytes
"Dr.Ruud" <(rvtol+news(AT)hacktic.nl) Administrator@[127.0.0.1]> wrote:
> Toen ik Curt Welch kietelde, kwam er dit uit:
> > Francois Petillon:
>
> >> If there is no single point of failure, then I just do not care... :-)
>
> > That is the root issue of my comment earlier in this thread about how
> > the article numbering which the NNTP protcol requires is a problem.
> > The fact that you must number the articles sequentially as they show up
> > creates a single point of failure.  It's impossible to build a
> > completely redundant usenet server with no single point of failure
> > because of the article numbering requirement of the protocol.
> >
> > You have to either make the single point of falure as reliable as
> > possible to minimize down time, or you make it redundant, and accept
> > the fact that articles may be lost or duplicated when there's a
> > failure.
>
> (With possibly some lenience) you can have both.
>
> The system that does the numbering, should be redundant in a
> master/slaves way: if the master disappears, one of the slaves becomes
>   the new master
> (in a predictable order).

Yes, you can create a redundant system like that to attempt to improve
reliability, but you still can't make it work all the time.  You have
to accept the fact that articles may be lost or duplicated when there's a
failure.  You can't have error-free operation and redundancy.

> Each time a number (or a set or range of numbers) is requested from the
> numbering system, the master sends the reply to the requestor and to all
> the slaves. These slaves can be daemons on all machines involved.
>
> If you allow for a range of numbers to be requested, the number of
> requests
> is of course much lower, but articles are no longer numbered absolutely
> sequential, unless there is another layer added that translates the
> (still unique) local numbering to public numbering.

With distributed systems you have a well known problem of partitioning for
which there is no solution.  If you try to create a master/slave system,
there must be a provision for converting a slave into the master if the
master fails.  But, this conversion can only work without errors if all
servers in the system know who is the current master at the exact same
time, but that can't be done.  You have to replace your previous single
point of failure (article numbering) with a new one - a master arbitrator.
So by creating the master-slave system you have not created an error-free
reduant system.

The problem goes back to the issue of communication.  There must be
communication between the various distirbuted components, but
communication, as well as the servers/processes, can fail.  A server can
not tell the difference between failed communication, and a failed
processes.  If the master and slave loose touch with each other, they will
both think the other has failed, so the slave will think it needs to start
acting as the master, and the master will continue to be a master thinking
the slave has died.

If the communication failure that caused the master and slave to be
partitioned into two independent systems allowed some of the clients to be
partitioned with the slave, and left others partitioned with the master,
then you have two independent systems running with two independent masters,
totally corrupting article numbers left and right.

This partitioning problem has no solution.  It's well known in distributed
system design.  What you can do however is use a good design to greatly
improve your MTBF and to minimze the impact of the errors when they do
happen.  If you can push the MTBF to a few thousand years for a Usenet
server, you have more than solved all the practical problems even if the
ultimate 0 down-time distributed system hasn't been created.

In my current server, the numbering server acts as a master, and all my
front-end servers act as slaves.  However, there is no attempt to
auto-promote a slave to a master.  I can however manually convert any
front-end server into the master in a few minutes with a simple
configuration change.  However, it's quite possible that the old (now dead)
master had received some articles which it was not able to tell the
front-end server about.  Those articles will be lost.  But since the
probability of the master failling is small, the system is "good enough".

I'm quite sure it's impossible to create a distributed Usenet server that
won't at times mis-number articles and/or get out of sync and/or loose
articles.  You can shape the probability of the various types of errors
with the right designs, but you can't eliminate them all.

On the other hand, a news server that used a different protocol than NNTP
which didn't require article numbering would be easy to make redundant and
distributed.  The only error you would be left with is the same one Usenet
is already forced to live with - the possibility of two different articles
having the same Message-ID.  However, without something to replace article
numbers, the job of a news client to identify new articles becomes
unresonably expensive (it would require the client to request a dump of the
message-id of every article in the group on the server every time it
connected).

I've not spent a lot of time thinking about what a new version of an
NNTP-like protocol might make the job of of the client still resonobable
and also work better than article numbers for a redundant distributed
server.  Some use of timestamps might be a resonable middle ground between
the two extremes of strict article numbers and no sequencing at all.

When I tried to post the above message, I found my server was dead.  It
seems a raid controller wasn't working as well as it should have.  It's
funny how you can stop to write a message which touches on the subject of
server reliability and your server manages to die while you are writing it.
At least it wasn't my master server which numbers articles which died. :)

-- 
Curt Welch                                            http://CurtWelch.Com/
curt@kcwc.com                          Webmaster for http://NewsReader.Com/
Re: New NNTP standard in Working Group Last Call
#68802
Author: Dr.Ruud
Date: Fri, 26 Mar 2004 03:27
116 lines
6616 bytes
Toen ik Curt Welch kietelde, kwam er dit uit:


Thanks for your reply. I am not very familiar with all the
constraints of feeding and sucking, I am comparing this to
database-replication.

> You can't have error-free operation and redundancy.

OK.


> [conversion from slave to master] can only work without
> errors if all servers in the system know who is the current master at
> the exact same time, but that can't be done.  You have to replace your
> previous single point of failure (article numbering) with a new one - a
> master arbitrator. So by creating the master-slave system you have not
> created an error-free redundant system.

But that time-point can be stretched if the systems have a range of
numbers to work from. This means that each machine goes solo for a
while, receiving articles. When there are no more article-numbers
in stock, or some period of time has passed, the article-numbering
is synchronized with the master (which can send some numbers back
to the machine's article-number-store, because the article was
already known). This synchronization is logged by all the slaves
(and processed when possible or necessary). Is that feasible?

Or don't you want for machines to run independent for such a period
of time, because they can of course fail in that time? Or don't
you want article-numbers stay unused for a while, meaning that
article #100 is already promoted to the front-end server, while
article #1 is allocated but still has no actual article.


> The problem goes back to the issue of communication.  There must be
> communication between the various distributed components, but
> communication, as well as the servers/processes, can fail.  A server can
> not tell the difference between failed communication, and a failed
> processes.

Can a 'heartbeat' minimize that problem? A process that still sends
heartbeats, should acknowledge a communication within a few heartbeats,
or be considered failing.


> If the master and slave loose touch with each other, they
> will both think the other has failed, so the slave will think it needs
> to start acting as the master, and the master will continue to be a
> master thinking the slave has died.

Before it becomes a master, the converting slave asks for approvals.
There is a timeframe of a few minutes, since all machines that
receive articles have a range of article-numbers to use up.

Only a system that gets some minimum number of votes (more than
half the original number of slaves) can become master. There can
never be more than one master. If, even after some retries, the
voting fails, human intervention is called for.


> In my current server, the numbering server acts as a master, and all my
> front-end servers act as slaves.  However, there is no attempt to
> auto-promote a slave to a master.  I can however manually convert any
> front-end server into the master in a few minutes with a simple
> configuration change.  However, it's quite possible that the old (now
> dead) master had received some articles which it was not able to tell
> the front-end server about.  Those articles will be lost.  But since the
> probability of the master failling is small, the system is "good
> enough".

I don't see the master as a server that is receiving articles. OK,
it knows (a lot) about all articles. It might even have a copy of
important headerlines (or hashes of their values) of all articles.
Or just of all Message-IDs (and -hashes). But that is another subject.
Is that the right way to model a master?


> I'm quite sure it's impossible to create a distributed Usenet server
> that won't at times mis-number articles and/or get out of sync and/or
> loose articles.  You can shape the probability of the various types of
> errors with the right designs, but you can't eliminate them all.

Ack.


> On the other hand, a news server that used a different protocol than
> NNTP which didn't require article numbering would be easy to make
> redundant and distributed.  The only error you would be left with is
> the same one Usenet is already forced to live with - the possibility of
> two different articles having the same Message-ID.  However, without
> something to replace article numbers, the job of a news client to
> identify new articles becomes unresonably expensive (it would require
> the client to request a dump of the message-id of every article in the
> group on the server every time it connected).

Yes, though proper hashing of Message-IDs minimizes the search area.


> When I tried to post the above message, I found my server was dead.  It
> seems a raid controller wasn't working as well as it should have.  It's
> funny how you can stop to write a message which touches on the subject
> of server reliability and your server manages to die while you are
> writing it. At least it wasn't my master server which numbers articles
> which died. :)

Lucky us.

-- 
Affijn, Ruud   `  -  ?
               + ` ? *
                 ? `
               ?  =  `


Re: New NNTP standard in Working Group Last Call
#68803
Author: Curt Welch
Date: Fri, 26 Mar 2004 06:34
255 lines
15876 bytes
"Dr.Ruud" <(rvtol+news(AT)hacktic.nl) Administrator@[127.0.0.1]> wrote:
> Toen ik Curt Welch kietelde, kwam er dit uit:
>
> Thanks for your reply. I am not very familiar with all the
> constraints of feeding and sucking, I am comparing this to
> database-replication.
>
> > You can't have error-free operation and redundancy.
>
> OK.
>
> > [conversion from slave to master] can only work without
> > errors if all servers in the system know who is the current master at
> > the exact same time, but that can't be done.  You have to replace your
> > previous single point of failure (article numbering) with a new one - a
> > master arbitrator. So by creating the master-slave system you have not
> > created an error-free redundant system.
>
> But that time-point can be stretched if the systems have a range of
> numbers to work from. This means that each machine goes solo for a
> while, receiving articles. When there are no more article-numbers
> in stock, or some period of time has passed, the article-numbering
> is synchronized with the master

Well, first off, each group has it's own article number sequence.  There
isn't one global numbering happening, there's 100,000 different sequence
numbers, one for each group.  So if you want to assign a block to one
server, you have to assign a block from each group, which is a lot of data
to to "assign".

But more important, articles must show up externally to the clients in
sequence.  If you assign a block of numbers like 100 to 110, to one server,
and 111 to 120 to a second server, articles will show up such as 100, then
111, then maybe 112, then 101.  You can never have a lower article number
show up after a higher article has already been made visible to the
clients.

The reason for this is because the client is told what the high water mark
is, and is allowed to make the assumption that all articles below that
point are already available on the server.  If any article with a number
below the high water mark returns error when you try to fetch it, then the
client should assume the article has expired, or been canceled, and that it
will never return.

You do have the ability to skip numbers without great harm being done, but
you can't have the articles show up out of sequence, so the idea of assign
different blocks of numbers to independent servers just isn't going to be
workable.

> (which can send some numbers back
> to the machine's article-number-store, because the article was
> already known). This synchronization is logged by all the slaves
> (and processed when possible or necessary). Is that feasible?
>
> Or don't you want for machines to run independent for such a period
> of time, because they can of course fail in that time? Or don't
> you want article-numbers stay unused for a while, meaning that
> article #100 is already promoted to the front-end server, while
> article #1 is allocated but still has no actual article.

Right, if article 100 has been made available to the users/clients, then
you have shut the door on the option of having article 99, or 98, or 1,
show up later.

> > The problem goes back to the issue of communication.  There must be
> > communication between the various distributed components, but
> > communication, as well as the servers/processes, can fail.  A server
> > can not tell the difference between failed communication, and a failed
> > processes.
>
> Can a 'heartbeat' minimize that problem? A process that still sends
> heartbeats, should acknowledge a communication within a few heartbeats,
> or be considered failing.

If the network fails and netither server can talk to the other, then they
both assume the other has died when in fact neither has.  If the network
fails in a way that cuts them off from each other, but not from some of the
other parts of the system that's trying to get article numbers, then
everything gets confused.

> > If the master and slave loose touch with each other, they
> > will both think the other has failed, so the slave will think it needs
> > to start acting as the master, and the master will continue to be a
> > master thinking the slave has died.
>
> Before it becomes a master, the converting slave asks for approvals.

Asks who for approval!  That's the point, there is no single "master" to
ask.  And if there is a single master then that single master becomes the
single poing of falure you have to figure out how to prevent from failing.
SO what do you do then, set up a master master and a slave master?  Do you
see the recursion problem here which has no solution?

The idea is that you have multiple independent boxes receiving articles,
and independently, they need to asign article numbers based on what groups
the articles they recieve are posted to.  At the same time, you need a
master to not only assign article numbers, but guarantee that you have not
duplicated an article (assigned two different numbers to the same article).
But that fact was just being ignored because it's more of the same problem.

So if you have two spool servers, A, and B, and a master article number
assigner M, and the slave S, the spool servers will normally ask M for the
correct number for each article, and every article M deals with, it sends
updates to S to let S stay in sync with M.

If spool server B can't contact M, the assumption is that it's down, so it
contact the slave S.  The slave S can't contact M either, so B and S
together decide the Master is down and S is now the new master.  So S
starts assigning article numbers for B.

But at the same time, it's possible that the master M is still working, and
that the only real problem is a network problem which prevents M from
talking to either S or B.  But what if it can still talk to A, but A,
because of the same network failure, can't talk to S or B.  M and A think
that both the slave, and spool server B have crashed.  This is not a
problem, because you have redundant parts for both, so M continues along
assigning article numbers for spool server A.

You have the distributed network partitioned into two working subsets which
both think (incorrectly) that the other subset has crashed.

Creating a reduant and acurate copy of some information (such as the
current sequence number for each group in the active file) is easy when the
redundant componets are working.  But when there's a failure, the system
must halt if accuracy at all cost is required.  However, what you can
always do is to use a single point of failure which has a very low
probability of failing, and use that to act as the master arbitrator for
the reduntand components.  And as long as that single high reliability
componet is working, everything is redundant, and guaranteed to continue
functioning correctly even in the face of multiple failures.  You could for
example create a single master abitrator which the slaves and servers all
talk to just to find out the state of the network.  Any component which
can't talk to the master controler, should consider itself off-line and
stop all functioning.  The master controler is the one that will decide
which box is assigning article numbers, and if that box dies, and the
function needs to be assigned to another box, it's the master controler
which does all the cordination with all the components to make sure the
switch happens and happens without err.

A system like that can be built where the master controler is the only
single point of failure, and the relieablitly of the system can then become
a function of how reliable that master controler is.  For computer hardware
you can make it very relieable by putting the software in ROM and not
having a disk, and by not having any fans that can fail etc.

Or, if the master "controling" task is simple enough, then the master
controler may just be a few electronic components and no software at all.

Usenet news servers however are not so important that you would take this
stuff very far.  Having a single point of failure for the master article
number server is what every server I know does.   If it fails, the server
stops receiving new articles unilt it's fixed, and that's normally good
enough.  A lot of systems require that single point of failure to receive a
full news feed, some require it to receive only a full header feed, and
others have segmented usenet into sets of groups and use a separate master
article number server for each subset.

> There is a timeframe of a few minutes, since all machines that
> receive articles have a range of article-numbers to use up.
>
> Only a system that gets some minimum number of votes (more than
> half the original number of slaves) can become master. There can
> never be more than one master. If, even after some retries, the
> voting fails, human intervention is called for.

Yeah, stuff like that is done to shape the characteristic of the failure.
If the master and slave segment, you have the risk of them running
independently, which for this application would be bad, for other
applications, it might not be so bad.  So what do you want the system to do
when the handoff to the slave fails?  Run independently, or halt?  A voting
system like you suggest above causes it to fail on the side of halting,
which would probably be a good choice for a Usenet server.  If halting is
worse than having them run independently, then you wouldn't use a voting
system like that.  For example, if you have two water pumps acting as
backups for each other, and a master controler uses presure sensors to tell
if the master is working, and to activate the secondary if the master
fails, what should the controler do if it detects a failure in the master
presure sensor and is unable to determine if only the presure sensor failed
or if the pump failed because it just blew up and took out the presure
sensor at the same time?  If running both pumps is only wastes electricty
where as running no pumps causes the reactor to melt down, then it's better
to let them run independently than to risk no pumps working.  So you design
the system to fail on the side of running both pumps when they are unable
to tell the true status of the other.

> > In my current server, the numbering server acts as a master, and all my
> > front-end servers act as slaves.  However, there is no attempt to
> > auto-promote a slave to a master.  I can however manually convert any
> > front-end server into the master in a few minutes with a simple
> > configuration change.  However, it's quite possible that the old (now
> > dead) master had received some articles which it was not able to tell
> > the front-end server about.  Those articles will be lost.  But since
> > the probability of the master failling is small, the system is "good
> > enough".
>
> I don't see the master as a server that is receiving articles. OK,
> it knows (a lot) about all articles. It might even have a copy of
> important headerlines (or hashes of their values) of all articles.
> Or just of all Message-IDs (and -hashes). But that is another subject.
> Is that the right way to model a master?

There is a huge number of ways to segment a usenet server into a
distributed system.  None is really "correct".  Each architecture has
different performance, cost, complexity, and failure characteristics.

I've used the concept of "master" and "slave" in many different generic
terms in these messages.  But the generic idea is that you have two
components, both able to perform the same function, and you want only one
performing the function at a time.  The slave is there ready to perform the
function if the master is unable to continue.  The problem with using a
master slave system is in transfering the job of the master to the slave
when the master fails.

The simple way to do redundancy, and the way that works for a lot of
usenet, is to design the redundant components so that they run at the same
time and share the work.  If there's a failure, you simply have less
components sharing the work.  To gurantee that the system keeps working and
doesn't loose articles when there is a failure, you can design the failure
modes to error on the side of duplication.  i.e., two components may
sometimes duplicate the work, and copy, or store, the same article.

With the execption of the problem of assigning article numbers, this
duplication error is harmelss in a distributed Usenet system assuming the
error happens at a low enough rate to not over burden the individual
components with work.

In a simple, and typical, distributed, usenet server, the article numbering
is handled by a single transit box which is receiving articles from
multiple redundant sources (either external peers or other internal
peering/filtering boxes), it gurantees uniqueness (only one copy of each
article is allowed), and it assigns the article numbers, and then sends the
numbered articles (with Xref lines documenting the numners) to one or more
other spoolers, and/or reader boxes.  This numbering server might be the
only single point of failure in the system with a high probability of
failure.

If you wanted to, you could try to set up a slave to replace the master
article numbering server and set up a system to make the feeds all switch
over to the slave if the master died.  Making sure the slave would be
correctly syncronized and always correctly take over after a failure would
take a lot of work, and would in the end require you to put your trust in
some component which was still a single point of failure.  YOu would only
do that if you felt the MTBF of the master article numbering server wasn't
good enough for you, and if you felt for sure that the far more complex
master slave system did in fact have a better MTBF than the single system.

But like I said, I don't know of anyone that has set up a master slave
system for article numbering in a Usenet sever with an automatic fall-over
system. (i.e., one that doesn't include a human as part of the system like
mine does).

-- 
Curt Welch                                            http://CurtWelch.Com/
curt@kcwc.com                          Webmaster for http://NewsReader.Com/
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads