Howto enable Directory Listing in nginx

To enable directory listing use the following configuration option:

autoindex on;

eg:
server {    listen 80;    server_name gnusys.net;    autoindex on;…………}

Posted under hosting, nginx

This post was written by Anoop Alias on September 1, 2008

Tags: ,

howto reinitialize CPAN configuration

To reinitialize your CPAN configuration type the following from your cpan shell

=========

cpan> o conf init
=========

Posted under perl

This post was written by Anoop Alias on August 27, 2008

Tags:

Good WHM-cpanel troubleshooting guide

The following guide (property of Cpanel.net ) is a good starting point in troubleshooting cpanel /whm problems

Please note that this document belongs to Cpanel.net and may contain proprietary informationr

Download a copy from here

http://gnusys.net/downloads/Troubleshooting.pdf

Posted under cpanel, hosting

This post was written by Anoop Alias on August 26, 2008

Tags: ,

nginx server_names_hash_bucket_size error

The error:

Starting nginx daemon: nginx2008/08/25 00:29:09 [emerg] 4011#0: could not build the server_names_hash, you should increase server_names_hash_bucket_size: 32

The fix:

Within the http block of the nginx config file make sure you have the server_names_hash_bucket_size set higher than the minimum 32

something lik

http { server_names_hash_bucket_size 64;

}

explanation :

hash_max_size will control the
number of virtual host entries, while _hash_bucket_size will control
the maximum length of single entries
if you have a lot of virtual host entries, you should increase
hash_max_size, while I should increase hash_bucket_size if some
domain names are too long.

Posted under Uncategorized, nginx

This post was written by Anoop Alias on August 25, 2008

Tags:

Howto install GeoIP C API in GNU/Linux

MaxMind’s GeoIP C api is used by various programs to map IP address to locations .

Here is the procedure to install this :

Download the latest source from http://www.maxmind.com/download/geoip/api/c/

mkdir /usr/local/geoip

./configure –prefix=/usr/local/geoip –exec-prefix=/usr/local/geoip

make

make install

Now we have to make the system loader load the shared libraries

Add the following to /etc/ld.so.conf.d/geoip.conf

====

cat /etc/ld.so.conf.d/geoip.conf
/usr/local/geoip/lib
====

ldconfig

If all goes well , you should have GeoIP installed in /usr/local/geoip

Posted under Uncategorized

This post was written by Anoop Alias on August 23, 2008

Tags:

Fix locales warning on Debian or Ubuntu

Sometimes you get the following warning when running commands in Debian / Ubuntu powered computers

==============

perl: warning: Setting locale failed.
perl: warning: Please check that your locale settings:
LANGUAGE = (unset),
LC_ALL = (unset),
LANG = “en_US.UTF-8″
are supported and installed on your system.
perl: warning: Falling back to the standard locale (”C”).

===============

To fix this run the following command as root

root@php-server:~# apt-get install language-pack-en-base

Posted under Debian, apt

This post was written by Anoop Alias on August 23, 2008

Tags: ,

Howto install yum on a Virtuozzo container

Please follow the following commands to install yum on your Virtuozzo container . The follwoing commands are to be run from the hardware node .

————————

[root@vps1 ~]# vzlist  -a
CTID      NPROC STATUS    IP_ADDR         HOSTNAME
1         91 running   192.168.46.242  ServiceCT
105         49 running   69.72.234.148   asdf
107         49 running   69.72.234.150   test.test.com2

————————

This will list all the configured containers and their container ID (CTID) which is of importance to us

Assume you have to install yum on container 107

————————

[root@vps1 ~]# vzpkg install -p 107 yum

————————

!please note that If there is no yum available in the template repository it will fail.

Posted under virtuozzo, yum

This post was written by Anoop Alias on August 21, 2008

Tags: ,