OceanBase logo

OceanBase

A unified distributed database ready for your transactional, analytical, and AI workloads.

Product Overview
DEPLOY YOUR WAY

OceanBase Cloud

The best way to deploy and scale OceanBase

OceanBase Enterprise

Run and manage OceanBase on your infra

TRY OPEN SOURCE

OceanBase Community Edition

The free, open-source distributed database

OceanBase seekdb

Open source AI native search database

Customer Stories

Real-world success stories from enterprises across diverse industries.

View All
BY USE CASES

Mission-Critical Transactions

Global & Multicloud Application

Elastic Scaling for Peak Traffic

Real-time Analytics

Active Geo-redundancy

Database Consolidation

Resources

Comprehensive knowledge hub for OceanBase.

Blog

Live Demos

Training & Certification

Documentation

Official technical guides, tutorials, API references, and manuals for all OceanBase products.

View All
PRODUCTS

OceanBase Cloud

OceanBase Database

Tools

Connectors and Middleware

QUICK START

OceanBase Cloud

OceanBase Database

BEST PRACTICES

Practical guides for utilizing OceanBase more effectively and conveniently

Company

Learn more about OceanBase – our company, partnerships, and trust and security initiatives.

About OceanBase

Partner

Trust Center

Contact Us

International - English
中国站 - 简体中文
日本 - 日本語
Sign In
Start on Cloud

OceanBase

A unified distributed database ready for your transactional, analytical, and AI workloads.

Product Overview
DEPLOY YOUR WAY

OceanBase Cloud

The best way to deploy and scale OceanBase

OceanBase Enterprise

Run and manage OceanBase on your infra

TRY OPEN SOURCE

OceanBase Community Edition

The free, open-source distributed database

OceanBase seekdb

Open source AI native search database

Customer Stories

Real-world success stories from enterprises across diverse industries.

View All
BY USE CASES

Mission-Critical Transactions

Global & Multicloud Application

Elastic Scaling for Peak Traffic

Real-time Analytics

Active Geo-redundancy

Database Consolidation

Comprehensive knowledge hub for OceanBase.

Blog

Live Demos

Training & Certification

Documentation

Official technical guides, tutorials, API references, and manuals for all OceanBase products.

View All
PRODUCTS
OceanBase CloudOceanBase Database
ToolsConnectors and Middleware
QUICK START
OceanBase CloudOceanBase Database
BEST PRACTICES

Practical guides for utilizing OceanBase more effectively and conveniently

Learn more about OceanBase – our company, partnerships, and trust and security initiatives.

About OceanBase

Partner

Trust Center

Contact Us

Start on Cloud
编组
All Products
    • Databases
    • iconOceanBase Database
    • iconOceanBase Cloud
    • iconOceanBase Tugraph
    • iconInteractive Tutorials
    • iconOceanBase Best Practices
    • Tools
    • iconOceanBase Cloud Platform
    • iconOceanBase Migration Service
    • iconOceanBase Developer Center
    • iconOceanBase Migration Assessment
    • iconOceanBase Admin Tool
    • iconOceanBase Loader and Dumper
    • iconOceanBase Deployer
    • iconKubernetes operator for OceanBase
    • iconOceanBase Diagnostic Tool
    • iconOceanBase Binlog Service
    • Connectors and Middleware
    • iconOceanBase Database Proxy
    • iconEmbedded SQL in C for OceanBase
    • iconOceanBase Call Interface
    • iconOceanBase Connector/C
    • iconOceanBase Connector/J
    • iconOceanBase Connector/ODBC
    • iconOceanBase Connector/NET
icon

OceanBase Database

SQL - V4.4.2

    Download PDF

    OceanBase logo

    The Unified Distributed Database for the AI Era.

    Follow Us
    Products
    OceanBase CloudOceanBase EnterpriseOceanBase Community EditionOceanBase seekdb
    Resources
    DocsBlogLive DemosTraining & CertificationTicket
    Company
    About OceanBaseTrust CenterLegalPartnerContact Us
    Follow Us

    © OceanBase 2026. All rights reserved

    Cloud Service AgreementPrivacy PolicySecurity
    Contact Us
    Document Feedback
    1. Documentation Center
    2. OceanBase Database
    3. SQL
    4. V4.4.2
    iconOceanBase Database
    SQL - V 4.4.2
    SQL
    KV
    • V 4.6.0
    • V 4.4.2
    • V 4.3.5
    • V 4.3.3
    • V 4.3.1
    • V 4.3.0
    • V 4.2.5
    • V 4.2.2
    • V 4.2.1
    • V 4.2.0
    • V 4.1.0
    • V 4.0.0
    • V 3.1.4 and earlier

    Update `access_id` and `access_key` information for the backup or archive path

    Last Updated:2026-04-02 06:23:56  Updated
    share
    What is on this page
    Limitations
    Considerations
    Procedure
    References

    folded

    share

    OceanBase Database supports dynamically updating the access_id and access_key information for backup paths or archive paths. After configuring the backup path or archive path, if the user changes the key information of the object storage for security or other reasons, this method can be used to update the access_id and access_key for the already configured backup path or archive path to ensure the normal execution of backups or archiving.

    Limitations

    • Only the access_id and access_key information of object storage paths can be updated.

    • Only user tenants are allowed to update the key information of their own backup paths or archive paths. System tenants are not allowed to update the key information of backup paths or archive paths for specific user tenants.

    Considerations

    • During the backup or archiving process, if the key information corresponding to the object storage path is changed, the access_id and access_key information for the backup path or archive path must be updated promptly. Failure to do so may result in backup task execution failures or issues with archiving progress.

    • In physical standby scenarios based on log archiving, if the key information corresponding to the object storage path is changed, the access_id and access_key information in the log restore path of the standby database (standby tenant) must be updated as soon as possible. Otherwise, it may cause issues with log synchronization progress. For detailed steps on updating the access_id and access_key information in the log restore path of the standby database (standby tenant), see Set the log restore source.

    Procedure

    1. Log in to the user tenant of the cluster as the tenant administrator of the user tenant.

      Note

      In MySQL-compatible mode, the administrator user is the root user, and in Oracle-compatible mode, the administrator user is the SYS user.

      An example of the connection is shown below. Please adjust the connection settings according to the actual environment.

      obclient -h10.xx.xx.xx -P2883 -uroot@mysql_tenant#obdemo -p***** -A
      
    2. Execute the following statement to change the key information of the backup path or archive path.

      The SQL statement is as follows:

      ALTER SYSTEM {ALTER|CHANGE|MODIFY} EXTERNAL_STORAGE_DEST PATH [=] 'path' SET ACCESS_INFO = 'access_id=new_access_id&access_key=new_access_key';
      

      The parameters in the statement are described as follows:

      • path: the backup path or archive path for which the key information is to be updated. The path must be a backup path or archive path already configured for the current tenant, and it must be an object storage path. Additionally, the path must include the host information.

        For example, in the case of OSS, the path format is as follows: oss://oceanbase-test-bucket/backup/data?host=***.

      • access_id=new_access_id&access_key=new_access_key: the new access_id and access_key after the update. You must specify both access_id and access_key.

      For example, assuming that the backup path and archive path configured for the current user tenant during backup are oss://oceanbase-test-bucket/backup/data?host=cn-****.aliyuncs.com and oss://oceanbase-test-bucket/backup/archive?host=cn-****.aliyuncs.com respectively, the key information of the backup path and archive path can be updated as follows:

      • Update the key information of the backup path

        obclient> ALTER SYSTEM CHANGE EXTERNAL_STORAGE_DEST PATH='oss://oceanbase-test-bucket/backup/data?host=cn-****.aliyuncs.com' SET ACCESS_INFO = 'access_id=******&access_key=******';
        
      • Update the key information of the archive path

        obclient> ALTER SYSTEM CHANGE ARCHIVELOG DESTINATION PATH='oss://oceanbase-test-bucket/backup/archive?host=cn-****.aliyuncs.com' SET ACCESS_INFO = 'access_id=******&access_key=******';
        

      For more examples, see ALTER/CHANGE/MODIFY EXTERNAL_STORAGE_DEST.

    3. After the modification succeeds, you can query the DBA_OB_BACKUP_STORAGE_INFO view to confirm the change.

      MySQL-compatible mode
      Oracle-compatible mode
      • Confirm the access_id and access_key of the backup path.

        obclient[oceanbase]> SELECT AUTHORIZATION FROM oceanbase.DBA_OB_BACKUP_STORAGE_INFO WHERE PATH='oss://oceanbase-test-bucket/backup/data' AND ENDPOINT = 'host=cn-****.aliyuncs.com';
        

        The query result is as follows:

        +-------------------------------------+
        | AUTHORIZATION                       |
        +-------------------------------------+
        | access_id=******&encrypt_key=****** |
        +-------------------------------------+
        1 row in set
        
      • Confirm the access_id and access_key of the archive path.

        obclient[oceanbase]> SELECT AUTHORIZATION FROM oceanbase.DBA_OB_BACKUP_STORAGE_INFO WHERE PATH='oss://oceanbase-test-bucket/backup/archive' AND ENDPOINT = 'host=cn-****.aliyuncs.com';
        

        The query result is as follows:

        +-------------------------------------+
        | AUTHORIZATION                       |
        +-------------------------------------+
        | access_id=******&encrypt_key=****** |
        +-------------------------------------+
        1 row in set
        
      • Confirm the access_id and access_key of the backup path.

        obclient[SYS]> SELECT AUTHORIZATION FROM SYS.DBA_OB_BACKUP_STORAGE_INFO WHERE PATH='oss://oceanbase-test-bucket/backup/data' AND ENDPOINT = 'host=cn-****.aliyuncs.com';
        

        The query result is as follows:

        +-------------------------------------+
        | AUTHORIZATION                       |
        +-------------------------------------+
        | access_id=******&encrypt_key=****** |
        +-------------------------------------+
        1 row in set
        
      • Confirm the access_id and access_key of the archive path.

        obclient[SYS]> SELECT AUTHORIZATION FROM SYS.DBA_OB_BACKUP_STORAGE_INFO WHERE PATH='oss://oceanbase-test-bucket/backup/archive' AND ENDPOINT = 'host=cn-****.aliyuncs.com';
        

        The query result is as follows:

        +-------------------------------------+
        | AUTHORIZATION                       |
        +-------------------------------------+
        | access_id=******&encrypt_key=****** |
        +-------------------------------------+
        1 row in set
        

    References

    • View parameters related to data backup

    • View parameters related to data archiving

    • ALTER/CHANGE/MODIFY EXTERNAL_STORAGE_DEST

    Previous topic

    Views related to data backup
    Last

    Next topic

    Automatically clean up expired backups
    Next
    What is on this page
    Limitations
    Considerations
    Procedure
    References