Rechercher une page de manuel

Chercher une autre page de manuel:

gr_monitor

Langue: en

Version: 251768 (debian - 07/07/09)

Section: 1 (Commandes utilisateur)

NAME

gr_monitor - 3D Process or Data Monitor V0.53

SYNOPSIS

gr_monitor [-t proc|free|rup|CMD] [-host h] [-sleep n] [-noskip] [-stdin] [-perrow n] [-gap x] [-witdh n] [-height n] [-geometry] [-angle n] [-dolly n] [-zoom x] [-zhorz x] [-zvert x] [-color] [-nolight] [-fog] [-onebuf] [-rotate] [-verbose] [-v]


DESCRIPTION

Gr_Monitor displays a series of datasets as animated 3D bar charts.

By default gr_monitor displays information about processes resident on a UNIX system. For each process it displays a 3D bar graph of CPU consumed, memory consumed, resident set size, and elapsed time. The processes are grouped by username. Each username grouping sits on its own little plinth.

There are controls for translating, rotating, scaling, lighting and fog effects.

Gr_monitor receives info via an input stream and displays it in a X11 Mesa or X11 OpenGL window. The input is expected to be an XML document with a DTD that defines the data to be plotted.

Gr_gather(1) is an implementation of a data gatherer. It obtains data from the Linux process file system and reformats it as a suitable XML document. You can run it stand alone and redirect its output to a file if you wish to record data for later playback.

Gr_free(1) and Gr_rup(1) are implementations of data gatherers for disk/memory statistics and local-host load averages.

The gr_monitor XML input requirements are easily understood and could be used to display new kinds of data without any modification.

OPTIONS

-t proc|free|rup|CMD
Gr_monitor will start up one of three possible data gathering sub processes. Proc does process monitoring. Free does disk and memory monitoring. Rup monitors the load average on local hosts.
-host hostname
Gr_monitor will use rsh to fire up the gather process on another host. Data will be piped back to the local host for display.
-sleep seconds
Time to sleep between updates. The default is 5 seconds. A sleep of 0 (zero) will cause gr_monitor to start up halted (the space bar will single step the display). By default gr_monitor will start a gather process and pass it the same -sleep value.
-noskip
Normally data will be skipped if the renderer can't keep up with it. When playing back pre-recorded data via the -stdin option, you should switch off skipping.
-stdin
Take data in gather format from standard input. Use this option if you've writen your own gatherer, or if you want to play back a previously recorded set of gather data.
-perrow n
If a row exceeds this many processes, a new row will be started.
-gap x
Space between plinths (a real number).
-width n
Display width in pixels.
-height
Display height in pixels.
-geometry
Normal X11 geometry spec.
-angle n
Tilt on X axis in degrees.
-dolly n
Distant to translate in the z axis (dolly the camera).
-zoom x
Projection zoom factor.
-zhorz x
Horizontal zoom factor.
-zvert n
Vertical zoom factor.
-color
Use own color map. Colors will look better. Worth a look.
-nolight
Turn off lighting effects.
-fog
Turn on fog effects.
-onebuf
Use single buffering of the display image.
-rotate
Start up rotating.
-verbose
or -v Provides some feedback to stderr. Maximum output is generated by -verbose. Alternatively the -v option will only report skipped data sets due to the monitor not being able to keep up with the gatherer, which is useful when trying to select a good -sleep value.

GR_MONITOR WINDOW

The following controls are available in the gr_monitor window. The middle mouse button will bring a keyboard quick reference. The right mouse button will bring up another small menu duplicating some of the keyboard functions. When pressing keys beware of excessive type-a-head (count your key presses).

Here is a summary of the keys and what they do:

ESC
Exits gr_monitor.
?
Dump a key summary on stdout.
p/P
Increase or decrease the items per row guideline by one (default 12). Handy if you don't like the layout.
a/A
Zoom in or out.
x/X y/Y z/Z
Rotation about the specified axis. Lowercase +ve rotation. Uppercase -ve rotation.
i/I j/J k/K
Translation along the specified axis (i,j,k implies x,y,z).
r
Toggles rotation.
0 1 2 3 4 5 6 7 8 9
Selects a bar type. Can only select from the first 10 bar types.
s/S
Scale selected bar type up or down. Lowercase = up. Uppercase = down.
n or N
Scale selected bar type by 1.0 (i.e. reset scale).
o or O
Turn off selected bar type.
l or L
Toggle lighting.
f or F
Toggle fog effects.
h or H
Halt the display.
SPACE
Step one frame through a halted display.

ENVIRONMENT

GR_GATHER_COMMAND can contain an alternative command to run instead of the default which is gr_gather.

DATA FORMAT

The input data format is a XML document. The DTD for the XML document should contain a hierarchy of elements that conforms to the following guidelines.

The DTD should contain a datastream element that contains a list of dataset elements that represent snapshots to be plotted.

Each dataset should contain a list of group elements that group the data by some major key, for example userid.

Each group element should contain a list of item elements that group the data by some minor key, for example process ID.

Datasets, groups and items must have id attributes.

In a given datastream, each item element must contain a number of uniquely named data elements. For example, an item might contain data elements called cpu, rss, and memory. And each of these data elements should have a data attribute that specifies a value to be plotted. The date values should be a percentage value, i.e 1.0 to 100.00. Items may have differing numbers of data elements.

Here is a sample document produced by gr_gather. It uses an embedded DTD (between the square brackets).


  <?xml version="1.0"?>
  <!DOCTYPE datastream [
                <!ELEMENT datastream (dataset)*>

                <!ELEMENT dataset (group)*>

                <!ATTLIST dataset

                        id      CDATA   #REQUIRED>

                <!ELEMENT group (item)*>

                <!ATTLIST group

                        id      CDATA   #REQUIRED>

                <!ELEMENT item (cpu, rss, mem)>

                <!ATTLIST item

                        id      CDATA   #REQUIRED>

                <!ELEMENT cpu EMPTY>

                <!ATTLIST cpu

                        data    CDATA   #REQUIRED>

                <!ELEMENT rss EMPTY>

                <!ATTLIST rss

                        data    CDATA   #REQUIRED>

                <!ELEMENT mem EMPTY>

                <!ATTLIST mem

                        data    CDATA   #REQUIRED>

  ]>
  <datastream>
  
   <dataset id="viking1 Tue Nov  9 11:07:13 1999">
    <group id="bin">
     <item id="801">
      <cpu  data="0.0001"/>
      <rss  data="3.2584"/>
      <mem  data="3.2584"/>
     </item>
    </group>
    <group id="daemon">
     <item id="840">
      <cpu  data="0.0000"/>
      <rss  data="6.7496"/>
      <mem  data="6.7496"/>
     </item>
     <item id="866">
      <cpu  data="0.0000"/>
      <rss  data="4.4554"/>
      <mem  data="4.4554"/>
     </item>
    </group>
   </dataset>
  
   <dataset id="viking1 Tue Nov  9 11:07:18 1999">
    <group id="bin">
     <item id="801">
      <cpu  data="0.001"/>
      <rss  data="3.3584"/>
      <mem  data="3.5384"/>
     </item>
    </group>
   </dataset>
  
  <datastream>

Further examples can be obtained by viewing the stardard output from any of the gather implementations.

SEE ALSO

top(1), ps(1), gr_free(1), gr_gather(1), gr_rup(1)

BUGS AND LIMITATIONS

Please send any bug reports to michael@actrix.gen.nz.

Gr_Monitor is very slow on a 486 with a non-accelerated graphics card but OK on more modern systems. It is fun to watch, especially on a machine where processes or users are coming and going. It is very useful for spotting hogs and uninhibited growth.

Gr_monitor is something I hacked together to learn more about OpenGL, SGI's open standard for 2D/3D graphics. The whole thing was developed under Linux using the Mesa OpenGL look-a-like library.

AUTHOR

Michael Hamilton (michael@actrix.gen.nz)

ACKNOWLEDGEMENTS

Brian Paul (brianp@ssec.wisc.edu) is the author of the The Mesa 3-D graphics library.

XML parsing is handled by James Clark's (jjc@jclark.com) expat library.

Linux gr_gather is based on procps top by Branko Lankester, Roger Binns, and Michael K. Johnson.

Gr_monitor is based on a cut up of the GLUT example/scube.c which rotates a cube above a checker board with shadows, lighting etc. Thanks to GLUT author Mark J. Kilgard (mjk@sgi.com), scube author David G Yu.

LICENCE

(c) Copyright 1999, Michael Hamilton, Gentoo South Pacific Limited.

Rights to this work are defined by the copyrights on the work on which it is based. Portions coded by myself are covered by the GNU GENERAL PUBLIC LICENCE.

Gr_gather is covered by the same licence as procps: the GNU GENERAL PUBLIC LICENCE.

The expat library is covered by the Mozilla Public License Version 1.1 or the GNU GENERAL PUBLIC LICENSE.

For potions of gr_monitor you have the same rights as stated in the original SGI copyright:

(c) Copyright 1993, 1994, Silicon Graphics, Inc.

ALL RIGHTS RESERVED

Permission to use, copy, modify, and distribute this software for any purpose and without fee is hereby granted, provided that the above copyright notice appear in all copies and that both the copyright notice and this permission notice appear in supporting documentation, and that the name of Silicon Graphics, Inc. not be used in advertising or publicity pertaining to distribution of the software without specific, written prior permission.

THE MATERIAL EMBODIED ON THIS SOFTWARE IS PROVIDED TO YOU "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL SILICON GRAPHICS, INC. BE LIABLE TO YOU OR ANYONE ELSE FOR ANY DIRECT, SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, OR ANY DAMAGES WHATSOEVER, INCLUDING WITHOUT LIMITATION, LOSS OF PROFIT, LOSS OF USE, SAVINGS OR REVENUE, OR THE CLAIMS OF THIRD PARTIES, WHETHER OR NOT SILICON GRAPHICS, INC. HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH LOSS, HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE POSSESSION, USE OR PERFORMANCE OF THIS SOFTWARE.
  US Government Users Restricted Rights Use, duplication, or disclosure by the Government is subject to restrictions set forth in FAR 52.227.19(c)(2) or subparagraph (c)(1)(ii) of the Rights in Technical Data and Computer Software clause at DFARS 252.227-7013 and/or in similar or successor clauses in the FAR or the DOD or NASA FAR Supplement. Unpublished-- rights reserved under the copyright laws of the United States. Contractor/manufacturer is Silicon Graphics, Inc., 2011 N. Shoreline Blvd., Mountain View, CA 94039-7311.

OpenGL(TM) is a trademark of Silicon Graphics, Inc.
 

De plus, rien n'empeche Amiga de créer eux-même un shell Amiga afin de
rester dans la course et d'avoir un ordinateur compatible avec ceux qui
sont dans le commerce aujourd'hui. [...] C'est pour ce genre de société
que MultideskOS peut s'avérer etre une puissance de taille à moyen et à
long terme.
-- Jayce - Tous avec moi ! --