I have deployed mail server in the intranet. Whenever I try to send email from my corporate email server, the mail does not get delivered. Gives error like IP not found. But when I deploy mail server on DMZ (cloud), it works.
So when both corporate email server & my test mail server are in same intranet, why the email gets bounced?
Check DNS MX record for the domain from the email address used in To: field. The sending server will try to deliver your email to one of the MX-servers first.