Skip to content

[DocDB] Certain yb-admin CDC commands fail when servers have separate broadcast and rpc addresses #28539

@iSignal

Description

@iSignal

Jira Link: DB-18238

Description

In the YB-admin call made to run the cdc rpc, we’re using the private_rpc_address of the first tserver in list of tservers from ListTabletServers response.

Rpc address for the tservers in Istio is not resolvable( its set to POD_IP, 127.0.0.1 ) outside pod.

We switched to run the yb-admin on the first tserver from the list_all_tablet_servers response, so that the private rpc address is resolvable as its run inside the pod. That made it work.
I think we’ll need to fix the yb-admin client code to use broadcast addresses instead of private_rpc_address ?

HostPort ts_addr = VERIFY_RESULT(GetFirstRpcAddressForTS());

Fetching the rpc address here:
return HostPortFromPB(server.registration().common().private_rpc_addresses(0));

We should use logic similar to

const HostPortPB& PublicHostPort(const ServerRegistrationPB& registration) {
  return GetHostPort(registration.broadcast_addresses(),
                     registration.private_rpc_addresses(),
                     PublicAddressAllowed::kTrue);
}

in yb client instead.

Issue Type

kind/bug

Warning: Please confirm that this issue does not contain any sensitive information

  • I confirm this issue does not contain any sensitive information.

Metadata

Metadata

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions