Commit graph

5351 commits

Author SHA1 Message Date
Valentin Bartenev
6a771704df Configure: added gcc5 to the list of known GCC versions. 2015-06-10 19:18:20 +03:00
Ruslan Ermilov
e62e8a0006 Configure: search OpenSSL in a bunch of standard places. 2015-06-10 12:25:45 +03:00
Ruslan Ermilov
05084363d7 Configure: moved NGX_SBIN_PATH variable initialization.
It's now initialized in auto/options like the rest of variables
for system paths.

As a side effect, the currently unused macro NGX_SBIN_PATH now
gets the correct value.
2015-06-10 12:25:31 +03:00
Vladimir Homutov
ba1eec3b04 Stream: access module.
stream {
    server {
        ...
        allow 127.0.0.1;
        deny all;
    }
}
2015-06-04 13:04:12 +03:00
Vladimir Homutov
7f714ecc48 Stream: added postconfiguration method to stream modules. 2015-06-09 13:00:45 +03:00
Ruslan Ermilov
b5e65d633d Mail: listen backlog=. 2015-06-08 23:13:56 +03:00
Ruslan Ermilov
1c02c89ae9 Stream: listen backlog=. 2015-06-08 23:13:33 +03:00
Ruslan Ermilov
d02654e7b4 Mail: embed ngx_mail_listen_t into ngx_mail_conf_addr_t. 2015-06-08 23:11:58 +03:00
Ruslan Ermilov
2432c09ef7 Stream: embed ngx_stream_listen_t into ngx_stream_conf_addr_t. 2015-06-08 23:11:42 +03:00
Ruslan Ermilov
82f43aeb19 Stream: fixed "reuseport" to actually work. 2015-06-05 23:03:13 +03:00
Maxim Dounin
652fb06a66 Added the REQUEST_SCHEME parameter.
The REQUEST_SCHEME parameter was introduced in Apache 2.3.11 and seems
to be used by some scripts now.  It looks more logical than previously
used HTTPS.
2015-06-05 22:23:26 +03:00
Roman Arutyunyan
eaff49e1d7 Upstream keepalive: reduced diffs to the plus version of nginx. 2015-06-04 23:46:44 +03:00
Maxim Dounin
6c28e55dbb Style. 2015-06-05 17:10:34 +03:00
Sergey Kandaurov
83b0d1c750 Event pipe: call ngx_handle_read_event() with a proper flags type.
The change was missed in f69d1aab6a0f.
2015-06-03 19:12:26 +03:00
Ruslan Ermilov
1fced9afbd Fixed misspellings of the word "dependencies". 2015-06-03 08:23:35 +03:00
Valentin Bartenev
009fe1ef67 Fixed excessive memory usage while parsing configuration.
The b->pos points to the next symbol here.

Reported by ilexshen.
2015-06-01 21:08:56 +03:00
Valentin Bartenev
4741bcb86f Fixed spelling in change logs. 2015-06-01 16:58:07 +03:00
Ruslan Ermilov
e07c020105 Fixed bullying style of comments. 2015-05-29 09:26:33 +03:00
Ruslan Ermilov
8c116d36b1 Version bump. 2015-05-29 09:26:27 +03:00
Maxim Dounin
15b91a96ef release-1.9.1 tag 2015-05-26 16:49:51 +03:00
Maxim Dounin
105cb1e616 nginx-1.9.1-RELEASE 2015-05-26 16:49:50 +03:00
Maxim Dounin
f5cee646a7 Disabled SSLv3 by default (ticket #653). 2015-05-25 17:58:20 +03:00
Maxim Dounin
1e5b6ec2a1 Configure: GNU Hurd properly recognized.
With this change it's no longer needed to pass -D_GNU_SOURCE manually,
and -D_FILE_OFFSET_BITS=64 is set to use 64-bit off_t.

Note that nginx currently fails to work properly with master process
enabled on GNU Hurd, as fcntl(F_SETOWN) returns EOPNOTSUPP for sockets
as of GNU Hurd 0.6.  Additionally, our strerror() preloading doesn't
work well with GNU Hurd, as it uses large numbers for most errors.
2015-05-25 17:58:13 +03:00
Maxim Dounin
66cb331a38 Fixed reuseport with accept_mutex. 2015-05-21 19:39:11 +03:00
Ruslan Ermilov
c4b1b3907f Upstream: report to error_log when max_fails is reached.
This can be useful to understand why "no live upstreams" happens,
in particular.
2015-05-20 22:44:00 +03:00
Maxim Dounin
65ad1171c9 The "reuseport" option of the "listen" directive.
When configured, an individual listen socket on a given address is
created for each worker process.  This allows to reduce in-kernel lock
contention on configurations with high accept rates, resulting in better
performance.  As of now it works on Linux and DragonFly BSD.

Note that on Linux incoming connection requests are currently tied up
to a specific listen socket, and if some sockets are closed, connection
requests will be reset, see https://lwn.net/Articles/542629/.  With
nginx, this may happen if the number of worker processes is reduced.
There is no such problem on DragonFly BSD.

Based on previous work by Sepherosa Ziehau and Yingqi Lu.
2015-05-20 15:51:56 +03:00
Maxim Dounin
1881445bba Simplified ngx_http_init_listening().
There is no need to set "i" to 0, as it's expected to be 0 assuming
the bindings are properly sorted, and we already rely on this when
explicitly set hport->naddrs to 1.  Remaining conditional code is
replaced with identical "hport->naddrs = i + 1".

Identical modifications are done in the mail and stream modules,
in the ngx_mail_optimize_servers() and ngx_stream_optimize_servers()
functions, respectively.

No functional changes.
2015-05-20 15:51:28 +03:00
Maxim Dounin
831662ea73 Introduced worker number, ngx_worker. 2015-05-20 15:51:21 +03:00
Maxim Dounin
9456863c64 Configure: style. 2015-05-20 15:51:13 +03:00
Valentin Bartenev
5fd1f0fd59 Core: properly initialized written bytes counter in memory log. 2015-05-19 19:27:07 +03:00
Sergey Kandaurov
1ac2ceeb8d Upstream hash: consistency across little/big endianness. 2015-05-18 16:05:44 +03:00
Ruslan Ermilov
7c48049b72 Upstream: $upstream_connect_time.
The variable keeps time spent on establishing a connection with
the upstream server.
2015-05-16 01:32:27 +03:00
Ruslan Ermilov
a0cfe06ec6 Upstream: times to obtain header/response are stored as ngx_msec_t. 2015-05-16 01:31:04 +03:00
Igor Sysoev
0106fe5106 Events: ngx_event_t size reduction by grouping bit fields. 2015-05-15 17:15:33 +03:00
Ruslan Ermilov
68e6c887d0 Events: made a failure to create a notification channel non-fatal.
This may happen if eventfd() returns ENOSYS, notably seen on CentOS 5.4.
Such a failure will now just disable the notification mechanism and let
the callers cope with it, instead of failing to start worker processes.
If thread pools are not configured, this can safely be ignored.
2015-05-06 17:04:00 +03:00
Ruslan Ermilov
de2b39c702 Configure: handle deprecated options.
Removed the deprecated --without-http_limit_zone_module option.
Deprecated the --with-imap and --with-imap_ssl_module options.
2015-04-29 14:59:02 +03:00
Ruslan Ermilov
95ca7efd49 Removed the deprecated "imap" directive. 2015-04-29 13:53:24 +03:00
Ruslan Ermilov
909aa15688 Removed the deprecated "so_keepalive" directive. 2015-04-29 13:53:08 +03:00
Ruslan Ermilov
75fae2df1e Removed deprecated HTTP directives. 2015-04-29 13:52:49 +03:00
Ruslan Ermilov
1554f987b3 Removed the deprecated "connections" directive. 2015-04-29 13:52:37 +03:00
Valentin Bartenev
b370ea3fa7 Fixed overflow detection in ngx_inet_addr().
Overflow detection of the last octet might not work.

Reported by Sergey Polovko.
2015-04-28 18:55:03 +03:00
Valentin Bartenev
e3efe0d999 Version bump. 2015-04-28 18:54:48 +03:00
Maxim Dounin
5bfbac7203 release-1.9.0 tag 2015-04-28 18:31:18 +03:00
Maxim Dounin
9b6eb4f737 nginx-1.9.0-RELEASE 2015-04-28 18:31:17 +03:00
Maxim Dounin
ffd7ee2660 Added stream module to win32 builds. 2015-04-27 18:51:18 +03:00
Maxim Dounin
f9d7aaa7b6 Win32: shared memory base addresses and remapping.
Two mechanisms are implemented to make it possible to store pointers
in shared memory on Windows, in particular on Windows Vista and later
versions with ASLR:

- The ngx_shm_remap() function added to allow remapping of a shared memory
  zone to the address originally used for it in the master process.  While
  important, it doesn't solve the problem by itself as in many cases it's
  not possible to use the address because of conflicts with other
  allocations.

- We now create mappings at the same address in all processes by starting
  mappings at predefined addresses normally unused by newborn processes.

These two mechanisms combined allow to use shared memory on Windows
almost without problems, including reloads.

Based on the patch by Sergey Brester:
http://mailman.nginx.org/pipermail/nginx-devel/2015-April/006836.html
2015-04-27 18:25:42 +03:00
Maxim Dounin
a5e3b66ce3 Win32: fixed shm.handle loss on reload. 2015-04-27 03:44:30 +03:00
Maxim Dounin
3b43a7a702 Core: fixed nginx_shared_zone name. 2015-04-27 03:44:03 +03:00
Vladimir Homutov
366a6f29e4 Mail: error_log support. 2015-02-20 15:31:37 +03:00
Vladimir Homutov
bcf9cd2d24 Core: the ngx_set_connection_log() macro.
The http and stream versions of this macro were identical.
2015-04-25 22:44:02 +03:00