Purpose
Monitors File Servers and Cache Managers
Description
afsmonitor [initcmd] [-config <configuration file>] [-frequency <poll frequency, in seconds>] [-output <storage file name>] [-detailed] [-debug <turn debugging output on to the named file>] [-fshosts <list of file servers to monitor>+] [-cmhosts <list of cache managers to monitor>+] [-buffers <number of buffer slots>] [-help] afsmonitor [i] [-co <configuration file>] [-fr <poll frequency, in seconds>] [-o <storage file name>] [-det] [-deb <turn debugging output on to the named file>] [-fs <list of file servers to monitor>+] [-cm <list of cache managers to monitor>+] [-b <number of buffer slots>] [-h]
Description
The afsmonitor command initializes a program that gathers and displays statistics about specified File Server and Cache Manager operations. It allows the issuer to monitor, from a single location, a wide range of File Server and Cache Manager operations on any number of machines in both local and foreign cells.
There are 271 available File Server statistics and 570 available Cache Manager statistics, listed in the appendix about afsmonitor statistics in the IBM AFS Administration Guide. By default, the command displays all of the relevant statistics for the file server machines named by the -fshosts argument and the client machines named by the -cmhosts argument. To limit the display to only the statistics of interest, list them in the configuration file specified by the -config argument. In addition, use the configuration file for the following purposes:
For a description of the configuration file, see the afsmonitor Configuration File reference page
Cautions
The following software must be accessible to a machine where the afsmonitor program is running:
The afsmonitor screens format successfully both on so-called dumb terminals and in windowing systems that emulate terminals. For the output to looks its best, the display environment needs to support reverse video and cursor addressing. Set the TERM environment variable to the correct terminal type, or to a value that has characteristics similar to the actual terminal type. The display window or terminal must be at least 80 columns wide and 12 lines long.
The afsmonitor program must run in the foreground, and in its own separate, dedicated window or terminal. The window or terminal is unavailable for any other activity as long as the afsmonitor program is running. Any number of instances of the afsmonitor program can run on a single machine, as long as each instance runs in its own dedicated window or terminal. Note that it can take up to three minutes to start an additional instance.
Options
Output
The afsmonitor program displays its data on three screens:
Fields at the corners of every screen display the following information:
Navigating the afsmonitor Display Screens
As noted, the lower left hand corner of every display screen displays the names of the commands currently available for moving to alternate screens, which can either be a different type or display more statistics or machines of the current type. To execute a command, press the lowercase version of the first letter in its name. Some commands also have an uppercase version that has a somewhat different effect, as indicated in the following list.
The System Overview Screen
The System Overview screen appears automatically as the afsmonitor program initializes. This screen displays the status of as many File Server and Cache Manager processes as can fit in the current window; scroll down to access additional information.
The information on this screen is split into File Server information on the left and Cache Manager information on the right. The header for each grouping reports two pieces of information:
A list of the machines being monitored follows. If there are any alerts on a machine, the number of them appears in square brackets to the left of the hostname. If a process failed to respond to the last probe, the letters PF (probe failure) appear in square brackets to the left of the hostname.
The File Servers Screen
The File Servers screen displays the values collected at the most recent probe for File Server statistics.
A summary line at the top of the screen (just below the standard program version and screen title blocks) specifies the number of monitored File Servers, the number of alerts, and the number of machines affected by the alerts.
The first column always displays the hostnames of the machines running the monitored File Servers.
To the right of the hostname column appear as many columns of statistics as can fit within the current width of the display screen or window; each column requires space for 10 characters. The name of the statistic appears at the top of each column. If the File Server on a machine did not respond to the most recent probe, a pair of dashes (--) appears in each column. If a value exceeds its configured threshold, it is highlighted in reverse video. If a value is too large to fit into the allotted column width, it overflows into the next row in the same column.
The Cache Managers Screen
The Cache Managers screen displays the values collected at the most recent probe for Cache Manager statistics.
A summary line at the top of the screen (just below the standard program version and screen title blocks) specifies the number of monitored Cache Managers, the number of alerts, and the number of machines affected by the alerts.
The first column always displays the hostnames of the machines running the monitored Cache Managers.
To the right of the hostname column appear as many columns of statistics as can fit within the current width of the display screen or window; each column requires space for 10 characters. The name of the statistic appears at the top of each column. If the Cache Manager on a machine did not respond to the most recent probe, a pair of dashes (--) appears in each column. If a value exceeds its configured threshold, it is highlighted in reverse video. If a value is too large to fit into the allotted column width, it overflows into the next row in the same column.
Writing to an Output File
Include the -output argument to name the file into which the afsmonitor program writes all of the statistics it collects. The output file can be useful for tracking performance over long periods of time, and enables the administrator to apply post-processing techniques that reveal system trends. The AFS distribution does not include any post-processing programs.
The output file is in ASCII format and records the same information as the File Server and Cache Manager display screens. Each line in the file uses the following format to record the time at which the afsmonitor program gathered the indicated statistic from the Cache Manager (CM) or File Server (FS) running on the machine called host_name. If a probe failed, the error code -1 appears in the statistic field.
time host_name CM|FS statistic
If the administrator usually reviews the output file manually, rather than using it as input to an automated analysis program or script, including the -detail flag formats the data in a more easily readable form.
Examples
For examples of commands, display screens, and configuration files, see the section about the afsmonitor program in the IBM AFS Administration Guide.
Privilege Required
None
Related Information