Changing or Disabling M Compatibility Port
Function
This API is used to change or disable the M compatibility port. Before calling this API:
- Learn how to authenticate this API.
- Obtain the required region and endpoint.
Constraints
To change or disable this function, you need to ensure that there is the templatem template database in your DB instance. If there is no the template database, it will be automatically created. The templatem template database cannot be created for DB instances whose replica consistency protocol is Paxos.
URI
PUT https://{Endpoint}/v3/{project_id}/instances/{instance_id}/mysql-compatibility
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
project_id |
Yes |
String |
Explanation: Project ID of a tenant in a region. For details about how to obtain the value, see Obtaining a Project ID. Restrictions: None Value range: The value can contain 32 characters. Only letters and digits are allowed. Default value: None |
instance_id |
Yes |
String |
Instance ID, which is compliant with the UUID format. |
Request Parameters
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
port |
Yes |
string |
Port for M compatibility. Value range: 0 or 1024 to 39989
|
Response Parameters
Parameter |
Type |
Description |
---|---|---|
job_id |
String |
Task ID. |
Example Request
- Changing the M compatibility port to 3307
PUT https://gaussdb-opengauss.ap-southeast-1.myhuaweicloud.com/v3/619d3e78f61b4be68bc5aa0b59edcf7b/instances/1bb786201ae54b179b45c17e0f332f4bin14/mysql-compatibility { "port" : "3307" }
- Disabling M compatibility port
PUT https://gaussdb-opengauss.ap-southeast-1.myhuaweicloud.com/v3/619d3e78f61b4be68bc5aa0b59edcf7b/instances/1bb786201ae54b179b45c17e0f332f4bin14/mysql-compatibility { "port" : "0" }
Example Response
M compatibility port changed or disabled.
{ "job_id": "2b414788a6004883a02390e2eb0ea227" }
Status Code
- Normal
- Abnormal
For details, see Status Codes.
Error Code
For details, see Error Codes.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot