lsvlog command
Purpose
Lists virtual logs.
Syntax
To list all virtual logs:
lsvlog [-detail | -field FieldList]
To list all virtual logs in the local repository:
lsvlog -local [-detail | -field FieldList]
To list all virtual logs in the specified shared storage pool:
lsvlog -sp StoragePool [-detail | -field FieldList]
To list the virtual log with the specified UUID:
lsvlog -u UUID | -uuid UUID [-detail | -field FieldList]
To list the virtual log with the specified device name:
lsvlog -dev DeviceName [-detail | -field FieldList]
To list all virtual logs that are currently attached to VSCSI host adapters:
lsvlog -vtd [-detail | -field FieldList]
The client name is an arbitrary string that is either specified or automatically copied from the host name of a client LPAR when the virtual log is created. To list all virtual logs with the specified client name:
lsvlog -client ClientName [-detail | -field FieldList]
To list all the virtual logs attached to the specified virtual SCSI (VSCSI) host adapter:
lsvlog -vadapter Adapter [-detail | -field FieldList]
To list all the virtual logs in the specified state:
Description
The lsvlog command displays the properties of the specified virtual log or set of virtual logs. Various parameters can be used to list all virtual logs; to filter by universal unique Identifier (UUID), device name, virtual SCSI (VSCSI) host adapter, client name, and state; or to show only connected virtual logs.
- Client name
- Log name
- UUID
- Device name and attached VSCSI host adapter, if the virtual log is connected.
- Log name
- UUID
- Virtual target device
- VSCSI host adapter
- Virtual log state
- Status of the target device (if connected)
- Logical unit address on the VSCSI host adapter
- Name of the shared storage pool in which the log data is stored
- Directory in which the log data is stored
- Maximum number of log files
- Maximum size of each log file
- Maximum number of state files
- Maximum size of each state file
| Field name | Description |
|---|---|
| client | Client name |
| devstatus | Status of the target device (if connected) |
| dir | Directory in which the log data is stored |
| lf | Maximum size of each log file |
| lfs | Maximum number of log files |
| lua | Logical unit address on the VSCSI host adapter |
| name | Log name |
| parent | VSCSI host adapter |
| sf | Maximum size of each state file |
| sfs | Maximum number of state files |
| sp | Name of the shared storage pool in which the log data is stored |
| state | Virtual log state |
| uuid | UUID |
| vtd | Virtual target device |
Flags
| Flag name | Description |
|---|---|
| -c, -client | Shows only virtual logs for the specified client name. |
| -d, -detail | Shows extended output for the virtual logs. |
| -dev | Shows only the virtual log with the specified device name. |
| -field | Shows output by using the given list of fields. |
| -l, -local | Shows only the virtual logs in the local repository. |
| -s, -state | Shows only virtual logs with the specified state. |
| -sp | Shows only the virtual logs in the specified shared storage pool. |
| -u, -uuid | Shows only the virtual log with the specified UUID. |
| -v, -vadapter | Shows only virtual logs connected to the specified adapter. |
| -vtd | Shows only virtual logs with virtual target devices. |
Exit Status
| Return code | Description |
|---|---|
| 0 | All files were written successfully. |
| >0 | An error occurred. |
Examples
- To list all virtual logs, type the command as follows:
The system displays the output as follows:lsvlogClient Name Log Name UUID VTD lpar-03 syslog 02392437473b6c552680a9ddd2fd8d06 vhost1/vtlog1 lpar-02 syslog 956f8c1c25208091495c721e0796f456 vhost0/vtlog0 lpar-01 audit 9705340b31a7883573a1cd04b2254efd lpar-01 syslog b27a94a8e187ee5c917577c2a2df0268 - To list the virtual log with the UUID 02392437473b6c552680a9ddd2fd8d06,
type the command as follows:
The system displays the output as follows:lsvlog -uuid 02392437473b6c552680a9ddd2fd8d06Client Name Log Name UUID VTD lpar-03 syslog 02392437473b6c552680a9ddd2fd8d06 vhost1/vtlog1 - To list the details of the virtual log with the UUID 0000000000000000f5e421165dfcc619,
type the command as follows:
The system displays the output as follows:lsvlog -uuid 02392437473b6c552680a9ddd2fd8d06 -detailClient Name: lpar-03 Log Name: syslog UUID: 0000000000000000f5e421165dfcc619 Virtual Target Device: vtlog1 Parent Adapter: vhost1 State: enabled Logical Unit Address: 8100000000000000 Storage Pool: Log Directory: /var/vio/vlogs/lpar-03/syslog Maximum Log Files: 10 Maximum Log File Size: 1048576 Maximum State Files: 10 Maximum State File Size: 1048576 - To list all virtual logs by using a custom field string, displaying
the UUID, a tab character, the size of each state file, the colon
(:), and the number of state files, type the command as follows:
The system displays the output as follows:lsvlog -field "uuid\tsfs:sf"02392437473b6c552680a9ddd2fd8d06 1048576:10 956f8c1c25208091495c721e0796f456 1048576:10 9705340b31a7883573a1cd04b2254efd 1048576:5 b27a94a8e187ee5c917577c2a2df0268 65536:20