Welcome! Log In Create A New Profile

Advanced

Re: nginx workers in "D" status in top

July 27, 2010 02:54PM
On Tue, Jul 27, 2010 at 11:54:31AM -0500, Ryan Malayter wrote:

> I'm seeing a number of workers periodically entering the "D" status in
> top (uninteruptible sleep). Normally, this means it is blocking on
> disk IO. However, I am using nginx 0.7.62 (default package) on Ubunutu
> 9.10, and I believe asynchronous IO should be enabled.
>
> We are using proxy_cache, so there is some reading from disk in our
> configuration (not just reverse proxy).
>
> Is it normal to have nginx workers block on the disk even on an
> asynchronous IO-capable system?
>
> How can I check if nginx is actually using async IO?
>
> My configuration is large, but I will post fragments if necessary. I
> am using 4 worker processes on a single-CPU system (recently upped to
> 10 because of this issue).

nginx supports file AIO only in 0.8.11+, but the file AIO is functional
on FreeBSD only. On Linux AIO is supported by nginx only on kerenl
2.6.22+ (although, CentOS 5.5 has backported the required AIO features).
Anyway, on Linux AIO works only if file offset and size are aligned
to a disk block size (usually 512 bytes) and this data can not be cached
in OS VM cache (Linux AIO requires DIRECTIO that bypass OS VM cache).
I believe a cause of so strange AIO implementaion is that AIO in Linux
was developed mainly for databases by Oracle and IBM.


--
Igor Sysoev
http://sysoev.ru/en/

_______________________________________________
nginx mailing list
nginx@nginx.org
http://nginx.org/mailman/listinfo/nginx
Subject Author Posted

nginx workers in "D" status in top

Ryan Malayter July 27, 2010 01:04PM

Re: nginx workers in "D" status in top

Joaquin Cuenca Abela July 27, 2010 01:28PM

Re: nginx workers in "D" status in top

Ryan Malayter July 27, 2010 02:32PM

Re: nginx workers in "D" status in top

Igor Sysoev July 27, 2010 02:54PM

Re: nginx workers in "D" status in top

Ryan Malayter July 27, 2010 11:28PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 94
Record Number of Users: 8 on December 15, 2016
Record Number of Guests: 386 on August 02, 2016
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready