# Remote reindex No route to host error despite remote cluster returning \_cluster/health info

**URL:** <https://discuss.elastic.co/t/remote-reindex-no-route-to-host-error-despite-remote-cluster-returning-cluster-health-info/364187>\
**Category:** Elasticsearch\
**Created:** [August 1, 2024, 7:07am UTC](https://discuss.elastic.co/t/remote-reindex-no-route-to-host-error-despite-remote-cluster-returning-cluster-health-info/364187 "2024-08-01T07:07:15Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![fidsamuraiCrelio](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/fidsamuraicrelio/32/101334_2.png) [@fidsamuraiCrelio](https://discuss.elastic.co/u/fidsamuraiCrelio)\
**Post date:** [August 1, 2024, 7:07am UTC](https://discuss.elastic.co/t/remote-reindex-no-route-to-host-error-despite-remote-cluster-returning-cluster-health-info/364187/1 "2024-08-01T07:07:15Z")

</div>

Hi All!

We use Elasticsearch `6.8.0` as a search engine for our application logs.  
Unfortunately our cluster crashed and some indices were unrecoverable.  
Since the cluster was in `red` state we spun up a new cluster so that logs could start again.

We've setup the new cluster with the `reindex.remote.whitelist:` setting.  
Initially we were able to migrate around 4-5k indices from the Old cluster.

However we need to migrate a few more but we've started getting the error -  
`No route to host`

Full error -

```auto
{
  "error": {
    "root_cause": [
      {
        "type": "no_route_to_host_exception",
        "reason": "No route to host"
      }
    ],
    "type": "no_route_to_host_exception",
    "reason": "No route to host"
  },
  "status": 500
}

```

Reindex request -

```auto
POST _reindex?wait_for_completion=true&refresh
{
  "source": {
    "remote": {
      "host": "http://old-cluster:80",
      "socket_timeout": "1m",
      "connect_timeout": "1m"
    },
    "index": "index"
  },
  "dest": {
    "index": "index"
  }
}

```

These are all the logs I could find -

```auto
[2024-08-01T05:40:18,597][WARN][r.suppressed] [titanNew-01] path: /_reindex, params: {wait_for_completion=true}
java.net.NoRouteToHostException: No route to host
        at sun.nio.ch.SocketChannelImpl.checkConnect(Native Method) ~[?:?]
        at sun.nio.ch.SocketChannelImpl.finishConnect(SocketChannelImpl.java:716) ~[?:?]
        at org.apache.http.impl.nio.reactor.DefaultConnectingIOReactor.processEvent(DefaultConnectingIOReactor.java:171) ~[?:?]
        at org.apache.http.impl.nio.reactor.DefaultConnectingIOReactor.processEvents(DefaultConnectingIOReactor.java:145) ~[?:?]
        at org.apache.http.impl.nio.reactor.AbstractMultiworkerIOReactor.execute(AbstractMultiworkerIOReactor.java:348) ~[?:?]
        at org.apache.http.impl.nio.conn.PoolingNHttpClientConnectionManager.execute(PoolingNHttpClientConnectionManager.java:192) ~[?:?]
        at org.apache.http.impl.nio.client.CloseableHttpAsyncClientBase$1.run(CloseableHttpAsyncClientBase.java:64) ~[?:?]
        at java.lang.Thread.run(Thread.java:750) [?:1.8.0_412]

```

Someone please help with this.

---

<div class="post-metadata">

**Author:** ![DavidTurner](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/davidturner/32/22453_2.png) [@DavidTurner](https://discuss.elastic.co/u/DavidTurner)\
**Post date:** [August 1, 2024, 7:56am UTC](https://discuss.elastic.co/t/remote-reindex-no-route-to-host-error-despite-remote-cluster-returning-cluster-health-info/364187/2 "2024-08-01T07:56:05Z")

</div>

I'm pretty sure that `No route to host` is an error message coming directly from the OS, you likely need to involve your local network experts. Can't be certain without looking at the code tho, and 6.8.0 is far too old for that. Does it reproduce on a version that isn't [EOL](https://www.elastic.co/support/eol)?

---

<div class="post-metadata">

**Author:** ![fidsamuraiCrelio](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/fidsamuraicrelio/32/101334_2.png) [@fidsamuraiCrelio](https://discuss.elastic.co/u/fidsamuraiCrelio)\
**Post date:** [August 1, 2024, 8:42am UTC](https://discuss.elastic.co/t/remote-reindex-no-route-to-host-error-despite-remote-cluster-returning-cluster-health-info/364187/3 "2024-08-01T08:42:17Z")

</div>

Hi David,

The weird thing is that if I `curl` the old cluster it's successful.  
This is from a VM in the new Cluster -

```auto
root@ip-192-168-31-250:~# curl titan-old.search.com/_cluster/health?pretty
{
  "cluster_name" : "Titan",
  "status" : "red",
  "timed_out" : false,
  "number_of_nodes" : 7,
  "number_of_data_nodes" : 6,
  "active_primary_shards" : 8474,
  "active_shards" : 8926,
  "relocating_shards" : 0,
  "initializing_shards" : 0,
  "unassigned_shards" : 3879,
  "delayed_unassigned_shards" : 0,
  "number_of_pending_tasks" : 0,
  "number_of_in_flight_fetch" : 0,
  "task_max_waiting_in_queue_millis" : 0,
  "active_shards_percent_as_number" : 69.70714564623194
}

```

Unfortunately we can't test this with a newer version since `7.x.x` breaks a lot of things for us.

Let me know if you'd like me to test anything else.

Thanks!

---

<div class="post-metadata">

**Author:** ![DavidTurner](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/davidturner/32/22453_2.png) [@DavidTurner](https://discuss.elastic.co/u/DavidTurner)\
**Post date:** [August 1, 2024, 9:03am UTC](https://discuss.elastic.co/t/remote-reindex-no-route-to-host-error-despite-remote-cluster-returning-cluster-health-info/364187/4 "2024-08-01T09:03:07Z")

</div>

> [@fidsamuraiCrelio](#):
>
> Let me know if you'd like me to test anything else.

I have no other suggestions, sorry.

---

<div class="post-metadata">

**Author:** ![fidsamuraiCrelio](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/fidsamuraicrelio/32/101334_2.png) [@fidsamuraiCrelio](https://discuss.elastic.co/u/fidsamuraiCrelio)\
**Post date:** [August 1, 2024, 9:20am UTC](https://discuss.elastic.co/t/remote-reindex-no-route-to-host-error-despite-remote-cluster-returning-cluster-health-info/364187/5 "2024-08-01T09:20:58Z")

</div>

@DavidTurner thanks!

Anyone else who you could refer to help with this?

---

<div class="post-metadata">

**Author:** ![DavidTurner](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/davidturner/32/22453_2.png) [@DavidTurner](https://discuss.elastic.co/u/DavidTurner)\
**Post date:** [August 1, 2024, 9:33am UTC](https://discuss.elastic.co/t/remote-reindex-no-route-to-host-error-despite-remote-cluster-returning-cluster-health-info/364187/6 "2024-08-01T09:33:02Z")

</div>

No I don't think anyone else would look into issues with such an old version either.

---

<div class="post-metadata">

**Author:** ![fidsamuraiCrelio](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/fidsamuraicrelio/32/101334_2.png) [@fidsamuraiCrelio](https://discuss.elastic.co/u/fidsamuraiCrelio)\
**Post date:** [August 2, 2024, 4:25am UTC](https://discuss.elastic.co/t/remote-reindex-no-route-to-host-error-despite-remote-cluster-returning-cluster-health-info/364187/7 "2024-08-02T04:25:07Z")

</div>

😱

Thanks anyways @DavidTurner !

---

<div class="post-metadata">

**Author:** ![fidsamuraiCrelio](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/fidsamuraicrelio/32/101334_2.png) [@fidsamuraiCrelio](https://discuss.elastic.co/u/fidsamuraiCrelio)\
**Post date:** [August 7, 2024, 4:11am UTC](https://discuss.elastic.co/t/remote-reindex-no-route-to-host-error-despite-remote-cluster-returning-cluster-health-info/364187/8 "2024-08-07T04:11:59Z")

</div>

For anyone else struggling with something similar a decent workaround is -  
`elasticdump`

It's a `NodeJS` based tool that migrates data and mappings as needed.

> **[GitHub - elasticsearch-dump/elasticsearch-dump: Import and export tools for elasticsearch &...](https://github.com/elasticsearch-dump/elasticsearch-dump)**
>
> Import and export tools for elasticsearch & opensearch

Not sure if this is approved by the #Elastic Stack team though
