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


I configured postfix on my server, but when I send an email to 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:

Technical details of permanent failure: Google tried to deliver your message, but it was rejected by the server for the recipient domain by [].

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;; 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: 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: Content-Type: multipart/alternative; boundary=20cf304275be04886304fa25b9bd

Thanks, Renato França

Submit an answer

This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

Sign In or Sign Up to Answer

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Want to learn more? Join the DigitalOcean Community!

Join our DigitalOcean community of over a million developers for free! Get help and share knowledge in Q&A, subscribe to topics of interest, and get courses and tools that will help you grow as a developer and scale your project or business.

Hello Marinos, <br> <br>I did not change the DNS for email. <br> <br>Here the /etc/postfix/ <br> <br># See /usr/share/postfix/ for a commented, more complete version <br> <br> <br># Debian specific: Specifying a file name will cause the first <br># line of that file to be used as the name. The Debian default <br># is /etc/mailname. <br>#myorigin = /etc/mailname <br> <br>smtpd_banner = $myhostname ESMTP $mail_name (Ubuntu) <br>biff = no <br> <br># appending .domain is the MUA’s job. <br>append_dot_mydomain = no <br> <br># Uncomment the next line to generate “delayed mail” warnings <br>#delay_warning_time = 4h <br> <br>readme_directory = no <br> <br># TLS parameters <br>smtpd_tls_cert_file=/etc/ssl/certs/ssl-cert-snakeoil.pem <br>smtpd_tls_key_file=/etc/ssl/private/ssl-cert-snakeoil.key <br>smtpd_use_tls=yes <br>smtpd_tls_session_cache_database = btree:${data_directory}/smtpd_scache <br>smtp_tls_session_cache_database = btree:${data_directory}/smtp_scache <br> <br># See /usr/share/doc/postfix/TLS_README.gz in the postfix-doc package for <br># information on enabling SSL in the smtp client. <br> <br>myhostname = localhost <br>alias_maps = hash:/etc/aliases <br>alias_database = hash:/etc/aliases <br>mydestination = batmail, ogreshop <br>relayhost = <br>mynetworks = [::ffff:]/104 [::1]/128 <br>mailbox_size_limit = 0 <br>recipient_delimiter = + <br>inet_interfaces = all <br>virtual_alias_maps = hash:/etc/postfix/virtual <br> <br>Thanks for the help!

What configuration have you done to the DNS? <br>Also can you post /etc/postfix/