[MCOL-4804] CMAPI needs to dynamically update IP addresses Created: 2021-07-07  Updated: 2022-04-15  Resolved: 2022-04-15

Status: Closed
Project: MariaDB ColumnStore
Component/s: cmapi
Affects Version/s: cmapi-1.4
Fix Version/s: cmapi-1.6.3

Type: Bug Priority: Blocker
Reporter: Todd Stoffel (Inactive) Assignee: Daniel Lee (Inactive)
Resolution: Fixed Votes: 0
Labels: None

Issue Links:
Problem/Incident
is caused by MCOL-4440 Multi-Node CS 5.4 with S3 storage fai... Closed
Sprint: 2021-9

 Description   

The DBaaS team is using dns entries when adding nodes to cmapi.

However, the IP address for that dns name is getting hardcoded into the Columnstore.xml file

On a pod restart in K8s, the IP address is dynamically changed even though the dns name stays the same.

1. cmapi should respect the dns name
or
2. cmapi should dynamically update the ip address on restart

    <DBRM_Controller>
        <NumWorkers>1</NumWorkers>
        <IPAddr>10.77.64.228</IPAddr>
        <Port>8616</Port>
    </DBRM_Controller>

=======================
Draft of external description by AV

CMAPI "add node" function described in https://mariadb.com/docs/reference/cmapi/add-node/ accepts both the Host and IP address.
The current production version of CMAPI (which release range ??) converts the host name to IP and stores it into the DBRM_Controller section of the /etc/columnstore/Columnstore.xml .
In the case of K8S deployment the pod does not retain the IP after it is restarted. Only the Host name is guaranteed to be retained.
This results in CS losing functionality after the pod restart.

The fix retains the host name in the relevant section of /etc/columnstore/Columnstore.xml
==============================



 Comments   
Comment by Roman [ 2021-07-13 ]

Plz review.

Comment by alexey vorovich (Inactive) [ 2022-04-07 ]

Alan is working on this ticket now.
Suggestions:

  1. It would be good to have a general outline of the fix when it becomes clear. Do we refresh the IP in relevant files after restart ?
  2. There was also a discussion of having an option of relying on host names instead of IP addresses and not persisting IP in the config files. It would be good to clarify Alan's position on this
Comment by alexey vorovich (Inactive) [ 2022-04-08 ]

alan.mologorsky Good progress - as we see from the slack channel. Thanks !!!

Please describe the change that was done in both internal and external details(external being changes visible to customers) and upgrade considerations - if any..

Not much - paragraph of each

We will also need to provide dleeyh with QA instructions.

Comment by Daniel Lee (Inactive) [ 2022-04-15 ]

Build verified: cmapi-1.6.3-1 (#623)

The reported issue has been addressed in this build. The fixed/version of the ticket called for 1.6.3, but the cmapi package file name is still label as 1.6.2. The file name needs to be changed before GA release.

I noticed the Columnstore.xml file still contains some status IP addresses. For example:

<SystemModuleConfig>
...
        <ModuleIPAddr1-1-3>172.20.0.4</ModuleIPAddr1-1-3>
        <ModuleIPAddr3-1-3>172.20.0.2</ModuleIPAddr3-1-3>
        <ModuleIPAddr2-1-3>172.20.0.3</ModuleIPAddr2-1-3>
...
</SystemModuleConfig>
<ClusterManager>172.20.0.4</ClusterManager>

I logged the same info in MCOL-5055 for further investigation.

Generated at Thu Feb 08 02:53:07 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.