blob: c046e3c3c13f4ce819fd357ab84842178442d4af [file] [log] [blame]
willy tarreau036e1ce2005-12-17 13:46:33 +01001ChangeLog :
2===========
willy tarreau4302f492005-12-18 01:00:37 +01003
willy tarreau77bc8542005-12-18 01:31:43 +010042005/10/25
5 - building with -DUSE_PCRE should include PCRE headers and not regex.h. At
6 least on Solaris, this caused the libc's regex primitives to be used instead
7 of PCRE, which caused trouble on group references. This is now fixed.
8
willy tarreaub952e1d2005-12-18 01:31:20 +010092005/10/09 : 1.2.7rc (1.1.33rc)
10 - second batch of socklen_t changes.
11 - clean-ups from Cameron Simpson.
12 - because tv_remain() does not know about eternity, using no timeout can
13 make select() spin around a null time-out. Bug reported by Cameron Simpson.
14 - client read timeout was not properly set to eternity initialized after an
15 accept() if it was not set in the config. It remained undetected so long
16 because eternity is 0 and newly allocated pages are zeroed by the system.
17 - do not call get_original_dst() when not in transparent mode.
18 - implemented a workaround for a bug in certain epoll() implementations on
19 linux-2.4 kernels (epoll-lt <= 0.21).
20 - implemented TCP keepalive with new options : tcpka, clitcpka, srvtcpka.
21
willy tarreauc5f73ed2005-12-18 01:26:38 +0100222005/08/07 : 1.2.6
23 - clean-up patch from Alexander Lazic fixes build on Debian 3.1 (socklen_t).
24
252005/07/06 : 1.2.6-pre5 (1.1.32)
willy tarreau0fe39652005-12-18 01:25:24 +010026 - added the number of active sessions (proxy/process) in the logs
27
282005/07/06 : 1.2.6-pre4 (1.1.32-pre4)
willy tarreaub1285d52005-12-18 01:20:14 +010029 - the time-out fix introduced in 1.1.25 caused a corner case where it was
30 possible for a client to keep a connection maintained regardless of the
31 timeout if the server closed the connection during the HEADER phase,
32 while the client ignored the close request while doing nothing in the
33 other direction. This has been fixed now by ensuring that read timeouts
34 are re-armed when switching to any SHUTW state.
35
362005/07/05 : 1.2.6-pre3 (1.1.32-pre3)
37 - enhanced error reporting in the logs. Now the proxy will precisely detect
38 various error conditions related to the system and/or process limits, and
39 generate LOG_EMERG logs indicating that a resource has been exhausted.
40 - logs will contain two new characters for the error cause : 'R' indicates
41 a resource exhausted, and 'I' indicates an internal error, though this
42 one should never happen.
43 - server connection timeouts can now be reported in the logs (sC), as well
44 as connections refused because of maxconn limitations (PC).
45
462005/07/05 : 1.2.6-pre2 (1.1.32-pre2)
47 - new global configuration keyword "ulimit-n" may be used to raise the FD
48 limit to usable values.
49 - a warning is now displayed on startup if the FD limit is lower than the
50 configured maximum number of sockets.
51
522005/07/05 : 1.2.6-pre1 (1.1.32-pre1)
53 - new configuration keyword "monitor-net" makes it possible to be monitored
54 by external devices which connect to the proxy without being logged nor
55 forwarded to any server. Particularly useful on generic TCPv4 relays.
56
willy tarreau5dffb602005-12-18 01:15:23 +0100572005/06/21 : 1.2.5.2
58 - fixed build on PPC where chars are unsigned by default
59
willy tarreau08dedbe2005-12-18 01:13:48 +0100602005/05/02 : 1.2.5.1
61 - dirty hack to fix a bug introduced with epoll : if we close an FD and
62 immediately reassign it to another session through a connect(), the
63 Prev{Read,Write}Events are not updated, which causes trouble detecting
64 changes, thus leading to many timeouts at high loads.
65
willy tarreau64a3cc32005-12-18 01:13:11 +0100662005/04/30 : 1.2.5 (1.1.31)
67 - changed the runtime argument to disable epoll() to '-de'
68 - changed the runtime argument to disable poll() to '-dp'
69 - added global options 'nopoll' and 'noepoll' to do the same at the
70 configuration level.
71 - added a 'linux24e' target to the Makefile for Linux 2.4 systems patched to
72 support epoll().
73 - changed default FD_SETSIZE to 65536 on Solaris (default=1024)
74 - conditionned signals redirection to #ifdef DEBUG_MEMORY
75
willy tarreau1c2ad212005-12-18 01:11:29 +0100762005/04/26 : 1.2.5-pre4
77 - made epoll() support a compile-time option : ENABLE_EPOLL
78 - provided a very little libc replacement for a possibly missing epoll()
79 implementation which can be enabled by -DUSE_MY_EPOLL
80 - implemented the poll() poller, which can be enabled with -DENABLE_POLL.
81 The equivalent runtime argument becomes '-P'. A few tests show that it
82 performs like select() with many fds, but slightly slower (certainly
83 because of the higher amount of memory involved).
84 - separated the 3 polling methods and the tasks scheduler into 4 distinct
85 functions which makes the code a lot more modular.
86 - moved some event tables to private static declarations inside the poller
87 functions.
88 - the poller functions can now initialize themselves, run, and cleanup.
89 - changed the runtime argument to enable epoll() to '-E'.
90 - removed buggy epoll_ctl() code in the client_retnclose() function. This
91 function was never meant to remove anything.
92 - fixed a typo which caused glibc to yell about a double free on exit.
93 - removed error checking after epoll_ctl(DEL) because we can never know if
94 the fd is still active or already closed.
95 - added a few entries in the makefile
96
willy tarreauad90a0c2005-12-18 01:09:15 +0100972005/04/25 : 1.2.5-pre3
98 - experimental epoll() support (use temporary '-e' argument)
99
1002005/04/24 : 1.2.5-pre2
willy tarreauc1f47532005-12-18 01:08:26 +0100101 - implemented the HTTP 303 code for error redirection. This forces the
102 browser to fetch the given URI with a GET request. The new keyword for
103 this is 'errorloc303', and a new 'errorloc302' keyword has been created
104 to make them easily distinguishable.
105 - added more controls in the parser for valid use of '\x' sequence.
106 - few fixes from Alex & Klaus
107
willy tarreauad90a0c2005-12-18 01:09:15 +01001082005/02/17 : 1.2.5-pre1
willy tarreauc1f47532005-12-18 01:08:26 +0100109 - fixed a few errors in the documentation
110
1112005/02/13
112 - do not pre-initialize unused file-descriptors before select() anymore.
113
willy tarreau12350152005-12-18 01:03:27 +01001142005/01/22 : 1.2.4
115 - merged Alexander Lazic's and Klaus Wagner's work on application
116 cookie-based persistence. Since this is the first merge, this version is
117 not intended for general use and reports are more than welcome. Some
118 documentation is really needed though.
119
willy tarreau0174f312005-12-18 01:02:42 +01001202005/01/22 : 1.2.3 (1.1.30)
121 - add an architecture guide to the documentation
122 - released without any changes
123
1242004/12/26 : 1.2.3-pre1 (1.1.30-pre1)
125 - increased default BUFSIZE to 16 kB to accept max headers of 8 kB which is
126 compatible with Apache. This limit can be configured in the makefile now.
127 Thanks to Eric Fehr for the checks.
128 - added a per-server "source" option which now makes it possible to bind to
129 a different source for each (potentially identical) server.
130 - changed cookie-based server selection slightly to allow several servers to
131 share a same cookie, thus making it possible to associate backup servers to
132 live servers and ease soft-stop for maintenance periods. (Alexander Lazic)
133 - added the cookie 'prefix' mode which makes it possible to use persistence
134 with thin clients which support only one cookie. The server name is prefixed
135 before the application cookie, and restore back.
136 - fixed the order of servers within an instance to match documentation. Now
137 the servers are *really* used in the order of their declaration. This is
138 particularly important when multiple backup servers are in use.
139
willy tarreau4302f492005-12-18 01:00:37 +01001402004/10/18 : 1.2.2 (1.1.29)
141 - fixed a bug where a TCP connection would be logged twice if the 'logasap'
142 option was enabled without the 'tcplog' option.
143 - encode_string() would use hdr_encode_map instead of the map argument.
144
1452004/08/10 : (1.1.29-pre2)
146 - the logged request is now encoded with '#XX' for unprintable characters
147 - new keywords 'capture request header' and 'capture response header' enable
148 logging of arbitrary HTTP headers in requests and responses
149 - removed "-DSOLARIS" after replacing the last inet_aton() with inet_pton()
150
willy tarreau982249e2005-12-18 00:57:06 +01001512004/06/06 : 1.2.1 (1.1.28)
152 - added the '-V' command line option to verbosely report errors even though
153 the -q or 'quiet' options are specified. This is useful with '-c'.
154 - added a Red Hat init script and a .spec from Simon Matter <simon.matter@invoca.ch>
willy tarreau036e1ce2005-12-17 13:46:33 +0100155
willy tarreau982249e2005-12-18 00:57:06 +01001562004/06/05 :
157 - added the "logasap" option which produces a log without waiting for the data
158 to be transferred from the server to the client.
159 - added the "httpclose" option which removes any "connection:" header and adds
160 "Connection: close" in both direction.
willy tarreau97f58572005-12-18 00:53:44 +0100161 - added the 'checkcache' option which blocks cacheable responses containing
162 dangerous headers, such as 'set-cookie'.
willy tarreau982249e2005-12-18 00:57:06 +0100163 - added 'rspdeny' and 'rspideny' to block certain responses to avoid sensible
164 information leak from servers.
willy tarreau25c4ea52005-12-18 00:49:49 +0100165
1662004/04/18 :
willy tarreaudd07e972005-12-18 00:48:48 +0100167 - send an EMERG log when no server is available for a given proxy
168 - added the '-c' command line option to syntactically check the
169 configuration file without starting the service.
170
willy tarreau8a86dbf2005-12-18 00:45:59 +01001712003/11/09 : 1.2.0
172 - the same as 1.1.27 + IPv6 support on the client side
173
willy tarreaufe2c5c12005-12-17 14:14:34 +01001742003/10/27 : 1.1.27
175 - the configurable HTTP health check introduced in 1.1.23 revealed a shameful
176 bug : the code still assumed that HTTP requests were the same size as the
177 original ones (22 bytes), and failed if they were not.
178 - added support for pidfiles.
179
willy tarreauc58fc692005-12-17 14:13:08 +01001802003/10/22 : 1.1.26
181 - the fix introduced in 1.1.25 for client timeouts while waiting for servers
182 broke almost all compatibility with POST requests, because the proxy
183 stopped to read anything from the client as soon as it got all of its
184 headers.
185
willy tarreauc1cae632005-12-17 14:12:23 +01001862003/10/15 : 1.1.25
187 - added the 'tcplog' option, which provides enhanced, HTTP-like logs for
188 generic TCP proxies, or lighter logs for HTTP proxies.
189 - fixed a time-out condition wrongly reported as client time-out in data
190 phase if the client timeout was lower than the connect timeout times the
191 number of retries.
192
willy tarreau197e8ec2005-12-17 14:10:59 +01001932003/09/21 : 1.1.24
194 - if a client sent a full request then shut its write connection down, then
195 the request was aborted. This case was detected only when using haproxy
196 both as health-check client and as a server.
197 - if 'option httpchk' is used in a 'health' mode server, then responses will
198 change from 'OK' to 'HTTP/1.0 200 OK'.
199 - fixed a Linux-only bug in case of HTTP server health-checks, where a single
200 server response followed by a close could be ignored, and the server seen
201 as failed.
202
willy tarreaueedaa9f2005-12-17 14:08:03 +01002032003/09/19 : 1.1.23
204 - fixed a stupid bug introduced in 1.1.22 which caused second and subsequent
205 'default' sections to keep previous parameters, and not initialize logs
206 correctly.
207 - fixed a second stupid bug introduced in 1.1.22 which caused configurations
208 relying on 'dispatch' mode to segfault at the first connection.
209 - 'option httpchk' now supports method, HTTP version and a few headers.
210 - now, 'option httpchk', 'cookie' and 'capture' can be specified in
211 'defaults' section
212
2132003/09/10 : 1.1.22
willy tarreaua41a8b42005-12-17 14:02:24 +0100214 - 'listen' now supports optionnal address:port-range lists
215 - 'bind' introduced to add new listen addresses
216 - fixed a bug which caused a session to be kept established on a server till
217 it timed out if the client closed during the DATA phase.
218 - the port part of each server address can now be empty to make the proxy
219 connect to the server on the same port it was connected to, be an absolute
220 unsigned number to reflect a single port (as in older versions), or an
221 explicitly signed number (+N/-N) to indicate that this offset must be
222 applied to the port the proxy was connected to, when connecting to the
223 server.
224 - the 'port' server option allows the user to specify a different
225 health-check port than the service one. It is mandatory when only relative
226 ports have been specified and check is required. By default, the checks are
227 sent to the service port.
228 - new 'defaults' section which is rather similar to 'listen' except that all
229 values are only used as default values for future 'listen' sections, until
230 a new 'defaults' resets them. At the moment, server options, regexes,
231 cookie names and captures cannot be set in the 'defaults' section.
232
willy tarreau2f6ba652005-12-17 13:57:42 +01002332003/05/06 : 1.1.21
234 - changed the debug output format so that it now includes the session unique
235 ID followed by the instance name at the beginning of each line.
236 - in debug mode, accept now shows the client's IP and port.
237 - added one 3 small debugging scripts to search and pretty print debug output
238 - changed the default health check request to "OPTIONS /" instead of
239 "OPTIONS *" since not all servers implement the later one.
240 - "option httpchk" now accepts an optional parameter allowing the user to
241 specify and URI other than '/' during health-checks.
242
willy tarreaub1ff9db2005-12-17 13:51:03 +01002432003/04/21 : 1.1.20
244 - fixed two problems with time-outs, one where a server would be logged as
245 timed out during transfer that take longer to complete than the fixed
246 time-out, and one where clients were logged as timed-out during the data
247 phase because they didn't have anything to send. This sometimes caused
248 slow client connections to close too early while in fact there was no
249 problem. The proper fix would be to have a per-fd time-out with
250 conditions depending on the state of the HTTP FSM.
251
willy tarreau906b2682005-12-17 13:49:52 +01002522003/04/16 : 1.1.19
253 - haproxy was NOT RFC compliant because it was case-sensitive on HTTP
254 "Cookie:" and "Set-Cookie:" headers. This caused JVM 1.4 to fail on
255 cookie persistence because it uses "cookie:". Two memcmp() have been
256 replaced with strncasecmp().
257
willy tarreau036e1ce2005-12-17 13:46:33 +01002582003/04/02 : 1.1.18
259 - Haproxy can be compiled with PCRE regex instead of libc regex, by setting
260 REGEX=pcre on the make command line.
261 - HTTP health-checks now use "OPTIONS *" instead of "OPTIONS /".
262 - when explicit source address binding is required, it is now also used for
263 health-checks.
264 - added 'reqpass' and 'reqipass' to allow certain headers but not the request
265 itself.
266 - factored several strings to reduce binary size by about 2 kB.
267 - replaced setreuid() and setregid() with more standard setuid() and setgid().
268 - added 4 status flags to the log line indicating who ended the connection
269 first, the sessions state, the validity of the cookie, and action taken on
270 the set-cookie header.
271
2722002/10/18 : 1.1.17
273 - add the notion of "backup" servers, which are used only when all other
274 servers are down.
275 - make Set-Cookie return "" instead of "(null)" when the server has no
276 cookie assigned (useful for backup servers).
277 - "log" now supports an optionnal level name (info, notice, err ...) above
278 which nothing is sent.
279 - replaced some strncmp() with memcmp() for better efficiency.
280 - added "capture cookie" option which logs client and/or server cookies
281 - cleaned up/down messages and dump servers states upon SIGHUP
282 - added a redirection feature for errors : "errorloc <errnum> <url>"
283 - now we won't insist on connecting to a dead server, even with a cookie,
284 unless option "persist" is specified.
285 - added HTTP/408 response for client request time-out and HTTP/50[234] for
286 server reply time-out or errors.
287
2882002/09/01 : 1.1.16
289 - implement HTTP health checks when option "httpchk" is specified.
290
2912002/08/07 : 1.1.15
292 - replaced setpgid()/setpgrp() with setsid() for better portability, because
293 setpgrp() doesn't have the same meaning under Solaris, Linux, and OpenBSD.
294
2952002/07/20 : 1.1.14
296 - added "postonly" cookie mode
297
2982002/07/15 : 1.1.13
299 - tv_diff used inverted parameters which led to negative times !
300
3012002/07/13 : 1.1.12
302 - fixed stats monitoring, and optimized some tv_* for most common cases.
303 - replaced temporary 'newhdr' with 'trash' to reduce stack size
304 - made HTTP errors more HTML-fiendly.
305 - renamed strlcpy() to strlcpy2() because of a slightly difference between
306 their behaviour (return value), to avoid confusion.
307 - restricted HTTP messages to HTTP proxies only
308 - added a 502 message when the connection has been refused by the server,
309 to prevent clients from believing this is a zero-byte HTTP 0.9 reply.
310 - changed 'Cache-control:' from 'no-cache="set-cookie"' to 'private' when
311 inserting a cookie, because some caches (apache) don't understand it.
312 - fixed processing of server headers when client is in SHUTR state
313
3142002/07/04 :
315 - automatically close fd's 0,1 and 2 when going daemon ; setpgrp() after
316 setpgid()
317
3182002/06/04 : 1.1.11
319 - fixed multi-cookie handling in client request to allow clean deletion
320 in insert+indirect mode. Now, only the server cookie is deleted and not
willy tarreau906b2682005-12-17 13:49:52 +0100321 all the header. Should now be compliant to RFC2965.
willy tarreau036e1ce2005-12-17 13:46:33 +0100322 - added a "nocache" option to "cookie" to specify that we explicitly want
323 to add a "cache-control" header when we add a cookie.
324 It is also possible to add an "Expires: <old-date>" to keep compatibility
325 with old/broken caches.
326
3272002/05/10 : 1.1.10
328 - if a cookie is used in insert+indirect mode, it's desirable that the
329 the servers don't see it. It was not possible to remove it correctly
330 with regexps, so now it's removed automatically.
331
3322002/04/19 : 1.1.9
333 - don't use snprintf()'s return value as an end of message since it may
334 be larger. This caused bus errors and segfaults in internal libc's
335 getenv() during localtime() in send_log().
336 - removed dead insecure send_syslog() function and all references to it.
337 - fixed warnings on Solaris due to buggy implementation of isXXXX().
338
3392002/04/18 : 1.1.8
340 - option "dontlognull"
341 - fixed "double space" bug in config parser
342 - fixed an uninitialized server field in case of dispatch
343 with no existing server which could cause a segfault during
344 logging.
345 - the pid logged was always the father's, which was wrong for daemons.
346 - fixed wrong level "LOG_INFO" for message "proxy started".
347
3482002/04/13 :
349 - http logging is now complete :
350 - ip:port, date, proxy, server
351 - req_time, conn_time, hdr_time, tot_time
352 - status, size, request
353 - source address
354
3552002/04/12 : 1.1.7
356 - added option forwardfor
357 - added reqirep, reqidel, reqiallow, reqideny, rspirep, rspidel
358 - added "log global" in "listen" section.
359
3602002/04/09 :
361 - added a new "global" section :
362 - logs
363 - debug, quiet, daemon modes
364 - uid, gid, chroot, nbproc, maxconn
365
3662002/04/08 : 1.1.6
367 - regex are now chained and not limited anymore.
368 - unavailable server now returns HTTP/502.
369 - increased per-line args limit to 40
370 - added reqallow/reqdeny to block some request on matches
371 - added HTTP 400/403 responses
372
3732002/04/03 : 1.1.5
374 - connection logging displayed incorrect source address.
375 - added proxy start/stop and server up/down log events.
376 - replaced log message short buffers with larger trash.
377 - enlarged buffer to 8 kB and replace buffer to 4 kB.
378
3792002/03/25 : 1.1.4
380 - made rise/fall/interval time configurable
381
3822002/03/22 : 1.1.3
383 - fixed a bug : cr_expire and cw_expire were inverted in CL_STSHUT[WR]
384 which could lead to loops.
385
3862002/03/21 : 1.1.2
387 - fixed a bug in buffer management where we could have a loop
388 between event_read() and process_{cli|srv} if R==BUFSIZE-MAXREWRITE.
389 => implemented an adjustable buffer limit.
390 - fixed a bug : expiration of tasks in wait queue timeout is used again,
391 and running tasks are skipped.
392 - added some debug lines for accept events.
393 - send warnings for servers up/down.
394
3952002/03/12 : 1.1.1
396 - fixed a bug in total failure handling
397 - fixed a bug in timestamp comparison within same second (tv_cmp_ms)
398
3992002/03/10 : 1.1.0
400 - fixed a few timeout bugs
401 - rearranged the task scheduler subsystem to improve performance,
402 add new tasks, and make it easier to later port to librt ;
403 - allow multiple accept() for one select() wake up ;
404 - implemented internal load balancing with basic health-check ;
405 - cookie insertion and header add/replace/delete, with better strings
406 support.
407
4082002/03/08
409 - reworked buffer handling to fix a few rewrite bugs, and
410 improve overall performance.
411 - implement the "purge" option to delete server cookies in direct mode.
412
4132002/03/07
414 - fixed some error cases where the maxfd was not decreased.
415
4162002/02/26
417 - now supports transparent proxying, at least on linux 2.4.
418
4192002/02/12
420 - soft stop works again (fixed select timeout computation).
421 - it seems that TCP proxies sometimes cannot timeout.
422 - added a "quiet" mode.
423 - enforce file descriptor limitation on socket() and accept().
424
4252001/12/30 : release of version 1.0.2 : fixed a bug in header processing
4262001/12/19 : release of version 1.0.1 : no MSG_NOSIGNAL on solaris
4272001/12/16 : release of version 1.0.0.
4282001/12/16 : added syslog capability for each accepted connection.
4292001/11/19 : corrected premature end of files and occasional SIGPIPE.
4302001/10/31 : added health-check type servers (mode health) which replies OK then closes.
4312001/10/30 : added the ability to support standard TCP proxies and HTTP proxies
432 with or without cookies (use keyword http for this).
4332001/09/01 : added client/server header replacing with regexps.
434 eg:
435 cliexp ^(Host:\ [^:]*).* Host:\ \1:80
436 srvexp ^Server:\ .* Server:\ Apache
4372000/11/29 : first fully working release with complete FSMs and timeouts.
4382000/11/28 : major rewrite
4392000/11/26 : first write