Skip to main content
All CollectionsGeneral
Delete WHM account completely
Delete WHM account completely
Antonio avatar
Written by Antonio
Updated over a year ago

To completely delete an account in WHM, you must check the following points.

User account in cPanel

It is possible that the user in cPanel has been left saved. To delete it, as always, we will access WHM > Account Functions > Terminate an account

Entries for the user in /etc/passwd

Within the /etc/passwd file, residues of the user may remain. To delete it, we will only have to edit it and search for the last line, which will correspond to our new user.

nano /etc/passwd

User home directory

Sometimes, even if the copy fails, the home directory for the user remains created, so it is not possible to try the copy again.

To delete their home directory, we will run the following command:

rm -dfr /home/user

DNS zone of the domains

It is also very likely that DNS zones have been created for the domains. So we will have to delete them from WHM > DNS Functions > Delete a DNS zone

User group

The user's file group may have been saved. To delete it:

groupdel user

Delete entries from the httpd.conf file

Finally, we will have to edit the httpd.conf file and delete the virtualhost for the domain:

nano /usr/local/apache/conf/httpd.conf

Did this answer your question?