MENU
      exportDbServerLogToObjectStorage

        exportDbServerLogToObjectStorage


        Article summary

        Available in Classic

        Overview

        Transfer Cloud DB database server log files to Object Storage.

        Requests

        Request headers

        Header nameDescription
        x-ncp-apigw-timestampIt indicates the time elapsed since January 1, 1970, 00:00:00 UTC in milliseconds and the request is considered invalid if the time difference with the API Gateway server is greater than 5 minutes
        x-ncp-apigw-timestamp:{Timestamp}
        x-ncp-apigw-api-keyKey value issued by APIGW; api-key is not used when using v2.
        x-ncp-apigw-api-key:{API Gateway API Key}
        x-ncp-iam-access-keyValue of access key ID issued on NAVER Cloud Platform portal
        x-ncp-iam-access-key:{Sub Account Access Key}
        x-ncp-apigw-signature-v2Signature encrypted with the access key ID value and secret key
        x-ncp-apigw-signature-v2:{API Gateway Signature}
        Content-TypeSpecify the request body content type as application/json
        Content-Type: application/json

        Request bodies

        API field names in the request body are case sensitive.

        Parameter NameRequirement statusTypeRestrictionsDescription
        regionNoNStringRegion number
        dbKindCodeYStringMYSQLDB type code
        fileNameYString- Database server log file name
        - Can be acquired through the getDbServerLogList.
        bucketNameYString- Object Storage bucket name
        - You can obtain bucketName through the ListBuckets action.
        cloudDBInstanceNoYString- Instance number of the created MySQL server
        - Value acquired through the getCloudDBInstanceList
        cloudDBServerInstanceNoYString- Cloud DB for MySQL server instance number
        - Can be acquired through the getCloudDBInstanceList.
        logTypeYStringBINARY, ERROR, SLOW, GENERALDatabase server log file type
        responseFormatTypeNStringxml, jsonFormat type of the response result
        Default : xml
        • regionNo
          • It can be acquired through the getRegionList, which is the Server API.
        • dbKindCode
          • Selects the type of CloudDB to search. Only MySQL may be entered.
        • fileName
        • bucketName
          • Enter the name of the bucket created in the console.
        • cloudDBInstanceNo
        • cloudDBServerInstanceNo
        • LogType
          • Determine the database server log file type. You can select among BINARY, ERROR, SLOW, and GENERAL.
        • responseFormatType
          • Determines the format to receive API execution results as a response. You may select from xml and json.

        Responses

        Field nameTypeDescriptionRemarks
        requestIdStringRequest ID value
        returnCodeIntegerResponse code value
        returnMessageStringResponse message

        Examples

        Request Examples

        GET {API_URL}/exportDbServerLogToObjectStorage
        ?regionNo=1
        &dbKindCode=MYSQL
        &fileName=20221209
        &bucketName=temp-bucket
        &cloudDBInstanceNo=15064241
        &cloudDBServerInstanceNo=15064245
        &logType=BINARY
        &responseFormatType=XML
        HTTP

        Request sample

        {
          "regionNo": "1",
          "dbKindCode": "MYSQL",
          "fileName": "20221209",
          "bucketName": "temp-bucket",
          "cloudDBInstanceNo": "15064241",
          "cloudDBServerInstanceNo": "15064245",
          "logType": "BINARY",
          "responseFormatType": "xml"
        }
        JSON

        Response examples

        connection: keep-alive
        content-type: application/xml;charset=UTF-8
        date: Fri, 09 Dec 2022 06:51:39 GMT
        server: nginx
        transfer-encoding: chunked
        x-ncp-apigw-response-origin: ENDPOINT
        x-ncp-trace-id: 3ce9h6sqm2cpi6cdj460s6copg
        HTTP
        <exportDbServerLogToObjectStorageResponse>
          <requestId>e2cbeac2-1583-479a-a8a3-ed72b3c899a0</requestId>
          <returnCode>0</returnCode>
          <returnMessage>success</returnMessage>
        </exportDbServerLogToObjectStorageResponse>
        XML

        Errors

        If the Cloud DB API request fails or an error has occurred while processing, a success or failure is returned with the HTTP status code and a detailed message is returned in JSON format.

        The errors are divided into two, "common error code" of the Cloud DB API and "API Gateway error code."

        ErrorsResponse messageDescription
        200Ok
        500Server Error

        Was this article helpful?

        Changing your password will log you out immediately. Use the new password to log back in.
        First name must have atleast 2 characters. Numbers and special characters are not allowed.
        Last name must have atleast 1 characters. Numbers and special characters are not allowed.
        Enter a valid email
        Enter a valid password
        Your profile has been successfully updated.