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

MySQL: Error 1016 when using LOCK TABLES

August 8, 2011 by Igor Drobot 2 Comments

I run a nightly mysqldump of all my databases and one of them has over 500 tables, mysqldumper bring me a error while processing this huge database: [Read more…]

Filed Under: Linux, MySQL Tagged With: MySQL, mysqldump, single-transaction, skip-lock-tables

Hide BIND sever version from nmap

July 26, 2011 by Igor Drobot Leave a Comment

Security fix for the DNS infrastructure to hide the the sensible information about the version and potential security critical bugs.

[Read more…]

Filed Under: Linux Tagged With: bind, DNS, named

Remove logs older than X days

July 12, 2011 by Igor Drobot Leave a Comment

The simplest way to remove files older than $NUMBER of days..

Dry run (files will be NOT deleted, you will see a list with files older than 100 days)

1
find -mtime +100 | less

find -mtime +100 | less

Another dry run, see what would be delete:

1
2
3
find -mtime +600 | xargs echo rm
rm /var/log/squid3/access.log.0
rm /var/log/squid3/access.log.2

find -mtime +600 | xargs echo rm rm /var/log/squid3/access.log.0 rm /var/log/squid3/access.log.2

Finally if you decided to remove the files – the final command to delete them:

1
find -mtime +600 | xargs rm

find -mtime +600 | xargs rm

Filed Under: Bash, Linux Tagged With: bash, find, Logs, rm, xargs

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

  • « Previous Page
  • 1
  • …
  • 28
  • 29
  • 30
  • 31
  • 32
  • …
  • 62
  • 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