Purpose
The
VMware vSphere Management Assistant (vMA) can be configured to accept
logs from your ESX and ESXi host. For more information about
downloading, installing, and configuring vMA, see the vSphere Management Assistant Documentation.
Resolution
Configuring your VMware vSphere Management Assistant (vMA) appliance to collect the logs from an ESX/ESXi host:
- Run this command to add the ESX/ESXi host to the vMA appliance:
# sudo vifp addserver [ESX/ESXi IP or HOSTNAME]
You are prompted for the root password for the target system. - Run this command to view the list of ESX/ESXi hosts connected to the vMA appliance.
# sudo vifp listservers
- Run this
command to enable the vilogger interface and to configure vMA to collect
log files from the target ESX/ESXi or vCenter Server hosts according to
the specified log policy:
# vilogger enable --server [ESX/ESXi IP or HOSTNAME] --numrotation <ROTATION: 1 to 1024> --maxfilesize <SIZE in MB: 1 to 1024> --collectionperiod <PERIOD in seconds: 10 to 3600>
Where is the ESX/ESXi IP or HOSTNAME is the IP address or hostname of the ESX/ESXi host.
For example, the command with default values is:
# vilogger enable --server [ESX/ESXi IP or HOSTNAME] --numrotation 5 --maxfilesize 5 --collectionperiod 10
In the vMA 4.x versions, the logs are located at /var/log/vmware. In earlier vMA versions, the logs are located at /var/log/syslog.
Each host managed by the vMA appliance has a subdirectory within /var/log/vmware. Each of these subdirectories, in turn, contains the log files, such as hostd.log, messages.log, vmkernel.log, vmkwarning.log, and vpxa.log.
To read the log files, you can use commands such as tail -f. For example, to read the contents of the vpxa.log file, run this command:
To read the log files, you can use commands such as tail -f. For example, to read the contents of the vpxa.log file, run this command:
# tail -f /var/log/vmware/<FQDN of Host>/vpxa.log
To customize the options for the vilogger command, see the vilogger Daemon and Log Management Commands section of the vSphere Management Assistant Guide.
Additional Information
The syntax of the vilogger command is:
vilogger <command>
Where <command> can be one of the following:vilogger <command>
- enable [--server <SERVER>]
[--logname <LOGNAME>]
[--collectionperiod <PERIOD in seconds: 10 to 3600>]
[--numrotation <ROTATION: 1 to 1024>]
[--maxfilesize <SIZE in MB: 1 to 1024>]
- disable [--server <SERVER>]
[--logname <LOGNAME>]
[--force] - list [--server <SERVER>]
[--logname <LOGNAME>] - updatepolicy [--server <SERVER>]
[--logname <LOGNAME>]
[--collectionperiod <PERIOD in seconds: 10 to 3600>]
[--numrotation <ROTATION: 1 to 1024>]
[--maxfilesize <SIZE in MB: 1 to 1024>]
- help | --help | -h [<command name>]
No comments:
Post a Comment