DNS Zone templates edition ('bad dotted quad' error)
Hello,
I'm trying to edit DNS Zone Templates for all new hosting accounts. I want to change the default cPanel DNS configuration for MX records so as to get the following
Being, of course,
and
I made this code but it doesn't work:
But I get this error: near 'domain.com.': bad dotted quad What's the correct syntax? Regards,
mail IN A 1.2.3.4
example.com. IN MX 0 mail.example.com.
_dmarc TXT "v=DMARC1;p=none;sp=none;adkim=r;aspf=r;pct=100;fo=0;rf=afrf;ri=86400;rua=mailto:postmaster@example.com;ruf=mailto:postmaster@example.com"
Being, of course,
%ip% = 1.2.3.4and
%domain% = example.comI made this code but it doesn't work:
; cPanel %cpversion%
; Zone file for %domain%
$TTL %ttl%
@ %nsttl% IN SOA %nameserver%. %rpemail%. (
%serial% ; serial, todays date+todays
3600 ; refresh, seconds
1800 ; retry, seconds
1209600 ; expire, seconds
86400 ) ; minimum, seconds
%domain%. %nsttl% IN NS %nameserver%.
%domain%. %nsttl% IN NS %nameserver2%.
%domain%. %nsttl% IN NS %nameserver3%.
%domain%. %nsttl% IN NS %nameserver4%.
%nameserverentry%. IN A %nameservera%
%nameserverentry2%. IN A %nameservera2%
%nameserverentry3%. IN A %nameservera3%
%nameserverentry4%. IN A %nameservera4%
%domain%. IN A %ip%
%domain%. IN AAAA %ipv6%
ipv6 IN AAAA %ipv6%
mail.%domain%. IN A %domain%.
%domain%. IN MX 0 mail.%domain%.
www IN CNAME %domain%.
ftp IN CNAME %domain%.
_dmarc IN TXT v=DMARC1\;p=quarantine\;sp=none\;adkim=r\;aspf=r\;pct=100\;fo=0\;rf=afrf\;ri=86400\;rua=mailto:postmaster\@%domain%\;ruf=postmaster\@%domain%But I get this error: near 'domain.com.': bad dotted quad What's the correct syntax? Regards,
-
My bad! I should have used the IP for the A record, instead of a domain name. mail.%domain%. IN A %domain%.
should be:mail.%domain%. IN A %ip%0 -
I'm glad you got this resolved! 0
Please sign in to leave a comment.
Comments
2 comments