All Products
Search
Document Center

Virtual Private Cloud:ListIpsecServerLogs

Last Updated:Mar 22, 2024

Queries the logs of an IPsec server.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer.

Authorization information

There is currently no authorization information disclosed in the API.

Request parameters

ParameterTypeRequiredDescriptionExample
RegionIdstringYes

The ID of the region where the IPsec server is created.

You can call the DescribeRegions operation to obtain the region ID.

cn-hangzhou
IpsecServerIdstringYes

The ID of the IPsec server.

iss-2zei2n5q5zhirfh73****
FromintegerNo

The beginning of the time range to query. The value must be a UNIX timestamp. For example, 1671003744 specifies 15:42:24 (UTC+8) on December 14, 2022.

Note If you specify From, you must also specify To or MinutePeriod.
1671003744
TointegerNo

The end of the time range to query. The value must be a unix timestamp. For example, 1671004344 specifies 15:52:24 (UTC+8) on December 14, 2022.

Note If you specify To, you must also specify From or MinutePeriod.
1671004344
MinutePeriodintegerNo

The interval at which log data is queried. Valid values: 1 to 10. Unit: minutes.

Note If both From and To are not specified, you must specify MinutePeriod.
10
PageNumberintegerNo

The number of the page to return. Default value: 1.

1
PageSizeintegerNo

The number of entries to return on each page. Valid values: 1 to 50. Default value: 10.

10

Response parameters

ParameterTypeDescriptionExample
object
PageSizeinteger

The number of entries returned per page.

10
PageNumberinteger

The page number of the returned page.

1
RequestIdstring

The ID of the request.

DEDAC5B1-9292-5BF7-BDDF-61BA58CFB2FB
Countinteger

The number of entries on the current page.

10
IsCompletedboolean

Indicates whether the log is accurate. Valid values:

  • true: accurate
  • false: inaccurate
true
Dataarray

An array of strings.

Each item in the array is a log entry.

string
"2022-12-15 17:00:43 [INFO]: : iss-2zei2n5q5zhirfh73**** del ipsec policy successfully", "2022-12-15 17:00:43 [INFO]: : iss-2zei2n5q5zhirfh73**** add ipsec policy successfully"

Examples

Sample success responses

JSONformat

{
  "PageSize": 10,
  "PageNumber": 1,
  "RequestId": "DEDAC5B1-9292-5BF7-BDDF-61BA58CFB2FB",
  "Count": 10,
  "IsCompleted": true,
  "Data": [
    "\"2022-12-15 17:00:43 [INFO]: : iss-2zei2n5q5zhirfh73**** del ipsec policy successfully\", \"2022-12-15 17:00:43 [INFO]: : iss-2zei2n5q5zhirfh73**** add ipsec policy successfully\""
  ]
}

Error codes

HTTP status codeError codeError messageDescription
403ForbiddenUser not authorized to operate on the specified resource.You do not have the permissions to manage the specified resource. Apply for the permissions and try again.
404InvalidIpsecServerId.NotFoundThe specified IPsec server ID (%s) does not exist.-

For a list of error codes, visit the Service error codes.

Change history

Change timeSummary of changesOperation
No change history