0
I have a domain on shared hosting, which has a Drupal site and the domain's mail accounts.
Two years ago I built a PHP web application using the Laravel framework which sends email. The application runs on a separate VPS but the app URL is a subdomain of the shared hosting domain. The nameservers for the subdomain are at the shared hosting. The mail server is on the primary domain.
Instead of installing a mail server on the Ubuntu VPS I configured the application to use the shared hosting mail server with smtp to send the mail. There is a mail account on the shared hosting mail which the web app uses to connect to the mail server using SMTP to send mail. It worked fine, delivering mail to the local domain and any other domain like gmail, hotmail, and so on.
It looked like this
Shared Hosting
www.mydomain.com (Example IP 100.100.100.10)
mail.mydomain.com (Example IP 100.100.100.10)
VPS
webapp.mydomain.com (Example IP 200.200.200.10)
Then the shared hosting provider announced that they were moving the domain to a new server and creating new nameservers. This was supposed to be transparent to the users - "you don't have to do anything".
However of course the nameserver change needed to be made on the domain registration because as soon as they turned off the old server the stuff hit the fan.
Now it looks like
Shared Hosting
www.mydomain.com (Example IP 300.300.300.10)
mail.mydomain.com (Example IP 300.300.300.10)
VPS
webapp.mydomain.com (Example IP 200.200.200.10)
The issue I am looking for help with here is that the web application can no longer send mail using the shared hosting mail server to any addresses EXCEPT the server domain. If I send to person at mydomain dot com the message is delivered. If I send to a gmail address the message is not delivered. Not delivered for outlook, hotmail, and any other domain.
I don't get an error in any logs on the web app side, so I'm connecting to the mail server. But the messages are never processed.
A mail client (e.g. Outlook 2016) with the exact same parameters CAN send to addresses other than the local domain over the shared hosting mail server. Messages sent from any domain to the local domain on the shared hosting mail server are delivered.
The support people at the shared hosting provider haven't been forthcoming with any of their logs etc. so I can't see exactly what is hitting their server. They don't seem to have a clue what is happening and they are overwhelmed because their little migration lost a month of data from most customers ...
If anyone has any experience with a situation like this and can give me some clues to look for I'd appreciate it.