Query VCF Critical Errors
When the user asks to find recent errors, investigate failures, or troubleshoot SDDC Manager workflows, follow these steps:
- Verify Credentials: Ensure
LOGINSIGHT_HOSTandLOGINSIGHT_API_TOKENare available in the environment. - Query Recent Errors: Use the
exectool to run the following command. This queries the Log Insight API for recent log entries containing the keyword "error" specifically originating from SDDC Manager or related VCF components:curl -s -k -X GET "https://$LOGINSIGHT_HOST/api/v1/events?keyword=error&limit=10" \ -H "Authorization: Bearer $LOGINSIGHT_API_TOKEN" \ -H "Accept: application/json" | jq '.events[]? | {timestamp, source, text}' - Format and Analyze Output: * Parse the returned JSON payload.
- Present the logs to the user in a clean, readable format (e.g., bulleted list or table) showing the Timestamp, Source, and the exact Error Text.
- Provide a brief, logical assessment of what might be failing in the VCF environment based on the context of the error messages. If no errors are found, let the user know the recent workflows appear clean.