Copyright (c) 2009, Sun Microsystems, Inc. All Rights Reserved.
Copyright 2012 Joshua M. Clulow <josh@sysmgr.org>
The contents of this file are subject to the terms of the Common Development and Distribution License (the "License"). You may not use this file except in compliance with the License. You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing.
See the License for the specific language governing permissions and limitations under the License. When distributing Covered Code, include this CDDL HEADER in each file and include the License file at usr/src/OPENSOLARIS.LICENSE. If applicable, add the following below this CDDL HEADER, with the
fields enclosed by brackets "[]" replaced with your own identifying information: Portions Copyright [yyyy] [name of copyright owner]
fmdump [-efmvV] [-c class] [-R dir] [-t time] [-T time] [-u uuid] [-n name[.name]*[=value]] [file]
The Fault Manager maintains two sets of log files for use by administrators and service personnel: error log
A log which records error telemetry, the symptoms of problems detected by the system.
A log which records fault diagnosis information, the problems believed to explain these symptoms.
By default, fmdump displays the contents of the fault log, which records the result of each diagnosis made by the fault manager or one of its component modules.
An example of a default fmdump display follows:
# fmdump TIME UUID SUNW-MSG-ID Dec 28 13:01:27.3919 bf36f0ea-9e47-42b5-fc6f-c0d979c4c8f4 FMD-8000-11 Dec 28 13:01:49.3765 3a186292-3402-40ff-b5ae-810601be337d FMD-8000-11 Dec 28 13:02:59.4448 58107381-1985-48a4-b56f-91d8a617ad83 FMD-8000-OW ...
Each problem recorded in the fault log is identified by:
The time of its diagnosis
A Universal Unique Identifier (UUID) that can be used to uniquely identify this particular problem across any set of systems
A message identifier that can be used to access a corresponding knowledge article located on http://illumos.org/msg/
If a problem requires action by a human administrator or service technician or affects system behavior, the Fault Manager also issues a human-readable message to syslogd(8). This message provides a summary of the problem and a reference to the knowledge article on http://illumos.org/msg/.
You can use the -v and -V options to expand the display from a single-line summary to increased levels of detail for each event recorded in the log. The -c, -t, -T, and -u options can be used to filter the output by selecting only those events that match the specified class, range of times, or uuid.
If more than one filter option is present on the command-line, the options combine to display only those events that are selected by the logical AND of the options. If more than one instance of the same filter option is present on the command-line, the like options combine to display any events selected by the logical OR of the options. For example, the command:
# fmdump -u uuid1 -u uuid2 -t 02Dec03
selects events whose attributes are (uuid1 OR uuid2) AND (time on or after 02Dec03).
Select events that match the specified class. The class argument can use the glob pattern matching syntax described in sh(1). The class represents a hierarchical classification string indicating the type of telemetry event.
Display events from the fault management error log instead of the fault log. This option is shorthand for specifying the pathname of the error log file. The error log file contains Private telemetry information. This information is recorded to facilitate post-mortem analysis of problems and event replay, and should not be parsed or relied upon for the development of scripts or other tools.
Follow the growth of the log file by waiting for additional data. fmdump enters an infinite loop where it will sleep for a second, attempt to read and format new data from the log file, and then go back to sleep. This loop can be terminated at any time by sending an interrupt (Control-C).
Print the localized diagnosis message associated with each entry in the fault log.
Select fault log or error log events, depending on the -e option, that have properties with a matching name (and optionally a matching value). For string properties the value can be a regular expression match. Regular expression syntax is described in the EXTENDED REGULAR EXPRESSIONS section of the regex(7) manual page. Be careful when using the characters:
$ * { ^ | ( ) \e...or a regular expression, because these are meaningful to the shell. It is safest to enclose any of these in single quotes. For numeric properties, the value can be octal, hex, or decimal.
Use the specified root directory for the log files accessed by fmdump, instead of the default root (/).
Select events that occurred at or after the specified time. The time can be specified using any of the following forms: mm/dd/yy hh:mm:ss
Month, day, year, hour in 24-hour format, minute, and second. Any amount of whitespace can separate the date and time. The argument should be quoted so that the shell interprets the two strings as a single argument.
Month, day, year, hour in 24-hour format, and minute. Any amount of whitespace can separate the date and time. The argument should be quoted so that the shell interprets the two strings as a single argument.
12:00:00AM on the specified month, day, and year.
Day, month name, year, hour in 24-hour format, minute, and second. Any amount of whitespace can separate the date and time. The argument should be quoted so that the shell interprets the two strings as a single argument.
Day, month name, year, hour in 24-hour format, and minute. Any amount of whitespace can separate the date and time. The argument should be quoted so that the shell interprets the two strings as a single argument.
Month, day, hour in 24-hour format, minute, and second of the current year.
Year, month, day, and optional hour in 24-hour format, minute, and second. The second, or hour, minute, and second, can be optionally omitted.
12:00:00AM on the specified day, month name, and year.
Hour in 24-hour format, minute, and second of the current day.
Hour in 24-hour format and minute of the current day.
T nanoseconds ago where T is an integer value specified in base 10.
T microseconds ago where T is an integer value specified in base 10.
T milliseconds ago where T is an integer value specified in base 10.
T seconds ago where T is an integer value specified in base 10.
T minutes ago where T is an integer value specified in base 10.
T hours ago where T is an integer value specified in base 10.
T days ago where T is an integer value specified in base 10.
Select events that occurred at or before the specified time. time can be specified using any of the time formats described for the -t option.
Select fault diagnosis events that exactly match the specified uuid. Each diagnosis is associated with a Universal Unique Identifier (UUID) for identification purposes. The -u option can be combined with other options such as -v to show all of the details associated with a particular diagnosis. If the -e option and -u option are both present, the error events that are cross-referenced by the specified diagnosis are displayed.
Display verbose event detail. The event display is enlarged to show additional common members of the selected events.
Display very verbose event detail. The event display is enlarged to show every member of the name-value pair list associated with each event. In addition, for fault logs, the event display includes a list of cross-references to the corresponding errors that were associated with the diagnosis.
Specifies an alternate log file to display instead of the system fault log. The fmdump utility determines the type of the specified log automatically and produces appropriate output for the selected log.
Use any of the following commands to retrieve information about a specified class from the fmd log. The complete class name is ereport.io.ddi.context.
# fmdump -Ve -c 'ereport.io.ddi.context' # fmdump -Ve -c 'ereport.*.context' # fmdump -Ve -n 'class=ereport.io.ddi.context' # fmdump -Ve -n 'class=ereport.*.context'
Any of the preceding commands produces the following output:
Oct 06 2007 11:53:20.975021712 ereport.io.ddi.context nvlist version: 0 class = ereport.io.ddi.context ena = 0x1b03a15ecf00001 detector = (embedded nvlist) nvlist version: 0 version = 0x0 scheme = dev device-path = / (end detector) __ttl = 0x1 __tod = 0x470706b0 0x3a1da690
Example 2 Retrieving Specific Detector Device Path from fmd Log
The following command retrieves a detector device path from the fmd log.
# fmdump -Ve -n 'detector.device-path=.*/disk@1,0$' Oct 06 2007 12:04:28.065660760 ereport.io.scsi.disk.rqs nvlist version: 0 class = ereport.io.scsi.disk.rqs ena = 0x453ff3732400401 detector = (embedded nvlist) nvlist version: 0 version = 0x0 scheme = dev device-path = /pci@0,0/pci1000,3060@3/disk@1,0 (end detector) __ttl = 0x1 __tod = 0x4707094c 0x3e9e758
Successful completion. All records in the log file were examined successfully.
A fatal error occurred. This prevented any log file data from being examined, such as failure to open the specified file.
Invalid command-line options were specified.
The log file was opened successfully, but one or more log file records were not displayed, either due to an I/O error or because the records themselves were malformed. fmdump issues a warning message for each record that could not be displayed, and then continues on and attempts to display other records.
Fault management log directory
Fault management error log
Fault management fault log
ATTRIBUTE TYPE ATTRIBUTE VALUE |
Interface Stability See below. |
The command-line options are Evolving. The human-readable error log output is Private. The human-readable fault log output is Evolving.
http://illumos.org/msg/