SLOANE@kuhub.cc.ukans.edu (Bob Sloane) (08/30/89)
Hi All, Some time ago we had some problems with the disk drive this is used to store the news database. To make a long story short, we had to restore the disk from save tapes that were several days old. As a result the Message-ID: headers for some of the articles we sent out could have been duplicates. I would like to suggest that the Message-ID: be a little more complicated than just <number@site>, perhaps something like <number.pid@site>, where pid is the Process ID of the process creating the article. This would tend to make it VERY unlikely that a job with a duplicate ID would be generated, even if the NEWS.GROUPS file was restored from a previous time. +-------------------+-------------------------------------+------------------+ | Bob Sloane \Internet: SLOANE@KUHUB.CC.UKANS.EDU/Anything I said is | | Computer Center \ BITNET: SLOANE@UKANVAX.BITNET / my opinion, not my | | University of Kansas\ AT&T: (913) 864-0444 / employer's. | +-----------------------+-----------------------------+----------------------+
lusgr@vax1.cc.lehigh.edu (STEVE ROSEMAN) (08/30/89)
In article <10147@kuhub.cc.ukans.edu>, SLOANE@kuhub.cc.ukans.edu (Bob Sloane) writes: > .....I > would like to suggest that the Message-ID: be a little more complicated than > just <number@site>, perhaps something like <number.pid@site>, where pid is the > Process ID of the process creating the article. This would tend to make it > VERY unlikely that a job with a duplicate ID would be generated, even if the > NEWS.GROUPS file was restored from a previous time. > +-------------------+-------------------------------------+------------------+ > | Bob Sloane \Internet: SLOANE@KUHUB.CC.UKANS.EDU/Anything I said is | > | Computer Center \ BITNET: SLOANE@UKANVAX.BITNET / my opinion, not my | > | University of Kansas\ AT&T: (913) 864-0444 / employer's. | > +-----------------------+-----------------------------+----------------------+ -- I would suggest a Message-ID: which includes a date/time stamp. Besides being unique, it gives some real indication of the message's originating time. ------------------------------------------------------------------------- Steve Roseman Lehigh University Computing Center LUSGR@VAX1.CC.Lehigh.EDU
SYSNET@cc.nu.oz (David Morrison) (08/31/89)
In article <10147@kuhub.cc.ukans.edu>, SLOANE@kuhub.cc.ukans.edu (Bob Sloane) writes: > Some time ago we had some problems with the disk drive this is used to store > the news database. To make a long story short, we had to restore the disk > from save tapes that were several days old. As a result the Message-ID: > headers for some of the articles we sent out could have been duplicates. I > would like to suggest that the Message-ID: be a little more complicated than > just <number@site>, perhaps something like <number.pid@site>, where pid is the > Process ID of the process creating the article. This would tend to make it > VERY unlikely that a job with a duplicate ID would be generated, even if the > NEWS.GROUPS file was restored from a previous time. Some systems use a message ID containing the date and time, eg, 890831112515@cc.nu.oz The only drawback with this is its length and trying to remember it to type to READ/ID=... It could be made more readable by making it a more recognisable form: 89Aug3111:25:15@cc.nu.oz -- David Morrison, Network Manager, Uni of Newcastle, Australia Try sysnet@cc.nu.oz.au or sysnet@cc.nu.oz (mail only) or (VAX PSI) psi%newcastle.edu.au::sysnet or psi%0505249626002::sysnet
gih900@UUNET.UU.NET (Geoff Huston) (09/06/89)
The message-id question is solved quite easily...
NEWSUTILITY.C
/*
* gen_id
*
* generate a unique message id of the form <seq num>@<internet address>
*/
char genid[132];
char *gen_id()
{
GRP savegrp;
int seq;
savegrp = newsgrp;
grprab.rab$l_kbf = c$rfi(0);
grprab.rab$b_ksz = 4;
grprab.rab$b_krf = 1;
grprab.rab$l_rop = RAB$M_WAT;
grprab.rab$b_rac = RAB$C_KEY;
_c$cks(sys$get(&grprab));
seq = ++newsgrp.grp_iavd;
_c$cks(sys$update(&grprab));
sprintf(genid,"<%d.%X@%s>",seq,time(0),Node_address);
s_to_lower(genid);
return(genid);
}
The id format so generated is <sequence-number.hex-time@node>. The use of the
time rather than pid makes the message id unique whatever happens.
Geoff Huston