The removeacct Script
Valid for versions 96 through the latest version
Version:
96
Last modified: February 18, 2021
Looking for this interface?
Note:
Your hosting provider can enable or disable this interface for resellers in WHM's Edit Reseller Nameservers and Privileges interface (WHM >> Home >> Resellers >> Edit Reseller Nameservers and Privileges).
Overview
The /usr/local/cpanel/scripts/removeacct
script terminates a cPanel account from the command line. You can also use WHM’s Terminate Accounts interface (WHM » Home » Multi Account Functions » Terminate Accounts) to terminate an account.
Warning:
- This script removes all of the information for an account. Make certain that you wish to completely remove the account from your server before you run this script.
- After you use this script to terminate an account, you cannot recreate the account immediately (for example, to restore the account from a backup). A short delay occurs while the system removes the account’s MySQL® users.
Run the script
To run this script on the command line, use the following format:
/usr/local/cpanel/scripts/removeacct [account] [options]
Options
Use the following options with this script:
Option | Description | Example |
---|---|---|
account |
Required. The cPanel account that you want to terminate. | username |
--child-ok |
Force the script to terminate a distributed cPanel account via a child node.
Warning:
You should always terminate accounts from the parent node. Only use this option in an emergency.
|
--child-ok |
--force |
Skip the script’s confirmation prompt and terminate the account. | --force |
--keep-remote-databases |
Keep the account’s remote databases and users on the server after account termination, if any exist. | --keep-remote-databases |
--keepdns |
Keep the account’s zone files on the DNS server after account termination. | --keepdns |
--help |
Display the script’s help documentation. | --help |