Invalid Domain Key (DKIM) Fix

Issue: After troubleshooting a cPanel server for email deliverability, it’s found that the DKIM key is invalid, When keys are generated, the hash creates the public key (placed in DNS records), and the server retains the private key. Sometimes the records can be edited, leaving the keys invalid.

Solution: Regenerate the DKIM keys.

Establish an SSH session and issue the following two commands:

/usr/local/cpanel/bin/dkim_keys_uninstall <account_name>
/usr/local/cpanel/bin/dkim_keys_install <account_name>

Obviously change “<account_name>” to that of the actual name of the cPanel account

Then ensure the DNS zone displays the correct default._domainkey (DKIM) key

Leave a comment

BlogLogistics