I said that php mail function works, the problem is that the email is not delivered. No error in log filesHow do you know that mail() isn't working? Did you check /var/log/maillog (/var/log/mail.log) to see that the mail is not sent? In that case PHP should show an error mesage in /logs/error_log (/logs/error.log). So either way, did you actually prove that the mail is not being sent?
Tell me what kind of info do you need, I'll try to supplyNeed. More. Info.
this is the maillog content"Not delivered" does not mean "not sent". It is crucial to know whether the e-mail is placed into the mail out queue. Try to find it in /var/log/maillog (/var/log/mail.log), because there you can normally see what the mail server is doing with it. You can normally find it by searching for the recipient address, e.g.
# grep "<recipient address here>" /var/log/maillog
and then read the unique processing id (e.g. B1D992A98722F9) and displaying all entries of that id like
# grep "<unique processing id>" /var/log/maillog
Ok, sorry I understand better now:If the commands are given correctly, the grep search phrase must be part of the output. In the case shown above it is not, hence the commands were not entered correctly.
For example
# grep 6544 /var/log/maillog
could possibly yield the output shown above. But where is the recipient address in this? This does not seem to be linked to mail sending attempts.
the mailbox is not localDo you see more details when doing
# grep 12569 /var/log/maillog
?
It does not look wrong, rather that the mail is being delivered to the local mailbox.
ok, I understand better. On my server with Plesk I had different domain.the mailbox is not local
Thanks for help, you was very usefull. I fix my issue. Have a nice dayIs the mailbox [email protected] located on the same host that is sending the mail? In that case mail will be delivered to the local mailbox. It will not leave the server.