PHP generated mails not received in Zoho Mail Dashboard
I am using cloud hosting from Digital Ocean and using PHP to send emails to the website's administrator. This is my Ubuntu Droplet and mail configuration:-
- using PHP (via PHP function mail()) to send emails programatically to admins of the website (www.rakeshsir.com)
- installed Postfix as the send-only mail server
- configured Zoho Mail as the email service where this website's admins login and check the emails my programmed website sends them programatically
- my MX records are as they should be for the use of Zoho Mail
- the email id of the admin of the website are: superadmin@rakeshsir.com
On sending mails via PHP to this email id, I also BCC the same in my personal Gmail id. Interestingly my personal Gmail IDs are receiving this email (in Spam folder), but no mail is received by the superadmin@rakeshsir.com
Now the problem is that when the email is sent, and I being logged in via terminal in the droplet, receives an email on the terminal. I am attaching the received email content below:-
--------------------------mail I receive in terminal--------------------------
Return-Path: <>
X-Original-To: varunk@rakeshsir.com
Delivered-To: varunk@rakeshsir.com
Received: by rakeshsir.com (Postfix)
id 09EDB8059C; Fri, 3 Feb 2017 22:23:18 +0530 (IST)
Date: Fri, 3 Feb 2017 22:23:18 +0530 (IST)
From: MAILER-DAEMON@rakeshsir.com (Mail Delivery System)
Subject: Undelivered Mail Returned to Sender
To: varunk@rakeshsir.com
Auto-Submitted: auto-replied
MIME-Version: 1.0
Content-Type: multipart/report; report-type=delivery-status;
boundary="88D198059B.1486140798/rakeshsir.com"
Message-Id: <20170203165318.09EDB8059C@rakeshsir.com>
This is a MIME-encapsulated message.
--88D198059B.1486140798/rakeshsir.com
Content-Description: Notification
Content-Type: text/plain; charset=us-ascii
This is the mail system at host rakeshsir.com.
I'm sorry to have to inform you that your message could not
be delivered to one or more recipients. It's attached below.
For further assistance, please send mail to postmaster.
If you do so, please include this problem report. You can
delete your own text from the attached returned message.
The mail system
<superadmin@rakeshsir.com>: unknown user: "superadmin"
--88D198059B.1486140798/rakeshsir.com
Content-Description: Delivery report
Content-Type: message/delivery-status
Reporting-MTA: dns; rakeshsir.com
X-Postfix-Queue-ID: 88D198059B
X-Postfix-Sender: rfc822; varunk@rakeshsir.com
Arrival-Date: Fri, 3 Feb 2017 22:23:15 +0530 (IST)
Final-Recipient: rfc822; superadmin@rakeshsir.com
Action: failed
Status: 5.1.1
Diagnostic-Code: X-Postfix; unknown user: "superadmin"
--88D198059B.1486140798/rakeshsir.com
Content-Description: Undelivered Message
Content-Type: message/rfc822
Return-Path: <varunk@rakeshsir.com>
Received: by rakeshsir.com (Postfix, from userid 1000)
id 88D198059B; Fri, 3 Feb 2017 22:23:15 +0530 (IST)
To: superadmin@rakeshsir.com
Subject: A user tried to purchase a typing test pack but payment failed
X-PHP-Originating-Script: 1000:mailer.php
MIME-Version: 1.0
Content-type:text/html;charset=UTF-8
From: My Notifications <contact@rakeshsir.com>
Message-Id: <20170203165315.88D198059B@rakeshsir.com>
Date: Fri, 3 Feb 2017 22:23:15 +0530 (IST)
A user tried to purchase a typing package but payment failed:
--88D198059B.1486140798/rakeshsir.com--
--------------------------mail I receive in terminal--------------------------
Not able to fix this issue. Please help me fixing this.