Turbo charge lighttpd with Linux AIO - Gain more performance
Support for Linux kernel AIO (Asynchronous I/O) has been included in the version 2.6. By enabling Lighttpd AIO you can gain good performance gain. But what is AIO?
Usually your application needs to wait till I/O call is finished. AIO enables even a single application thread to overlap I/O operations with other processing, by providing an interface for submitting one or more I/O requests in one system call without waiting for completion, and a separate interface to reap completed I/O operations associated with a given completion group (see Linux AIO home page for more details).
Lighttpd 1.5.x support AIO. First make sure you have libaio installed:
# yum install libaio-devel
Next grab lighttpd source code and compile with --with-linux-aio option:
# ./configure --with-openssl --with-linux-aio
Install lighttpd
# make; make install
Create configuration file and put following directive in lighttpd.conf file:
server.network-backend = "linux-aio-sendfile"
Save and close the file. Restart lighttpd:
# /etc/init.d/lighttpd restart
Use httpd_load / ab command Performance Benchmarks a Web server.
Please note that I’ve tested above instructions on Redhat Enterprise Linux 4/5 and Cent OS.
Want to stay up to date with the latest Linux tips, news and announcements? Subscribe to our free e-mail newsletter or RSS feed to get all updates.
You can Email this page to a friend.
You may also be interested in other helpful articles:
- Lighttpd client side optimization with mod_expire to controls the expire http header
- Lighttpd / Apache : Run Xcache in Chrooted Jail
- Download of the day: Lighttpd web server 1.4.17
- Lighttpd PHP fastcgi configuration
- FreeBSD Install Lighttpd Web Server
Discussion on This Article:
Leave a Reply
We encourage your comments, and suggestions. But please stay on topic, be polite, and avoid spam. Thank you very much for stopping by our site!
Tags: application_thread, asynchronous, lighttpd, lighttpd_aio, linux_aio, linux_kernel, performance_gain



what are your result (gain) with this feateures ?