Manually removing the domains from plesk – when plesk frontend don’t work

Tags: domain removalPlesk

Published on: June 22, 2010 by George K.

Manually removing the domains from plesk – when plesk frontend don’t work


Could be a bug with Plesk 9.5 version. But Plesk 9.5 is giving issues once in a while in deleting the domains which are “partially” created. Let us see how Plesk remove domain manually can be done.


DNS zones are never created, and the DBs are not properly updated. Even after reconfiguring the domains using websrvmng.exe –reconfigure-vhost –vhost-name =”” it couldn’t be deleted. Shows the message “Information: Domains are now removed”, but in real, the domain will be still shown under the domains list.

And the domain will be in suspended state. Unsuspension of the domain will result in an error message “DNSZone::Table::select() failed: no such row in the table”

Solution for the above issue is explained at

However even after fixing the DNS like this, the issue cycles.

Removal of domain results in suspension of domain -> Unsuspension of domains results in above error -> Fixing the error allows to unsuspend and Removal of domain results in suspension of domain 😀


So solution I used to solve was to manually remove the domain related entries from plesk database, from the file system and also from the email services. Get into MySQL or whichever DB plesk is using. For finding the current DB, use Plesk Reconfigurator and then follow the parallels KB found at

The instructions below assumes that you are using Mailenable and Plesk vhosts directory is at “C:\Inetpub\Vhosts” . This location can be at D:\ or E:\ even. Also, I hereby assume that there are no two domains which can match the mysql LIKE query I used below i.e There are no domains like , along with actual If there is one, please use your “brain” to find the right domain and the IDs associated with it. When in doubt, please comment.

Disclaimer : If you mess up the database neither me or SS will be responsible for it 🙂

Let’s first gather all the ‘id”s first, like dom_id, sys_user_id, id etc which will be helpful in the deletion of database entries relating to the domain name which you want to removed.

1. Getting the IDs.

Domain ID – dom_id or id

 mysql> SELECT id FROM domains where name=’’

We are assuming that dom_id you got as a result of above command is 8880

Database ID – db_id

mysql> select id FROM data_bases where dom_id=(SELECT id FROM domains where name=’’);

We are assuming that db_id you got as a result of above query is 1433. Please note that you could get more than one result. Please save all the db_id and re-execute the sql query for each db_id.

System User IDsys_user_id

mysql> select id FROM sys_users where home like '';

We are assuming that sys_user_id you got as a result of above command is 8843

Let’s start the actual deletion process

Shall we backup ? Better be safe!

C:\Program Files (x86)\Parallels\Plesk\Databases\MySQL\bin>mysqldump -P8306 -uadmin -p<plesk DB admin pass> psa > c:\psa.sql

You are now ready to delete. Please execute the follow sql commands in mysql prompt

delete from db_users where db_id='1433';
delete from data_bases where dom_id='8880';
delete from mail where id='8880';
delete from subdomains where id='8880';
delete from dns_recs where id='8880';
delete from domains where id='8880';
delete from domain_aliases where dom_id='8880';
delete from hosting where sys_user_id='8843';
delete FROM sys_users where id='8843';
delete from dns_zone where displayName=’’;

Database entries are deleted. Now it’s time to remove the users and files from the filesystems, IIS, Server, Mail server, DNS server etc.

  1. Remove the domain from inetpub -> vhosts
  2. Remove from Mail Enable Administrator. If it is SmarterMail, follow other steps.
  3. Start => run => mailenable.msc => Post Offices and remove it.
  4. Remove Sites “” and “Application Pool” from Internet Information Services manager. If IIS7, use command line option => %systemroot%\system32\inetsrv\APPCMD.EXE delete site “” .
  5. Remove from Computer management Console –  System Tools > Local Users and Groups > Users. You must remove references to the domain for Plesk Domain User and Plesk IIS User as well.
  6. Remove DNS entry – depending on the DNS server.


cd %plesk_bin%
domain.exe -r

These steps should help remove the domain manually from the plesk. Please note that this article is based on the second attempt and could be buggy. I assume some “common sense” when running these commands. Understand the commands and each step before you actually execute it. Good luck. Don’t MESS up!!

Category : Howtos, Linux, Plesk, Troubleshooting

George K.

George K.

George started his career in web hosting and Linux technical support in the year 2004 and is with SupportSages since 2009. He has keen interest in server optimizations, custom security solutions, hacked server recovery, cyber forensic and high availability fail over system design and implementation. George loves long drives and is passionate about art and literature.

You may also read:


Add new commentSIGN IN

Let's Connect


Your Cart

Cart is empty.

Send this to a friend