Posts

Showing posts with the label server

Nginx error 413: Request entity too large Quick Fix

A quick article today about a common error people encounter with Nginx: the infamous 413 Request Entity Too Large HTTP error. I had the problem myself just yesterday on one of my newly configured servers, so I thought I'd make a blog post about it to make sure I don't forget this next time. Error 413: what does it mean? This error shows up when a visitor sends too much data in the HTTP request. This is normally caused by: • an overy large file being uploaded by the visitor • more generally too much POST data being sent by the client The fix is as simple as setting a directive in your Nginx configuration, read on below. How to fix it? client_max_body_size To fix this, you need to increase the value of the client_max_body_size directive. This directive defines the maximum amount of data Nginx will accept in an HTTP request. By default this value is set to 1 megabyte, meaning if you attempt to upload a file larger than 1 megabyte you'll be getting an  Error ...

Nginx market share soon to hit 10% mark

Image
According to multiple sources such as: NetCraft's July 2011 Web Server survey W3tech's Web server usage statistics as of October 25 the amazing and lightning-fast web server known as nginx is just about to hit the 10% market share mark in the next couple of months. This is a fantastic milestone for the author, Igor Sysoev , who probably didn't imagine that the application (which he originally developed on his own) would meet such fame. Diagram courtesy of W3Techs.com (article linked above). Its market share went from a little over 5% to almost 10% over the last year as you can see.  I wouldn't go so far as to say that the release of my Nginx HTTP Server book  (released Summer 2010) was one of the factors that contributed to the popularity of the Russian web server. It is my belief that the sole quality and efficiency of the software is what made its success. The book was and is being translated into three languages: In Japanese In Chinese (t...

"Nginx HTTP Server" book published

Nginx HTTP Server was published and is now available for purchase on various locations. It will begin to appear in store in the coming weeks. You can already purchase the eBook from the publisher's website at the link below: https://www.packtpub.com/nginx-http-server-for-web-applications/book The eBook can be purchased for 23.79€ whereas the book is 31.49€. There is also a preview chapter available on the website for anyone to read! Please feel free to leave your comments, feedback and questions if you have read the book.

Nginx HTTP Server: the book

Image
Hello, I am glad to to announce the first Nginx book on the market: Nginx HTTP Server , written by... me . :-) NGINX HTTP SERVER "Adopt Nginx for your web applications to make the most of your infrastructure and server pages faster than ever." Focused on the primary aspect of Nginx (HTTP serving), the book covers the following topics: Get started with Nginx to serve websites faster and safer Learn to configure your servers and virtual hosts efficiently Set up Nginx to work with PHP and other applications via FastCGI Explore possible interactions between Nginx and Apache to get the best of both worlds A step-by-step guide to switching from Apache to Nginx Complete configuration directive and module reference There are 8 chapters and 3 appendices, listed here: 1. Preparing your work environment: getting ready to work under a command-line environment, with a reminder on the basic tools and commands. 2. Downloading and installing Nginx : downloading the source, th...

Nginx & PHP via FastCGI important security issue

A critical security issue has recently been pointed out on servers that run Nginx and PHP via FastCGI. The issue allows anyone to execute their own PHP code on the system, I don't think I have to remind you of the consequences this could have. I will attempt to provide a simple explanation of the issue and more importantly how to fix it. What is the issue? I would like to begin by discussing the nature of the problem: it is not caused by Nginx itself - it is not a bug or a security breach in itself. Actually, it is the way that people usually configure Nginx FastCGI options to work with PHP, and how PHP reacts to that configuration. Pretty much everyone adopts the same configuration without being aware of the issue. The issue itself can be understood simply, then I will explain why PHP behaves that way. Most dynamic websites allow for a reason or another uploading of files. Say, I'm running a forum-based community, users can upload images to use as personal photo or ava...