Hi,

after updating from HAProxy 2.4.26 to 2.4.27, I noticed some strange behavior change when issuing commands via the socket. I have a script that calls the "prepare map" command and looks at the output to determine the new map version number. This script failed after upgrading to 2.4.27. Going back to 2.4.26, everything is fine.

The command used in the script is:

/usr/bin/socat $SOCKET stdio <<< "prepare map ${MAPFILE}"

Previously, the output of the socket command would look like this:

```
New version created: 1

```

Note the empty line after the actual output.

With version 2.4.27, more often than not, the output from the socket command looks like this:

```
New version created: 1
<some random garbage from memory>
```

The random garbage output does not appear every time I try this. When it appears, it looks like an excerpt from an HTTP request that is being processed at the same time, so it is different every time I run the socket command. Sometimes, it's just an empty line, like it used to be with version 2.4.26.

I did not look further to check if this happens with other socket commands as well. So I cannot say which socket commands exhibit this behavior, only that "prepare map" does. My question really is if I'm the only one seeing this or if it affects others as well.

The other version I tried, 2.8.10, did not show this error when issuing the "prepare map" command multiple times. So for me, it's just version 2.4.27 that does not work as expected.

In the haproxy.cfg file, the socket definition looks like this:

```
stats socket /var/lib/haproxy/stats mode 600 expose-fd listeners level admin
```

Any ideas on this?
Thanks,
Jens

Attachment: smime.p7s
Description: Kryptografische S/MIME-Signatur

Reply via email to