postfix doesn't resolve host name

  • Hi,


    The notifications only works if I set ip address of the smtp server. If i use the host name it fails like below


    suspended: Host or domain name not found. Name service error for name=smtp.aaa.com type=MX: Host not found, try again)


    Any ideas?

    • Offizieller Beitrag

    Do you have a dns server set in network settings?

    omv 7.0.4-2 sandworm | 64 bit | 6.5 proxmox kernel

    plugins :: omvextrasorg 7.0 | kvm 7.0.10 | compose 7.1.2 | k8s 7.0-6 | cputemp 7.0 | mergerfs 7.0.3


    omv-extras.org plugins source code and issue tracker - github


    Please try ctrl-shift-R and read this before posting a question.

    Please put your OMV system details in your signature.
    Please don't PM for support... Too many PMs!

    • Offizieller Beitrag

    It is a dns issue. Can you ping a different domain? ping -c 2 www.google.com

    omv 7.0.4-2 sandworm | 64 bit | 6.5 proxmox kernel

    plugins :: omvextrasorg 7.0 | kvm 7.0.10 | compose 7.1.2 | k8s 7.0-6 | cputemp 7.0 | mergerfs 7.0.3


    omv-extras.org plugins source code and issue tracker - github


    Please try ctrl-shift-R and read this before posting a question.

    Please put your OMV system details in your signature.
    Please don't PM for support... Too many PMs!

  • yes...I can ping host names.
    I can even ping the host name of the smtp server without problem.
    And traceroute goes through without problems too. All working with host names.


    Just postfix won't work with the name but only with the ip :(

    • Offizieller Beitrag

    Maybe it is giving a inaccurate error. Does you ISP block the port you are using? Mine does (charter).

    omv 7.0.4-2 sandworm | 64 bit | 6.5 proxmox kernel

    plugins :: omvextrasorg 7.0 | kvm 7.0.10 | compose 7.1.2 | k8s 7.0-6 | cputemp 7.0 | mergerfs 7.0.3


    omv-extras.org plugins source code and issue tracker - github


    Please try ctrl-shift-R and read this before posting a question.

    Please put your OMV system details in your signature.
    Please don't PM for support... Too many PMs!

    • Offizieller Beitrag

    If it was a config issue, wouldn't it affect all OMV systems ability to resolve a domain name? The only postfix config file that OMV writes is /etc/postfix/main.cf. Here is mine that works well. Compare it to yours.


    Code
    root@server:/etc/postfix# cat main.cf
    mydestination =
    inet_interfaces = loopback-only
    relayhost = smtp.charter.net:25
    sender_canonical_maps = hash:/etc/postfix/sender_canonical
    recipient_bcc_maps = hash:/etc/postfix/recipient_bcc
    smtp_generic_maps = hash:/etc/postfix/generic
    smtp_header_checks = regexp:/etc/postfix/smtp_header_checks

    omv 7.0.4-2 sandworm | 64 bit | 6.5 proxmox kernel

    plugins :: omvextrasorg 7.0 | kvm 7.0.10 | compose 7.1.2 | k8s 7.0-6 | cputemp 7.0 | mergerfs 7.0.3


    omv-extras.org plugins source code and issue tracker - github


    Please try ctrl-shift-R and read this before posting a question.

    Please put your OMV system details in your signature.
    Please don't PM for support... Too many PMs!

  • I think I got a step futher


    root@openmediavault:~# host -t mx gmail.com
    gmail.com mail is handled by 40 alt4.gmail-smtp-in.l.google.com.
    gmail.com mail is handled by 30 alt3.gmail-smtp-in.l.google.com.
    gmail.com mail is handled by 5 gmail-smtp-in.l.google.com.
    gmail.com mail is handled by 10 alt1.gmail-smtp-in.l.google.com.
    gmail.com mail is handled by 20 alt2.gmail-smtp-in.l.google.com.
    root@openmediavault:~#


    but the same for my smtp server gives :


    root@openmediavault:~# host -t mx smtp.aaa.com
    smtp.aaa.com has no MX record
    root@openmediavault:~#

    • Offizieller Beitrag

    Did you just setup your mx record?

    omv 7.0.4-2 sandworm | 64 bit | 6.5 proxmox kernel

    plugins :: omvextrasorg 7.0 | kvm 7.0.10 | compose 7.1.2 | k8s 7.0-6 | cputemp 7.0 | mergerfs 7.0.3


    omv-extras.org plugins source code and issue tracker - github


    Please try ctrl-shift-R and read this before posting a question.

    Please put your OMV system details in your signature.
    Please don't PM for support... Too many PMs!

Jetzt mitmachen!

Sie haben noch kein Benutzerkonto auf unserer Seite? Registrieren Sie sich kostenlos und nehmen Sie an unserer Community teil!