TIP: Click on subject to list as thread! ANSI
echo: synchronet
to: Digital Man
from: deon
date: 2021-03-14 22:34:00
subject: HAPROXY on Windows

Hey DM,

I've been using the haproxy on SBBS/Linux no problem at all. In my haproxy setup, I am using "check intr 60s" which has haproxy opening a TCP session (to check it is still there) and sending a check packet. My haproxy patch that I gave you consumes that check packet as well and closes the session. (If you have Debugging enabled it writes a "We are alive" message to the log.)

I've just spun up a SBBS on Windows (from the zip files on your website  a few days ago), and while haproxy is working OK - the check is failing.

In the log, I see "Working out client address ..." (line 375 of xpdev/multisock.c), but then a failed to read socket, followed by "looking for version - failed []". (line 383).

It seems the read_socket_line() is failing (381).

So I'm not sure why haproxy is working when a user is logging in, but failing for the haproxy check. (And if I reconfig my haproxy to point to my linux machine - it works, but that is a build from 8 weeks ago in case that helps.)

Here is an extract from the log on Windows:
  3/14  10:13:37p  1056 Working out client address from HAProxy PROTO
  3/14  10:13:37p  1056 multisock read_socket() - failed to read from socket. Got [-1] with error [An existing connection was forcibly closed by the remote host.]
  3/14  10:13:37p  1056 * HAPROXY looking for version - failed []
 
And here is the log on linux:

Mar 14 22:02:46 c-8-2 synchronet[1297558]: term 0012 Working out client address from HAProxy PROTO
Mar 14 22:02:46 c-8-2 synchronet[1297558]: term 0012 * HAPROXY looking for version - 1st 2 bytes received [0d0a] of (2)
Mar 14 22:02:46 c-8-2 synchronet[1297558]: term 0012 * HAPROXY PROTO v2
Mar 14 22:02:46 c-8-2 synchronet[1297558]: term 0012 * HAPROXY Version [2]
Mar 14 22:02:46 c-8-2 synchronet[1297558]: term 0012 * HAPROXY Command [0]
Mar 14 22:02:46 c-8-2 synchronet[1297558]: term 0012 * HAPROXY health check - we are alive!

I would try and debug this, but I dont have a windows dev environment and compiling on windows is out of my skill set anyway.

Do you know why it would be failing? I am happy to give you a haproxy config (or point mine to yours) to give you some debugging data if you wanted to try and debug it. (Although I see it says the remote closed the session - but it works to a linux host... hmm...)

...лоеп

... I shot an arrow into the air, and it stuck.

---
 ю Synchronet ю Alterant | an SBBS in Docker on Pi!
                                                                                      
* Origin: Vertrauen - [vert/cvs/bbs].synchro.net (1:103/705)

SOURCE: echomail via QWK@pharcyde.org

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.