Getting Cannot assign requested address while starting elasticsearch

I am not able to get perfect solution from any of the previously posted question so I am asking this again as I am a newbie to elastic. Here what all I have done

  1. Installed elasticsearch on linux using git clone.
  2. Running elastic using /bin/elasticsearch
  3. Runs successfully when there in no change in elasticsearch.yml file
  4. When I am changing the to 10.182.XX.XX it is not able to start.

Linux Installed

cat /proc/version
Linux version 2.6.32-696.23.1.el6.x86_64 (

Console snapshot

[2018-07-24T19:52:49,248][WARN ][o.e.b.ElasticsearchUncaughtExceptionHandler] [] uncaught exception in thread [main]
org.elasticsearch.bootstrap.StartupException: BindTransportException[Failed to bind to [9300-9400]]; nested: BindException[Cannot assign requested address];
at org.elasticsearch.bootstrap.Elasticsearch.init( ~[elasticsearch-6.3.1.jar:6.3.1]
at org.elasticsearch.bootstrap.Elasticsearch.execute( ~[elasticsearch-6.3.1.jar:6.3.1]
at org.elasticsearch.cli.EnvironmentAwareCommand.execute( ~[elasticsearch-6.3.1.jar:6.3.1]
at org.elasticsearch.cli.Command.mainWithoutErrorHandling( ~[elasticsearch-cli-6.3.1.jar:6.3.1]
at org.elasticsearch.cli.Command.main( ~[elasticsearch-cli-6.3.1.jar:6.3.1]
at org.elasticsearch.bootstrap.Elasticsearch.main( ~[elasticsearch-6.3.1.jar:6.3.1]
at org.elasticsearch.bootstrap.Elasticsearch.main( ~[elasticsearch-6.3.1.jar:6.3.1]
Caused by: org.elasticsearch.transport.BindTransportException: Failed to bind to [9300-9400]
at org.elasticsearch.transport.TcpTransport.bindToPort( ~[elasticsearch-6.3.1.jar:6.3.1]
at org.elasticsearch.transport.TcpTransport.bindServer( ~[elasticsearch-6.3.1.jar:6.3.1]
at org.elasticsearch.transport.netty4.Netty4Transport.doStart( ~[?:?]
at ~[?:?]
at ~[?:?]
at org.elasticsearch.common.component.AbstractLifecycleComponent.start( ~[elasticsearch-6.3.1.jar:6.3.1]
at org.elasticsearch.transport.TransportService.doStart( ~[elasticsearch-6.3.1.jar:6.3.1]
at org.elasticsearch.common.component.AbstractLifecycleComponent.start( ~[elasticsearch-6.3.1.jar:6.3.1]
at org.elasticsearch.node.Node.start( ~[elasticsearch-6.3.1.jar:6.3.1]
at org.elasticsearch.bootstrap.Bootstrap.start( ~[elasticsearch-6.3.1.jar:6.3.1]
at org.elasticsearch.bootstrap.Bootstrap.init( ~[elasticsearch-6.3.1.jar:6.3.1]
at org.elasticsearch.bootstrap.Elasticsearch.init( ~[elasticsearch-6.3.1.jar:6.3.1]
... 6 more
Caused by: Cannot assign requested address
at Method) ~[?:?]
at ~[?:?]
at ~[?:?]
at ~[?:?]

Looks like there is no support available in this forum. Sorry for the inconvenience.

Hi dhananjay,

This seems that you are assigning an IP to elasticsearch that doesn't seem to allotted to the machine.

Could change the value to the IP address of the machine?

What is the o/p of ip addr?

Thanks for replying. I am assigning the host address (ssh ip) in

Are you sure that is the actual IP of the host and not a NAT/PAT IP?

What is the output of ip addr on the remote machine?

I think you are right. Please see the ip addr output
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN
link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
inet scope host lo
inet6 ::1/128 scope host
valid_lft forever preferred_lft forever
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1450 qdisc pfifo_fast state UP qlen 1000
link/ether fa:16:3e:81:4d:e8 brd ff:ff:ff:ff:ff:ff
inet brd scope global eth0

I should give the IP in right ?

Since you are behind a NAT IP, you will have to keep the IP as localhost.

What is the use case? Are you planning to use Kibana as well or just elasticsearch?

I want to get the server details (like CPU load, Memory size etc) using Elasticsearch and display it on Microsoft Bi dashboard.

You could either do a port opening or set up elasticsearch behind a reverse proxy.

Please note that there are some security issues with exposing elasticsearch directly without authentication and authorization. See xpack for more details.

Port opening - do you mean open the port 9200 in firewall ?
Can you please share a link for more information so that I can explore.


Thanks a lot @NerdSec. Will be thankful for your kind support.

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.