Newshist prints the history line for each article identified by a msgid.
Newsdaily performs minor maintenance chores that typically should be done once a day for the news system: saving copies of log files and truncating them, reporting logged errors, checking for anomalies suggesting something is wrong, and cleaning out leftover files. Newsdaily saves one generation of old log files and three generations of old errlog and batchlog files. It reports problems via report(8CN).
Newswatch looks for indications of news problems on a shorter time scale than those reported by newsdaily, notably strangely-persistent lock files that may indicate a news-system failure. If spaceunit and spacemin are specified, newswatch checks the incoming, articles, control, and outbound areas to confirm that there is room for at least spacemin files, each of length spaceunit bytes, in each, and reports it if not. If inbatchmax is specified, newswatch inspects the incoming-news spooling area and reports if more than inbatchmax files are awaiting processing. Newswatch delivers its report, if any, via report(8CN). It typically should be run fairly frequently, perhaps once or twice an hour.
Newsboot should be run from /etc/rc or the system's equivalent on reboot. It cleans up files that the news system might have left lying about if the system crashed while news was being processed, notably old lock files.
Locknews locks the news system (retrying until it succeeds), starts up a shell ($SHELL if set, otherwise the system's standard shell) with the PS1 and prompt environment variables prepended with executable reminders, and waits around to unlock the news system when that shell terminates. This simplifies manual maintenance. -v produces messages on standard error upon successful locking and unlocking; this is only needed by users of shells that import neither PS1 nor prompt to set their prompts, notably C shells.
Addgroup and delgroup respectively add a newsgroup (with a specified flags field for the active file, normally `y' [see newsdb(5)]) and delete a newsgroup manually, with proper locking. The effect is purely local; no control message (to propagate the change to other machines) is sent.
Adddirs sweeps through the active file checking that directories exist for all newsgroups. (Relaynews will create directories as needed, but some user-interface software gets upset if a newsgroup exists but its directory does not.) This is mostly useful when adding groups in bulk, based on another site's active file.
Act.to.times emits (on standard output) a new active.times file (see newsdb(5)) based on the contents of activefile, which should normally be /etc/news/active.
Histfrom emits (on standard output) all history lines for unexpired articles arriving between startdate and enddate. The dates must be acceptable to getabsdate (see newsaux(8CN)). The default enddate is now.
Newsfrom runs histfrom and processes its output to produce a list of absolute pathnames of articles arriving between startdate and enddate (default now).
Addmissing scans the history file and the news-article tree to find articles that are not in the history file, and adds them to the file and the dbz database. If the -d option is given, addmissing rebuilds the dbz database from scratch after adding the missing articles to the history file; this is a convenience for use in disaster-recovery situations where manual repairs to the history file have rendered the file incomplete and the dbz database invalid. If the -v option is given, addmissing reports how many missing articles were found (and shows the resulting history lines, if there are not too many) on standard output.
/etc/news/historyhistory file /etc/news/history.pagdbz database for history file /etc/news/history.dirdbz database for history file /etc/news/logcurrent news log /etc/news/log.oprevious news log /etc/news/errlogcurrent news-error log /etc/news/errlog.o*old news-error logs /etc/news/batchlogcurrent news-batcher log /etc/news/batchlog.o*old news-batcher logs /var/news/in.cominginput-spooling area /var/news/out.goingoutput-batching area /etc/news/watchtimelast time newswatch was run /etc/news/activelist of current newsgroups /etc/news/active.oldbackup copy created by addgroup and delgroup /bin/shstandard Unix shell /bin/rcstandard Plan 9 shell
Addmissing complains and exits if it is unable to lock the news system, if expire appears to be running, or if there is not enough space for a temporary copy of the history file and database. It also notes the presence of articles which did not have intelligible headers (which are placed into history with an entry specifying immediate expiry). Complaints from it about articles being ``already present'' indicate a corrupt history file rather than merely missing articles; a complete rebuild is indicated if the offending entries cannot be identified and removed manually.
Addmissing balks at dealing with articles which are already in history but with an incomplete list of pathnames. This is very hard to fix.
Addmissing will falsely think articles are missing---leading to the problem above---if a newsgroup name has a component longer than 14 characters on a system which limits directory entries to 14. This too is fairly hard to fix.
Various nuisances can result if the maintenance utilities are run as root rather than as the owner of the news database. It's difficult to defend against this.