The vxtranslog
command allows you to log VxVM transactions to a file.
The following examples demonstrate the usage of vxtranslog
:
Set the maximum number of historic transaction log files to 10. | |
Remove any limit on the number of historic transaction log files. | |
Transactions are logged to the file, translog
, in the directory /etc/vx/log
. This path name is a symbolic link to a directory whose location depends on the operating system. If required, you can redefine the directory which is linked. If you want to preserve the settings of the vxtranslog
utility, you must also copy the settings file, .translog
, to the new directory.
The size of the transaction log is checked after an entry has been written so the actual size may be slightly larger than that specified. When the log reaches a maximum size, the current transaction log file, translog
, is renamed as the next available historic log file, translog.
number, where number is an integer from 1 up to the maximum number of historic log files that is currently defined, and a new current log file is created.
A limited number of historic log files is preserved to avoid filling up the file system. If the maximum number of historic log files has been reached, the oldest historic log file is removed, and the current log file is renamed as that file.
Each log file contains a header that records the host name, host ID, and the date and time that the log was created.
The following are sample entries from a transaction log file:
Clid = 23460, PID = 21240, Part = 0, Status = 0, Abort Reason = 0
The first line of each log entry is the time stamp of the transaction. The Clid
field corresponds to the client ID for the connection that the command opened to vxconfigd
. The PID
field shows the process ID of the utility that is requesting the operation. The Status
and Abort
Reason
fields contain error codes if the transaction does not complete normally. The remainder of the record shows the data that was used in processing the transaction.
The client ID is the same as that recorded for the corresponding command line in the command log.
See "Command logs" on page 45.
See "Association of command and transaction logs" on page 48.
If there is an error reading from the settings file, transaction logging switches to its built-in default settings. This may mean, for example, that logging remains enabled after being disabled using vxtranslog
-m
off
command. If this happens, use the vxtranslog
utility to recreate the settings file, or restore the file from a backup.