Terminating cPanel accounts that has been suspended for X days
Hello,
i found good looking bash scripts that can help terminate cpanel accounts that has been suspended for more than X days.
I wanted to ask if following command is safe and will list only accounts that has been inactive/suspended for more than 60 days?
find /var/cpanel/suspended/ -mtime +60
If it is safe to terminate each account found by that command. Im OK with terminating accounts that are non-temporarily suspended for more than 60 days.
Thank you
-
Hello The best way to do this management is through a billing solution, such as WHMCS, for example. See more: https://cpanel.com/account_automation_solutions/ 0 -
Hello, I wouldn't terminate accounts based on the output of that command because the product is not designed with the idea that users might terminate accounts based on the files within that directory. A new version of cPanel could theoretically change the way that directory works and result in the termination of accounts you don't want terminated. Instead, a third-party solution such as WHMCS is recommended. Thank you. 0 -
Im having WHMCS but can't find any bundled function or free addon for doing this bulk termination. If /var/cpanel/suspended/ do not contain sure fire key for deleting old suspended accounts, which files on WHM server can give me data on which i can base termination of long suspended accounts? I can create simple bash script, just need to know where are data on which i can base it. If WHM suspended accounts page contains checkboxes and select all option, i could be sorting according to suspension date and buk delete. 0 -
SUSPENDTIME seems to be there even for active (not suspended) cpanels but suspended cpanels seems to always have SUSPENDED=1 line (bandwidth suspended does not have this line) Here is the bash script that is using Michael's method/advice to discover old suspended cpanels and terminate them. 0
Please sign in to leave a comment.
Comments
5 comments