hostdiagnostics.pl - Extracts the specified log from the ESX server host or VirtualCenter server host.
hostdiagnostics.pl [options]
This command displays the log for the ESX server host or VirtualCenter server host and allows users to monitor the log.
Optional. Key of log file being monitored. Default file is hostd.
Optional. Output the last N lines. For example, if you specify 2, a log of the last 2 lines is displayed.
Optional. This is used to monitor log file and append data as it grows.
Optional. Used with follow sleep for S seconds between iterations.
Optional. Extract the entire diagnostic bundle as a zip file.
Optional. Name of the host. It is required when running via VirtualCenter.
Display log of hostd file:
hostdiagnostics.pl --url https://<ipaddress>:<port>/sdk/vimService --username myuser --password mypassword --log hostd
Display log details of hostd file's last 2 lines:
hostdiagnostics.pl --url https://<ipaddress>:<port>/sdk/vimService --username myuser --password mypassword --log hostd --lines 2
Monitor the hostd's log file and append new data as the file grows, if running via host directly:
hostdiagnostics.pl --url https://<ipaddress>:<port>/sdk/vimService --username myuser --password mypassword --log hostd --follow
If running via virtual center, give the host name also:
hostdiagnostics.pl --url https://<ipaddress>:<port>/sdk/vimService --username myuser --password mypassword --log hostd --follow --host myhost
Monitor the host's log file and append new data as the file grows. Sleep for 4 seconds between the iterations. If running via host:
hostdiagnostics.pl --url https://<ipaddress>:<port>/sdk/vimService --username myuser --password mypassword --log hostd --follow --sleep 4
If running via virtual center:
hostdiagnostics.pl --url https://<ipaddress>:<port>/sdk/vimService --username myuser --password mypassword --log hostd --host myHost
Generate the zip file of the log:
hostdiagnostics.pl --url https://<ipaddress>:<port>/sdk/vimService --username myuser --password mypassword --log hostd --bundle