|
|
1.1 ! root 1: Notes for 2.10: ! 2: ! 3: There are some incompatiblities between 2.9 and 2.10. None of them ! 4: should cause a problem, but you should be aware of them. Some conversion ! 5: is needed. ! 6: ! 7: The file storage format has been changed. Rather than storing news in ! 8: $SPOOL/net.games.rogue/123, an article now goes in $SPOOL/net/games/rogue/123. ! 9: This permits newsgroup names to be longer than 14 characters and still ! 10: have subgroups. It also makes directories smaller, resulting in faster ! 11: performance. The dot files are gone, rather than saving the next ! 12: article number in $SPOOL/.net.games.rogue as the length of the file, ! 13: it goes in the active file on the same line as net.games.rogue. ! 14: Thus, your active file contains lines like ! 15: net.games.rogue 00123 ! 16: where the newsgroup name and the max article number are separated by ! 17: a space. The article numbers are ALWAYS 5 digits long and include ! 18: the leading digits to do this (this is so they can be updated in place ! 19: without growing the active file). The old active file has been saved ! 20: as $LIB/oactive in case of emergency. ! 21: ! 22: This conversion of directory tree formats has an extra benefit. You'll ! 23: find that readnews is now considerably faster than version 2.9. The ! 24: movement of the dot files accounts for much of this, since it is no ! 25: longer necessary to "stat" every dot file. Additionally, a routine to ! 26: find a newsgroup in your .newsrc has been modified to keep the ! 27: file sorted in the same order as active, and a "last found" pointer ! 28: is used to reduce the find time algorithm from quadratic complexity ! 29: (on the number of newsgroups) to linear complexity. This makes the ! 30: total number of newsgroups less of a factor in determining speed, ! 31: and also keeps everyone's .newsrc cleaned out. It is important ! 32: that people not store extra junk in their .newsrc, because it will ! 33: be deleted when they run readnews. ! 34: ! 35: Before you do the conversion, you are urged to check your LIB/active ! 36: file and clean out any duplicates and old newsgroups. ! 37: ! 38: Overall recommended conversion order: ! 39: compile everything in this directory ! 40: make ! 41: make the new spool directories: ! 42: sh cvt.mkdirs.sh /usr/lib/news /usr/spool/news ! 43: convert the history file (non-USG only): ! 44: cc cvt.hist.c -ldbm ! 45: a.out /usr/lib/news ! 46: convert the active file: ! 47: sh cvt.active.sh /usr/lib/news /usr/spool/news ! 48: install the inews binary: ! 49: su ! 50: rm -f /usr/bin/inews /usr/bin/rnews ! 51: cp inews /usr/bin/inews ! 52: chown news /usr/bin/inews ! 53: chgrp news /usr/bin/inews ! 54: chmod 6755 /usr/bin/inews ! 55: ln /usr/bin/inews /usr/bin/rnews ! 56: ^D ! 57: make links to spooled articles (this takes awhile): ! 58: sh cvt.links.sh /usr/lib/news /usr/spool/news ! 59: (see below) ! 60: install the rest of the binaries: ! 61: su ! 62: make cp ! 63: ^D ! 64: test everything to make sure it all works ! 65: clean out the old spool hierarchy: ! 66: sh cvt.clean.sh /usr/spool/news ! 67: ! 68: ! 69: Several shell scripts and C programs are provided to help with this ! 70: conversion. The above scripts will convert active and create the new ! 71: directory tree. (Links will be made to the old articles, so news can ! 72: continue to be read while you are doing this.) Note that once you ! 73: install the inews binary, any incoming news processed by the new system ! 74: will not appear in the old system. The above order was chosen to ! 75: minimize the window during which incoming news could be lost. Once the ! 76: history and active files are converted, a new inews (and rnews) must be ! 77: installed, so that any incoming news will be kept in the new format. ! 78: Since the cross-linking is the time consuming part of the conversion, ! 79: it is deferred until after the critical window. The commands above to ! 80: install inews are equivalent to "make cp" except that they only install ! 81: inews, not readnews or checknews. This is so that anyone reading news ! 82: while you are cross-linking will be able to get at their news. ! 83: Otherwise, a "make cp" can be used if nobody will be reading news. You ! 84: can save the old binaries in case of catastrophe, but converting back ! 85: once 2.10 has been running for any length of time is not recommended. ! 86: ! 87: There are rumors of the cvt.links.sh part not working on a USG system. ! 88: If you have problems, the idea is to make a shell script with lines like ! 89: ln net.news.group/* net/news/group ! 90: for each newsgroup, then to run the shell script. An alternative ! 91: for USG is (roughly) ! 92: sort /usr/lib/news/active -u -o /usr/tmp/dirs.2.9 ! 93: cat /usr/tmp/dirs.2.9 | sed -e 's;\.;/;' > /usr/tmp/dirs.2.10 ! 94: cd $SPOOL ; past /usr/tmp/dirs.2.9 /usr/tmp/dirs.2.10 |\ ! 95: awk '{print "ln "$1"/* "$2}' | sh ! 96: On an older system (e.g. V7) your ln command won't handle multiple ! 97: source files - you can create a shell script to do the same thing. ! 98: ! 99: There are also rumors of cvt.mkdirs.sh not being able to make the ! 100: directories, for reasons nobody can figure out. Being unable to ! 101: reproduce this, all we can offer is that if it happens to you, ! 102: you should do it by hand (an appropriate shell script can be made ! 103: easily with the editor.) Please let us know if you figure out what ! 104: is going on. It is normal to get "File exists" errors from mkdir ! 105: for local newsgroup (no dots in the name) and from parent newsgroups ! 106: (e.g. net.rec, net.bugs, net.sport, net.news) which you can safely ignore. ! 107: ! 108: When you are satisfied that everything is working OK, run ! 109: cvt.clean.sh $SPOOL ! 110: and it will remove the old dot files and directories. ! 111: ! 112: The method used to determine if an incoming article has already been ! 113: seen locally has been changed. On V7 systems, profiling showed that ! 114: rnews spent about 1/2 of its time in fgets reading the history file. ! 115: It now uses the dbm(3) library to hash the message ID of each article. ! 116: To avoid incompatibilities between 2.9 and 2.10, if you have more than ! 117: one incoming news feed, run the provided cvt.hist program, which will ! 118: enter all the message ID's from your 2.9 format history file into ! 119: the hashed database. (On USG systems, there is no dbm library, but ! 120: fgets is much faster, so the problem should not be so pronounced. ! 121: inews 2.10 on a USG system will continue to use the old history file ! 122: method to detect duplicates.) The text history file is maintained as ! 123: it was in 2.9, for human use. ! 124: cc cvt.hist.c -ldbm ! 125: a.out $LIB ! 126: ! 127: Other incompatibilities: ! 128: ! 129: The headers now meet the USENET format standard and RFC822. Headers ! 130: stored will look verbose, and contain much more information. Headers ! 131: transmitted to other systems will work with old B news systems or new ! 132: ones. Once all your neighbors convert to the new standard, you can ! 133: take out the #define OLD in defs.h; this will prevent Posted and ! 134: Article-I.D. from being generated, saving some transmission costs ! 135: and making the stored articles a bit smaller. The format of dates ! 136: has been changed to conform to RFC822. If this causes your "Mail" ! 137: command to stop working with the -M option, it's easy to fix Mail. ! 138: In head.c, the first function "ishead" calls another function ! 139: "isdate". Simply comment out the 4 lines calling isdate. ! 140: ! 141: The user interface is roughly compatible, but the users will notice ! 142: a few differences, and there are a few extensions. There are two ! 143: major differences in the interface. The first is that postnews ! 144: now prompts for a "Distribution". This defaults to the same as ! 145: the newsgroup (and will be omitted in this case), but allows the ! 146: user to conveniently enter a Distribution header line. It also ! 147: makes them think about where their message is going to be sent ! 148: out to. Any newsgroup(s) can be typed here, but normally you ! 149: just type either nothing, or a class distribution (e.g. "net", ! 150: "btl", "nj", "world"), restricting the distribution to that ! 151: class of sites. ! 152: ! 153: The other change is that, on systems without page mode in the tty ! 154: driver (e.g. on systems with PAGE defined in defs.h), after printing ! 155: long articles with the pager, it will print a ":" and wait for ! 156: the user to hit return before printing the next header. This ! 157: is to give the user a chance to read the whole article before ! 158: the next header forces it off the top of the screen. ! 159: ! 160: Some less immediate interface changes: Headers are displayed ! 161: in a format which is more compact but more information is displayed ! 162: than before. If you want to see the article ID or full path, ! 163: or the date or newsgroups, the "h" command will show them. ! 164: The "H" command can be used for a full, verbose header dump. ! 165: ! 166: Control messages are slightly different. In particular, 2.10 now ! 167: requires that a newsgroup be created with a "newgroup" control message ! 168: (e.g. inews -C) before it can be used. If an incoming article is in ! 169: some newsgroup that is not in the local active file, the article will ! 170: be locally stored in newsgroup "junk" and not forwarded to other systems. ! 171: This will prevent the accidental creation of typographical errors ! 172: by systems running older versions of news. Also, the rmgroup control ! 173: message has been made less dangerous. The defs.h parameter MANUALLY ! 174: is now defaulted to on. This means that when an rmgroup message comes ! 175: around, you will be sent mail asking you to remove the group, but the ! 176: group will not actually be removed. This prevents someone from ! 177: accidently or deliberately removing an important newsgroup such as ! 178: net.general. If you control several machines and want to have ! 179: rmgroup messages automatically remove the group without your ! 180: intervention, disable MANUALLY. ! 181: ! 182: expire used to automatically archive news in /usr/spool/oldnews if ! 183: that directory existed. Now it won't archive it unless you give ! 184: it the -a option. ! 185: ! 186: There is now a shell script called localize.sh which makes whatever ! 187: local mods you need to news, so you won't have to keep making the ! 188: same fixes for every release. See localize.sample for an example ! 189: version, but you will want to fix it up to reflect your local ! 190: preferences. Normally the affected files are Makefile and defs.h, ! 191: plus copying (with no changes) postnews, but you can make whatever ! 192: changes you need here. ! 193: ! 194: CAUTION: If any of your neighbors run 2.9 or older news, you must ! 195: be sure you have OLD defined in your Makefile. (The distributed ! 196: localize.sample will define OLD.) Otherwise, your site will generate ! 197: articles with no Posted: or Article-I.D.: headers, resulting in ! 198: the "Inbound news is garbled" diagnostic at the remote end. ! 199: ! 200: When you ship your news software to a new site, you must now send ! 201: a copy of your active file, so that the appropriate newsgroup ! 202: directories and active file can be built. This was not necessary ! 203: in 2.9 because unrecognized incoming newsgroups were automatically ! 204: created, but they are thrown away in 2.10. ! 205: ! 206: After the conversion, you should create two new newsgroups: junk ! 207: and control. The first is for messages that are in an invalid ! 208: newsgroup (so you can see what's getting thrown away). The second ! 209: is for control messages. Ordinary users probably won't want to ! 210: read either, but as administrator you might want to. To create ! 211: them, mkdir $SPOOL/junk $SPOOL/control, and add ! 212: junk 00000 ! 213: control 00000 ! 214: to the end of $LIB/active. ! 215: ! 216: Note the addition of some new programs to $LIB. These include ! 217: recmail (a program which takes a mail message on stdin, figures ! 218: out who the To: and Cc: lines refer to, and invokes /bin/mail ! 219: with those arguments [not changed] and with the file on stdin; ! 220: recmail is used by the reply command) and caesar (a program used ! 221: to decode rotated jokes; it can also be used to create rotated jokes). ! 222: ! 223: Version 2.10 has some experimental batching provisions in it. ! 224: See the batch and unbatch programs, and the F and U options in ! 225: the sys file, for more details. There are some related UUCP ! 226: modifications in the uucp directory that can also help performance ! 227: considerably. All this is very new, and while it appears to run ! 228: OK, caution is advised in installing batching software. You must ! 229: also make sure your neighbor is prepared to receive batched news; ! 230: this is normally true if the neighbor is running at least 2.10. ! 231: ! 232: If you have an old C compiler which does not support the (void) ! 233: cast (V7 or C book based), you can add -Dvoid=int to CFLAGS in ! 234: the makefile to get the code to compile.
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.