Por que o Juju não está implementando meu cluster do MongoDB fragmentado?

0

Estou tentando implantar um cluster MongoDB fragmentado no Amazon EC2, usando as instruções no link .

No entanto (e eu tentei isso três vezes), minha unidade mongos sempre falha, com agente-state-info:

hook failed: "mongos-relation-changed"

Aqui está a saída do status do juju:

environment: amazon
machines:
  "0":
    agent-state: started
    agent-version: 1.16.6
    dns-name: ec2-XXX-XXX-XXX-XXX.compute-1.amazonaws.com
    instance-id: i-e36159c2
    instance-state: running
    series: precise
    hardware: arch=amd64 cpu-cores=1 cpu-power=100 mem=1740M root-disk=8192M
  "1":
    agent-state: started
    agent-version: 1.16.6
    dns-name: ec2-XXX-XXX-XXX-XXX.compute-1.amazonaws.com
    instance-id: i-b7645c96
    instance-state: running
    series: precise
    hardware: arch=amd64 cpu-cores=1 cpu-power=100 mem=1740M root-disk=8192M
  "2":
    agent-state: started
    agent-version: 1.16.6
    dns-name: ec2-XXX-XXX-XXX-XXX.compute-1.amazonaws.com
    instance-id: i-d5645cf4
    instance-state: running
    series: precise
    hardware: arch=amd64 cpu-cores=1 cpu-power=100 mem=1740M root-disk=8192M
  "3":
    agent-state: started
    agent-version: 1.16.6
    dns-name: ec2-XXX-XXX-XXX-XXX.compute-1.amazonaws.com
    instance-id: i-98665eb9
    instance-state: running
    series: precise
    hardware: arch=amd64 cpu-cores=1 cpu-power=100 mem=1740M root-disk=8192M
  "4":
    agent-state: started
    agent-version: 1.16.6
    dns-name: ec2-XXX-XXX-XXX-XXX.compute-1.amazonaws.com
    instance-id: i-fa645cdb
    instance-state: running
    series: precise
    hardware: arch=amd64 cpu-cores=1 cpu-power=100 mem=1740M root-disk=8192M
services:
  configsvr:
    charm: cs:precise/mongodb-26
    exposed: false
    relations:
      configsvr:
      - mongos
      replica-set:
      - configsvr
    units:
      configsvr/0:
        agent-state: started
        agent-version: 1.16.6
        machine: "1"
        open-ports:
        - 27017/tcp
        - 27019/tcp
        - 27021/tcp
        - 28017/tcp
        - 28019/tcp
        public-address: ec2-XXX-XXX-XXX-XXX.compute-1.amazonaws.com
  mongos:
    charm: cs:precise/mongodb-26
    exposed: true
    relations:
      mongos:
      - shard1
      - shard2
      mongos-cfg:
      - configsvr
      replica-set:
      - mongos
    units:
      mongos/0:
        agent-state: error
        agent-state-info: 'hook failed: "mongos-relation-changed"'
        agent-version: 1.16.6
        machine: "2"
        open-ports:
        - 27017/tcp
        - 27019/tcp
        - 28017/tcp
        public-address: ec2-XXX-XXX-XXX-XXX.compute-1.amazonaws.com
  shard1:
    charm: cs:precise/mongodb-26
    exposed: true
    relations:
      database:
      - mongos
      replica-set:
      - shard1
    units:
      shard1/0:
        agent-state: started
        agent-version: 1.16.6
        machine: "3"
        open-ports:
        - 27017/tcp
        - 27019/tcp
        - 27021/tcp
        - 28017/tcp
        public-address: ec2-XXX-XXX-XXX-XXX.compute-1.amazonaws.com
  shard2:
    charm: cs:precise/mongodb-26
    exposed: true
    relations:
      database:
      - mongos
      replica-set:
      - shard2
    units:
      shard2/0:
        agent-state: started
        agent-version: 1.16.6
        machine: "4"
        open-ports:
        - 27017/tcp
        - 27019/tcp
        - 27021/tcp
        - 28017/tcp
        public-address: ec2-XXX-XXX-XXX-XXX.compute-1.amazonaws.com

Aqui está a saída de tail /var/log/juju/unit-mongos-0.log on mongos / 0:

2014-03-05 19:59:44 INFO worker.uniter.jujuc server.go:108 running hook tool "juju-log" ["mongos_relation_change: undefined rel_type: None"]
2014-03-05 19:59:44 DEBUG worker.uniter.jujuc server.go:109 hook context id "mongos/0:mongos-cfg-relation-changed:7095643384867257998"; dir "/var/lib/juju/agents/unit-mongos-0/charm"
2014-03-05 19:59:44 INFO juju juju-log.go:66 mongos/0 mongos-cfg:5: mongos_relation_change: undefined rel_type: None
2014-03-05 19:59:45 ERROR juju.worker.uniter uniter.go:350 hook failed: exit status 1
2014-03-05 19:59:45 DEBUG juju.worker.uniter modes.go:423 ModeAbide exiting
2014-03-05 19:59:45 INFO juju.worker.uniter modes.go:421 ModeHookError starting
2014-03-05 19:59:45 DEBUG juju.worker.uniter.filter filter.go:418 want resolved event
2014-03-05 19:59:45 DEBUG juju.worker.uniter.filter filter.go:412 want forced upgrade true
2014-03-05 19:59:45 DEBUG juju.worker.uniter.filter filter.go:523 no new charm event
2014-03-05 20:06:32 DEBUG juju.worker.uniter.filter filter.go:338 got relations change

O que está acontecendo? Como faço para corrigir isso?

Uma solução alternativa é aceitável:)

    
por Dylan McCall 05.03.2014 / 20:21

1 resposta

1

O primeiro começo a depurar uma falha como essa é dar uma olhada nos registros da unidade. Para fazer isso:

juju ssh mongos/0

cd /var/log/juju

Se o erro / solução não for óbvio, sinta-se à vontade para atualizar sua pergunta com os registros da unidade.

    
por hatch 05.03.2014 / 20:57