One-deploy ansible playbook fails to find leader

Please, describe the problem here and provide additional information below (if applicable) …

I am trying to test a opennebula cluster using: arch_ha · OpenNebula/one-deploy Wiki · GitHub and it doesnt seem to find the “leader”.


Versions of the related components and OS (frontend, hypervisors, VMs):

Debian 11

Opennebula 6.6

Steps to reproduce:

I have setup a three frontend cluster:

  1. nebula-cluster-1
  2. nebula-cluster-2
  3. nebula-cluster-3

I also have NFS server

  1. nebula-storage-1

This is my config:

---
all:
  vars:
    ansible_user: root
    ensure_keys_for: [root]
    one_version: '6.6'
    one_pass: testpassword
    one_vip: 192.168.76.253
    one_vip_cidr: 24
    one_vip_if: eth0
    ds:
      mode: shared
      config:
        mounts:
          - type: system
            path: /mnt/nebula_datastore/system
          - type: image
            path: /mnt/nebula_datastore/image
          - type: files
            path: /mnt/nebula_datastore/files
    vn:
      admin_net:
        managed: true
        template:
          VN_MAD: bridge
          PHYDEV: eth0
          BRIDGE: br0
          AR:
            TYPE: IP4
            IP: 192.168.78.100
            SIZE: 48
          NETWORK_ADDRESS: 192.168.78.100
          NETWORK_MASK: 255.255.255.0
          GATEWAY: 192.168.78.254
          DNS: 1.1.1.1
frontend:
  hosts:
    nebula-cluster-1: { ansible_host: 192.168.76.51 }
    nebula-cluster-2: { ansible_host: 192.168.76.52 }
    nebula-cluster-3: { ansible_host: 192.168.76.59 }
node:
  hosts: {}

Current results:

When running the playbook using: make I=inventory/nebula-test.yml

I get these result

fatal: [nebula-cluster-1]: FAILED! => 
  msg: |-
    The task includes an option with an undefined variable. The error was: {{ (_peers | selectattr('STATE', '==', '3') | first).NAME }}: No first item, sequence was empty.. No first item, sequence was empty.. {{ (_peers | selectattr('STATE', '==', '3') | first).NAME }}: No first item, sequence was empty.. No first item, sequence was empty.
  
    The error appears to be in '/home/REDACTD/one-deploy/ansible_collections/opennebula/deploy/roles/opennebula/server/tasks/ha.yml': line 10, column 3, but may
    be elsewhere in the file depending on the exact syntax problem.
  
    The offending line appears to be:
  
  
    - name: Detect or select a Leader
      ^ here

Expected results:

Things to work?


Any suggestions?

I tried running the playbook again today. And now it worked. Maybe while running the playbook data was changed and the new state was not present while the playbook was running?