Diagnosing “Server Internal Error” in OceanBase OMS OCP Association: A Case Study
This article walks through a real‑world OceanBase OMS migration case where adding an OCP association triggers a “Server Internal Error”, detailing log analysis, metadb schema inspection, OAT deployment checks, the impact of the MySQL “-f” flag, a temporary fix, and the root‑cause conclusion.
OceanBase's OMS migration tool (OMS 402bp2) paired with OCP 410 may present a vague "Server Internal Error" when users attempt to add an OCP association from the OMS white‑screen UI, offering little diagnostic information.
The investigation begins by accessing the OMS container and examining the OMS‑Console log at /home/admin/logs/ghana/Ghana/comon-error.log , filtering for ERROR . The relevant entry reveals an SQL execution failure: "Field 'ocp_proxy_host' doesn't have a default value".
### The error occurred while setting parameters
### SQL: INSERT INTO ocp_info ( id, ocp_domain, ocp_api_user, ocp_api_password, ocp_charset, ocp_version, region, ocp_name) VALUES (?, ?, ?, ?, ?, ?, ?, ?)
### Cause: java.sql.SQLTransientConnectionException: (conn=783124) Field 'ocp_proxy_host' doesn't have a default value;Further probing of the OMS metadb ( oms_rm ) shows the ocp_info table still contains the ocp_proxy_host column, which is defined as NOT NULL without a default value. These columns were removed in OMS 402, indicating a schema mismatch.
To verify whether an outdated metadb was being read, the deployment timestamp from OAT (July 1 2023 15:39) is compared with the gmt_create of ocp_info . The table was created after the OMS deployment, ruling out an old metadb.
During the OAT deployment, the start_first_batch_oms_container step runs a MySQL command that loads drc_rm_schema.sql with the -f flag:
[2023-07-01T15:49:20.785+0800] INFO - mysql -h 'xxxxx' -P2883 -u 'root@oms_meta#xxxxxx' --password='xxxxxx' -f -D 'oms_rm' < /root/omsflow/meta_init/drc_rm_schema.sqlThe -f option tells the MySQL client to ignore errors, so DROP COLUMN statements that failed (because the cluster was partially down) returned a zero exit code, and OAT marked the task as successful.
As a temporary remedy, re‑executing the OMS metadb initialization inside the container fixes the missing column defaults:
python -m omsflow.scripts.units,oms_init_manager --init-dbIn conclusion, the "Server Internal Error" stems from an INSERT into ocp_info that fails due to the absent default value for ocp_proxy_host . The schema inconsistency originates from the OAT deployment script ignoring DDL errors with the -f flag, a defect that has been reported to OceanBase and will be addressed in OMS version 421.
Aikesheng Open Source Community
The Aikesheng Open Source Community provides stable, enterprise‑grade MySQL open‑source tools and services, releases a premium open‑source component each year (1024), and continuously operates and maintains them.
How this landed with the community
Was this worth your time?
0 Comments
Thoughtful readers leave field notes, pushback, and hard-won operational detail here.