Similar configuration and HAProxy don't notify when backend is up

Hi community!

haproxy version: 2.3.0
method: haproxy-container from docker hub official image.

I got 2 backends with similar and simple configuration and the fisrt one when container is down / up i got the notify email of checks down/up

But with the second when i try down / up… just receive DOWN notification email… but NOT UP.

the configurations to check is here below.
what i’m missing.???

thanks in advance

#---------------------------------------------------------------------
#       Backend: MediaWiki test
#---------------------------------------------------------------------
backend mediawiki_be_https
  mode http
  balance roundrobin
  option forwardfor
  option httpchk HEAD / HTTP/1.1\r\nHost:\ localhost
  email-alert mailers apsmailer1
  email-alert from alert.mng."$DOCKER_ENGINE_NAME"."$THIS_CONTAINER_NAME"@example.com
  email-alert to alerts.haproxy@example.com
  email-alert myhostname smtp1
  email-alert level info
  cookie SERVERID insert indirect nocache httponly secure
  server mediawiki mediawiki:8080 check inter 5s weight 50 id 1 cookie mediawiki_

#---------------------------------------------------------------------
#       Backend: Vault devel
#---------------------------------------------------------------------
backend vault_be_https
  mode http
  balance roundrobin
  option forwardfor
  option httpchk HEAD / HTTP/1.1\r\nHost:\ localhost
  email-alert mailers apsmailer1
  email-alert from alert.mng."$DOCKER_ENGINE_NAME"."$THIS_CONTAINER_NAME"@example.com
  email-alert to alerts.haproxy@example.com
  email-alert myhostname smtp1
  email-alert level info
  cookie SERVERID insert indirect nocache httponly secure
  server vault vault:8200 check inter 5s weight 50 id 1 cookie vault_

in the site statistic of haproxy I can see the UP backend but never get that notify UP email.

making check from CLI seams ok

curl -Is https://vaultdevel.localhost/v1/sys/health
HTTP/1.1 200 OK

I had a similar problem, the issue was the log type needs to be set to notice.

Global Section

global
log 127.0.0.1 local2
log 127.0.0.1 local2 notice

Defaults Section

defaults
email-alert mailers mta
email-alert level notice
email-alert from myhaproxy@myhaproxy.test
email-alert to myserver@myhaproxy.test

Mailers

mailers mta
mailer smtp1 localhost:25

Hope this helps

Hi, thanks for the tip but not works…
in fact I have many backends and all can send alert down/up except for this last one for vault.

you had similar situation using haproxy in container too?

:frowning:

Sorry for late reply, no we do not run in a container at all, might be something related to that part of it.