Failed to connect to ConfD: Connection refused

How does a subscriber connect to a CDB that running on a different host?i use the function cdb_connect to do that but it return -1 with “Failed to connect to ConfD: Connection refused”.


Client libraries connect to ConfD using TCP. We tell ConfD which address to use for these connections through the /confdConfig/confdIpcAddress/ip (default value and /confdConfig/confdIpcAddress/port (default value 4565) elements in confd.conf.
Additional IPs can be configured through the /confdConfig/confdIpcExtraListenIp element.

See ConfD UG chapter “Advanced Topics” --> “ConfD IPC”. It’s subchapter “Restricting access to the IPC port” might be relevant for you too.