zeldor.biz

Linux, programming and more

Copyright © 2025
Log in

Nginx – Error 413: Request Entity Too Large

August 9, 2011 by Igor Drobot Leave a Comment

The default Nginx maximum body-size of a client request, or maximum file size is 1M. So when you try to upload something larger than 1M, you get the following error: 413: Request Entity Too Large

Create a new configuration file: [Read more…]

Filed Under: Debian, HTTP, Linux, Networking Tagged With: client_max_body_size, Error 413, Nginx

Apache short paths

July 9, 2011 by Igor Drobot Leave a Comment

A little trick to simplify your apache virtual hosts configuration, instead of full paths you can use some predefined variables like the directory of apache logs or the configuration directory.

${APACHE_LOG_DIR} is for /var/log/apache2

1
2
ErrorLog ${APACHE_LOG_DIR}/access.log
CustomLog ${APACHE_LOG_DIR}/error.log

ErrorLog ${APACHE_LOG_DIR}/access.log CustomLog ${APACHE_LOG_DIR}/error.log

$APACHE_CONFDIR is for /etc/apache2

1
$APACHE_CONFDIR/mods-available

$APACHE_CONFDIR/mods-available

Filed Under: HTTP, Linux, Networking Tagged With: apache2, HTTP Server

APC – Alternative PHP Cache

June 21, 2011 by Igor Drobot Leave a Comment

A PHP-accelerator is a PHP extension designed to improve the performance of software applications written in the PHP language.

Most PHP accelerators work by caching the compiled p-code (portable code) of PHP-Scripts to avoid the overhead of reparsing and recompiling source code on each request made for example by a stupid bot.

APC is free, open source framework that optimizes PHP intermediate code and caches data and compiled code from the PHP bytecode compiler in shared memory. APC is quickly becoming the de-facto standard PHP caching mechanism as it will be included built-in to the core of PHP starting with PHP 6 <- Great news! [Read more…]

Filed Under: HTTP, Linux, Networking Tagged With: Accelerator, apc, Benchmark, Nginx, php5-fpm

Generate self-signed certificate

February 4, 2011 by Igor Drobot Leave a Comment

Quick and easy – generate self-signed certificate in one line:

1
openssl req -new -newkey rsa:4096 -days 365 -nodes -x509 -keyout ipv6.mysql.idrobot.net.key -out ipv6.mysql.idrobot.net.crt

openssl req -new -newkey rsa:4096 -days 365 -nodes -x509 -keyout ipv6.mysql.idrobot.net.key -out ipv6.mysql.idrobot.net.crt

Country Name (2 letter code) [AU]:DE
State or Province Name (full name) [Some-State]:Niedersachsen
Locality Name (eg, city) []:Hannover
[Internet Widgits Pty Ltd]:ipv6.mysql.idrobot.net
Organizational Unit Name (eg, section) []:
Common Name (eg, YOUR name) []:Igor Drobot
Email Address []:id@drobot.de

Filed Under: Bash, HTTP, Linux Tagged With: generate cert, OpenSSL

Enable CGI in Apache2

January 31, 2011 by Igor Drobot 2 Comments


If you want to enable CGI support for you domain or subdomain.

Install Apache2 mod-perl module:

1
aptitude install libapache2-mod-perl2

aptitude install libapache2-mod-perl2

Add this to the Apache configuration:

1
2
3
4
<directory "="" var="" www="" domain="" cgi-scripts"="">
    Allow from all
    Options All FollowSymLinks MultiViews
</directory>

<directory "="" var="" www="" domain="" cgi-scripts"=""> Allow from all Options All FollowSymLinks MultiViews </directory>

Only scripts in directory /var/www/cgi-scripts can be executed as CGI.

Filed Under: Debian, HTTP, Linux Tagged With: apache2 cgi, cgi, enable cgi

  • « Previous Page
  • 1
  • 2
  • 3
  • Next Page »
Yeaaah Cookie! We use cookies to ensure that we give you the best experience on our website. If you continue to use this site we will assume that you are happy with it.Ok