Mass delete e-mail accounts script
I had a customer who moved a domain to Google's MX servers, and needed the old accounts removed from his system.
The only "good" search result on google for this was this very old thread I can no longer post in:
/tmp/acctlist
if [ -s /tmp/acctlist ]
then
for each in `cat /tmp/acctlist` ; do /scripts/delpop --email=$each@$domain ; done
else
echo "no accounts found or other error. Check $maildir/shadow"
exit 1
fi
rm -f /tmp/acctlist
#thats all folks
-
Hello :) Thank you for sharing this workaround. Please note that user-submitted workarounds are not tested or supported by cPanel. We encourage everyone to review all aspects of workarounds before implementing them on a production server. Thank you. 0
Please sign in to leave a comment.
Comments
1 comment