
				INSTALLATION

    Get and install XMake if you don't have it.  You can get XMake
    from http://www.backplane.com/xmake/

    Please read the README.READER and README.SERVER files if you haven't
    already.

    Edit lib/vendor.h

	You may wish to set certain options, read the file.  Most people 
	shouldn't have to change anything, however.  Note that many things
	can be set in diablo.config (see samples/diablo.config) and need not
	be hardwired in lib/vendor.h

	>> We suggest that you follow the instructions at the end of this file
	if you wish to upgrade to a larger hash table size. <<

    Edit lib/config.h

	You shouldn't have to modify anything in here, but this is where the
	port-specific defaults reside.

    Edit XMakefile.inc

	To set compiler flags if necessary.

    xmake clean
    xmake

    Create a news home called /news (in recognition that usenet news is
    a major subsystem, we have none of this /usr/local/news crap).  /news
    can be a softlink to wherever the real news home is.

    Create a news user-id and a news group-id.  Determine whether you are
    going to run the Diablo feeder side, the Diablo reader side, or both
    subsystems on your box.  Anything marked MOUNTED PARTITION below is
    recommended to be a separately mounted partition.  The MINIMUM partition
    sizes for a full feed are also shown.

	mkdir /news		(reader and feeder, MOUNTED PARTITION/ 4G)
	mkdir /news/dbin	(reader and feeder)
	mkdir /news/spool	(reader and feeder)
	mkdir /news/dqueue	(feeder only)
	mkdir /news/spool/news	(feeder only, MOUNTED PARTITION, 8G)
	mkdir /news/spool/cache	(reader only, MOUNTED PARTITION, 2G)
	mkdir /news/spool/group	(reader only, MOUNTED PARTITION, 8G)
	mkdir /news/spool/postq	(reader only)
	chown -R news.news /news

	xmake install

    Be sure that all *underlying* mount points are properly chown'd and chmod'd
    to prevent weirdness on a number of UNIX platforms.

    Generally speaking, when you do an 'xmake install', Diablo will install
    defaults for all system files.  The following systems files must be in
    /news or placed in /news if not placed there by the 'xmake install'.
    Read the TUNING_NOTES and RELEASE_NOTES for more information.
    The required files are:

	diablo.config	(reader and feeder)
	dhistory	(feeder only)
	dexpire.ctl	(feeder only)
	diablo.hosts	(feeder only)
	dnewsfeeds	(feeder only)
	dnntpspool.ctl	(feeder only)
	dactive.kp	(required for reader, optional for feeder (1))
	dcontrol.ctl	(reader only)
	moderators	(reader only)
	dreader.hosts	(reader only)
	dserver.hosts	(reader only)

	note (1): The dsyncgroups program can be used to generate an initial
		  dactive.kp database, see the manual page for dsyncgroups.
		  You can configure either the Diablo feeder OR the Diablo
		  reader to master the article numbering.  If you want the
		  feeder to master article numbering in order to then push
		  out a slave feed to one or more readers, dactive.kp must
		  be maintained on the machine running the feeder.  Otherwise
		  the feeder does not need to use dactive.kp.  See 
		  samples/diablo.config for more information.

    Don't forget the adm directory with the sample crontabs.  You will have
    to edit the sample crontab as appropriate for your system, and then
    install it for the 'news' user.

    And you are off.

			WHEN UPGRADING FROM AN EARLIER RELEASE

    We now recommend that if you are upgrading from 1.13 or earlier, that you
    completely wipe and reinstall diablo including wiping the history file
    and spool.  If upgrading from a later release you should be able to simply
    install over the previous release (though making a backup is always good).

		       /NEWS and /NEWS/SPOOL/NEWS HINTS

		    ** FOR A DEDICATED NEWSFEEDS MACHINE **

    /news should generally own its own partition, as should /news/spool/news
    and (if running the reader) /news/spool/group.  If you are running the
    reader with an article cache, /news/spool/cache should also generally own
    its own partition.  Note that when running an article cache, you must
    supply a crontab to check and delete files from the cache when the cache
    gets full.  You can arbitrarily remove cached files at any time from
    /news/spool/cache.  See README.READER for more information.

    /news can usually share the root disk as long as you have 3 or 4 GB
    free prior to install.  Don't forget that rebuilding the dhistory file
    can take a lot of space so there should always be around 1G free on
    /news for proper operation.

    You do not need to outfit your machine with dozens of striped disks.  With
    a reasonably modern operating system (the latest FreeBSD-current, for
    example), you can create a CCD disk made up of three or four striped disks
    and create you various news-related partitions on that single CCD disk.
    For example, striping three 18G seagates together will work just fine 
    if building a reader machine with a 40G spool, 9G group, and 5G /news
    partition (running both the feeder and reader sides of Diablo on the same
    box).  I am now recommending a stripe size of 128 sectors (64KBytes) to
    maximize load balancing while minimizing single I/O ops from bring broken
    down into multiple-disk ops.

    The minimum recommended configuration when taking a full feed is:

	128 MB ram, parity or ECC protected is recommended.

	For a feeder box, Four 4G seagate barracudas (or better) 
	striped 2x2 putting /news on two disks and /news/spool/news on
	the other two disks.  You may want to throw in a larger spool, in
	which case it may make sense to stripe three 9G disks together
	(or three 18G disks together) and build your partitions out of that
	one stripe.

	pentium 90 equivalent or better motherboard.  I suggest a
	pentium-II/300 for a good low-cost solution.

	run FreeBSD, BSDI, or Linux.  My personal favorite is FreeBSD-current
	(FreeBSD-3.x).


		    ** FOR A DEDICATED NEWSREADER MACHINE **

    For a nice low-cost news reading system able to handle a full feed, I
    suggest a pentium-II/300 box running FreeBSD-current (or linux, or solaris,
    etc...) with three 18G drives on a SCSI UW (ultra-wide) 40MByte/sec bus.
    Note: an 80MBytes/sec bus would be overkill for a news box since the disks
    are going to be seek limited, not bandwidth limited.

    Create one CCD disk that covers all three disks and partition it into
    a 5G /news, 9G /news/spool/group, and 40G /news/spool/news.  
    /news/spool/cache is not required in this case since you are going to
    run a full spool on the same box (though if you have a remote-spool
    configuration you might then have a big /news/spool/cache and a tiny
    /news/spool/news for your feed-in).

    Note that the reader side of Diablo does not maintain a dhistory file,
    which means that the 'header only' feed it expects may come from only
    one place.  However, even in a configuration where you expect to utilize
    a remote article spool, it may be beneficial to run the feeder on the same
    machine as the reader in order to be able to take multiple redundant feeds
    (which the feeder CAN handle since the feeder maintains dhistory).
    See README.READER.

    For a newsreader box, I recommend a minimum of 256MB of ram but you
    could probably survive with 128MB if you had to.  As described above,
    with 256MB of ram, the box should be able to support at least 600 
    online readers.

		    FREEBSD / PENTIUM BOX / ADAPTEC CONTROLLER

    We use pentium-pro/pentium-II boxes running FreeBSD-current (3.x) with 
    seagate drives and a single adaptec 2940UW controller.  We have had 
    serious firmware problems with other drives, especially quantums (even 
    the new ones).  If you are going with a pentium/FreeBSD solution for
    news, I suggest sticking with the newer seagate drives.

    I recommend at least 3 spindles (i.e. 3 physical disks), but you shouldn't
    need to put in more then four or five even in a high-capacity configuration
    unless you are going for super-huge spools.  It is *OK* to use
    high-capacity disks!!!!  

    For any news system, you should not underestimate the memory 
    requirements.  Most modern UNIX operating systems are able to use any
    free memory as a disk buffer cache, and that can be very important
    when it comes to news.  News machines cannot generally afford to 
    swap, but it depends heavily on the software you are using.

			CHECKLIST ONCE IT IS RUNNING

    Here's a checklist for once you have Diablo running:

    * Make sure syslog is logging news

    * fgrep DIABLO /var/log/news (or wherever your syslog puts the log) and
      use the uptime and 'arts' numbers to calculate the articles per minute.
      The uptime is in HH:MM, so calculate:  arts / (HH * 60 + MM) .  For
      a full feed as of March 1997, you should wind up with between 
      190 and 250 articles/min if you properly primed the history file.
      If you have not primed the history file and are taking multiple feeds,
      you may see a higher article rate for several days until Diablo's
      history file stabilizes.

    * After DIABLO has been running for a day, check the logs generated by
      the cron scripts.  Make sure that the expire is being run every four
      hours.

    * After DIABLO has been running for a few days, check the logs again.
      Make sure that expire is still running properly, and that the 
      history rewrite (biweekly.rehist) is running properly.

    * After four weeks of operation, double check that biweekly.rehist has
      been running properly and that the dhistory file has stabilized to
      a reasonable size (as of July 1997, between 200 and 300 MBytes).

      If you have a lot of feeds and a lot of memory, it may be worthwhile 
      increasing the dhistory table hash size from 4 million entries to 
      8 million, see adm/biweekly.atrim and the manual page to diload for
      more information.

    * When running Diablo in a reader configuration, you need to periodically
      (like once a month) clean dactive.kp.  This is not yet automated... you
      have to shut the whole diablo system down and do 'dkp -t dactive.kp'.

