Comment 1 for bug 1669044

Revision history for this message
Jorge Niedbalski (niedbalski) wrote : Re: haproxy ceilometer backends missing when using two VIPS

Hello,

I can confirm that this bug is reproducible. I configured a mitaka cloud with
the latest stable release of the charms.

I configured 3 units of ceilometer relating it to hacluster, with the following settings:

juju set ceilometer vip="10.5.0.200 10.7.0.190"

juju set ceilometer os-internal-network="10.5.0.0/16"
juju set ceilometer os-public-network="10.7.0.0/24"

The resulting haproxy configuration lacks on the backend for the configured os-public-network:

root@juju-niedbalski-xenial-machine-23:/home/ubuntu# more /etc/haproxy/haproxy.cfg
global
    log 127.0.0.1 local0
    log 127.0.0.1 local1 notice
    maxconn 20000
    user haproxy
    group haproxy
    spread-checks 0

defaults
    log global
    mode tcp
    option tcplog
    option dontlognull
    retries 3
    timeout queue 5000
    timeout connect 5000
    timeout client 30000
    timeout server 30000

listen stats
    bind 127.0.0.1:8888
    mode http
    stats enable
    stats hide-version
    stats realm Haproxy\ Statistics
    stats uri /
    stats auth admin:djT4pZm9L5WNPzTbZq6ddz5fVdz4Z2jj

frontend tcp-in_ceilometer_api
    bind *:8777
    acl net_10.7.0.100 dst 10.7.0.100/255.255.255.0
    use_backend ceilometer_api_10.7.0.100 if net_10.7.0.100
    acl net_10.5.0.96 dst 10.5.0.96/255.255.0.0
    use_backend ceilometer_api_10.5.0.96 if net_10.5.0.96
    default_backend ceilometer_api_10.5.0.96

backend ceilometer_api_10.7.0.100
    balance leastconn
    server ceilometer-1 10.7.0.100:8767 check

backend ceilometer_api_10.5.0.96
    balance leastconn
    server ceilometer-2 10.5.0.97:8767 check
    server ceilometer-0 10.5.0.73:8767 check
    server ceilometer-1 10.5.0.96:8767 check

The reason seems to be related to the lack of public-address on the cluster relation:

ubuntu@niedbalski-xenial-bastion:~/openstack-charm-testing$ juju run --unit ceilometer/1 "relation-get -r cluster:0 - ceilometer/0"
private-address: 10.5.0.73
ubuntu@niedbalski-xenial-bastion:~/openstack-charm-testing$ juju run --unit ceilometer/1 "relation-get -r cluster:0 - ceilometer/1"
private-address: 10.5.0.96
ubuntu@niedbalski-xenial-bastion:~/openstack-charm-testing$ juju run --unit ceilometer/1 "relation-get -r cluster:0 - ceilometer/2"
private-address: 10.5.0.97