Updated on 2026-09-18 GMT+08:00

Managing Error Logs

Scenarios

RDS log management allows you to view database-level logs, including error logs and slow SQL query logs.

Error logs help you analyze problems with databases. You can download error logs for further analysis.

Viewing and Downloading Error Logs

  1. Log in to the RDS console.
  2. Click in the upper left corner and select a region.
  3. On the Instances page, click the target instance name to go to the Summary page.
  4. In the navigation pane, choose Logs.
  5. On the Error Logs tab page, click the Log Details tab. You can view error logs by node, level, and specific time range.

    Figure 1 Error log details
    Table 1 Error log details

    Parameter

    Description

    Time

    UTC time when a log was generated

    Log Level

    • You can select a log level in the upper right corner to view logs of the selected level.
      • All log levels
      • ERROR
      • WARNING
      • NOTE
    • You can also click in the upper right corner to select a time range and view error logs for different periods.

      Only error logs generated within the last month can be viewed.

    Description

    • A maximum of 2,000 error log records can be displayed. To view more error log records, submit a service ticket.
    • If the description of a log is truncated, locate the log and move your pointer over the description in the Description column to view details.

  1. Log in to the RDS console.
  2. Click in the upper left corner and select a region.
  3. On the Instances page, click the target instance name.
  4. In the navigation pane on the left, choose Logs. On the Error Logs page, click the Downloads tab. In the log list, locate a log file whose status is Preparation completed and click Download in the Operation column.

    Figure 2 Downloading an error log
    • The system automatically loads the downloading preparation tasks. The loading duration is determined by the log file size and network environment.
      • When the log is being prepared for download, the log status is Preparing.
      • When the log is ready for download, the log status is Preparation completed.
      • If the preparation for download fails, the log status is Abnormal.

      Logs in the Preparing or Abnormal status cannot be downloaded.

    • The download link is valid for 5 minutes. After the download link expires, a message is displayed indicating that the download link has expired. If you need to redownload the log, click OK.
    • The downloaded logs contain only the logs of the primary node.
    • If the size of a log to be downloaded is greater than 40 MB, you need to use OBS Browser+ to download it.
      1. Download OBS Browser+.
      2. Decompress and install OBS Browser+.
        Figure 3 Logging in to OBS Browser+
      3. On the OBS Browser+ download page of any backup, obtain the name of an external bucket. For details, see Method 1: Using OBS Browser+.
        Figure 4 Obtaining an external bucket name
      4. Add an external bucket.
        Figure 5 Adding an external bucket

        If you want to access OBS external buckets across accounts, the access permission is required. For details, see Granting IAM Users Under an Account the Access to a Bucket and Resources in the Bucket.

      5. Click the name of the external bucket to go to the object list page. In the search box on the right, enter the log file name and start a search. In the search result, click to download the log file.
        Figure 6 Downloading a log file

Configuring Error Log Ingestion to LTS and Showing the Analysis View

  1. Log in to the RDS console.
  2. Click in the upper left corner and select a region.
  3. On the Instances page, click the target instance name to go to the Summary page.
  4. In the navigation pane, choose Logs.
  5. On the Error Logs tab page, click Ingest Logs to LTS in the upper right corner.
  6. In the displayed dialog box, select Ingest Logs to LTS, select Error logs under Log Types, select a log group and log stream, and click OK.

    Figure 7 Configuring error log ingestion to LTS

  7. If error log ingestion to LTS is enabled, you can switch to the analysis view in the upper right corner of the page to see more details.

    Figure 8 List view
    Figure 9 Analysis view
    • On the Log Search tab page, you can view structured fields and index configuration fields under Quick Analysis as well as view and download log contents. For more information, see Searching and Analyzing Logs.

      For explanations of the fields on the Raw Logs page in the analysis view, see Table 2.

      Table 2 LTS error log fields

      Parameter

      Description

      log_type

      Log type. Fixed value: error_log.

      instance_id

      Instance ID.

      node_id

      Node ID within an instance.

      _resource_id

      Resource ID. Fixed value: DBS_LOG. Ignore this parameter.

      _resource_name

      Resource name. Fixed value: DBS_LOG. Ignore this parameter.

      _service_type

      Service type. Fixed value: DBS.

      service_name

      Service name. Fixed value: MYSQL.

      severity

      Error log level. Values: ERROR, WARNING, and NOTE.

      raw_message

      Error log description.

      log_time

      UTC timestamp when the log entry was generated.

      project_id

      Project ID. You can view it by hovering over the username in the upper right corner and choosing My Credentials from the drop-down list.

    • On the Charts tab page, you can view scenario-specific data in multiple chart types, including tables, bar charts, and line charts. For more information, see Statistical Charts.
    • On the Log Analysis tab page, you can search for and analyze collected log data. For more information, see Log Search and Analysis.
    • On the Real-Time Logs tab page, you can view logs reported in real time to quickly search for and analyze log data. For more information, see Viewing Real-Time Logs.