Documentation Index

Fetch the complete documentation index at: https://cli.ncloud-docs.com/llms.txt

Use this file to discover all available pages before exploring further.

exportDbServerLogsToObjectStorage

Prev Next

Available in VPC

Send Cloud DB for MSSQL instance DB server log files to Object Storage. To send DB server log files to Object Storage, Object Storage buckets for storing and searching DB server log files must be created in advance. For more information, see Object Storage user guide.

Syntax

The exportDbServerLogsToObjectStorage syntax is as follows:

./ncloud vmssql exportDbServerLogsToObjectStorage \
    --cloudMssqlInstanceNo <instance-no> \
    --cloudMssqlServerInstanceNo <server-instance-no> \
    --cloudMssqlObjectNameList <object-name-list> \
    --bucketName <bucket-name> \
    [--folderPath <folder-path>] \
    [--regionCode <KR|SGN|JPN>] \
    [--output <json|xml>]

Options

This section describes the options available when running exportDbServerLogsToObjectStorage.

Required options

The following options are required for exportDbServerLogsToObjectStorage.

Options Type Required Description
--cloudMssqlInstanceNo String Required Cloud DB for MSSQL instance number
--cloudMssqlServerInstanceNo String Required Cloud DB for MSSQL server instance number
--cloudMssqlObjectNameList List Required List of log file names to transfer to Object Storage
  • Multiple entries can be specified, separated by spaces (e.g., --cloudMssqlObjectNameList ERRORLOG ERRORLOG.1).
  • See getCloudMssqlLogFileList.
--bucketName String Required Name of the Object Storage bucket the DB server log file will be sent to

Optional options

These are the optional options for exportDbServerLogsToObjectStorage. Options that are not specified will use their default values.

Options Type Required Description
--folderPath String Optional Folder path where DB server log files will be sent

Common options

For information about the options common to all vmssql subcommands, see Cloud DB for MSSQL (VPC) options.

Examples

If the DB server log file transfer request is successful, the log file will be transferred to the specified Object Storage bucket.

Command

The command example is as follows:

./ncloud vmssql exportDbServerLogsToObjectStorage \
    --cloudMssqlInstanceNo 25280088 \
    --cloudMssqlServerInstanceNo 25280089 \
    --cloudMssqlObjectNameList ERRORLOG \
    --bucketName my-test-bucket \
    --folderPath mssql-log/ \
    --regionCode KR \
    --output json

Output

The output example is as follows:

{
  "exportDbServerLogsToObjectStorageResponse": {
    "requestId": "c3d4e5f6-a7b8-9012-cdef-345678901234",
    "returnCode": "0",
    "returnMessage": "success"
  }
}