cpanel accounts not receiving email
Good afternoon, I have a problem on my server that after an automatic migration attempt stopped receiving email, but I managed to find out that it has a target.
the following command solved my problem: whmapi1 unset_manual_mx_redirects domain='exemple.com'
but I need to apply this command to all domains on my server, can anyone tell me how I can apply this command to all domains on my server
thank you all in advance for the support
-
Hi, since the manual mx data is stored in the file /etc/manualmx, I think removing entries from the file will fix it, or if you need to remove all you can simply null the file with command > /etc/manualmx
But ofcourse take a backup of the file always before doing. Or if you need to run command for all domains, following will workfor i in $(cat /etc/userdomains | cut -d : -f1 | grep -v "nobody"); do echo doing $i; whmapi1 unset_manual_mx_redirects domain="$i" ; done;0 -
Thanks for the for-loop - that's what I would have recommended in this case. 0
Please sign in to leave a comment.
Comments
2 comments