How wildcard MX Record

how to configure wildcard in MX record I have synology mail plus server but I don’t want to be adding name every time I want to create a new email thank you for your help

You’d never need to add MX records for each email address unless you’re putting emails on subdomains, i.e foo.example.org will need it’s own MX servers on foo since it won’t inherit them from example.org

Whilst theoretically they’re a thing (see RFC 1912: Common DNS Operational and Configuration Errors), I wouldn’t really recommend doing it.

I’m new to this I hope you have patience my configuration is this

A–domain(@)—ip server

rcname—mail----ip server

rMX—@----email.domain.com

rMX—@—mail.domain.com

Every time I add an email I have to add an MX record

rMX—@—1.domain.com

rMX—@—2.domain.com

etc

1 Like

Your question is unclear. (If English is not your native language, you can try and let the translator built into the community do the translation).

Do the email addresses take the form of [email protected] or [email protected]?

If it is [email protected], then there is only one MX needed, and it should point to the A record for your mail server.

example.com MX mail.example.com
mail.example.com A 192.0.2.1

If it is the subdomain example, then you are better off creating individual MX records for each subdomain. This is because of the way wildcards work. Take this configuration for example:

example.com A 192.0.2.1
www.example.com A 192.0.2.1
mail.example.com A 192.0.2.1
example.com MX mail.example.com
mail2.example.com A 192.0.2.2
*.example.com MX mail2.example.com

It looks like you want mail for [email protected] to be sent to mail2, but it will not. This is because the A record for alice exists, so the wildcard MX will not be used. Mail for [email protected] will use the wildcard MX, as no matching A record exists.

2 Likes

already solved

I just had to add

-A—@—server ip

-MX–@----mail+domain.com

cname—mail—server ip

in synology I only add emails

[email protected]
[email protected]
[email protected]
[email protected]

and i can receive mail

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.