RESOLVED-Deploy landscape - no port 80 on haproxy/1

After have deployed Landscape via juju command

$: juju deploy landscape-dense-maas

at the end of all tasks the juju status report that the charm of haproxy has not a port assigned and I can view the gui

while inside the vm and run that

$: systemctl status haproxy.service
● haproxy.service - HAProxy Load Balancer
Loaded: loaded (/lib/systemd/system/haproxy.service; enabled; vendor preset: enabled)
Active: failed (Result: exit-code) since Sun 2020-03-08 23:36:36 UTC; 1min 16s ago
Docs: man:haproxy(1)
file:/usr/share/doc/haproxy/configuration.txt.gz
Process: 30600 ExecStart=/usr/sbin/haproxy -Ws -f $CONFIG -p $PIDFILE $EXTRAOPTS (code=exited, status=143)
Process: 18818 ExecStartPre=/usr/sbin/haproxy -f $CONFIG -c -q $EXTRAOPTS (code=exited, status=1/FAILURE)
Main PID: 30600 (code=exited, status=143)

Mar 08 23:36:36 landscape systemd[1]: haproxy.service: Control process exited, code=exited status=1
Mar 08 23:36:36 landscape systemd[1]: haproxy.service: Failed with result ‘exit-code’.
Mar 08 23:36:36 landscape systemd[1]: Failed to start HAProxy Load Balancer.
Mar 08 23:36:36 landscape systemd[1]: haproxy.service: Service hold-off time over, scheduling restart.
Mar 08 23:36:36 landscape systemd[1]: haproxy.service: Scheduled restart job, restart counter is at 5.
Mar 08 23:36:36 landscape systemd[1]: Stopped HAProxy Load Balancer.
Mar 08 23:36:36 landscape systemd[1]: haproxy.service: Start request repeated too quickly.
Mar 08 23:36:36 landscape systemd[1]: haproxy.service: Failed with result ‘exit-code’.
Mar 08 23:36:36 landscape systemd[1]: Failed to start HAProxy Load Balancer.

A good hint will be to have a look in the “/var/log/juju/*” for hints to what might have happened to your deploy.

This is where you find both machine and unit logs which are more dense than “juju debug-log”.

On my lab before to deploy that via JUJU I’ve deployed Ubuntu 18.04 on my node via MAAS, then have used the following command for adding it to my juju model:

$: juju add-machine ssh:richardsith@10.0.0.25

with juju status

$:juju status
Model      Controller             Cloud/Region        Version  SLA          Timestamp
landscape  maas-cloud-controller  maas-cloud/default  2.7.3    unsupported  23:50:17Z

Machine  State    DNS        Inst id           Series  AZ  Message
0        started  10.0.0.21  manual:10.0.0.21  bionic      Manually provisioned machine

after that via JUJU gui I’ve made:

  • select the bundle
  • added that on my model
  • removed the second machine
  • and added the charms on mine

then I’ve run the deploy of Landscape Dense Maas

here are the log of the files present in /var/log/juju/* for the unit dedicated to haproxy/0

unit-haproxy-0.log
machine-0-lxd-o.log
machine-lock.log

thanks

During a test I’ve used this command:

$: juju deploy landscape-dense-maas --map-machines=existing,0=0

and its status is that:

$:juju status
Model      Controller             Cloud/Region        Version  SLA          Timestamp
landscape  maas-cloud-controller  maas-cloud/default  2.7.3    unsupported  22:52:58Z

App               Version  Status   Scale  Charm             Store       Rev  OS      Notes
haproxy                    unknown      1  haproxy           jujucharms   48  ubuntu  exposed
landscape-server           active       1  landscape-server  jujucharms   35  ubuntu  
postgresql        10.12    active       1  postgresql        jujucharms  199  ubuntu  
rabbitmq-server   3.6.10   active       1  rabbitmq-server   jujucharms   85  ubuntu  
Unit                 Workload  Agent  Machine  Public address  Ports           Message
haproxy/0*           unknown   idle   0/lxd/0  10.0.0.174      80/tcp,443/tcp  
landscape-server/0*  active    idle   0/lxd/1  10.0.0.172                      
postgresql/0*        active    idle   0/lxd/2  10.0.0.171      5432/tcp        Live master (10.12)
rabbitmq-server/0*   active    idle   0/lxd/3  10.0.0.173      5672/tcp        Unit is ready

Machine  State    DNS         Inst id              Series  AZ  Message
0        started  10.0.0.21   manual:10.0.0.21     bionic      Manually provisioned machine
0/lxd/0  started  10.0.0.174  juju-30443c-0-lxd-0  bionic      Container started
0/lxd/1  started  10.0.0.172  juju-30443c-0-lxd-1  bionic      Container started
0/lxd/2  started  10.0.0.171  juju-30443c-0-lxd-2  bionic      Container started
0/lxd/3  started  10.0.0.173  juju-30443c-0-lxd-3  bionic      Container started

and on gui I’ve that:

why???