查看oceanbase的license信息

root@lnob bin# obclient -h192.168.207.28 -P2881 -uroot@sys -pxxxxxx. -A -Doceanbase

Welcome to the OceanBase. Commands end with ; or \g.

Your OceanBase connection id is 3221600926

Server version: OceanBase 4.2.5.4 (r104030022025070212-37927c3517f028002a34b40302f78cce88afdbd9) (Built Jul 2 2025 12:21:09)

Copyright (c) 2000, 2018, OceanBase and/or its affiliates. All rights reserved.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

obclient(root@sys)oceanbase> show tables like '%LICENSE%';

+---------------------------------+

| Tables_in_oceanbase (%LICENSE%) |

+---------------------------------+

| DBA_OB_LICENSE |

| __all_license |

+---------------------------------+

2 rows in set (0.006 sec)

obclient(root@sys)oceanbase> SELECT * FROM oceanbase.__all_license;

+------------+------------+--------------+--------------+--------------+----------------------------+----------------------------+----------------------------+-----------+----------+----------+----------------------------+----------------------------+

| LICENSE_ID | END_USER | LICENSE_CODE | LICENSE_TYPE | PRODUCT_TYPE | ISSUANCE_DATE | ACTIVATION_TIME | EXPIRED_TIME | OPTIONS | CORE_NUM | NODE_NUM | LTS_TIME | CLUSTER_ULID |

+------------+------------+--------------+--------------+--------------+----------------------------+----------------------------+----------------------------+-----------+----------+----------+----------------------------+----------------------------+

| Trial ID | Trial User | Trial Code | Trial | SE | 2025-07-22 14:43:30.772011 | 2025-07-22 14:43:30.772011 | 2026-01-18 14:43:30.772011 | Unlimited | 9999 | 1 | 2025-08-11 10:47:52.015326 | 06C31QW1AKJAFWM2CR6R9QQZR8 |

+------------+------------+--------------+--------------+--------------+----------------------------+----------------------------+----------------------------+-----------+----------+----------+----------------------------+----------------------------+

1 row in set (0.002 sec)

obclient(root@sys)oceanbase> SELECT * FROM DBA_OB_LICENSE;

+------------+------------+--------------+--------------+--------------+---------------------+---------------------+---------------------+-----------+----------+----------------------------+

| END_USER | LICENSE_ID | LICENSE_CODE | LICENSE_TYPE | PRODUCT_TYPE | ISSUANCE_DATE | ACTIVATION_TIME | EXPIRED_TIME | OPTIONS | NODE_NUM | CLUSTER_ULID |

+------------+------------+--------------+--------------+--------------+---------------------+---------------------+---------------------+-----------+----------+----------------------------+

| Trial User | Trial ID | Trial Code | Trial | SE | 2025-07-22 14:43:30 | 2025-07-22 14:43:30 | 2026-01-18 14:43:30 | Unlimited | 1 | 06C31QW1AKJAFWM2CR6R9QQZR8 |

+------------+------------+--------------+--------------+--------------+---------------------+---------------------+---------------------+-----------+----------+----------------------------+

1 row in set (0.001 sec)

https://www.oceanbase.com/docs/common-oceanbase-database-standalone-1000000003577290

加载 License

获取 License 文件之后,您可以通过 ALTER SYSTEM LOAD LICENSE 语句加载 License。

  1. 使用 sys 租户登录数据库。

    复制代码
    obclient -hxxx.xxx.xxx.xxx -P2881 -uroot -p****** -Doceanbase -A
  2. 查看 License 信息。

    您可以查询 DBA_OB_LICENSE 查看当前 License 详细内容。

    复制代码
    obclient> select * from DBA_OB_LICENSE;
  3. 加载 license。

    复制代码
    obclient> ALTER SYSTEM LOAD LICENSE <license_file_path>;
    说明

    license_file_path必填项,代表 License 文件的路径。

    示例如下。

    复制代码
    obclient(root@(none))[oceanbase]> alter system load license "/data/OceanBase.lic";
    Query OK, 0 rows affected (0.012 sec)
  4. 查看 license 信息。

    复制代码
    obclient> select * from DBA_OB_LICENSE;
相关推荐
AllData公司负责人5 天前
AllData 可定义数据中台完成信创适配|银河麒麟 + 海光X86 CPU / 华为鲲鹏ARM CPU+ OceanBase / 人大金仓国产化环境部署落地
大数据·arm开发·数据库·人工智能·oceanbase·kingbase
隔窗听雨眠6 天前
OceanBase调优实战:从合并策略到执行计划的工程化调优体系
oceanbase
隔窗听雨眠8 天前
从存储引擎到执行计划:OceanBase高效运维的调优逻辑与工程实践
运维·oceanbase
隔窗听雨眠13 天前
从预测数据分布到设定阈值:OceanBase自动分区桌面版体验实录
oceanbase
shunwahma13 天前
MySQL 替代选型,为什么首选 OceanBase 集中式?
数据库·mysql·oceanbase
运维小斌16 天前
麒麟 V10 部署 OceanBase:故障速查与验收清单
linux·数据库·oceanbase·麒麟
云贝贝贝16 天前
白天稳如狗半夜就抖:OceanBase 合并转储把读写延迟顶了上去
数据库·sql·oceanbase
库库的数据库笔记17 天前
国产信创数据库的MySQL兼容性深度对比解析
大数据·数据库·mysql·oceanbase·政务
NineData18 天前
MySQL 迁移到 OceanBase 怎么做?NineData 全量迁移、CDC 实时同步与数据校验指南
数据库·mysql·oceanbase
运维小斌20 天前
麒麟 V10 ARM64 离线部署 OceanBase:8 步实施手册
linux·数据库·oceanbase·麒麟