[Postfix] Mail is delivered but get a second email with error

May 24, 2014 1.2k views
Hello, I configured postfix on my server, but when I send an email to contato@ogreshop.com I get 2 emails, the email I sent and another email with delivery error. I tried many solutions without success. The error email that I receive is the following: Delivery to the following recipient failed permanently: contato@ogreshop.com.br Technical details of permanent failure: Google tried to deliver your message, but it was rejected by the server for the recipient domain ogreshop.com.br by ogreshop.com.br. []. The error that the other server returned was: 554 5.7.1 : Relay access denied ----- Original message ----- DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:date:message-id:subject:from:to:content-type; bh=1JSx+tl94xnwAQuarHMzqfRomO90igRwu+obuFLXQo8=; b=gLCjklu3Ll/HnbllLxF+XRYy7rhIy0b/fPtx3ptg8wDE0b0yAAaa9OUP7YRPm6kkaY R3ROBZ+X5Z6mp/xxlJdmjrkKgUkRc+0BPK/kQSZRyxKx+jvOAXR3QXWMEGPQlkh1Uvxr iu402iUyZ3d0EUhU8dabX0qD/fk8LV8fSUh+ef7qHsKJixz7OBmfj1ahGAdBN+3S9R8d GN1+VEO79Dh81iLuC3O6QkqDl5zuGU4j2J83019eNY2ARLOJARpGGzpLI1A+uW0+PQ/H LEC6+fiRH+XYayNh2ZNMs7OCFIN97igFUIfrE/dJNQR333HOD61Ic/lsEjk/A3N3o2AW uW6g== MIME-Version: 1.0 X-Received: by with SMTP id y16mr802326ico.94.1400939831656; Sat, 24 May 2014 06:57:11 -0700 (PDT) Sender: renatofrancarpmf@gmail.com Received: by with HTTP; Sat, 24 May 2014 06:57:11 -0700 (PDT) Date: Sat, 24 May 2014 10:57:11 -0300 X-Google-Sender-Auth: IkMOuFtVZ0lEbPqAItzHCWVdoD0 Message-ID: Subject: Teste From: =?UTF-8?Q?Renato_Fran=C3=A7a?= To: contato@ogreshop.com.br Content-Type: multipart/alternative; boundary=20cf304275be04886304fa25b9bd Thanks, Renato França
2 Answers
What configuration have you done to the DNS?
Also can you post /etc/postfix/main.cf?
Hello Marinos,

I did not change the DNS for email.

Here the /etc/postfix/main.cf:

# See /usr/share/postfix/main.cf.dist for a commented, more complete version

# Debian specific: Specifying a file name will cause the first
# line of that file to be used as the name. The Debian default
# is /etc/mailname.
#myorigin = /etc/mailname

smtpd_banner = $myhostname ESMTP $mail_name (Ubuntu)
biff = no

# appending .domain is the MUA's job.
append_dot_mydomain = no

# Uncomment the next line to generate "delayed mail" warnings
#delay_warning_time = 4h

readme_directory = no

# TLS parameters
smtpd_tls_session_cache_database = btree:${data_directory}/smtpd_scache
smtp_tls_session_cache_database = btree:${data_directory}/smtp_scache

# See /usr/share/doc/postfix/TLS_README.gz in the postfix-doc package for
# information on enabling SSL in the smtp client.

myhostname = localhost
alias_maps = hash:/etc/aliases
alias_database = hash:/etc/aliases
mydestination = batmail, ogreshop
relayhost =
mynetworks = [::ffff:]/104 [::1]/128
mailbox_size_limit = 0
recipient_delimiter = +
inet_interfaces = all
virtual_alias_maps = hash:/etc/postfix/virtual

Thanks for the help!
Have another answer? Share your knowledge.