# How setup cluster on two different vps

**URL:** <https://discuss.elastic.co/t/how-setup-cluster-on-two-different-vps/311516>\
**Category:** Elasticsearch\
**Created:** [August 5, 2022, 11:34am UTC](https://discuss.elastic.co/t/how-setup-cluster-on-two-different-vps/311516 "2022-08-05T11:34:06Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Himan\_Yukubov](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/himan_yukubov/32/82044_2.png) [@Himan\_Yukubov](https://discuss.elastic.co/u/Himan_Yukubov)\
**Post date:** [August 5, 2022, 11:34am UTC](https://discuss.elastic.co/t/how-setup-cluster-on-two-different-vps/311516/1 "2022-08-05T11:34:06Z")

</div>

I have vps\_master and vps\_node. When i try setup cluster - its show on vps\_node

`skipping cluster bootstrapping as local node does not match`

What's wrong in my config?

```auto
version: '3.9'
services:
  master:
    image: elasticsearch:8.1.1
    container_name: master
    environment:
      node.name: "master"
      cluster.name: "elastic-cluster"
      network.host: "0.0.0.0"
      discovery.seed_hosts: "vps_node:1029"
      cluster.initial_master_nodes: "master"
      ELASTIC_PASSWORD: ${ELASTIC_PASSWORD}
      ES_JAVA_OPTS: "-Xms512m -Xmx512m"
      bootstrap.memory_lock: "true"
      xpack.security.enabled: "false"
      xpack.security.transport.ssl.enabled: "false"
    mem_limit: ${MEM_LIMIT}
    ulimits:
      memlock:
        soft: -1
        hard: -1
    volumes:
      - master-data:/usr/share/elasticsearch/data
    ports:
      - 1026:9200
      - 1027:9300
volumes:
  master-data:
    driver: local

```

```auto
version: '3.9'
services:
  node01:
    image: elasticsearch:8.1.1
    container_name: node01
    environment:
      node.name: "node01"
      cluster.name: "elastic-cluster"
      network.host: "0.0.0.0"
      discovery.seed_hosts: "vps_master:1026"
      cluster.initial_master_nodes: "vps_master:1026"
      ELASTIC_PASSWORD: ${ELASTIC_PASSWORD}
      ES_JAVA_OPTS: "-Xms512m -Xmx512m"
      bootstrap.memory_lock: "true"
      xpack.security.enabled: "false"
      xpack.security.transport.ssl.enabled: "false"
    mem_limit: ${MEM_LIMIT}
    ulimits:
      memlock:
        soft: -1
        hard: -1
    volumes:
      - master-data:/usr/share/elasticsearch/data
    ports:
      - 1028:9200
      - 1029:9300
volumes:
  master-data:
    driver: local

```

---

<div class="post-metadata">

**Author:** ![warkolm](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/warkolm/32/39224_2.png) [@warkolm](https://discuss.elastic.co/u/warkolm)\
**Post date:** [August 8, 2022, 12:55am UTC](https://discuss.elastic.co/t/how-setup-cluster-on-two-different-vps/311516/2 "2022-08-08T00:55:05Z")

</div>

Welcome to our community! 😃

It'd be useful if you shared your Elasticsearch logs that show this.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [September 5, 2022, 12:55am UTC](https://discuss.elastic.co/t/how-setup-cluster-on-two-different-vps/311516/3 "2022-09-05T00:55:55Z")

</div>

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