Failed to add %s address %s – How to solve this Elasticsearch error

Opster Team

Aug-23, Version: 8.4-8.9

Briefly, this error occurs when Elasticsearch is unable to add a specific IP address to its network configuration. This could be due to an incorrect IP address format, network issues, or firewall restrictions. To resolve this, you can verify the IP address format, check your network connectivity, and ensure that your firewall settings allow Elasticsearch to access the IP address. Additionally, check your Elasticsearch configuration files for any errors or inconsistencies.

This guide will help you check for common problems that cause the log ” failed to add %s; address %s ” to appear. To understand the issues related to this log, read the explanation below about the following Elasticsearch concepts: plugins, discovery-gce, discovery.

Log Context

Log “failed to add %s; address %s” classname is GceSeedHostsProvider.java.
We extracted the following from Elasticsearch source code for those seeking an in-depth context :

                            cachedDynamicHosts.add(transportAddress);
                        }
                    }
                } catch (Exception e) {
                    final String finalIpPrivate = ip_private;
                    logger.warn(() -> format("failed to add %s; address %s"; name; finalIpPrivate); e);
                }

            }
        } catch (Exception e) {
            logger.warn("exception caught during discovery"; e);

 

How helpful was this guide?

We are sorry that this post was not useful for you!

Let us improve this post!

Tell us how we can improve this post?