Star

Nebula Graph v2 是否可用 docker swarm 方式部署集群?

  • nebula 版本:v2
  • 部署方式:分布式
  • 问题的具体描述
  1. 之前一直使用docker-compose的方式将v2版本部署在集群上,但是发现所有images和service均只在layer节点上,在其他两个节点查不到。(这里希望有大佬解释一下原因哈,我没在docker-compose文档中查到相关内容)

  2. 于是只能用 docker swarm 的方式重新进行部署,但是由于手册2.0暂时没有相关内容,于是去查询1.0版本的手册。1.0中官方的配置yml文件在我这里并不能用,原因不太清楚,于是通过在论坛寻找在https://github.com/vesoft-inc/nebula-docker-compose/blob/docker-swarm/docker-stack.yaml这个链接中找到了可以使用的1.0版本的 docker swarm 集群部署方式。

  3. 由于想要直接使用新版本中的功能,希望能修改一个2.0版本的 yml 配置文件,经过查找资料,直接使用了https://github.com/vesoft-inc/nebula-docker-compose/blob/master/docker-compose.yaml这个文件作为配置文件,但是由于 swarm 中会忽略 cap_add 参数,会导致所有服务均无法启动,将所有路径都修改为已存在的绝对路径也是会报相同的错误,日志文件如下:

# docker service ls
ID                  NAME                MODE                REPLICAS            IMAGE                               PORTS
0l6y7ce8cdn4        nebula_graphd       replicated          0/1                 vesoft/nebula-graphd:v2-nightly     *:3699->3699/tcp, *:30165->13000/tcp, *:30166->13002/tcp
5a7s5po2hkfh        nebula_graphd1      replicated          0/1                 vesoft/nebula-graphd:v2-nightly     *:30167->3699/tcp, *:30168->13000/tcp, *:30169->13002/tcp
sk7ooubkrxx7        nebula_graphd2      replicated          0/1                 vesoft/nebula-graphd:v2-nightly     *:30179->3699/tcp, *:30180->13000/tcp, *:30181->13002/tcp
wte0tge03dhe        nebula_metad0       replicated          0/1                 vesoft/nebula-metad:v2-nightly      *:30156->45500/tcp, *:30157->11000/tcp, *:30158->11002/tcp
9xnh0hp0a56i        nebula_metad1       replicated          0/1                 vesoft/nebula-metad:v2-nightly      *:30170->45500/tcp, *:30171->11000/tcp, *:30172->11002/tcp
3kq0untkcbfs        nebula_metad2       replicated          0/1                 vesoft/nebula-metad:v2-nightly      *:30173->45500/tcp, *:30174->11000/tcp, *:30175->11002/tcp
p9u5paak60g7        nebula_storaged0    replicated          0/1                 vesoft/nebula-storaged:v2-nightly   *:30176->44500/tcp, *:30177->12000/tcp, *:30178->12002/tcp
paq6nvoobr82        nebula_storaged1    replicated          0/1                 vesoft/nebula-storaged:v2-nightly   *:30159->44500/tcp, *:30160->12000/tcp, *:30161->12002/tcp
zhv2hu4nirmi        nebula_storaged2    replicated          0/1                 vesoft/nebula-storaged:v2-nightly   *:30162->44500/tcp, *:30163->12000/tcp, *:30164->12002/tcp

# docker service ps wte0tge03dhe --no-trunc
ID                          NAME                  IMAGE                                                                                                    NODE                  DESIRED STATE       CURRENT STATE                 ERROR                                                          PORTS
s9jr8tt0jfzncx6gdlybx8p09   nebula_metad0.1       vesoft/nebula-metad:v2-nightly@sha256:457f6e1e5a5f79d7e3d71b63ff9ced9b11be4c500c6886d384dbe9af205088af   test001   Running             Starting about a minute ago                                    
7x67cislgppqgb0s4y9jhwxjj    \_ nebula_metad0.1   vesoft/nebula-metad:v2-nightly@sha256:457f6e1e5a5f79d7e3d71b63ff9ced9b11be4c500c6886d384dbe9af205088af   test001   Shutdown            Failed about a minute ago     "task: non-zero exit (137): dockerexec: unhealthy container"
2ccnagz8gfcvhdy4emfvga92n    \_ nebula_metad0.1   vesoft/nebula-metad:v2-nightly@sha256:457f6e1e5a5f79d7e3d71b63ff9ced9b11be4c500c6886d384dbe9af205088af   test001   Shutdown            Failed 3 minutes ago          "task: non-zero exit (137): dockerexec: unhealthy container"
z8hzv6xgrkjdmsdpn5ay0k098    \_ nebula_metad0.1   vesoft/nebula-metad:v2-nightly@sha256:457f6e1e5a5f79d7e3d71b63ff9ced9b11be4c500c6886d384dbe9af205088af   test001   Shutdown            Failed 6 minutes ago          "task: non-zero exit (137): dockerexec: unhealthy container"
vdgpg45grlln82q08qcnwjtyb    \_ nebula_metad0.1   vesoft/nebula-metad:v2-nightly@sha256:457f6e1e5a5f79d7e3d71b63ff9ced9b11be4c500c6886d384dbe9af205088af   test001   Shutdown            Failed 8 minutes ago          "task: non-zero exit (137): dockerexec: unhealthy container"

于是希望有大佬帮忙看看,v2 是否可用 docker swarm 方式部署集群?
如果是用compose的方式为什么只能在主节点运行?

:expressionless: 目前我没有机器测试,光这个unhealthy也没法定位问题

您有没有什么好的建议?我这来测试 :joy:
我的配置文件现在是这样的

version: '3.4'
services:
  metad0:
    image: vesoft/nebula-metad:v2-nightly
    environment:
      USER: root
      TZ:   "UTC"
    command:
      - --meta_server_addrs=metad0:45500,metad1:45500,metad2:45500
      - --local_ip=metad0
      - --ws_ip=metad0
      - --port=45500
      - --ws_http_port=11000
      - --data_path=/data/meta
      - --log_dir=/logs
      - --v=0
      - --minloglevel=0
    healthcheck:
      test: ["CMD", "curl", "-sf", "http://metad0:11000/status"]
      interval: 30s
      timeout: 10s
      retries: 3
      start_period: 20s
    ports:
      - 45500
      - 11000
      - 11002
    volumes:
      - ./nebula-swarm/data/meta0:/data/meta
      - ./nebula-swarm/logs/meta0:/logs
    networks:
      - nebula-net
    restart: on-failure
    cap_add:
      - SYS_PTRACE

  metad1:
    image: vesoft/nebula-metad:v2-nightly
    environment:
      USER: root
      TZ:   "UTC"
    command:
      - --meta_server_addrs=metad0:45500,metad1:45500,metad2:45500
      - --local_ip=metad1
      - --ws_ip=metad1
      - --port=45500
      - --ws_http_port=11000
      - --data_path=/data/meta
      - --log_dir=/logs
      - --v=0
      - --minloglevel=0
    healthcheck:
      test: ["CMD", "curl", "-sf", "http://metad1:11000/status"]
      interval: 30s
      timeout: 10s
      retries: 3
      start_period: 20s
    ports:
      - 45500
      - 11000
      - 11002
    volumes:
      - ./nebula-swarm/data/meta1:/data/meta
      - ./nebula-swarm/logs/meta1:/logs
    networks:
      - nebula-net
    restart: on-failure
    cap_add:
      - SYS_PTRACE

  metad2:
    image: vesoft/nebula-metad:v2-nightly
    environment:
      USER: root
      TZ:   "UTC"
    command:
      - --meta_server_addrs=metad0:45500,metad1:45500,metad2:45500
      - --local_ip=metad2
      - --ws_ip=metad2
      - --port=45500
      - --ws_http_port=11000
      - --data_path=/data/meta
      - --log_dir=/logs
      - --v=0
      - --minloglevel=0
    healthcheck:
      test: ["CMD", "curl", "-sf", "http://metad2:11000/status"]
      interval: 30s
      timeout: 10s
      retries: 3
      start_period: 20s
    ports:
      - 45500
      - 11000
      - 11002
    volumes:
      - ./nebula-swarm/data/meta2:/data/meta
      - ./nebula-swarm/logs/meta2:/logs
    networks:
      - nebula-net
    restart: on-failure
    cap_add:
      - SYS_PTRACE

  storaged0:
    image: vesoft/nebula-storaged:v2-nightly
    environment:
      USER: root
      TZ:   "UTC"
    command:
      - --meta_server_addrs=metad0:45500,metad1:45500,metad2:45500
      - --local_ip=storaged0
      - --ws_ip=storaged0
      - --port=44500
      - --ws_http_port=12000
      - --data_path=/data/storage
      - --log_dir=/logs
      - --v=0
      - --minloglevel=0
    depends_on:
      - metad0
      - metad1
      - metad2
    healthcheck:
      test: ["CMD", "curl", "-sf", "http://storaged0:12000/status"]
      interval: 30s
      timeout: 10s
      retries: 3
      start_period: 20s
    ports:
      - 44500
      - 12000
      - 12002
    volumes:
      - ./nebula-swarm/data/storage0:/data/storage
      - ./nebula-swarm/logs/storage0:/logs
    networks:
      - nebula-net
    restart: on-failure
    cap_add:
      - SYS_PTRACE

  storaged1:
    image: vesoft/nebula-storaged:v2-nightly
    environment:
      USER: root
      TZ:   "UTC"
    command:
      - --meta_server_addrs=metad0:45500,metad1:45500,metad2:45500
      - --local_ip=storaged1
      - --ws_ip=storaged1
      - --port=44500
      - --ws_http_port=12000
      - --data_path=/data/storage
      - --log_dir=/logs
      - --v=0
      - --minloglevel=0
    depends_on:
      - metad0
      - metad1
      - metad2
    healthcheck:
      test: ["CMD", "curl", "-sf", "http://storaged1:12000/status"]
      interval: 30s
      timeout: 10s
      retries: 3
      start_period: 20s
    ports:
      - 44500
      - 12000
      - 12002
    volumes:
      - ./nebula-swarm/data/storage1:/data/storage
      - ./nebula-swarm/logs/storage1:/logs
    networks:
      - nebula-net
    restart: on-failure
    cap_add:
      - SYS_PTRACE

  storaged2:
    image: vesoft/nebula-storaged:v2-nightly
    environment:
      USER: root
      TZ:   "UTC"
    command:
      - --meta_server_addrs=metad0:45500,metad1:45500,metad2:45500
      - --local_ip=storaged2
      - --ws_ip=storaged2
      - --port=44500
      - --ws_http_port=12000
      - --data_path=/data/storage
      - --log_dir=/logs
      - --v=0
      - --minloglevel=0
    depends_on:
      - metad0
      - metad1
      - metad2
    healthcheck:
      test: ["CMD", "curl", "-sf", "http://storaged2:12000/status"]
      interval: 30s
      timeout: 10s
      retries: 3
      start_period: 20s
    ports:
      - 44500
      - 12000
      - 12002
    volumes:
      - ./nebula-swarm/data/storage2:/data/storage
      - ./nebula-swarm/logs/storage2:/logs
    networks:
      - nebula-net
    restart: on-failure
    cap_add:
      - SYS_PTRACE

  graphd:
    image: vesoft/nebula-graphd:v2-nightly
    environment:
      USER: root
      TZ:   "UTC"
    command:
      - --meta_server_addrs=metad0:45500,metad1:45500,metad2:45500
      - --port=3699
      - --ws_ip=graphd
      - --ws_http_port=13000
      - --log_dir=/logs
      - --v=0
      - --minloglevel=0
    depends_on:
      - metad0
      - metad1
      - metad2
    healthcheck:
      test: ["CMD", "curl", "-sf", "http://graphd:13000/status"]
      interval: 30s
      timeout: 10s
      retries: 3
      start_period: 20s
    ports:
      - "3699:3699"
      - 13000
      - 13002
    volumes:
      - ./nebula-swarm/logs/graph0:/logs
    networks:
      - nebula-net
    restart: on-failure
    cap_add:
      - SYS_PTRACE

  graphd1:
    image: vesoft/nebula-graphd:v2-nightly
    environment:
      USER: root
      TZ:   "UTC"
    command:
      - --meta_server_addrs=metad0:45500,metad1:45500,metad2:45500
      - --port=3699
      - --ws_ip=graphd1
      - --ws_http_port=13000
      - --log_dir=/logs
      - --v=0
      - --minloglevel=0
    depends_on:
      - metad0
      - metad1
      - metad2
    healthcheck:
      test: ["CMD", "curl", "-sf", "http://graphd1:13000/status"]
      interval: 30s
      timeout: 10s
      retries: 3
      start_period: 20s
    ports:
      - 3699
      - 13000
      - 13002
    volumes:
      - ./nebula-swarm/logs/graph1:/logs
    networks:
      - nebula-net
    restart: on-failure
    cap_add:
      - SYS_PTRACE

  graphd2:
    image: vesoft/nebula-graphd:v2-nightly
    environment:
      USER: root
      TZ:   "UTC"
    command:
      - --meta_server_addrs=metad0:45500,metad1:45500,metad2:45500
      - --port=3699
      - --ws_ip=graphd2
      - --ws_http_port=13000
      - --log_dir=/logs
      - --v=0
      - --minloglevel=0
    depends_on:
      - metad0
      - metad1
      - metad2
    healthcheck:
      test: ["CMD", "curl", "-sf", "http://graphd2:13000/status"]
      interval: 30s
      timeout: 10s
      retries: 3
      start_period: 20s
    ports:
      - 3699
      - 13000
      - 13002
    volumes:
      - ./nebula-swarm/logs/graph2:/logs
    networks:
      - nebula-net
    restart: on-failure
    cap_add:
      - SYS_PTRACE

networks:
  nebula-net:

swarm 为啥要写成固定路径的

改成这种,参考1.x版本的docker-stack.yml

不成,感觉2.0的dns还是没有很好地支持,有点复杂,使用service_name:port这种方式不确定在swarm集群重启后nebula这边有没有做兼容。

最坏的情况,还是用host模式。

没机器测试猜也没用,需要ng这边来解答一下。

改了之后貌似还是不行,starting一会就挂了,还是报容器不健康的错误。
我找了之前的一个logs是这样的:

Log file created at: 2020/12/30 09:21:23
Running on machine: 09b31b0162e9
Log line format: [IWEF]mmdd hh:mm:ss.uuuuuu threadid file:line] msg
E1230 09:21:23.398514    51 ThriftClientManager.inl:51] Failed to resolve address for 'metad1': Name or service not known (error=-2): Unknown error -2
E1230 09:21:23.414639    51 ThriftClientManager.inl:51] Failed to resolve address for 'metad1': Name or service not known (error=-2): Unknown error -2

看起来是不能解析meta1的地址,我来全部换成ip试一试

这个需要ng这边来支持了

好的好的,感谢 :pray:

添加:
全部修改为IP之后仍然产生unhealthy container 的问题,日志如下:

Log file created at: 2020/12/30 09:46:14
Running on machine: ceda7c469c19
Log line format: [IWEF]mmdd hh:mm:ss.uuuuuu threadid file:line] msg
I1230 09:46:14.083281     1 MetaDaemon.cpp:213] identify myself as [192.168.1.168:45500]
I1230 09:46:14.093941     1 NebulaStore.cpp:47] Start the raft service...
I1230 09:46:14.094988     1 RaftexService.cpp:65] Init thrift server for raft service, port: 45501
I1230 09:46:14.095170    50 RaftexService.cpp:99] Starting the Raftex Service
I1230 09:46:14.110343    50 RaftexService.cpp:87] Starting the Raftex Service on 45501
I1230 09:46:14.110386    50 RaftexService.cpp:111] Start the Raftex Service successfully
I1230 09:46:14.110414     1 NebulaStore.cpp:75] Scan the local path, and init the spaces_
I1230 09:46:14.110741     1 NebulaStore.cpp:81] Scan path "/data/meta/0"
I1230 09:46:14.123821     1 RocksEngine.cpp:105] open rocksdb on /data/meta/nebula/0/data
I1230 09:46:14.123867     1 NebulaStore.cpp:111] Load space 0 from disk
I1230 09:46:14.123920     1 NebulaStore.cpp:146] Need to open 1 parts of space 0
I1230 09:46:14.134423    46 Part.cpp:50] [Port: 45501, Space: 0, Part: 0] Cannot fetch the last committed log id from the storage engine
I1230 09:46:14.134472    46 RaftPart.cpp:295] [Port: 45501, Space: 0, Part: 0] There are 2 peer hosts, and total 3 copies. The quorum is 2, as learner 0, lastLogId 0, lastLogTerm 0, committedLogId 0, term 0
I1230 09:46:14.134496    46 RaftPart.cpp:308] [Port: 45501, Space: 0, Part: 0] Add peer [218.255.77.47:45501]
I1230 09:46:14.134541    46 RaftPart.cpp:308] [Port: 45501, Space: 0, Part: 0] Add peer [223.255.155.250:45501]
I1230 09:46:14.134754    46 NebulaStore.cpp:177] Load part 0, 0 from disk
I1230 09:46:14.134878     1 NebulaStore.cpp:192] Load space 0 complete
I1230 09:46:14.134919     1 NebulaStore.cpp:201] Init data from partManager for [192.168.1.168:45500]
I1230 09:46:14.134989     1 NebulaStore.cpp:293] Data space 0 has existed!
I1230 09:46:14.135025     1 NebulaStore.cpp:322] [Space: 0, Part: 0] has existed!
I1230 09:46:14.135087     1 NebulaStore.cpp:68] Register handler...
I1230 09:46:14.135118     1 MetaDaemon.cpp:98] Waiting for the leader elected...
I1230 09:46:14.135149     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:46:14.963918    47 RaftPart.cpp:1043] [Port: 45501, Space: 0, Part: 0] Start leader election, reason: lastMsgDur 830, term 0
I1230 09:46:14.965150    47 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 1, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:46:14.969036    47 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:46:15.135318     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:46:16.019896    49 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 2, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:46:16.023799    49 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:46:16.135532     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:46:17.135738     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:46:17.569749    46 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 3, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:46:17.573256    46 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:46:18.136005     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:46:19.136265     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:46:19.255120    47 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 4, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:46:19.259114    47 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:46:20.136526     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:46:20.824934    48 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 5, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:46:20.828394    48 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:46:21.136817     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:46:22.137138     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:46:22.264183    49 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 6, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:46:22.267208    49 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:46:23.137384     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:46:23.229382    46 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 7, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:46:23.233301    46 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:46:24.126466    47 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 8, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:46:24.130081    47 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:46:24.137622     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:46:25.137825     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:46:25.307449    48 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 9, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:46:25.311004    48 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:46:25.885756    49 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 10, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:46:25.889465    49 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:46:26.138067     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:46:27.138304     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:46:27.410200    46 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 11, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:46:27.413669    46 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:46:28.138635     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:46:28.449918    47 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 12, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:46:28.453539    47 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:46:29.138949     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:46:29.486810    48 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 13, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:46:29.489485    48 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:46:30.139200     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:46:31.139590     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:46:31.163532    49 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 14, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:46:31.167119    49 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:46:32.139946     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:46:32.878087    46 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 15, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:46:32.881841    46 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:46:33.140283     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:46:34.140558     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:46:34.537699    47 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 16, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:46:34.541049    47 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:46:35.140828     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:46:35.472231    48 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 17, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:46:35.475657    48 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:46:36.087479    49 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 18, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:46:36.090696    49 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:46:36.141064     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:46:37.141299     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:46:37.679512    46 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 19, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:46:37.682801    46 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:46:38.141551     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:46:38.567975    47 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 20, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:46:38.571596    47 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:46:39.141886     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:46:40.142168     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:46:40.317602    48 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 21, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:46:40.321202    48 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:46:41.060209    49 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 22, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:46:41.063426    49 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:46:41.142436     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:46:42.142814     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:46:42.810556    46 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 23, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:46:42.814306    46 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:46:43.143151     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:46:43.706390    47 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 24, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:46:43.709692    47 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:46:44.143402     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:46:44.390640    48 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 25, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:46:44.394093    48 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:46:45.096088    49 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 26, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:46:45.099421    49 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:46:45.144017     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:46:46.110836    46 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 27, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:46:46.114331    46 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:46:46.144227     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:46:47.144502     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:46:47.769229    47 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 28, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:46:47.772051    47 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:46:48.144893     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:46:49.145299     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:46:49.364351    48 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 29, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:46:49.367314    48 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:46:49.976171    49 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 30, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:46:49.979949    49 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:46:50.145654     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:46:51.145871     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:46:51.168367    46 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 31, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:46:51.171979    46 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:46:52.146169     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:46:52.752933    47 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 32, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:46:52.755115    47 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:46:53.146524     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:46:53.819393    48 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 33, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:46:53.822631    48 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:46:54.146807     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:46:54.870889    49 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 34, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:46:54.874506    49 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:46:55.147037     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:46:56.006852    46 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 35, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:46:56.010581    46 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:46:56.147300     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:46:57.147545     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:46:57.195925    47 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 36, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:46:57.199343    47 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:46:58.147889     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:46:58.208554    48 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 37, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:46:58.212105    48 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:46:59.148164     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:00.148430     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:00.151304    49 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 38, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:00.154525    49 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:00.871417    46 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 39, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:00.874763    46 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:01.148819     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:02.149085     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:02.177371    47 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 40, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:02.179801    47 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:02.727625    48 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 41, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:02.730998    48 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:03.149353     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:04.039474    49 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 42, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:04.042589    49 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:04.149519     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:05.149713     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:05.691476    46 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 43, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:05.694649    46 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:06.149997     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:07.103258    47 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 44, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:07.106824    47 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:07.150315     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:07.764757    48 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 45, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:07.767836    48 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:08.150492     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:08.520787    49 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 46, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:08.522979    49 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:09.150703     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:10.150956     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:10.349007    46 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 47, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:10.351377    46 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:11.151336     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:11.366602    47 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 48, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:11.370306    47 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:12.151721     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:12.188580    48 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 49, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:12.191089    48 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:13.152056     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:14.130239    49 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 50, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:14.133306    49 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:14.152492     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:14.782426    46 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 51, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:14.785014    46 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:15.152699     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:16.152997     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:16.226687    47 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 52, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:16.230202    47 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:17.153328     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:17.675907    48 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 53, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:17.679067    48 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:18.153683     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:18.370985    49 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 54, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:18.374632    49 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:19.037566    46 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 55, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:19.041065    46 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:19.154003     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:19.969254    47 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 56, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:19.972470    47 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:20.154247     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:21.154510     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:21.362150    48 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 57, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:21.365566    48 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:22.058452    49 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 58, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:22.061997    49 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:22.154835     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:23.155090     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:23.713831    46 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 59, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:23.717296    46 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:24.155344     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:24.255066    47 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 60, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:24.258316    47 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:25.155529     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:25.230471    48 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 61, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:25.233884    48 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:26.155736     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:26.272114    49 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 62, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:26.275569    49 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:27.156116     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:27.633183    46 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 63, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:27.636299    46 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:28.156450     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:28.974853    47 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 64, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:28.978868    47 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:29.156687     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:30.156919     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:30.425496    48 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 65, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:30.428880    48 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:31.157178     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:31.538182    49 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 66, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:31.540735    49 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:32.157474     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:33.157802     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:33.517912    46 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 67, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:33.520264    46 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:34.158041     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:35.158963     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:35.296232    47 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 68, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:35.299572    47 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:36.159373     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:36.778280    48 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 69, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:36.781710    48 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:37.159703     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:38.160930     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:38.314476    49 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 70, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:38.317503    49 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:39.163856     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:40.164124     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:40.173559    46 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 71, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:40.176869    46 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:41.164443     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:41.734628    47 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 72, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:41.738035    47 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:42.164700     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:43.165024     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:43.349869    48 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 73, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:43.352993    48 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:44.165421     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:45.157121    49 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 74, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:45.159615    49 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:45.165700     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:45.941593    46 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 75, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:45.944938    46 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:46.165916     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:46.545024     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:47.235864    47 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 76, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:47.239372    47 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:47.545274     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:48.545580     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:49.014183    48 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 77, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:49.016903    48 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:49.545938     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:49.695865    49 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 78, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:49.699164    49 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:50.218870    46 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 79, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:50.222002    46 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:50.546203     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:51.180197    47 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 80, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:51.185187    47 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:51.548420     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:52.471740    48 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 81, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:52.475262    48 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:52.548929     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:53.549122     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:53.818831    49 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 82, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:53.822149    49 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:54.362879    46 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 83, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:54.365257    46 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:54.549455     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:55.212276    47 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 84, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:55.215565    47 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election
I1230 09:47:55.549707     1 MetaDaemon.cpp:111] Leader has not been elected, sleep 1s
I1230 09:47:56.044618    48 RaftPart.cpp:1192] [Port: 45501, Space: 0, Part: 0] Sending out an election request (space = 0, part = 0, term = 85, lastLogId = 0, lastLogTerm = 0, candidateIP = 192.168.1.168, candidatePort = 45501)
I1230 09:47:56.048298    48 RaftPart.cpp:1274] [Port: 45501, Space: 0, Part: 0] No one is elected, continue the election

@CPWstatic @pandasheeps @kyle

1赞

更新:经过尝试,完成了v2版本使用swarm方式的集群部署。

  1. 使用1.0版本swarm方式可用的yml:https://github.com/vesoft-inc/nebula-docker-compose/blob/docker-swarm/docker-stack.yaml
  2. 在其中所有mated节点的command部分添加- --ws_http_port=11000
  3. 在其中所有storaged节点的command部分添加- --ws_http_port=12000
  4. 在其中所有graphd节点的command部分添加- --ws_http_port=13000
    即可以以1.0同样方式swarm部署集群。

修改后yml文件修改如下:

version: '3.6'
services:
  metad0:
    container_name: nebula-mate0
    image: vesoft/nebula-metad:v2-nightly
    env_file:
      - /home/gdelt/nebula/nebula.env
    command:
      - --meta_server_addrs=192.168.4.172:45500,192.168.4.173:45500,192.168.4.174:45500
      - --local_ip=192.168.4.172
      - --ws_ip=192.168.4.172
      - --port=45500
      - --ws_http_port=11000
      - --data_path=/data/meta
      - --log_dir=/logs
      - --v=0
      - --minloglevel=0
    deploy:
      replicas: 1
      restart_policy:
        condition: on-failure
      placement:
        constraints:
          - node.hostname == node172
    healthcheck:
      test: ["CMD", "curl", "-f", "http://192.168.4.172:11000/status"]
      interval: 30s
      timeout: 10s
      retries: 3
      start_period: 20s
    ports:
      - target: 11000
        published: 11000
        protocol: tcp
        mode: host
      - target: 11002
        published: 11002
        protocol: tcp
        mode: host
      - target: 45500
        published: 45500
        protocol: tcp
        mode: host
    volumes:
      - /home/gdelt/nebula/data/meta0:/data/meta
      - /home/gdelt/nebula/logs/meta0:/logs
    networks:
      - nebula-net

  metad1:
    container_name: nebula-mate1
    image: vesoft/nebula-metad:v2-nightly
    env_file:
      - /home/gdelt/nebula/nebula.env
    command:
      - --meta_server_addrs=192.168.4.172:45500,192.168.4.173:45500,192.168.4.174:45500
      - --local_ip=192.168.4.173
      - --ws_ip=192.168.4.173
      - --port=45500
      - --ws_http_port=11000
      - --data_path=/data/meta
      - --log_dir=/logs
      - --v=0
      - --minloglevel=0
    deploy:
      replicas: 1
      restart_policy:
        condition: on-failure
      placement:
        constraints:
          - node.hostname == node173
    healthcheck:
      test: ["CMD", "curl", "-f", "http://192.168.4.173:11000/status"]
      interval: 30s
      timeout: 10s
      retries: 3
      start_period: 20s
    ports:
      - target: 11000
        published: 11000
        protocol: tcp
        mode: host
      - target: 11002
        published: 11002
        protocol: tcp
        mode: host
      - target: 45500
        published: 45500
        protocol: tcp
        mode: host
    volumes:
      - /home/gdelt/nebula/data/meta1:/data/meta
      - /home/gdelt/nebula/logs/meta1:/logs
    networks:
      - nebula-net

  metad2:
    container_name: nebula-mate2
    image: vesoft/nebula-metad:v2-nightly
    env_file:
      - /home/gdelt/nebula/nebula.env
    command:
      - --meta_server_addrs=192.168.4.172:45500,192.168.4.173:45500,192.168.4.174:45500
      - --local_ip=192.168.4.174
      - --ws_ip=192.168.4.174
      - --port=45500
      - --ws_http_port=11000
      - --data_path=/data/meta
      - --log_dir=/logs
      - --v=0
      - --minloglevel=0
    deploy:
      replicas: 1
      restart_policy:
        condition: on-failure
      placement:
        constraints:
          - node.hostname == node174
    healthcheck:
      test: ["CMD", "curl", "-f", "http://192.168.4.174:11000/status"]
      interval: 30s
      timeout: 10s
      retries: 3
      start_period: 20s
    ports:
      - target: 11000
        published: 11000
        protocol: tcp
        mode: host
      - target: 11002
        published: 11002
        protocol: tcp
        mode: host
      - target: 45500
        published: 45500
        protocol: tcp
        mode: host
    volumes:
      - /home/gdelt/nebula/data/meta2:/data/meta
      - /home/gdelt/nebula/logs/meta2:/logs
    networks:
      - nebula-net

  storaged0:
    container_name: nebula-storaged0
    image: vesoft/nebula-storaged:v2-nightly
    env_file:
      - /home/gdelt/nebula/nebula.env
    command:
      - --meta_server_addrs=192.168.4.172:45500,192.168.4.173:45500,192.168.4.174:45500
      - --local_ip=192.168.4.172
      - --ws_ip=192.168.4.172
      - --port=44500
      - --ws_http_port=12000
      - --data_path=/data/storage
      - --log_dir=/logs
      - --v=0
      - --minloglevel=0
    deploy:
      replicas: 1
      restart_policy:
        condition: on-failure
      placement:
        constraints:
          - node.hostname == node172
    depends_on:
      - metad0
      - metad1
      - metad2
    healthcheck:
      test: ["CMD", "curl", "-f", "http://192.168.4.172:12000/status"]
      interval: 30s
      timeout: 10s
      retries: 3
      start_period: 20s
    ports:
      - target: 12000
        published: 12000
        protocol: tcp
        mode: host
      - target: 12002
        published: 12002
        protocol: tcp
        mode: host
    volumes:
      - /home/gdelt/nebula/data/storaged0:/data/meta
      - /home/gdelt/nebula/logs/storaged0:/logs
    networks:
      - nebula-net

  storaged1:
    container_name: nebula-storaged1
    image: vesoft/nebula-storaged:v2-nightly
    env_file:
      - /home/gdelt/nebula/nebula.env
    command:
      - --meta_server_addrs=192.168.4.172:45500,192.168.4.173:45500,192.168.4.174:45500
      - --local_ip=192.168.4.173
      - --ws_ip=192.168.4.173
      - --port=44500
      - --ws_http_port=12000
      - --data_path=/data/storage
      - --log_dir=/logs
      - --v=0
      - --minloglevel=0
    deploy:
      replicas: 1
      restart_policy:
        condition: on-failure
      placement:
        constraints:
          - node.hostname == node173
    depends_on:
      - metad0
      - metad1
      - metad2
    healthcheck:
      test: ["CMD", "curl", "-f", "http://192.168.4.173:12000/status"]
      interval: 30s
      timeout: 10s
      retries: 3
      start_period: 20s
    ports:
      - target: 12000
        published: 12000
        protocol: tcp
        mode: host
      - target: 12002
        published: 12004
        protocol: tcp
        mode: host
    volumes:
      - /home/gdelt/nebula/data/storaged1:/data/meta
      - /home/gdelt/nebula/logs/storaged1:/logs
    networks:
      - nebula-net

  storaged2:
    container_name: nebula-storaged2
    image: vesoft/nebula-storaged:v2-nightly
    env_file:
      - /home/gdelt/nebula/nebula.env
    command:
      - --meta_server_addrs=192.168.4.172:45500,192.168.4.173:45500,192.168.4.174:45500
      - --local_ip=192.168.4.174
      - --ws_ip=192.168.4.174
      - --port=44500
      - --ws_http_port=12000
      - --data_path=/data/storage
      - --log_dir=/logs
      - --v=0
      - --minloglevel=0
    deploy:
      replicas: 1
      restart_policy:
        condition: on-failure
      placement:
        constraints:
          - node.hostname == node174
    depends_on:
      - metad0
      - metad1
      - metad2
    healthcheck:
      test: ["CMD", "curl", "-f", "http://192.168.4.174:12000/status"]
      interval: 30s
      timeout: 10s
      retries: 3
      start_period: 20s
    ports:
      - target: 12000
        published: 12000
        protocol: tcp
        mode: host
      - target: 12002
        published: 12006
        protocol: tcp
        mode: host
    volumes:
      - /home/gdelt/nebula/data/storaged2:/data/meta
      - /home/gdelt/nebula/logs/storaged2:/logs
    networks:
      - nebula-net

  graphd0:
    container_name: nebula-graphd0
    image: vesoft/nebula-graphd:v2-nightly
    env_file:
      - /home/gdelt/nebula/nebula.env
    command:
      - --meta_server_addrs=192.168.4.172:45500,192.168.4.173:45500,192.168.4.174:45500
      - --port=3699
      - --ws_http_port=13000
      - --ws_ip=192.168.4.172
      - --log_dir=/logs
      - --v=0
      - --minloglevel=0
    deploy:
      replicas: 1
      restart_policy:
        condition: on-failure
      placement:
        constraints:
          - node.hostname == node172
    depends_on:
      - metad0
      - metad1
      - metad2
    healthcheck:
      test: ["CMD", "curl", "-f", "http://192.168.4.172:13000/status"]
      interval: 30s
      timeout: 10s
      retries: 3
      start_period: 20s
    ports:
      - target: 3699
        published: 3699
        protocol: tcp
        mode: host
      - target: 13000
        published: 13000
        protocol: tcp
        mode: host
      - target: 13002
        published: 13002
        protocol: tcp
        mode: host
    volumes:
      - /home/gdelt/nebula/logs/graphd0:/logs
      - /home/gdelt/nebula/config:/usr/local/nebula/etc
    networks:
      - nebula-net

  graphd1:
    container_name: nebula-graphd1
    image: vesoft/nebula-graphd:v2-nightly
    env_file:
      - /home/gdelt/nebula/nebula.env
    command:
      - --meta_server_addrs=192.168.4.172:45500,192.168.4.173:45500,192.168.4.174:45500
      - --port=3699
      - --ws_http_port=13000
      - --ws_ip=192.168.4.173
      - --log_dir=/logs
      - --v=0
      - --minloglevel=0
    deploy:
      replicas: 1
      restart_policy:
        condition: on-failure
      placement:
        constraints:
          - node.hostname == node173
    depends_on:
      - metad0
      - metad1
      - metad2
    healthcheck:
      test: ["CMD", "curl", "-f", "http://192.168.4.173:13000/status"]
      interval: 30s
      timeout: 10s
      retries: 3
      start_period: 20s
    ports:
      - target: 3699
        published: 3699
        protocol: tcp
        mode: host
      - target: 13000
        published: 13000
        protocol: tcp
        mode: host
      - target: 13002
        published: 13002
        protocol: tcp
        mode: host
    volumes:
      - /home/gdelt/nebula/logs/graphd1:/logs
      - /home/gdelt/nebula/config:/usr/local/nebula/etc
    networks:
      - nebula-net

  graphd2:
    container_name: nebula-graphd2
    image: vesoft/nebula-graphd:v2-nightly
    env_file:
      - /home/gdelt/nebula/nebula.env
    command:
      - --meta_server_addrs=192.168.4.172:45500,192.168.4.173:45500,192.168.4.174:45500
      - --port=3699
      - --ws_http_port=13000
      - --ws_ip=192.168.4.174
      - --log_dir=/logs
      - --v=0
      - --minloglevel=0
    deploy:
      replicas: 1
      restart_policy:
        condition: on-failure
      placement:
        constraints:
          - node.hostname == node174
    depends_on:
      - metad0
      - metad1
      - metad2
    healthcheck:
      test: ["CMD", "curl", "-f", "http://192.168.4.174:13000/status"]
      interval: 30s
      timeout: 10s
      retries: 3
      start_period: 20s
    ports:
      - target: 3699
        published: 3699
        protocol: tcp
        mode: host
      - target: 13000
        published: 13000
        protocol: tcp
        mode: host
      - target: 13002
        published: 13002
        protocol: tcp
        mode: host
    volumes:
      - /home/gdelt/nebula/logs/graphd2:/logs
      - /home/gdelt/nebula/config:/usr/local/nebula/etc
    networks:
      - nebula-net

networks:
  nebula-net:
    external: true
    attachable: true
    name: host

2赞

仍然是host模式

上面修改后的yml文件storage路径映射有误,更新为:

version: '3.6'
services:
  metad0:
    container_name: nebula-mate0
    image: vesoft/nebula-metad:v2-nightly
    env_file:
      - /home/gdelt/nebula/nebula.env
    command:
      - --meta_server_addrs=192.168.4.172:45500,192.168.4.173:45500,192.168.4.174:45500
      - --local_ip=192.168.4.172
      - --ws_ip=192.168.4.172
      - --port=45500
      - --ws_http_port=11000
      - --data_path=/data/meta
      - --log_dir=/logs
      - --v=0
      - --minloglevel=0
    deploy:
      replicas: 1
      restart_policy:
        condition: on-failure
      placement:
        constraints:
          - node.hostname == node172
    healthcheck:
      test: ["CMD", "curl", "-f", "http://192.168.4.172:11000/status"]
      interval: 30s
      timeout: 10s
      retries: 3
      start_period: 20s
    ports:
      - target: 11000
        published: 11000
        protocol: tcp
        mode: host
      - target: 11002
        published: 11002
        protocol: tcp
        mode: host
      - target: 45500
        published: 45500
        protocol: tcp
        mode: host
    volumes:
      - /home/gdelt/nebula/data/meta0:/data/meta
      - /home/gdelt/nebula/logs/meta0:/logs
    networks:
      - nebula-net

  metad1:
    container_name: nebula-mate1
    image: vesoft/nebula-metad:v2-nightly
    env_file:
      - /home/gdelt/nebula/nebula.env
    command:
      - --meta_server_addrs=192.168.4.172:45500,192.168.4.173:45500,192.168.4.174:45500
      - --local_ip=192.168.4.173
      - --ws_ip=192.168.4.173
      - --port=45500
      - --ws_http_port=11000
      - --data_path=/data/meta
      - --log_dir=/logs
      - --v=0
      - --minloglevel=0
    deploy:
      replicas: 1
      restart_policy:
        condition: on-failure
      placement:
        constraints:
          - node.hostname == node173
    healthcheck:
      test: ["CMD", "curl", "-f", "http://192.168.4.173:11000/status"]
      interval: 30s
      timeout: 10s
      retries: 3
      start_period: 20s
    ports:
      - target: 11000
        published: 11000
        protocol: tcp
        mode: host
      - target: 11002
        published: 11002
        protocol: tcp
        mode: host
      - target: 45500
        published: 45500
        protocol: tcp
        mode: host
    volumes:
      - /home/gdelt/nebula/data/meta1:/data/meta
      - /home/gdelt/nebula/logs/meta1:/logs
    networks:
      - nebula-net

  metad2:
    container_name: nebula-mate2
    image: vesoft/nebula-metad:v2-nightly
    env_file:
      - /home/gdelt/nebula/nebula.env
    command:
      - --meta_server_addrs=192.168.4.172:45500,192.168.4.173:45500,192.168.4.174:45500
      - --local_ip=192.168.4.174
      - --ws_ip=192.168.4.174
      - --port=45500
      - --ws_http_port=11000
      - --data_path=/data/meta
      - --log_dir=/logs
      - --v=0
      - --minloglevel=0
    deploy:
      replicas: 1
      restart_policy:
        condition: on-failure
      placement:
        constraints:
          - node.hostname == node174
    healthcheck:
      test: ["CMD", "curl", "-f", "http://192.168.4.174:11000/status"]
      interval: 30s
      timeout: 10s
      retries: 3
      start_period: 20s
    ports:
      - target: 11000
        published: 11000
        protocol: tcp
        mode: host
      - target: 11002
        published: 11002
        protocol: tcp
        mode: host
      - target: 45500
        published: 45500
        protocol: tcp
        mode: host
    volumes:
      - /home/gdelt/nebula/data/meta2:/data/meta
      - /home/gdelt/nebula/logs/meta2:/logs
    networks:
      - nebula-net

  storaged0:
    container_name: nebula-storaged0
    image: vesoft/nebula-storaged:v2-nightly
    env_file:
      - /home/gdelt/nebula/nebula.env
    command:
      - --meta_server_addrs=192.168.4.172:45500,192.168.4.173:45500,192.168.4.174:45500
      - --local_ip=192.168.4.172
      - --ws_ip=192.168.4.172
      - --port=44500
      - --ws_http_port=12000
      - --data_path=/data/storage
      - --log_dir=/logs
      - --v=0
      - --minloglevel=0
    deploy:
      replicas: 1
      restart_policy:
        condition: on-failure
      placement:
        constraints:
          - node.hostname == node172
    depends_on:
      - metad0
      - metad1
      - metad2
    healthcheck:
      test: ["CMD", "curl", "-f", "http://192.168.4.172:12000/status"]
      interval: 30s
      timeout: 10s
      retries: 3
      start_period: 20s
    ports:
      - target: 12000
        published: 12000
        protocol: tcp
        mode: host
      - target: 12002
        published: 12002
        protocol: tcp
        mode: host
    volumes:
      - /home/gdelt/nebula/data/storaged0:/data/storage
      - /home/gdelt/nebula/logs/storaged0:/logs
    networks:
      - nebula-net

  storaged1:
    container_name: nebula-storaged1
    image: vesoft/nebula-storaged:v2-nightly
    env_file:
      - /home/gdelt/nebula/nebula.env
    command:
      - --meta_server_addrs=192.168.4.172:45500,192.168.4.173:45500,192.168.4.174:45500
      - --local_ip=192.168.4.173
      - --ws_ip=192.168.4.173
      - --port=44500
      - --ws_http_port=12000
      - --data_path=/data/storage
      - --log_dir=/logs
      - --v=0
      - --minloglevel=0
    deploy:
      replicas: 1
      restart_policy:
        condition: on-failure
      placement:
        constraints:
          - node.hostname == node173
    depends_on:
      - metad0
      - metad1
      - metad2
    healthcheck:
      test: ["CMD", "curl", "-f", "http://192.168.4.173:12000/status"]
      interval: 30s
      timeout: 10s
      retries: 3
      start_period: 20s
    ports:
      - target: 12000
        published: 12000
        protocol: tcp
        mode: host
      - target: 12002
        published: 12004
        protocol: tcp
        mode: host
    volumes:
      - /home/gdelt/nebula/data/storaged1:/data/storage
      - /home/gdelt/nebula/logs/storaged1:/logs
    networks:
      - nebula-net

  storaged2:
    container_name: nebula-storaged2
    image: vesoft/nebula-storaged:v2-nightly
    env_file:
      - /home/gdelt/nebula/nebula.env
    command:
      - --meta_server_addrs=192.168.4.172:45500,192.168.4.173:45500,192.168.4.174:45500
      - --local_ip=192.168.4.174
      - --ws_ip=192.168.4.174
      - --port=44500
      - --ws_http_port=12000
      - --data_path=/data/storage
      - --log_dir=/logs
      - --v=0
      - --minloglevel=0
    deploy:
      replicas: 1
      restart_policy:
        condition: on-failure
      placement:
        constraints:
          - node.hostname == node174
    depends_on:
      - metad0
      - metad1
      - metad2
    healthcheck:
      test: ["CMD", "curl", "-f", "http://192.168.4.174:12000/status"]
      interval: 30s
      timeout: 10s
      retries: 3
      start_period: 20s
    ports:
      - target: 12000
        published: 12000
        protocol: tcp
        mode: host
      - target: 12002
        published: 12006
        protocol: tcp
        mode: host
    volumes:
      - /home/gdelt/nebula/data/storaged2:/data/storage
      - /home/gdelt/nebula/logs/storaged2:/logs
    networks:
      - nebula-net

  graphd0:
    container_name: nebula-graphd0
    image: vesoft/nebula-graphd:v2-nightly
    env_file:
      - /home/gdelt/nebula/nebula.env
    command:
      - --meta_server_addrs=192.168.4.172:45500,192.168.4.173:45500,192.168.4.174:45500
      - --port=3699
      - --ws_http_port=13000
      - --ws_ip=192.168.4.172
      - --log_dir=/logs
      - --v=0
      - --minloglevel=0
    deploy:
      replicas: 1
      restart_policy:
        condition: on-failure
      placement:
        constraints:
          - node.hostname == node172
    depends_on:
      - metad0
      - metad1
      - metad2
    healthcheck:
      test: ["CMD", "curl", "-f", "http://192.168.4.172:13000/status"]
      interval: 30s
      timeout: 10s
      retries: 3
      start_period: 20s
    ports:
      - target: 3699
        published: 3699
        protocol: tcp
        mode: host
      - target: 13000
        published: 13000
        protocol: tcp
        mode: host
      - target: 13002
        published: 13002
        protocol: tcp
        mode: host
    volumes:
      - /home/gdelt/nebula/logs/graphd0:/logs
      - /home/gdelt/nebula/config:/usr/local/nebula/etc
    networks:
      - nebula-net

  graphd1:
    container_name: nebula-graphd1
    image: vesoft/nebula-graphd:v2-nightly
    env_file:
      - /home/gdelt/nebula/nebula.env
    command:
      - --meta_server_addrs=192.168.4.172:45500,192.168.4.173:45500,192.168.4.174:45500
      - --port=3699
      - --ws_http_port=13000
      - --ws_ip=192.168.4.173
      - --log_dir=/logs
      - --v=0
      - --minloglevel=0
    deploy:
      replicas: 1
      restart_policy:
        condition: on-failure
      placement:
        constraints:
          - node.hostname == node173
    depends_on:
      - metad0
      - metad1
      - metad2
    healthcheck:
      test: ["CMD", "curl", "-f", "http://192.168.4.173:13000/status"]
      interval: 30s
      timeout: 10s
      retries: 3
      start_period: 20s
    ports:
      - target: 3699
        published: 3699
        protocol: tcp
        mode: host
      - target: 13000
        published: 13000
        protocol: tcp
        mode: host
      - target: 13002
        published: 13002
        protocol: tcp
        mode: host
    volumes:
      - /home/gdelt/nebula/logs/graphd1:/logs
      - /home/gdelt/nebula/config:/usr/local/nebula/etc
    networks:
      - nebula-net

  graphd2:
    container_name: nebula-graphd2
    image: vesoft/nebula-graphd:v2-nightly
    env_file:
      - /home/gdelt/nebula/nebula.env
    command:
      - --meta_server_addrs=192.168.4.172:45500,192.168.4.173:45500,192.168.4.174:45500
      - --port=3699
      - --ws_http_port=13000
      - --ws_ip=192.168.4.174
      - --log_dir=/logs
      - --v=0
      - --minloglevel=0
    deploy:
      replicas: 1
      restart_policy:
        condition: on-failure
      placement:
        constraints:
          - node.hostname == node174
    depends_on:
      - metad0
      - metad1
      - metad2
    healthcheck:
      test: ["CMD", "curl", "-f", "http://192.168.4.174:13000/status"]
      interval: 30s
      timeout: 10s
      retries: 3
      start_period: 20s
    ports:
      - target: 3699
        published: 3699
        protocol: tcp
        mode: host
      - target: 13000
        published: 13000
        protocol: tcp
        mode: host
      - target: 13002
        published: 13002
        protocol: tcp
        mode: host
    volumes:
      - /home/gdelt/nebula/logs/graphd2:/logs
      - /home/gdelt/nebula/config:/usr/local/nebula/etc
    networks:
      - nebula-net

networks:
  nebula-net:
    external: true
    attachable: true
    name: host

浙ICP备20010487号