Replies: 1 comment 1 reply
|
@jhua04 mapping these 12 hosts to 127.0.0.1 on I am wondering if you could add IP aliases to your podman machine, so that each listener could bind port 6379/26379 on each specific IP address. Example (not a persistent way of doing it, but just for evaluation): Then you could define respective /etc/hosts entries, like: If so you could create your listeners bound to the specific alias ips/hosts above, like: |
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
We have 3 Redis/Sentinels instances running in data centre A (DCA) in OpenShift and 3 Redis/Sentinel instances in data centre B (DCB) in OpenShift as well, and we use Skupper v2 to form this Redis/Sentinel instances as one single Redis cluster so the Sentinel nodes can monitor the Redis master and failover to any Redis instance in DCA or DCB in case if the master failed. In this case, we have
dca-redis-0
dca-redis-1
dca-redis-2
dcb-redis-0
dcb-redis-1
dcb-redis-2
all on Redis port 6379
And
dca-sentinel-0
dca-sentinel-1
dca-sentinel-2
dcb-sentinel-0
dcb-sentinel-1
dcb-sentinel-2
all on Sentinel port 26379
Once the connectors/Listeners with routing keys get created, the Redis cluster looks good and the manual failover master nodes between Redis instances are working as expected.
However we need another Sentinel outside of these two DCs so in case of one DC fail, the master still can be failover to another DC. In this case, we have another machine (just call it as DCC) which running a Sentinel instance inside the Podman for this purposes.
We now have the following issue:
localhost:6379 -> dca-redis-0:6379
localhost:6380 -> dca-redis-1:6379
localhost:6381 -> dca-redis-2:6379
localhost:6382 -> dcb-redis-0:6379
localhost:6383 -> dcb-redis-1:6379
localhost:6384 -> dcb-redis-2:6379
And
localhost:26379 -> dca-sentinel-0:26379
localhost:26380 -> dca-sentinel-1:26379
localhost:26381 -> dca-sentinel-2:26379
localhost:26382 -> dcb-sentinel-0:26379
localhost:26383 -> dcb-sentinel-1:26379
localhost:26384 -> dcb-sentinel-2:26379
However we have some difficulties to get the Sentinel in Podman working as expected in this case, The Sentinel running in Podman on DCC cannot resolve the hostname of the sentinel announced hostname on DCA and DCB, when we config the sentinel.conf on DCC
In this case, the sentinel on DCC Podman cannot really connect to Redis/Sentinel on DCA and DCB due to the sentinel.conf adding the announced host names and port numbers as dca-redis-{n}:6379 and dca-sentinel-{n}:26379.
The question is:
All reactions