Elasticsearch 8.3.2 docker org.elasticsearch.gateway.CorruptStateException

Installed ES 8.3.2 using docker on my local dev machine. Before this installation I had ES 6.3.2 running and I had deleted all my test indices in 6.3.2 before installing 8.3.2 so that I would avoid any v6 issues with 8 on my local dev. When I attempt docker-compose up --build I get this error:

es_usamm-db          | org.elasticsearch.ElasticsearchException: failed to bind service
es_usamm-db          | Likely root cause: org.elasticsearch.gateway.CorruptStateException: Format version is not supported. Upgrading to [8.3.2] is only supported from version [7.17.0].

How do I completely wipe out any elasticsearch docker data so that I can just install 8.3.2? I thought deleting all indices in 6.3.2 would have allowed a clean install of 8.3.2, but there must still be some 6.3.2 data persisting somewhere?

Here is my docker-compose.yml

    container_name: es_usamm-db
    image: docker.elastic.co/elasticsearch/elasticsearch:8.3.2
      - node.name=es01
      - cluster.name=es-docker-cluster
      - bootstrap.memory_lock=true
      - "ES_JAVA_OPTS=-Xms512m -Xmx512m"
      - xpack.security.enabled=false
      - discovery.type=single-node
        soft: -1
        hard: -1
      - data01:/usr/share/elasticsearch/data
      - ./server/elastic/scripts:/server/elastic/scripts
      - 9200:9200
      - default
    container_name: kibana_usamm-db
    image: docker.elastic.co/kibana/kibana:8.3.2
      - 5601:5601
      - default

Can you elaborate more on what you did when you said you deleted the indices?

You should really be using a different volumes: value, if data01 was what you used for 6.X. That way you don't need to worry about deleting anything, as it'll be a new data directory.

I did end up using a different volume i.e. data02 to get past the error.

To answer your question, when v6 was running, in dev tools kibana, I ran DELETE _all. Everything was wiped out, which was confusing when I tried to run v8 on the data01 volume. Anyway, changing the volume fixed it.

1 Like

That's what I figured you did.

But that doesn't remove things like cluster state, which is probably part of the reason you ran into this issue.


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