BSD 4_3_Net_2 release
[unix-history] / usr / src / share / doc / usd / 11.notes / a.checklist
CommitLineData
af359dea
C
1.\" Copyright (c) 1980 The Regents of the University of California.
2.\" All rights reserved.
3.\"
4.\" Redistribution and use in source and binary forms, with or without
5.\" modification, are permitted provided that the following conditions
6.\" are met:
7.\" 1. Redistributions of source code must retain the above copyright
8.\" notice, this list of conditions and the following disclaimer.
9.\" 2. Redistributions in binary form must reproduce the above copyright
10.\" notice, this list of conditions and the following disclaimer in the
11.\" documentation and/or other materials provided with the distribution.
12.\" 3. All advertising materials mentioning features or use of this software
13.\" must display the following acknowledgement:
14.\" This product includes software developed by the University of
15.\" California, Berkeley and its contributors.
16.\" 4. Neither the name of the University nor the names of its contributors
17.\" may be used to endorse or promote products derived from this software
18.\" without specific prior written permission.
19.\"
20.\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
21.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
22.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
23.\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
24.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
25.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
26.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
27.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
28.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
29.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
30.\" SUCH DAMAGE.
31.\"
32.\" @(#)a.checklist 6.2 (Berkeley) 4/17/91
95f51977
C
33.\"
34.ls 1
35.ap A "Notesfile Installation Checklist"
36
37.a1 "Installing Notesfile Code"
38
39 You can be sure that you have modified all necessary constants
40in the notesfile system by following this simple checklist.
41
42.bz
43.iz
44change to the notesfile source directory
45.iz
46tar x
47[reads the notesfile tape]
48.iz
49cd src
50.iz
51[edit] parms.h
52.iz
53ARCHTIME.
54Default for how long unmodified note strings hang around.
55.iz
56WORKSETSIZE.
57The default number of notes to leave in a notesfile when archiving.
58.iz
59DFLTSH.
60This should be left as the Bourne shell, /bin/sh -RBE
61.iz
62DFLTED.
63The editor to use if no NFED or EDITOR environment variable
64exists.
65.iz
66SEQFILE.
67This is the name of a file in the utility directory which contains
68a list of notesfiles for users without an NFSEQ environment variable.
69The default is probably just fine.
70.iz
71DFLTSEQ.
72For users without an NFSEQ environment variable and when the file
73specified by the SEQFILE definition above doesn't exist, we
74finally fall back to using the notesfiles specified by this string.
75The nice thing about having things in SEQFILE is that you don't
76have to recompile the notesfile software everytime you wish to
77change the default set of notesfiles; instead you edit a file.
78.iz
79MAILER.
80The program which will do mailing.
81If you are in a networked environment, this mailer should
82manage to route letters to far away places for you.
83The notesfile system only retains the name of the destination site;
84a path to that site is not kept.
85.iz
86SUPERMAILER.
87This should be defined if you have an intelligent mail program.
88Intelligent here means that you can edit the letter and other
89fun things.
90.iz
91PAGER.
92A program which shows 1 screenful of information at a time.
93.iz
94WRITE.
95A program which allows online user-user communication
96(such as /bin/write).
97.iz
98FULLDOMAIN.
99This defines the domain name of your local systems. For many
100USENET sites, this should be ``UUCP''.
101Other examples include ``ARPA'' and ``Uiuc.ARPA''.
102This should not include the system name.
103In the UIUC Computer Science Department, we have machines named
104``uiucdcs'', ``uiucdcsb'', and so on;
105our value for FULLDOMAIN is ``Uiuc.ARPA''.
106The notesfile code puts
107things together to yield ``uiucdcsb.Uiuc.ARPA'' as a
108full domain name for one of our machines.
109Note that you do NOT need to place a ``.'' at the beginning of
110the domain name; the notesfile software does this for you.
111.ix
112IDDOMAIN.
113This switch is (for now) undefined.
114When defined it indicates the the unique id's associated with
115notes are to have a system component containing the system
116name and the string defined by FULLDOMAIN.
117The eventual goal is that this will be defined.
118Currently, there are problems with using long strings
119for unique identifiers. This is related to the old notesfile
120structure which used a 10 character maximum and didn't check for
121overflow.
122.br
123So for now, leave this undefined.
124I'm not sure when it will be good to enable this option.
125.iz
126Select a kernel type for your machine.
127If no kernel is selected, the code may compile but most
128likely will not run.
129.iz
130PROMPT.
131If you wish the system to give a command prompt.
132Otherwise the notesfile system is promptless.
133.iz
134USERHOST.
135If this is defined, the notesfile system uses the convention
136``user@host'' to indicate where an article originated.
137If undefined, the notesfile system uses a ``host!user''
138notation.
139If you are running in an environment which supports Internet
140style names, you may choose to use this.
141.iz
142DYNADIR.
143When defined, the notesfile system will determine the default
144spool directory notesfiles from /etc/passwd.
145The home directory for the user ``notes'' (actually whatever is
146specified in the Makefile) is read from /etc/passwd and the
147parent directory is used as the default spool directory.
148Thus if notes' home directory is ``/usr/spool/notes/.utilities'',
149the default directory is ``/usr/spool/notes''.
150This assumes that notes' home directory is in the .utilities
151directory.
152.sp
153This is useful for the case where a single binary will be run
154on several machines with differing disk layouts.
155On one, the database might live in /usr/spool/notes; another
156host might have the data base in /mnt/notes.
157By using DYNADIR and moving the ``notes'' home directory
158on various machines, only one binary is needed.
159.sp
160If the notes database lives in the same place on all of your
161machines, a better approach is to use the MSTDIR definition
162in the Makefile.
163.iz
164K_KEY.
165When defined, the ``k'' and ``K'' keys act similarly to the
166``q'' and ``Q' keys respectively.
167The choice is up to you.
168Defining them allows reading of notes with one hand.
169However some people get aggravated when the miss the ``j'' key
170and hit the ``k'' key.
171All the documentation considers the ``k'' key to be active.
172.iz
173BIGTEXT.
174Define this is you want to allow notes longer than 65000 bytes.
175Note that if you have old notesfiles, you will have to dump and
176reload them with the ``nfdump'' and ``nfload'' programs before
177the new code will work on them.
178.iz
179.ft B
180The following definitions are pretty much ``stock'' and
181usually aren't changed.
182.ft P
183.iz
184NFMAINT.
185This is the name of the notesfile which receives control messages,
186error reports and other notesfile logging functions.
187I do not recommend #undef'ing this.
188.iz
189AUTOCREATE.
190When defined, network receptions of previously undefined notesfiles
191will cause the creation of that notesfile.
192If undefined, the reception will fail if the notesfile doesn't
193exist.
194This is used in environments such as USENET where new notesfiles
195are often created remotely.
196.iz
197STATS.
198If defined, the statistics keeping code is enabled. If undefined,
199the notesfile system will not keep statistics.
200Keeping statistics involves no space overhead and relatively
201little time overhead; I recommend leaving this defined.
202.iz
203FASTSEQ.
204Enables code which ``fails-quickly'' by determining in an
205inexpensive operation if there can't be any new articles.
206When there might be new articles,
207a more thorough and time consuming algorithm
208is used.
209.iz
210DUMPCORE.
211This defines a subdirectory of the notesfile utility directory
212where core images generated by internal consistency checks are
213placed. If undefined, the errors will be logged but no core
214image is generated.
215.iz
216FASTFORK.
217This definition enables a quick forking algorithm which
218exec's the desired program immediately instead of going through
219the system(III) interface.
220It avoids an extra fork()/execl() and shell startup costs.
221However some functionality is lost.
222.iz
223[finished editing parms.h]
224.iz
225[edit] Makefile
226.iz
227select BIN.
228The directory where user commands are kept.
229The Makefile will NOT create this directory.
230At UIUC, we use /usr/bin. Another common choice is
231/usr/local.
232.iz
233MSTDIR.
234The default directory for notesfiles.
235The Makefile WILL make this directory for you.
236This is typically /usr/spool/notes.
237.iz
238ARCHDIR.
239Old notes never die, they go here instead;
240the Makefile WILL make this directory for you.
241.iz
242NET.
243This is the directory where the notesfile networking programs
244``nfxmit'' and ``nfrcv'' will be placed.
245In most cases, ``/usr/bin'' is a good choice.
246You may wish to change it if your UUCP or other networking
247mechanisms use other directories.
248This directory must already exist;
249the Makefile will not create it.
250.iz
251AUTOSEQ.
252The invocation name for the automatic sequencer.
253For multiple names like `autoseq', `readnotes' and `autonotes',
254make links to the file ``/usr/bin/notes'' with the appropriate
255names (assuming that BIN = `/usr/bin').
256.iz
257NOTES.
258The username of the user who ``owns'' all the notesfiles.
259.iz
260NOTESUID.
261The numeric userid of the notesfile ``owner''.
262For example NOTES = notes, NOTESUID = 10.
263.iz
264NOTESGRP.
265The name of the group to which the ``NOTES'' signon belongs.
266.ft B
267It is strongly recommended that this be a special group
268just for the notes database and programs.
269.ft P
270.iz
271ANON.
272The name of the ``anonymous'' user.
273.iz
274ANONUID.
275The numeric userid of the ``anonymous'' user;
276this should be an idle user id since it is not allowed to
277run the notesfile program.
278.iz
279LIBDIR.
280The directory to contain ``libnfcom.a'', a user accessible library
281of routines.
282This is distributed as /usr/local/lib.
283.iz
284CFLAGS.
285You may wish to arrange for split I/D loading on a PDP-11
286(the -i flag).
287It may also be prudent to optimize the code (-O flag).
288If code size is an issue, remove the RCSIDENT definition;
289when defined, version control information is included in the
290binaries and they are correspondingly larger.
291.iz
292[finished editing]
293Makefile
294.iz
295[may need to become super-user at this point]
296.iz
297type ``make base''
298and assess its completion.
299It will tell you if all went well.
300.ft B
301If you are merely installing a new version of the notesfile code,
302you should type ``touch base'' instead of ``make base''.
303.ft P
304.iz
305Signon as notesfile ``owner''.
306While remaining super-user isn't a fatal flaw at this point, it
307does mean that several default notesfiles won't be generated.
308These can be created by hand if you forget.
309Nothing from this point on (including future code updates) requires
310super-user privileges.
311.iz
312cd src
313.iz
314.ft B
315If you are merely installing a new version of the code,
316type ``touch spool'' now. This tells the makefile that the spool
317directories already exist.
318.ft P
319.iz
320make boot.
321This is the final step, it should complete with a message
322that the system is installed.
323An error message when doing the ``mknf -on nfmaint nfgripes''
324probaby means you are still super-user.
325Don't sweat it; just become notes and type the ``mknf'' command
326line over. Everything is now fine.
327.iz
328You may have to be Super-User for the next step depending on the
329modes of your manual directory, /usr/man.
330.iz
331cd ../man.
332[the man page directory for notesfiles]
333.iz
334make install.
335to install the man(I) pages for the notesfile system.
336They are placed, by default, in the directories /usr/man/man1,
337/usr/man/man3, and /usr/man/man8.
338.iz
339Examine the ``Samples'' directory for templates of files normally
340in the notesfile utility directory.
341These files include shell scripts to run through cron(8) which
342queue network transmissions, expire old notes, and
343map between notesfiles and news.
344.iz
345Modify UUCP's ``uuxqt.c'' to allow remote execution of ``nfrcv''.
346This is unnecessary if no notesfile networking will be done
347or if another remote execution mechanism will be used.
348Some versions of UUCP have a file ``/usr/lib/uucp/L.cmds''
349which contains names of permitted commands.
350.iz
351Modify /etc/rc to remove notesfile locks at boot time.
352[4.2 BSD machines might prefer to use /etc/rc.local.]
353Add the command ``rm -f /usr/spool/notes/.locks/*''.
354.ez
355
356.a1 "Upgrading Existing Notesfile Databases"
357
358 Revision 1.7 of the notesfile system requires converting
359existing notesfile databases to a new format.
360A set of programs to accomplish this task are included in the
361distribution.
362The ``nfdump'' program converts notesfiles into an ASCII representation.
363The ``nfload'' program converts this ASCII representation back
364into a properly formatted notesfile.
365To convert an existing notesfile database, these steps are what I
366follow:
367
368.bz
369.iz
370Compile ``nfdump'' with the OLD notes distribution.
371If your version of the software is old enough not to have a copy
372of nfdump,
373I suggest you either try to adapt the version in the current
374distribution or using the networking programs ``nfxmit'' and ``nfrcv''
375to get the information between the old and new databases.
376.iz
377Compile ``nfload'' with the NEW notes distribution.
378.iz
379cd /usr/spool/notes
380.iz
381mkdir .OLD
382.iz
383mv * .OLD
384.iz
385run the following script:
386.nf
387.br
388#! /bin/csh -f
389foreach i (`ls .OLD`)
390 echo $i start
391 nfdump-old /usr/spool/notes/.OLD/$i - | nfload-new $i
392 echo $i done
393end
394echo ALL DONE
395.fi
396.iz
397rm -rf .OLD
398.ez
399
400 You will also have to convert the sequencer information.
401In the ``utility/seq-cvt'' directory there are a pair of programs
402``seqtoascii'' and ``seqtobinary''.
403To convert the sequencer information:
404
405.bz
406.iz
407make ``seqtoascii'' using the OLD structs.h and parms.h.
408.iz
409make ``seqtobinary'' using the NEW structs.h and parms.h.
410.iz
411cd /usr/spool/notes/.sequencer
412.iz
413mkdir .OLD
414.iz
415mv * .OLD
416.iz
417run this shell script:
418.nf
419.br
420#!/bin/csh -f
421foreach i (`ls .OLD`)
422 echo $i
423 seqtoascii .OLD/$i | seqtobinary $i
424end
425echo ALL DONE
426.fi
427.iz
428rm -rf .OLD
429.iz
430If you are going to use the FULLDOMAIN option, you may want
431to go ahead and perform the following steps:
432.iz
433run this shell script, appropriately modified to reflect
434your domain setup.
435This one reflects the naming at UIUC.
436.nf
437.br
438#!/bin/csh -f
439foreach i (Sy:*)
440 echo $i
441 ln $i $i.UUCP
442 ln $i $i.Uiuc.ARPA
443end
444echo ALL DONE
445.fi
446.iz
447You have now converted your notesfile database to 1.7 format.
448Install the new binaries and fire away.
449.ex
450
451
452.a1 "Hints on Installing Notesfiles on Multiple Systems"
453
454 Notesfile binaries are portable across similar machines.
455User-id's and hostnames are determined by examining /etc/passwd
456and through system calls.
457
458 To install the Notesfile system on a network of like machines
459(a collection of 68000 workstations for example)
460one machine must go through the procedure detailed above.
461A shell script ``rinstall'' is included in the notesfile
462source directory.
463This shell script will propagate copies across the network.
464Rinstall is a simple script that assumes the correct
465hierarchies exist on the target machines.
466It was written to use the 4.2 BSD ``rcp'' and ``rsh'' programs
467to copy files and remotely execute commands.
468Different networking commands will require changes to the shell
469script.
470
471 To generate the proper hierarchies on other systems,
472copy the Makefile to each of the machines and make both
473``base'' and ``spool''. This will create the proper files
474and directories for the notesfile system.
475Then return to the master machine and run the rinstall script
476to send binaries to each of the other machines.
477
478 The ``Samples'' directory of the Notesfile distribution
479contains example cron scripts for sending information between
480a network of systems running notesfiles.
481These shell scripts can prove helpful in setting up notesfile
482transmissions around your local network.
483
484.a1 "Mail to Notesfiles"
485
486 To use the nfmail program with the 4.1 BSD /etc/delivermail
487or the 4.2 BSD /usr/lib/sendmail
488insert lines of the following form in the file /usr/lib/aliases.
489
490.in +1i
491.nf
492somenotes: ``|/usr/spool/notes/.utilities/nfmail somenotes''
493gripes: ``|/usr/spool/notes/.utilities/nfmail problems''
494.fi
495.in
496
497.a1 "The Notesfiles/News Gateway"
498
499 The notesfile/news gateway may need a little more tickling to
500convince it to work properly. For more information on how to set this
501up properly, see section 3.5 (``Interfacing to News'') and look at
502the file `Src/newsgate.h'.
503Appendix B (``Interfacing Notesfiles to News'')
504is another source of information for connecting the two systems.