Latest blog entry

how to enable log-queries-not-using-indexes

October 31, 2009    |   Posted by admin   |    Category: Mysql & PostGres SQL

How to enable “log-queries-not-using-indexes” in Mysql?

Edit /etc/my.cnf and place the following line under the [mysqld] section:

log-queries-not-using-indexes

Save the file and restart the mysql service:

# /etc/init.d/mysql restart

To verify if it is set to ON, use the following command:

# mysqladmin variables |grep  log_queries_not_using_indexes

Comments Off on how to enable log-queries-not-using-indexes

Plesk webmail + DB Error: connect failed

October 31, 2009    |   Posted by admin   |    Category: Plesk Management

You may receive the following error message while accessing Webmail on a Plesk server:

A fatal error has occurred
DB Error: connect failed

You need to make sure the ‘horde’ user is able to connect to the ‘horde’ database using the password mentioned in the file “/etc/psa/.webmail.shadow”. You have to create the file and specify a random password if the file is missing.

To set the password for user ‘horde’ , go to the mysql prompt.

#mysql -uadmin -p`cat /etc/psa/.psa.shadow` mysql

On the mysql prompt, execute:

mysql> update user set password=password(password-from-.webmail.shadow) where user=’horde’;

Also make sure sql.safe_mode is set to off in /etc/php.ini file:

sql.safe_mode=Off

Restart Apache server once you save the file.

If the problem persists, use the password from “/etc/psa/webmail/horde/.horde.shadow” file. Go through the following steps:

#cp /etc/psa/webmail/horde/.horde.shadow /etc/psa/.webmail.shadow

#mysql -uadmin -p`cat /etc/psa/.psa.shadow` mysql

mysql> update user set password=password(password-from-/etc/psa/webmail/horde/.horde.shadow) where user=’horde’;

You should now be able to access Webmail client.

Comments Off on Plesk webmail + DB Error: connect failed

Howto: Increase RAM/Memory for Java.

October 31, 2009    |   Posted by admin   |    Category: cPanel Management

In order to increase memory limit for Java, perform the following steps, edit the file:

/var/cpanel/tomcat.options

Insert the following 2 lines:

Xmx200M
Xms100M

where, Xmx is the upper limit and Xms is the lower limit. You have to replace the values as per your requirement. Save the file and restart the tomcat service:

root@server [~]#/scripts/restartsrv tomcat

Comments Off on Howto: Increase RAM/Memory for Java.

PureFtp + Not able to list more than 2000 files

October 24, 2009    |   Posted by admin   |    Category: Linux Administration

Problem: Not able to list more than 2000 files in a directory using Ftp.

Solution:

The pure-ftp by default limit maximum number of # files to be displayed to 2000.

So edit your pureftpd configuration file which is at /etc/pure-ftpd.conf and change the line

LimitRecursion 2000 8

to

LimitRecursion 5000 8

Save the file and restart the service.

service pure-ftpd restart

It will display 5000 files from a directory now.

Comments Off on PureFtp + Not able to list more than 2000 files

Remote host said: 553 sorry, that domain isn’t in my list of allowed rcpthosts

October 23, 2009    |   Posted by admin   |    Category: Plesk Management

Error Message:

Remote host said: 553 sorry, that domain isn’t in my list of allowed rcpthosts

You may see the above error message in the mail logs of Qmail. Follow the below steps:

1. Make sure the domain name is present in the file “/var/qmail/control/rcpthosts”, if it doesn’t, turn off mail for that domain and then turn it back on.

You can turn Off/On mails for a domain from Plesk >> Domains >> domainname.tld  >>  “Web Hosting Settings” >> Enable/Disable button at the top.

2. If it doesn’t, then run,

/usr/local/psa/admin/bin/mchk -a

It will look like it finishes quickly, but it will actually run in the background. It rebuilds direcories, files, permissions on all mail accounts based on the information in the plesk db.

Comments Off on Remote host said: 553 sorry, that domain isn’t in my list of allowed rcpthosts