Which Light Weight, Open Source Web Server is Right for You?

26321

If you use Linux, most likely Apache is your web server of choice. Apache is a great choice. It’s incredibly powerful, very reliable, and secure. There may, however, be certain deployments that either do not need all of the features found in Apache, do not have the resources to support Apache (such as in the case of an embedded system), or need something easier to manage. If that’s the case, fear not ─ there are plenty of light weight, open source, web servers out there ready to meet and exceed your needs.

Let’s take a look at some of the best small footprint web servers available and find out which one is right for you.

nginx logoNginx

Nginx has become one of the most important web servers over the last couple of years. There’s a reason for that. Instead of using the standard threaded- or process-oriented architecture, it uses a scalable, event-driven (asynchronous) architecture. So not only is it incredibly light weight, it’s highly scalable and memory usage is far better suited for limited resource deployments. Nginx also handles simple load balancing, fault tolerance, auto-indexing, virtual servers (both name- and IP-based), mod_rewrite, access control, and much more. Nginx can also serve as a reverse proxy and an IMAP/POP3 proxy server.

Surprisingly, Nginx powers a few very high-profile sites, such as: Netflix, Hulu, Pinterest, WordPress.com, and AirBnB.

Who is Nginx right for? The nice thing about this particular light weight HTTPD daemon is that it doesn’t perform like a lightweight server. Not only does it run with minimal resources, it offers plenty of optional modules and addons. You can find pre-built packages for Linux and BSD for easy installation. So if you need a powerhouse server, in a lighter weight package, Nginx is the server for you.

Nginx comes in at a 10 MB installation (versus the Apache 30 MB installation) and can give you up to a 35 percent performance increase (versus Apache).

Lighttpd logoLighttpd

Lighttpd is light ─ fly light in fact ─ and is the perfect server for any machine suffering from load problems. Lighttpd is also an ideal candidate for embedded systems. In fact, one of the most popular embedded systems on the market now, Raspberry Pi, is an ideal candidate for lighttpd.

Lighttpd offers effective memory management of cpu load, FastCGI, SCGI, Auth, Output-Compression, URL-Rewriting, and much more. Although Lighttpd can handle ten thousand simultaneous clients, chances are you won’t be running a massive site with this lightweight server. Lighttpd’s FastCGI can be configured to efficiently support PHP with opcode caches. This “flyweight” server also supports WebDNA (server-side scripting language with an embedded database system), so you can use lighttpd on an embedded system to create dynamic, database-driven websites.

Who is lighttpd right for? If you’re looking to create an embedded system (with far less available resources) that includes a web component, Lighttpd is most likely what you want. Lighttpd is very simple to use and set up. Configuration of this particular server is handled in a single .conf file.

monkey logoMonkey

Monkey HTTP Daemon is another web server aimed at the embedded systems market. Monkey features the likes of virtual hosts, indented configuration, plugins support, C API Interface, and HTTP/1.1. This is also another asynchronous (event-driven) web server. Monkey’s plugins aren’t nearly as extensive as other servers, but you can find additional support for: CGI, SSL, security, log writer, directory listing, and shell (command line). 

Monkey can serve as a stand-alone server for static content or, thanks to scripting languages such as PHP, Perl, Python, and Lua), it can provide a FastCGI interface to deliver dynamic content. Monkey also provides a C framework, called Duda I/O, for more sophisticated, scalable web services (such as big data, home automation, and real-time bidding markets).

The binary size of Monkey is around 100 KB on installation and around 250 KB on runtime, so it’s incredibly small. Monkey supports ARM, x86, and x64 architecture, so it’s available for multiple platforms and embedded systems.

Who is Monkey HTTP Daemon right for? Anyone needing a web server that is extremely simple to install and setup on an embedded device. For ease of use and static-content performance, Monkey is hard to beat.

cherokee logoCherokee

Cherokee is a user-friendly, lightweight, cross-platform (Linux, Mac, Solaris, BSD) web server that includes plenty of modern features. Out of the box, you’ll find Cherokee supports: FastCGI, SCGI, PHP, uWSGI, SSI, CGI, LDAP, TLS/SSL, HTTP proxying, video streaming, content caching, traffic shaping, and much more. This particular server also has a very user-friendly web-based setup tool.

Cherokee also offers a small listing of web application framework support. Included applications are: PHP, Ruby on Rails, ColdFusion, GlassFish, and Django.

There is one downfall with Cherokee ─ and this could be a deal breaker for some. The last released update was Oct. 2011. That’s seriously out of date. The server still works, but as far as getting security updates and patches ─ good luck.

Who is Cherokee right for? If you’re looking for an easy to setup and use web server that happens to be cross-platform, but aren’t concerned with using out-of-date software, Cherokee might be right for you.

hiawatha logoHiawatha

Hiawatha is a lightweight, open source web server with a focus geared toward security and ease of use. This particular light weight server isn’t designed for embedded systems, but as a fully-functioning, dynamic web server. Some of the features of this particular server include: load balancing, FastCGI, large file support, reverse proxy, chroot support, rewrite support, SSL/TLS, basie/digest HTTP authentication, IPv6 support, virtual hosting, and much more.

But what about the security? Via built-in technology, Hiawatha can stop SQL injections, XSS and CSRF attacks, control external image linking, ban potential hackers and limit the runtime of CGI applications and exploit attempts. There is also a built-in monitoring tool that allows you to keep tabs on all of your web servers.

Even with this solid feature set, Hiawatha remains an ideal option for embedded systems ─ especially those that require added security.

Who is Hiawatha right for? If you’re looking for a robust web server for either a standard setup or embedded system, and require a higher level of built-in security, Hiawatha is the server for you.

When deciding on a web server, it’s very tempting to go with the most widely used system on the planet ─ Apache. But when you have a need that Apache can’t fill, it’s good to know there are alternatives available. Be it for an embedded system, a standard server, or a test environment, open source has your web server needs covered. Give one of these systems a try and see if they don’t meet or exceed your expectations.