Webhosting Blog


Account Creation Status: failed. Your system has run out of available ip addresses, or you do not have permission to use any more ip addresses.

Above error normally is due to packages added on the server .

Please check the package assigned for the domains, the package  added might be by default created with dedicated IP.

To resolve the issue  remove the package and recreate the package with Dedicated IP option deselected .

Now try adding an account from WHM with defined package. It should be added now.


/var/spool/exim/db/retry: unexpected file type or format

You might face problems in receiving the emails in the inbox. Checking the email logs you can find the error logs as follows :

2012-02-19 12:45:17 Berkeley DB error: /var/spool/exim/db/ratelimit: unexpected file type or format
2012-02-19 12:45:17 failed to open DB file /var/spool/exim/db/ratelimit: Bad file descriptor
2012-02-19 12:45:17 H=xxx.xxxx.xxxx [] temporarily rejected connection in “connect” ACL: ratelimit database not available
2012-02-19 12:45:17 Berkeley DB error: /var/spool/exim/db/ratelimit: unexpected file type or format

The above error is basically due to exim database on the server being corrupted. You can follow the follow the following steps for this:

First stop the exim service

[root@support ~]#/etc/init.d/exim stop

[root@support ~]#cd /var/spool/exim

We will create a backup of the current exim DB.

[root@support exim]# cp -R db/ db-bak

[root@support exim]# cd db/

We will remove all the files currently existing in the folder.

[root@support db]#  rm -rf *

Now restart the exim service so the DB is auto created.

[root@support ~]# /etc/init.d/exim start

The emails should now be working fine on the server !


Enabling APC on cPanel server

What is APC:

The Alternative PHP Cache (APC) is a free and open opcode cache for PHP. Its goal is to provide a free, open, and robust framework for caching and optimizing PHP intermediate code. Apart from caching opcode cache it provides a user cache for storing application data.

Installing APC on cPanel server :

Before installing APC on the server ensure eAccelerator is enabled on the server .

root@server [~]# php -m | grep eAccelerator

Now lets install APC on the server . Follow the following commands on the server :

root@mailspec [~]# cd /usr/local/src

root@mailspec [~]# wget http://pecl.php.net/get/APC-3.0.19.tgz

root@mailspec [~]# tar -xzf APC-3.0.19.tgz && cd APC-3.0.19

root@mailspec [~]# phpize && ./configure –enable-apc –enable-apc-mmap –with-apxs=/usr/local/apache/bin/apxs –with-php-config=/usr/local/bin/php-config && make && make install

This should now configure APC and install it in your extension directory.

root@mailspec [~]# cd /usr/local/lib/php/extensions/no-debug-non-zts-200XXXX

You can locate a  file named apc.so in that directory.

You can now locate an entry for apc.so in the file /usr/local/lib/php.ini.


If you want to view APC interface via browser you can copy the file /usr/lib/php/apc.php into your sites documentroot path and access it via the browser. Ensure GD is installed on the server to view APC interface via the browser.

You can try accessing the URL:: http://domain.com/apc.com to view the interface

(replace the domain.com with your original domain name )

It will show you interface similar as follows :

Correcting Nameserver IP’s in cPanel

You might observe wrong nameservers IP allocated when you check the nameserver IP allocation from WHM>>  Main >> DNS Functions >> Nameserver IPs. 

You can correct these IP’s simple with following:

1 ) Check the file /etc/nameserverips. It should show you something as follows:

Correct the entries here if the entries are not as per expectation.

2)Now open the file /var/cpanel/nameserverips.yaml.

It should display you settings as follows

ns1.domain.com: “”: 1
count: ‘1’ zones:
ns2.domain.com: “”: 1
count: ‘1’
zones: domain.com

Edit the settings here as well if they are incorrect. Once done restart the cPanel service .

Now check the nameserver IP’s from WHM>> Main >> DNS Functions >> Nameserver IPs.  It should now be corrected.

Changing hostname for plesk server on linux.

Following are the steps to be followed in order to update the hostname on plesk server installed in linux environment.

1) Open the file /etc/hosts and edit the hostname entry as follows in the file (Eg: hostname= server.example.com)

# Auto-generated hostname. Please do not remove this comment. localhost.localdomain localhost
XX.XX.XX.XX server.example.com server

XX.XX.XX.XX — servers IP.

2) Now open the file /etc/sysconfig/network and edit the hostname entry in this file:


3) Now open the file /var/qmail/control/me  which contains the old hostname. Alter it to new hostname to make qmail identify itself  with  the new hostname.


4)Set the servers hostname in the plesk database with the following commands:

# mysql -u admin -p

Enter password:
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 181
Server version: 5.1.50 Source distribution

Copyright (c) 2000, 2010, Oracle and/or its affiliates. All rights reserved.
This software comes with ABSOLUTELY NO WARRANTY. This is free software,
and you are welcome to modify and redistribute it under the GPL v2 license

Type ‘help;’ or ‘\h’ for help. Type ‘\c’ to clear the current input statement.

mysql> use psa;
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A

Database changed
mysql> update misc set val=’server.example.com’ where param=’FullHostName’;
Query OK, 0 rows affected (0.00 sec)
Rows matched: 1  Changed: 1  Warnings: 0

mysql> quit

5) Now restart Plesk  service to activate the changes:

# /etc/init.d/psa stopall

# /etc/init.d/psa stop

# /etc/init.d/psa start

Now check the servers hostname. It should now be configured with the new hostname.




Modsecurity cron problem.

Sometimes you might start receiving the errors in mod security cron as follows:

connect(‘modsec:localhost’,’modsec’,…) failed: Access denied for user href=”mhtml:{CA6DED19-950C-4C5A-97F2-5C8634CBD55B}mid://00000086/!x-usc:mailto:’modsec’@’localhost'”>’modsec’@’localhost’
(using password: YES) at /etc/cron.hourly/modsecparse.pl line 19
Unable to connect to mysql database at /etc/cron.hourly/modsecparse.pl line 19.

The error occurs due to the password being mis configured in the file /etc/cron.hourly/modsecparse.pl .

You can use the following steps to sort the issue.

1) open the file /etc/cron.hourly/modsecparse.pl. You can find the following details in the file :

my $dbhost     = ‘localhost’;
my $dbuser     = ‘modsec’;
my $dbpassword = ‘somepassword’;      
my $dbname     = ‘modsec’;
my $tblname    = ‘modsec’;

check the password in the actual database for modsec.

server@root# mysql
mysql >\u mysql
mysql> select password from user where user=’modsec’;
mysql> select password(‘dbpassword’);

ERROR 2006 (HY000): MySQL server has gone away
No connection. Trying to reconnect…
Connection id:    4797
Current database: mysql

| password               |
| *8810994AD1910DDF9B31CB0DBF699C984CCFFEDC |
1 row in set (0.00 sec)

Replace the dbpassword with actual password from the file /etc/cron.hourly/modsecparse.pl .

mysql> UPDATE user SET Password=PASSWORD(‘somepassword’) WHERE User=’modsec’;

This will reset the password for the DB modsec to the original password  somepassword in the file /etc/cron.hourly/modsecparse.pl .

Once done you can just run the following command to ensure the DB is fixed !

server@root # perl -w /etc/cron.hourly/modsecparse.pl

If it runs without error the problem is sorted. :)



Mailman problems

After migrating the domain from one server to another server you might receive following error for the mailman lit:

“There currently are no publicly-advertised Mailman mailing lists
on XX.XX.XX.XX.To visit the administrators configuration page for
an unadvertised list, open a URL similar to this one, but with a ‘/’
and the right list name appended. If you have the proper authority,
you can also create a new mailing list.”

Use the following simple fix for this:

1) Navigate to the folder /usr/local/cpanel/3rdparty/mailman/bin

root@server # cd /usr/local/cpanel/3rdparty/mailman/bin

Following command will check the permissions for the mailing lists

root@server [/usr/local/cpanel/3rdparty/mailman/bin]# ./check_perms 

It will display something as follows:

directory permissions must be 02775: /usr/local/cpanel/3rdparty/mailman/archives/private/XX_domain.com/attachments/20101005/59ebfce0
Problems found: 1499
XX_domain.com : mailing list name

Either manually you can assign the permission as 02775 for the respective contents or simply fire following command to fix the errors:

root@server [/usr/local/cpanel/3rdparty/mailman/bin]# ./check_perms -f

This should now fix all the permissions. The mailing lists will again be functional on the new server.