Re: log format different and CAPTURE_LEN settings

2012-08-09 Thread William Lallemand
. Can you try this patch ? -- William Lallemand From 7d40e9f6d3f8f1c5ce09e264226a1e5e369d70a0 Mon Sep 17 00:00:00 2001 From: William Lallemand wlallem...@exceliance.fr Date: Thu, 9 Aug 2012 16:41:35 +0200 Subject: [PATCH] BUG/MINOR: to_log erased with unique-id-format curproxy-to_log was reset

Re: Haproxy not logging captured request headers with custom log format

2012-09-13 Thread William Lallemand
Help will be greatly appreciated. I don't have any problem with your configuration, which version of HAProxy are you using ? -- William Lallemand

Re: Haproxy not logging captured request headers with custom log format

2012-09-14 Thread William Lallemand
(-dev12) some bugs were fixed concerning log-format. -- William Lallemand

Re: http compression with haproxy possible

2012-09-20 Thread William Lallemand
Paul -- William Lallemand

Re: Tilde in haproxy 1.5 log

2013-01-09 Thread William Lallemand
in the log is %ft which add a ~ in SSL. You can use %f, it's the frontend without ~. http://cbonte.github.com/haproxy-dconv/configuration-1.5.html#8.2.4 -- William Lallemand

Re: haproxy duplicate http_request_counter values (BUG)

2013-08-28 Thread William Lallemand
implemented something more relevant, the unique-id is now generated when a request failed. -- William Lallemand From 6c2adb543c54df657e37836fc484a7f4e97ef7e1 Mon Sep 17 00:00:00 2001 From: William Lallemand wlallem...@exceliance.fr Date: Wed, 28 Aug 2013 15:44:19 +0200 Subject: [PATCH] BUG/MEDIUM

Re: junk at end of syslog packets in 1.5dev19

2013-08-29 Thread William Lallemand
: most of the times, the syslog msg ends with \n\0\0, other times with \n\n\0 or even \n\n. I've tracked this down to: Hello, I can't reproduce the bug, how did you compile HAProxy? What is your configuration file? Thanks, -- William Lallemand

Re: junk at end of syslog packets in 1.5dev19

2013-08-30 Thread William Lallemand
of digits in the facility. Here's a patch with the real size to send :) -- William Lallemand From fcf527a2c629b696e8e2fa2993feb5be90b9ef04 Mon Sep 17 00:00:00 2001 From: William Lallemand wlallem...@exceliance.fr Date: Fri, 30 Aug 2013 14:17:46 +0200 Subject: [PATCH] BUG/MINOR: log: junk

Re: Log format with odd number of quotes. Bug or conf error?

2014-03-11 Thread William Lallemand
from the logs when empty? And is there a way to force a or - sign when they are empty, to play nice with log parsers? Thanks, Julien It's a bug, indeed, and thierry's patch is the right way to fix it. -- William Lallemand

Re: Compile ZLIB in OpenBSD 5.4

2014-04-04 Thread William Lallemand
an operator in 'else' (Makefile:206) *** Parse error: Missing dependency operator (Makefile:207) *** Parse error: Need an operator in 'else' (Makefile:213) [...] You should install and use GNU Make, not the BSD one. -- William Lallemand

Re: Complete rewrite of HAProxy in Lua

2015-04-01 Thread William Lallemand
sense (anyone ever dreamed of having haproxy in their watches ?). That's good news, we'll finally get ride of these filthy pointers! -- William Lallemand

'set-dst' and 'set-dst-port' tcp/http actions

2016-05-31 Thread William Lallemand
Hello, Here a set of patches implementing http/tcp set-{dst,src}[-port]. The feature can be useful to connect to a IP/port which is defined in a map. Regards, -- William Lallemand >From 4f44c85bd02830d690539b269a4669b6bd251e44 Mon Sep 17 00:00:00 2001 From: William Lallemand <wlallem..

Re: 'set-dst' and 'set-dst-port' tcp/http actions

2016-06-01 Thread William Lallemand
On Tue, May 31, 2016 at 05:28:13PM -0700, Derek Brown wrote: > I'll give them a try. Are they to be applied to the latest 1.7-dev branch? > That's right. -- William Lallemand

Re: dynamically choosing back-end port

2016-05-13 Thread William Lallemand
Hi- > > I'm wondering if you need any additional information, or if I can provide > any clarification, to get a response to my query. > > Thanks, in advance > Derek > -- William Lallemand

Re: server ports - server state file

2017-08-03 Thread William Lallemand
erged. thanks Fred! > Willy > Thanks Fred, that will be really useful! -- William Lallemand

[ANNOUNCE] haproxy-1.7.8

2017-07-07 Thread William Lallemand
nheritance. Jarno Huuskonen (1): DOC: fix references to the section about time format. Willy Tarreau (1): BUG/MINOR: http: properly handle all 1xx informational responses -- William Lallemand

[PATCH v1 RFC 1/5] MEDIUM: mworkers: replace systemd mode by master workers mode

2017-04-26 Thread William Lallemand
This commit remove the -Ds systemd mode in HAProxy in order to replace it by a more generic master workers system. It aims to replace entirely the systemd wrapper in the near future. The master workers mode implements a new way of managing HAProxy processes. The master is in charge of parsing the

[PATCH v1 RFC 4/5] MEDIUM: mworkers: don't refork on daemon mode

2017-04-26 Thread William Lallemand
The master won't change PID anymore in master workers + daemon mode. --- src/haproxy.c | 10 -- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/src/haproxy.c b/src/haproxy.c index 5e3028d..e0b6462 100644 --- a/src/haproxy.c +++ b/src/haproxy.c @@ -157,6 +157,8 @@ struct

RFC: Master Workers model

2017-04-26 Thread William Lallemand
This is a work in progress set of patches. The current systemd model works this way: - systemd-wrapper ` haproxy master ` haproxy child ` haproxy child ` haproxy child The master workers model will allow you to have the same architecture, but without the systemd wrapper at the

[PATCH v1 RFC 5/5] MEDIUM: mworkers: wait mode on reload failure

2017-04-26 Thread William Lallemand
In Master Workers mode, when the reloading of the configuration fail, the process is exiting leaving the children without their father. To handle this, we register an exit function with atexit(3), which is reexecuting the binary in a special mode. This particular mode of HAProxy don't reload the

[PATCH v1 RFC 3/5] MEDIUM: mworkers: old PIDs awereness

2017-04-26 Thread William Lallemand
The master process is now able to manage old processes when they didn't quit on a reload. The master won't exit if every current processes has left but there are still old process. There is now a notification message when a child exits, either an old or a current process. When every workers have

[PATCH v1 RFC 2/5] MEDIUM: mworkers: reload processes on SIGUSR2

2017-04-26 Thread William Lallemand
This behavior allows to reload HAProxy using the master works mode. It's inherited from the systemd wrapper, when the SIGUSR2 signal is received, the master process will reexecute itself with the -sf flag followed by the PIDs of the children. --- src/haproxy.c | 135

Re: graceful shutdown maximum time

2017-08-18 Thread William Lallemand
ob that kills old haproxy > processes on a delay. Would be nice if there were a better option > though. > > Thanks for any suggestion. > > Justin > The "hard-stop-after" keyword do what you want: https://cbonte.github.io/haproxy-dconv/1.7/configuration.html#hard-stop-after -- William Lallemand

[ANNOUNCE] haproxy-1.7.9

2017-08-18 Thread William Lallemand
: always detach the tcp/http tasks before freeing them ben51degrees (1): DOC: Updated 51Degrees git URL to point to a stable version. -- William Lallemand

Re: master-worker and seamless reload (bug)

2017-06-19 Thread William Lallemand
and that's useful in your usecase, if your socket path changed in the configuration file. I think that's just a matter of documentation, maybe I can write a longer paragraph in the management.txt doc explaining how to upgrade for the legacy mode, and what changed between this one and the master worker. -- William Lallemand

Re: 1.7.6 redirect regression (commit 73d071ecc84e0f26ebe1b9576fffc1ed0357ef32)

2017-06-21 Thread William Lallemand
, patch fixes the problem (with test config (I'll try to > test with prod. config later)). > > -Jarno > Thanks for tests, I will backport it in the 1.7 branch. -- William Lallemand

Re: master-worker and seamless reload (bug)

2017-06-20 Thread William Lallemand
om it. I add a warning about that. I fixed the few issues you had in the attached patches. Willy, could you merge them? thanks -- William Lallemand >From 9927f4a1e864638e16dcb3c61de23bcc8f256a91 Mon Sep 17 00:00:00 2001 From: William Lallemand <wlallem...@haproxy.com> Date: Mon, 19 Jun 2017

Re: LoadBalance whole subnet

2017-06-20 Thread William Lallemand
copy to his mail which lead to this. Please don't continue this thread on the mailing list, thanks. -- William Lallemand

Re: LoadBalance whole subnet

2017-06-21 Thread William Lallemand
anks. > > > Well, I assume I understand you. > To clarify, I think I wasn't clear enough. I meant it's not necessary to continue the thread with Anamarija and contact@ on the mailing list :-) -- William Lallemand

Re: haproxy doesn't restart after segfault on systemd

2017-05-19 Thread William Lallemand
t know if that's a good idea. And you don't want your stats to disappear without asking a reload yourself. > But in any case, I think we need some way of handling this so that site > interruption is minimal. > > -Patrick -- William Lallemand

Re: [RFC][PATCHES] seamless reload

2017-05-26 Thread William Lallemand
listeners" stats socket option and remove the "no-unused-socket" global option. It behaves exactly has Willy explain above minus the master process :-) ps: Master Worker patches are coming soon! -- William Lallemand >From 5567d977f722e862c6ba56d65118e094ac28735c Mon Sep 17 00:

Re: haproxy doesn't restart after segfault on systemd

2017-05-19 Thread William Lallemand
Hi again, On Fri, May 19, 2017 at 11:45:18AM +0200, William Lallemand wrote: > Hi, > > On Thu, May 18, 2017 at 05:25:26PM -0400, Patrick Hemmer wrote: > > So we had an incident today where haproxy segfaulted and our site went > > down. Unfortunately we did not capture a c

[PATCH 7/9] DOC: add documentation for the master-worker mode

2017-05-29 Thread William Lallemand
--- doc/configuration.txt | 16 doc/management.txt| 15 +-- 2 files changed, 29 insertions(+), 2 deletions(-) diff --git a/doc/configuration.txt b/doc/configuration.txt index ad7d3a8..5fa49d3 100644 --- a/doc/configuration.txt +++ b/doc/configuration.txt @@

[PATCH 2/9] MEDIUM: mworker: handle reload and signals

2017-05-29 Thread William Lallemand
The master-worker will reload itself on SIGUSR2/SIGHUP It's inherited from the systemd wrapper, when the SIGUSR2 signal is received, the master process will reexecute itself with the -sf flag followed by the PIDs of the children. In the systemd wrapper, the children were using a pipe to notify

[PATCH 9/9] MAJOR: systemd-wrapper: get rid of the wrapper

2017-05-29 Thread William Lallemand
The master worker mode obsoletes the systemd-wrapper, to ensure that nobody uses it anymore, the code has been removed. --- Makefile | 18 +-- contrib/systemd/haproxy.service.in | 2 +- src/haproxy-systemd-wrapper.c | 319 - 3

[PATCH 4/9] MEDIUM: mworker: try to guess the next stats socket to use with -x

2017-05-29 Thread William Lallemand
In master worker mode, you can't specify the stats socket where you get your listeners FDs on a reload, because the command line of the re-exec is launched by the master. To solve the problem, when -x is found on the command line, its parameter is rewritten on a reexec with the first stats socket

[PATCH 1/9] MEDIUM: mworker: replace systemd mode by master worker mode

2017-05-29 Thread William Lallemand
This commit remove the -Ds systemd mode in HAProxy in order to replace it by a more generic master worker system. It aims to replace entirely the systemd wrapper in the near future. The master worker mode implements a new way of managing HAProxy processes. The master is in charge of parsing the

[PATCH 8/9] MEDIUM: systemd: Type=forking in unit file

2017-05-29 Thread William Lallemand
Adding Type=forking in the unit file ensure better monitoring from systemd. During a systemctl start the tool is able to return an error if it didn't work with this option. --- contrib/systemd/haproxy.service.in | 1 + 1 file changed, 1 insertion(+) diff --git

[PATCH 3/9] MEDIUM: mworker: wait mode on reload failure

2017-05-29 Thread William Lallemand
In Master Worker mode, when the reloading of the configuration fail, the process is exiting leaving the children without their father. To handle this, we register an exit function with atexit(3), which is reexecuting the binary in a special mode. This particular mode of HAProxy don't reload the

[PATCH 5/9] MEDIUM: mworker: exit-on-failure option

2017-05-29 Thread William Lallemand
This option exits every workers when one of the current workers die. It allows you to monitor the master process in order to relaunch everything on a failure. For example it can be used with systemd and Restart=on-failure in a spec file. --- include/types/global.h | 1 + src/cfgparse.c

[PATCH 6/9] MEDIUM: mworker: workers exit when the master leaves

2017-05-29 Thread William Lallemand
This patch ensure that the children will exit when the master quits, even if the master didn't send any signal. The master and the workers are connected through a pipe, when the pipe closes the children leave. --- src/haproxy.c | 55 +++ 1 file

Replace the systemd-wrapper by the master worker mode

2017-05-29 Thread William Lallemand
The master worker mode replaces the systemd wrapper, it does not need a separated binary anymore, everything is builtin. This mode will launch a "master" which will monitor the "workers". Using this mode, you can reload HAProxy directly by sending a SIGUSR2 signal to the master. The master-worker

Re: [PATCH 6/9] MEDIUM: mworker: workers exit when the master leaves

2017-05-30 Thread William Lallemand
Will do. > Otherwise the series looks quite good, it would be nice to get some > feedback especially from systemd hostages^Wusers (my comments above > will not affect their experience unless they're really unlucky). > > Thanks! > Willy > I'll send you another batch with the fixes, and maybe some cleanup. In the meanwhile people can still try them. -- William Lallemand

Re: Download site horrendously slow

2017-05-31 Thread William Lallemand
tuate between 1 and 2 kB/s. -- William Lallemand

[PATCH v3 5/9] MEDIUM: mworker: exit-on-failure option

2017-06-01 Thread William Lallemand
This option exits every workers when one of the current workers die. It allows you to monitor the master process in order to relaunch everything on a failure. For example it can be used with systemd and Restart=on-failure in a spec file. --- include/types/global.h | 1 + src/cfgparse.c

[PATCH v3 8/9] MEDIUM: systemd: Type=forking in unit file

2017-06-01 Thread William Lallemand
Adding Type=forking in the unit file ensure better monitoring from systemd. During a systemctl start the tool is able to return an error if it didn't work with this option. --- contrib/systemd/haproxy.service.in | 1 + 1 file changed, 1 insertion(+) diff --git

[PATCH v3 4/9] MEDIUM: mworker: try to guess the next stats socket to use with -x

2017-06-01 Thread William Lallemand
In master worker mode, you can't specify the stats socket where you get your listeners FDs on a reload, because the command line of the re-exec is launched by the master. To solve the problem, when -x is found on the command line, its parameter is rewritten on a reexec with the first stats socket

[PATCH v3 1/9] MEDIUM: mworker: replace systemd mode by master worker mode

2017-06-01 Thread William Lallemand
This commit remove the -Ds systemd mode in HAProxy in order to replace it by a more generic master worker system. It aims to replace entirely the systemd wrapper in the near future. The master worker mode implements a new way of managing HAProxy processes. The master is in charge of parsing the

[PATCH v3 9/9] MAJOR: systemd-wrapper: get rid of the wrapper

2017-06-01 Thread William Lallemand
The master worker mode obsoletes the systemd-wrapper, to ensure that nobody uses it anymore, the code has been removed. --- Makefile | 18 +-- contrib/systemd/haproxy.service.in | 2 +- src/haproxy-systemd-wrapper.c | 319 - 3

[PATCH v3 2/9] MEDIUM: mworker: handle reload and signals

2017-06-01 Thread William Lallemand
The master-worker will reload itself on SIGUSR2/SIGHUP It's inherited from the systemd wrapper, when the SIGUSR2 signal is received, the master process will reexecute itself with the -sf flag followed by the PIDs of the children. In the systemd wrapper, the children were using a pipe to notify

[PATCH v3 3/9] MEDIUM: mworker: wait mode on reload failure

2017-06-01 Thread William Lallemand
In Master Worker mode, when the reloading of the configuration fail, the process is exiting leaving the children without their father. To handle this, we register an exit function with atexit(3), which is reexecuting the binary in a special mode. This particular mode of HAProxy don't reload the

Re: Replace the systemd-wrapper by the master worker mode

2017-06-01 Thread William Lallemand
Those minor problems have been corrected in this new patchset. Please merge them if that's ok for you.

[PATCH v3 7/9] DOC: add documentation for the master-worker mode

2017-06-01 Thread William Lallemand
--- doc/configuration.txt | 16 doc/management.txt| 15 +-- 2 files changed, 29 insertions(+), 2 deletions(-) diff --git a/doc/configuration.txt b/doc/configuration.txt index ad7d3a8..5fa49d3 100644 --- a/doc/configuration.txt +++ b/doc/configuration.txt @@

[PATCH v3 6/9] MEDIUM: mworker: workers exit when the master leaves

2017-06-01 Thread William Lallemand
This patch ensure that the children will exit when the master quits, even if the master didn't send any signal. The master and the workers are connected through a pipe, when the pipe closes the children leave. --- src/haproxy.c | 60 +++ 1

[PATCH] BUG/MEDIUM: build without openssl broken

2017-06-08 Thread William Lallemand
The commit 872f9c213 ("MEDIUM: ssl: add basic support for OpenSSL crypto engine") broke the build without openssl support. The ssl_free_dh() function is not defined when USE_OPENSSL is not defined and leads to a compilation failure. --- src/haproxy.c | 2 +- 1 file changed, 1 insertion(+), 1

Re: exit error regression on haproxy1.8dev

2017-06-08 Thread William Lallemand
On Thu, Jun 08, 2017 at 01:49:15PM +0200, William Lallemand wrote: > > You are right about the regression, however this part of the code should be > called in daemon mode only, the regression was elsewhere :) > > Fix attached. > Willy, could you apply this one? Thanks, -- William Lallemand

Re: exit error regression on haproxy1.8dev

2017-06-08 Thread William Lallemand
; > bad: > >> haproxy -f test.cfg > >> echo $? > > 1 > > > > With bunch of modified code, i am a little lost to track the bug. > > > > Manu > > > > > You are right about the regression, however this part of the code should be called in

[PATCH] BUG/MINOR: warning: ‘need_resend’ may be used uninitialized

2017-06-08 Thread William Lallemand
The commit 201c07f68 ("MAJOR/REORG: dns: DNS resolution task and requester queues") introduces a warning during compilation: src/dns.c: In function ‘dns_resolve_recv’: src/dns.c:487:6: warning: ‘need_resend’ may be used uninitialized in this function [-Wmaybe-uninitialized] if (need_resend) {

Re: exit error regression on haproxy1.8dev

2017-06-07 Thread William Lallemand
; > bad: > >> haproxy -f test.cfg > >> echo $? > > 1 > > > > With bunch of modified code, i am a little lost to track the bug. > > > > Manu > > > > > You are right about the regression, however this part of the code should be called in

[ANNOUNCE] haproxy-1.7.6

2017-06-16 Thread William Lallemand
gent checks BUG/MAJOR: http: call manage_client_side_cookies() before erasing the buffer BUG/MEDIUM: unix: never unlink a unix socket from the file system scripts: create-release pass -n to tail SCRIPTS: create-release: enforce GIT_COMMITTER_{NAME|EMAIL} validity -- William Lallemand

Re: master-worker and seamless reload (bug)

2017-06-16 Thread William Lallemand
process adding a -x with what it found in the configuration, you don't have to start it with -x at startup. Regarding the PID, I think you have this behavior because you started the daemon mode with -sf. > one last: > # haproxy -x > Segmentation fault I'll fix that. > > ++ > Manu > Thanks for the tests! -- William Lallemand

Re: Haproxy refuses new connections when doing a reload followed by a restart

2017-10-08 Thread William Lallemand
orked between the reload and the restart. And the list will grow indefinitely with each reload/restart. The master-worker model should fix that kind of issue, because it's aware of all PIDs, old and new. You could try: * To change the KillMode to the default, which should kill -SIGTERM all processes on a stop or restart. But if I remember well, it leads to a bad exit code on the systemd side and display an error. * To reduce the timeout of the SIGTERM with TimeoutStopSec= in your unit file -- William Lallemand

Re: Haproxy refuses new connections when doing a reload followed by a restart

2017-10-12 Thread William Lallemand
ive traffic at this stage. However I'm not sure it's that useful, you can know when a process is ready using the logs, and it will add specific code for systemd and a dependency. Are there really advantages to letting know systemd when a reload is finished or when a process is ready? Cheers, -- William Lallemand

Re: Haproxy refuses new connections when doing a reload followed by a restart

2017-10-12 Thread William Lallemand
1 before starting units with After=haproxy (although HAProxy > is really a "leaf" kind of service). > That's interesting, nobody ever ask for that, but I see a few cases where that can be useful. > Note that the dependency is really thin, and you can always make it a > compile-time option. > > Regards, > Apollon Cheers, -- William Lallemand

Re: [PATCH] Reset a few more counters on "clear counters"

2017-10-18 Thread William Lallemand
at least one report for this in 1.7. > > > > Thanks, > Lukas Sure, it will be backported. -- William Lallemand

Re: [PATCH] BUG/MEDIUM: mworker: Fix re-exec when haproxy is started from PATH

2017-11-15 Thread William Lallemand
Hi Tim, On Tue, Nov 14, 2017 at 08:20:25PM +0100, Tim Düsterhus wrote: > William, > > Am 14.11.2017 um 15:03 schrieb William Lallemand: > > Well, in my opinion the return value does not need to be checked because we > > should never reach the code after the exec, that mean

Re: cache issue : some data skipped in the middle of the content

2017-11-28 Thread William Lallemand
I've not checked yet but I was wondering : is it specific to the cache > filter or can we find the same issue in other ones (compression for example) ? > > Cyril You're absolutely right, we spot this one before but it seems the patch didn't make it to the master

Re: [BUG] haproxy 1.8-last/master-worker/peers

2017-11-28 Thread William Lallemand
m the master-worker code, however that does not explain why the old worker does not quit. -- William Lallemand

Re: [BUG] haproxy 1.8-last/master-worker/peers

2017-11-28 Thread William Lallemand
On Tue, Nov 28, 2017 at 02:56:55PM +0100, William Lallemand wrote: > On Tue, Nov 28, 2017 at 12:22:04PM +0100, Emmanuel Hocdet wrote: > > ok, i should have something strange because it’s easy to reproduce in my > > environnement. > > > > When i look lsof i see on mas

Re: [docs] about master-worker mode

2017-11-27 Thread William Lallemand
Couldn’t use > this on the command line. > That's an error, -W doesn't take a process argument, it's only a flag. The master-worker only simplify the reload and the supervision of HAProxy. > ~jm > > [1] http://cbonte.github.io/haproxy-dconv/1.8/configuration.html#3.1-nbproc > [2

Re: [PATCH] BUG/MINOR: Check if master-worker pipe getenv succeeded, also allow pipe fd 0 as valid.

2017-11-28 Thread William Lallemand
worker_pipe); if (ret < 0) { ha_alert("[%s.main()] Cannot create master pipe.\n", argv[0]); exit(1); } This code will guarantee that the whole master-worker quit if there is a problem. -- William Lallemand

Re: [PATCH] BUG/MINOR: when master-worker is in daemon mode, detach from tty

2017-11-28 Thread William Lallemand
in the pipe, we also need to rely on setsid() to do a proper tty detach. This is already done in -D mode without -W, maybe this part of the code should me moved elsewhere, but we have to be careful not to break the daemon mode w/o mworker. -- William Lallemand

Re: [PATCH] BUG/MINOR: Check if master-worker pipe getenv succeeded, also allow pipe fd 0 as valid.

2017-12-02 Thread William Lallemand
+0100, PiBa-NL wrote: > Thanks for the review, new patch attached that basically incorporates > all your comments. > Regards, > PiBa-NL / Pieter > -- William Lallemand

Re: [PATCH] BUG/MEDIUM: mworker: Fix re-exec when haproxy is started from PATH

2017-11-14 Thread William Lallemand
ive signals. I spot two other problems in this code path, I'll fix them shortly. > Replace `execv` with `execvp` to establish the expected > behaviour. Willy, could you please apply this patch? thanks -- William Lallemand

Re: [PATCH v2 1/1] MEDIUM: mworker: Add systemd `Type=notify` support

2017-11-20 Thread William Lallemand
we can integrate the -Ws command in the unit file without changing the behavior of the normal option. Cheers, -- William Lallemand

Re: [PATCH v2 1/1] MEDIUM: mworker: Add systemd `Type=notify` support

2017-11-20 Thread William Lallemand
ait for session to be finished. It will cause the restart to behave like the reload but with a PID change. Cheers, -- William Lallemand

Re: [PATCH v3 1/1] MEDIUM: mworker: Add systemd `Type=notify` support

2017-11-20 Thread William Lallemand
On Mon, Nov 20, 2017 at 03:58:35PM +0100, Tim Düsterhus wrote: > From: Tim Duesterhus <t...@bastelstu.be> > > This patch adds support for `Type=notify` to the systemd unit. Looks good to me, thanks! Willy can you merge it? -- William Lallemand

Re: haproxy-1.8-rc4 - FreeBSD 11.1 - master-worker daemon parent staying alive/process-owner

2017-11-20 Thread William Lallemand
tly a whole new set of master-worker processes seems to be take over.. Well, I supposed that's because you launched a new master-worker with -sf, it's not supposed to be used that way but it should work too if you don't mind having a new PID. > Regards, > PiBa-NL / Pieter > Best Regards, -- William Lallemand

Re: [PATCH v3 1/1] MEDIUM: mworker: Add systemd `Type=notify` support

2017-11-20 Thread William Lallemand
g/software/systemd/man/systemd.service.html#TimeoutStartSec= I suggest we configure it to a greater value per default, it can be set to infinity too, but I don't like the idea. -- William Lallemand

Re: [PATCH v3 1/1] MEDIUM: mworker: Add systemd `Type=notify` support

2017-11-21 Thread William Lallemand
On Tue, Nov 21, 2017 at 11:28:55AM +0100, Willy Tarreau wrote: > On Tue, Nov 21, 2017 at 11:19:41AM +0100, William Lallemand wrote: > > I don't like the idea of the "daemon" keyword being ignored, > > We already do that with -D which ignores "debug" for exampl

Re: [PATCH v3 1/1] MEDIUM: mworker: Add systemd `Type=notify` support

2017-11-21 Thread William Lallemand
On Tue, Nov 21, 2017 at 11:12:45AM +0100, Lukas Tribus wrote: > Hello, > > 2017-11-21 8:39 GMT+01:00 William Lallemand <wlallem...@haproxy.com>: > > That's not it, the hold-off timer is only a consequence of this > problem. I believe the notification does not work in

Re: [PATCH v2 1/1] MEDIUM: mworker: Add systemd `Type=notify` support

2017-11-20 Thread William Lallemand
On Mon, Nov 20, 2017 at 12:55:06PM +0100, Tim Düsterhus wrote: > William, > > Am 20.11.2017 um 12:01 schrieb William Lallemand: > >> The only difference I can see is that haproxy will fail to start for a > >> different reason (use of undefined option, instead of n

Re: [PATCH v2 1/1] MEDIUM: mworker: Add systemd `Type=notify` support

2017-11-20 Thread William Lallemand
On Mon, Nov 20, 2017 at 11:39:53AM +0100, Tim Düsterhus wrote: > William, > > Am 20.11.2017 um 10:59 schrieb William Lallemand: > > I think a good way to activate this feature will be to use it with a -Ws > > command > > line option instead of changing

Re: [PATCH] BUG/MEDIUM: mworker: Fix re-exec when haproxy is started from PATH

2017-11-16 Thread William Lallemand
On Thu, Nov 16, 2017 at 05:30:05PM +0100, Tim Düsterhus wrote: > William, > > Am 15.11.2017 um 21:17 schrieb William Lallemand: > > These problems have been fixed in the master with the following commits: > > > > 75ea0a06b BUG/MEDIUM: mworker: does not close inherited

[PATCH 2/3] MINOR: mworker: allow pidfile in mworker + foreground

2017-11-06 Thread William Lallemand
This patch allows the use of the pidfile in master-worker mode without using the background option. --- src/haproxy.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/haproxy.c b/src/haproxy.c index bbd26b82d..f12e903b2 100644 --- a/src/haproxy.c +++ b/src/haproxy.c @@

some mworker + pidfile patches

2017-11-06 Thread William Lallemand
A few patches which help using the pidfile in master-worker mode.

[PATCH 3/3] MINOR: mworker: write parent pid in the pidfile

2017-11-06 Thread William Lallemand
The first pid in the pidfile is now the parent, it's more convenient for supervising the processus. You can now reload haproxy in master-worker mode with convenient command like: kill -USR2 $(head -1 /tmp/haproxy.pid) --- src/haproxy.c | 7 +++ 1 file changed, 7 insertions(+) diff --git

[PATCH] MINOR: mworker: do not store child pid anymore in the pidfile

2017-11-06 Thread William Lallemand
The parent process supervises itself the children, we don't need to store the children pids anymore in the pidfile in master-worker mode. --- src/haproxy.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/haproxy.c b/src/haproxy.c index bcbbad4a1..4d4bd3b26 100644 ---

Re: [ANNOUNCE] haproxy-1.8-rc1 : the last mile

2017-11-02 Thread William Lallemand
s mentionned > somewhere in the config manual. William was about to write some doc > when I interrupted him to get his code, but he'll certainly get back > to this soon. It will need a configuration filter keyword for the cache, to define the explicit order of the filters. The cache might not work after the compression in the current state of the filter API. -- William Lallemand

Re: Testing master-worker reloads on HAProxy 1.8

2017-12-08 Thread William Lallemand
old processes did not receive the SIGTTOU for an unknown reason, or did not unbind once it received the signal. Maybe you could try to compare what's happening on your solaris-like system and your ubuntu with the -dR option, using strace on linux and truss on solaris. Regards, -- William Lallemand

Re: [PATCH] BUG/MINOR: when master-worker is in daemon mode, detach from tty

2017-12-02 Thread William Lallemand
setsid(); > + } > + > mworker_wait(); > /* should never get there */ > exit(EXIT_FAILURE); Cheers, -- William Lallemand

Re: [PATCH 1/2] DOC: mworker: Update messages referencing exit-on-failure

2017-12-04 Thread William Lallemand
ha_alert("exit-on-failure: killing > every workers with SIGTERM\n"); I prefer to leave this one, because otherwise the user won't understand why it killed the workers, and a grep on "exit-on-failure" in the documentation will find "no-exit-on-failure" so that's not a problem. -- William Lallemand

Re: Testing master-worker reloads on HAProxy 1.8

2017-12-11 Thread William Lallemand
the SIGTTOU > signal from the master (200 times), so the worker must not have been > unbinding. > Okay, so it looks like that the unbinding with SIGTOUT does not work on your OS, but the seamless reload seems to work... According to the code commentary that's a known problem on Solaris, maybe we should add a note in the documentation about it. Regards, -- William Lallemand

Re: Testing master-worker reloads on HAProxy 1.8

2017-12-08 Thread William Lallemand
s post is not correct for the seamless reload (-x + expose-fd), but only for a "classic" reload. During a seamless reload, the new process try to get the FDs of the listeners using the unix socket. Did you try the seamless reload using -x without the master-worker? -- William Lallemand

[PATCH] BUG/MINOR: cli: don't stop cli_gen_usage_msg() when kw->usage == NULL

2018-05-15 Thread William Lallemand
In commit abbf607 ("MEDIUM: cli: Add payload support") some cli keywords without usage message have been added at the beginning of the keywords array. cli_gen_usage_usage_msg() use the kw->usage == NULL to stop generating the usage message for the current keywords array. With those keywords at

Re: remaining process after (seamless) reload

2018-05-24 Thread William Lallemand
last process > > but I sometimes get: "Pid: 28271"(!) which is a > 24 hours old > > process. > > > > Is there something we are doing wrongly? > > After some more testing, I don't have this issue using haproxy v1.8.8 > (rollbacked for > 12 hours). I hope I don't speak too fast. > Hi, I managed to reproduce something similar with the 1.8.8 version. It looks like letting a socat connected to the socket helps. I'm looking into the code to see what's happening. -- William Lallemand

[ANNOUNCE] haproxy-1.8.9

2018-05-18 Thread William Lallemand
BUG/MEDIUM: http: don't always abort transfers on CF_SHUTR BUG/MEDIUM: ssl: properly protect SSL cert generation -- William Lallemand

[PATCH] BUG/MAJOR: map: fix a segfault when using http-request set-map

2018-06-11 Thread William Lallemand
The bug happens with an existing entry, when you try to overwrite the value with wrong data, for example, a string when the type is INT. The code path was not secure and tried to set *err and *merr while err = merr = NULL when performing an http action. Must be backported in 1.6, 1.7, 1.8. ---

Re: [Patch] Lua / Increase error verbosity

2018-06-11 Thread William Lallemand
> > only increases verbosity in case of problem, do you want it to be > > backported to 1.8 as well ? > > > It should great ! > > Thierry Backported to 1.8. -- William Lallemand

Re: remaining process after (seamless) reload

2018-06-08 Thread William Lallemand
On Fri, Jun 08, 2018 at 02:10:44PM +0200, William Dauchy wrote: > On Thu, Jun 07, 2018 at 11:50:45AM +0200, William Lallemand wrote: > > Sorry for the late reply, I manage to reproduce and fix what seams to be > > the bug. > > The signal management was not handled c

  1   2   3   4   5   6   7   >