Does consul work if client ip is dynamic?

Hey all,
New to consul and I was wondering, are consul clients still reachable if they have a dynamic ip address?

Assuming you have 10 clients with dynamic ip address and 1(or many) servers (consul) will the discovery work properly? and if yes, with what delay?

1 Like

Consul should be working with the node_name (hostname -f by default). If this name is resolvable the client will work.

For your second question autopilot could be the answer:
After an ip change the old instance should be declared as dead - and cleaned up - after 200ms.

1 Like

Hi @czioutas,

Welcome to Discuss for Consul! Since Consul is quite flexible, I’d like to get some more information on what you’re looking for.

What is the use case you are trying to plan for? What is making the IP Dynamic?

I appreciate your patience on the response, and look back to hearing from you! :smiley:

We work with on-edge/on-customer-premise servers that we run our software on and we cannot guarantee that our customer base will have a static ip address.

Therefore this means that we will have to deal with for example prometheus pooling from a machine whose ip changed, and if consul cannot guarantee that we will have to roll out our own internal dns service :confused:

1 Like