Latest blog entry

Plesk: cannot remove email/domain/client: mailmng failed: Some errors occured

December 27, 2010    |   Posted by admin   |    Category: Plesk Management

If the mail handlers in Plesk are corrupt, you will be unable to remove the email account OR a domain from the Plesk control panel and will result in the following error


mailmng failed: Some errors occured. See log for details
0: class.MailManager.php:242
MailManager::execWithException(string ‘smart_exec’, string ‘mailmng’, array, array, string ‘lst’)
1: class.MailManager.php:274
MailManager->callMailManager(string ‘remove-mailname’, array)
2: class.MailManager.php:354
MailManager->removeMailname(string ‘domain.tld’, string ’emailid’)


The one of the following 3 methods can be used to resolve the issue:

1) To remove and re-create the mail handlers using the ‘mchk’ script and then deleting the email account from Plesk. For detailed steps, click here

2) To remove the email account via SSH.

# /usr/local/psa/bin/mail --remove email@domain.tld

3) If the above 2 methods doesn’t work, remove the email account from the Plesk database manually (backup the ‘psa’ database first). 

Let’s use the email ID as “” as an example here (of-course, it should be replaced with the actual values in your queries).

Connect to the psa database from SSH:

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

Retrieve the domain ID of

mysql> select id from domains where name="";

Now, first we will delete the password of the email account from the ‘accounts’ table by executing the below query:

mysql> delete from accounts where id in (select from \
mail INNER JOIN domains ON where \"" AND mail.mail_name="xyz");

Now, delete the email name ‘xyz’ from the ‘mail’ table (replace ‘ID’ with the id retrieved from the first query)

mysql> delete from mail where dom_id='ID' AND mail_name='xyz';

Once done, restart the Mysql service and you will be able to remove the email account from the Plesk control panel.

How to install and configure APC Cache on a CentOS server?

December 18, 2010    |   Posted by admin   |    Category: Installations

APC cache is a PHP caching solution which stands for Alternative PHP Cache. It serves PHP pages from a cache thus helping to reduce server load. APC is an open source software and is updated from time to time.

The following are the steps to install APC cache on a cPanel / Plesk OR even on a plan CentOS server:

1) SSH to your server and go to a temporary directory

# cd /usr/local/src

2) Download the latest APC version

# wget

3) Unpack the version and change to the APC directory

# tar -zxf APC-3.1.6.tgz 
# cd APC-*

4) Create configuration files

# phpize

5) Search for the “php-config” file since you need to configure APC with it

# which php-config

6) Now, configure APC

# ./configure --enable-apc --enable-apc-mmap --with-apxs\

7) Create the installation files and install APC

# make 
# make install

Now that the APC cache is installed on your server, the final step is to activate the APC extension in the php.ini file.

Locate the working php.ini file of your server

# php -i | grep php.ini

edit the file and search for “extension_dir” and place the following code below it (tweak the values as per your requirement):


Restart the Apache web server  for changes to take affect. To confirm if APC is activated, execute

# php -i | grep apc

Note: once APC is installed, make sure the ‘’ file is created under the directory specified at the “extension_dir” in php.ini. If not, look for the exact path of the file and create a symlink under it.

List of path to various log files in Plesk

December 11, 2010    |   Posted by admin   |    Category: Plesk Management

Following is the list of path to different log files on a Plesk server.

Plesk Installation Logs:


Plesk Upgrade Logs including other applications:


Plesk Access and Error Logs:


Plesk Migration Logs:


WatchDog Logs on Plesk:


Apache Web Server Logs on Plesk:


Apache Suexec Logs on Plesk:


Access and Error Logs of a Website (account):


Mysql Logs on Plesk:

/var/lib/mysql/server.hostname.err  (unless defined in /etc/my.cnf)

Named (Bind) Logs on Plesk:


Mail (Qmail and Postfix) Logs on Plesk:


Ftp Logs on Plesk:


Server Logs on Plesk:


Horde Logs:


Cronjob Logs:


SSH Logs:


Mailman Logs:


Tomcat Logs:


Starting sshd: Missing privilege separation directory: /var/empty/sshd

December 5, 2010    |   Posted by admin   |    Category: Linux Administration

The SSHD service while restarting, looks for the “/var/empty/sshd/etc” directory which contains a symlink to the ‘localtime’ file. If the file doesn’t exist, it results in a “cannot create symbolic link `/var/empty/sshd/etc’: No such file or directory” error message.

The complete error message is as follows:

-bash-3.2# service sshd restart 
cp: cannot create symbolic link `/var/empty/sshd/etc': 
No such file or directory 
Starting sshd: Missing privilege separation: /var/empty/sshd [FAILED]

The solution is to create the “/var/empty/sshd/etc” directory and then create a symlink for localtime file.

# mkdir /var/empty/sshd/etc
# cd /var/empty/sshd/etc
# ln -s /etc/localtime localtime

Once done, you should be able to restart the sshd service.