Diagnostic Manager Browse Diagnostic Log

Diagnostic Manager Browse Diagnostic Log

Returns part of a log file.

Log entries are always returned chronologically, typically with the newest event last.

Required privileges: Global.Diagnostics

Request
URI
POST
https://{vcenter-host}/sdk/vim25/{release}/DiagnosticManager/{moId}/BrowseDiagnosticLog
COPY
Path Parameters
string
moId
Required

The unique identifier for the managed object to which the method attaches; the serialized managed object reference for a request has the form moType/moId, in this case DiagnosticManager/{moId}.

string
release
Required

The vSphere release schema. The current specification covers vSphere 8.0.3.0 APIs.


Request Body
BrowseDiagnosticLogRequestType of type(s) application/json
Required

Show optional properties

{
    "key": "string"
}
{
    "host": {
        "_typeName": "string",
        "type": "string",
        "value": "string"
    },
    "key": "string",
    "start": 0,
    "lines": 0
}
host
Optional

Reference to an instance of the HostSystem managed object.

string
key
Required

A string key specifying the key for the log file to browse. Keys can be obtained using the queryDescriptions method.

integer As int32 As int32
start
Optional

The line number for the first entry to be returned. If the parameter is not specified, then the operation returns with lines starting from the top of the log.

integer As int32 As int32
lines
Optional

The number of lines to return. If not specified, then all lines are returned from the start value to the end of the file.

Authentication
This operation uses the following authentication methods.
Responses
200

A LogHeader that includes the log lines. Sometimes fewer log lines are returned than were requested. For example, fewer lines are returned than expected if the client requests lines that do not exist or if the server limits the number of lines that it returns. If zero lines are returned, then the end of the log file may have been reached.

Returns DiagnosticManagerLogHeader of type(s) application/json
This response body class contains all of the following: DataObject
{
    "_typeName": "string",
    "lineStart": 0,
    "lineEnd": 0,
    "lineText": [
        "string"
    ]
}
integer As int32 As int32
lineStart
Required

The first line of this log segment.

integer As int32 As int32
lineEnd
Required

The last line of this log segment.

array of string
lineText
Optional

Log entries, listed by line, for this log segment.


500

InvalidArgument: if the key refers to a nonexistent log file or the log file is not of type "plain".

CannotAccessFile: if the key refers to a file that cannot be accessed at the present time.

Returns CannotAccessFile of type(s) application/json
This response body class contains all of the following: FileFault
{
    "_typeName": "string",
    "faultCause": "MethodFault Object",
    "faultMessage": [
        {
            "_typeName": "string",
            "key": "string",
            "arg": [
                {
                    "_typeName": "string",
                    "key": "string",
                    "value": {
                        "_typeName": "string"
                    }
                }
            ],
            "message": "string"
        }
    ],
    "file": "string"
}