124139Sjoerg                             TOP
289750Sdwmalone                         Version 3.5
324139Sjoerg
424139Sjoerg                       William LeFebvre
524139Sjoerg		     and a cast of dozens
624139Sjoerg
724139Sjoerg
824139SjoergIf you do not want to read this entire file, then at least read
924139Sjoergthe section at the end entitled "KNOWN PROBLEMS".
1024139Sjoerg
1124139SjoergIf you are having any problems getting top to work, please read the
1224139Sjoergfile "FAQ" *before* contacting me.  Thank you.
1324139Sjoerg
1424139Sjoerg"top" is a program that will give continual reports about the state of
1524139Sjoergthe system, including a list of the top cpu using processes.  Version 3
1624139Sjoergof "top" has three primary design goals: provide an accurate snapshot of
1724139Sjoergthe system and process state, not be one of the top processes itself, be
1824139Sjoergas portable as possible.
1924139Sjoerg
2024139SjoergVersion 3 has many bug fixes from version 2.5, and it has also been
2124139Sjoergreorganized in a major way to make it easy to port to other platforms.
2224139SjoergAll system dependent code is now contained in one file.
2324139Sjoerg
2424139SjoergTop now includes a configuration script called "Configure".  It helps
2524139Sjoergthe installer choose the correct parameters for this particular
2624139Sjoerginstallation.  This script MUST be run before attempting to compile top.
2724139Sjoerg
2824139SjoergTop requires read access to the memory files "/dev/kmem" and "/dev/mem"
2924139Sjoergas well as the system image "/vmunix".  Some installations have these
3024139Sjoergfiles protected from general access.  These sites would have to install
3124139Sjoergthis program in the same way that programs such as "ps" are installed.
3224139SjoergIn addition, on those Unix variants that support the proc filesystem
3324139Sjoerg(such as SVR4 and Solaris 2), top requires read access to all the files
3424139Sjoergin /proc: typically dictating that top be installed setuid to root.
3524139Sjoerg
3624139SjoergCAVEAT: version 3 of top has internal commands that kill and renice
3724139Sjoergprocesses.  Although I have taken steps to insure that top makes
3824139Sjoergappropriate checks with these commands, I cannot guarantee that these
3924139Sjoerginternal commands are totally secure.  IF YOU INSTALL top as a SETUID
4024139Sjoergprogram, you do so AT YOUR OWN RISK!  I realize that some operating
4124139Sjoergsystems will require top to run setuid, and I will do everything I can
4224139Sjoergto make sure that top is a secure setuid program.
4324139Sjoerg
4424139SjoergConfigure will ask you to input values for certain parameters.  Before
4524139Sjoergeach parameter, Configure will display a description of what the
4624139Sjoergparameter does.  Read the description and choose an appropriate value.
4724139SjoergSometimes a default will appear in brackets.  Typing just return will
4824139Sjoergchoose the default.
4924139Sjoerg
5024139SjoergSystem support now takes the form of "modules".  Adding support for
5124139Sjoerga different architecture requires only adding a module.  Configure
5224139Sjoergasks which module to use when it is configuring top.  See the file
5324139Sjoerg"Porting" for a description of how to write your own module.
5424139Sjoerg
5524139SjoergTo compile and install "top", read the file "INSTALL" and follow the
5624139Sjoergdirections and advice contained therein.
5724139Sjoerg
5824139SjoergOnce you have created a binary for one particular type of machine, you
5924139Sjoergcan reconfigure for another type with "./Configure modulename" where
6024139Sjoerg"modulename" is replaced with the appropriate module name.  All other
6124139Sjoergparameter values are kept the same.  Note that in some cases this may
6224139Sjoergnot be appropriate.
6324139Sjoerg
6424139SjoergIf you make any kind of change to "top" that you feel would be
6524139Sjoergbeneficial to others who use this program, or if you find and fix a bug,
6624139Sjoergplease send me the change.
6724139Sjoerg
6824139SjoergBe sure to read the FAQ enclosed with the distrubution.  It contains
6924139Sjoerganswers to the most commonly asked questions about the configuration,
7024139Sjoerginstallation, and operation of top.
7124139Sjoerg
7289750Sdwmalone
7324139SjoergAVAILABILITY
7424139Sjoerg
7524139SjoergThe latest version of "top" is now being made available via anonymous
7624139SjoergFTP from the host "ftp.groupsys.com" in the directory "/pub/top".
7724139SjoergAdditional modules will be made available in the directory
7824139Sjoerg"/pub/top/m".  The site "eecs.nwu.edu" will continue to house copies
7924139Sjoergof the distribution as well.
8024139Sjoerg
8189750SdwmaloneHere are HTML links for the four best "top" archive sites:
8224139Sjoerg
8389750Sdwmalone<A HREF="ftp://ftp.groupsys.com/pub/top">Top archive (groupsys.com)</A>
8489750Sdwmalone<A HREF="ftp://eecs.nwu.edu/pub/top">Top archive (eecs.nwu.edu)</A>
8589750Sdwmalone<A HREF="ftp://pharos.dgim.doc.ca/packages/top"> Top mirror (dgim.doc.ca)</A>
8689750Sdwmalone<A HREF="ftp://uiarchive.uiuc.edu/pub/packages/top/">Top mirror (uiuc.edu)</A>
8724139Sjoerg
8824139SjoergNew releases will be posted to comp.sources.unix as they become
8924139Sjoergavailable.  Sites which arhive that newsgroup will also contain copies
9024139Sjoergof the distribution.
9124139Sjoerg
9289750SdwmaloneAnnouncements about availability will be made to the mailing list
9389750Sdwmalone"top-announce@groupsys.com".  This is an open list maintained by
9489750Sdwmalonemajordomo.  To join the list, send a message containing the word
9589750Sdwmalone"subscribe" to "top-announce-request@groupsys.com".  Addresses of
9689750Sdwmalonesubscribers to this list are kept confidential and will never be used
9789750Sdwmalonefor any purpose other than as recipients of announements concerning
9889750Sdwmalonethis software.
9989750Sdwmalone
10089750Sdwmalone
10124139SjoergKNOWN PROBLEMS:
10224139Sjoerg
10324139SjoergGnu CC
10424139Sjoerg
10524139SjoergCompiling via Gnu CC continued to be the source of most of the
10624139Sjoergquestions I receive.  By far the most common mistake made by those
10724139Sjoergattempting to compile top with Gnu CC is out of date include files.
10824139SjoergWhen the operating system is upgraded, the include files that are part
10924139Sjoergof the gcc package MUST also be updated.  Gcc maintains its own
11024139Sjoerginclude files.  Even a minor OS upgrade can involve changes to some of
11124139Sjoergthe kernel's internal data structures, which are defined in include
11224139Sjoergfiles in "sys".  Top is very sensitive to these changes.  If you are
11324139Sjoergcompiling with gcc and experience any sort of strange problems, please
11424139Sjoergmake sure the include files you are using are up to date BEFORE
11524139Sjoergsending me a bug report.  Look in the gcc source distribution for the
11624139Sjoergshell script "fixincludes".
11724139Sjoerg
11824139SjoergHP/UX 10.10
11924139Sjoerg
12024139SjoergIn their infinite wisdom, the folks at HP have decided that mere mortals
12124139Sjoergsuch as you and I don't need to know what the kernel's proc structure looks
12224139Sjoerglike.  To that end, they have removed all useful content from the include
12324139Sjoergfile <sys/proc.h> in version 10.10.  As a result, top will not compile
12424139Sjoergunder 10.10.  What HP is trying to accomplish with this move is to force
12524139Sjoergiconoclasts such as myself to use "pstat" for collecting all process
12624139Sjoerginformation.  I have no immediate solution for this problem, but hope to
12724139Sjoergobtain a sufficiently complete definition of "struct proc" at some point in
12824139Sjoergthe near future.  Stay tuned.
12924139Sjoerg
13024139SjoergDIGITAL UNIX 4.0 (DECOSF/1 V4.0)
13124139Sjoerg
13224139SjoergA user has reported that idle processes are not displayed regardless
13324139Sjoergof the flags used when invoking top.  We have not had time to track
13424139Sjoergthis problem down.
13524139Sjoerg
13624139SjoergDECOSF/1 V3.0
13724139Sjoerg
13824139SjoergThere is a bug either in the module, in utils.c, or in DEC's optimizer that
13924139Sjoergis tickled by the decosf1 module when compiled under V3.0 (and perhaps
14024139Sjoergearlier versions).  Top compiled using DEC's compiler with optimization
14124139Sjoergwill consistently produce a segmentation fault (in format_next_process
14224139Sjoergwhile calling sprintf).  To work around this problem, either compile top
14324139Sjoergwith gcc or turn off optimization (compile without -O).  We think that
14424139Sjoergone of the bugs fixed in utils.c fixed this problem as well, but we are
14524139Sjoergnot certain.
14624139Sjoerg
14724139Sjoerg
14824139SjoergSystem V R 4.2
14924139Sjoerg
15024139SjoergLoad average and memory displays do not work.  The problem has been
15124139Sjoergtraced down to a potential bug in the "mem" driver.  The author
15224139Sjoergof the svr42 module is working on a fix.
15324139Sjoerg
15424139Sjoerg
15524139Sjoerg
15624139SjoergGRATITUDE
15724139Sjoerg
15824139SjoergMy perpetual thanks to all the people who have helped me support top
15924139Sjoergon so many platforms.  Without these people, top would not be what it
16024139Sjoergis.  Here is a partial list of contributors and other individuals.
16124139Sjoerg
16224139Sjoerg	Robert Boucher		<boucher@sofkin.ca>
16324139Sjoerg	Marc Cohen 		<marc@aai.com>
16424139Sjoerg	David Cutter		<dpc@grail.com>
16589750Sdwmalone	Casper Dik		<Casper.Dik@Sun.COM>
16624139Sjoerg	Charles Hedrick 	<hedrick@geneva.rutgers.edu>
16724139Sjoerg	Andrew Herbert		<andrew@werple.apana.org.au>
16824139Sjoerg	Jeff Janvrin		<jeff.janvrin@columbiasc.ncr.com>
16924139Sjoerg	Torsten Kasch 		<torsten@techfak.uni-bielefeld.de>
17024139Sjoerg	Petri Kutvonen		<kutvonen@cs.helsinki.fi>
17124139Sjoerg	William L. Jones 	<jones@chpc>
17224139Sjoerg	Tim Pugh 		<tpugh@oce.orst.edu>
17324139Sjoerg	Steve Scherf		<scherf@swdc.stratus.com>
17424139Sjoerg	Phillip Wu		<pwu01@qantek.com.au>
17524139Sjoerg
17624139Sjoerg(My apologies if I missed anyone.)
17724139Sjoerg
17824139Sjoerg
17924139SjoergAUTHOR
18024139Sjoerg
18124139Sjoerg		William LeFebvre
18224139Sjoerg		Group sys Consulting
18324139Sjoerg		wnl@groupsys.com
18424139Sjoerg
18524139Sjoerg
18624139Sjoerg		U.S. Mail address:
18724139Sjoerg		    William LeFebvre
18889750Sdwmalone		    Group sys Consulting
18989750Sdwmalone		    11585 Jones Bridge Road
19089750Sdwmalone		    Suite 420-139
19189750Sdwmalone		    Alpharetta, GA  30022
19224139Sjoerg		    (770) 813-3224
193