Many email messages are sent from PHP scripts on a Plesk server. How to find domains on which these scripts are running if Postfix is used?

Follow

Comments

7 comments

  • Avatar
    Witawat Piyarattanavong (Edited )

    i not see data in mail.send 

    0
    Comment actions Permalink
  • Avatar
    Ivan Postnikov

    Hello @Witawat,

    In case the provided steps were done correctly, the cause of such behavior is that there were no messages sent by a script.

    0
    Comment actions Permalink
  • Avatar
    Bjorn Joosen (Edited )

    Followed steps 1-4, send multiple mails through phpmailer, mail.send stays empty.
    Need a solution to monitor ALL outgoing mail..

    Plesk 17.8.11 Update #38
    Postfix 2.10.1

    0
    Comment actions Permalink
  • Avatar
    Anton Maslov

    @Bjorn, the method from this article works in case mail sent through mail() function which uses /usr/bin/sendmail binary (on Plesk it is link to Postfix). phpmailer has own SMTP server implementation by PHP code, it does not use mail server installed on OS, thus it is not possible to track such messages.

    The only way is to block all mail that goes not through Postfix by iptables (see additional information section).

    0
    Comment actions Permalink
  • Avatar
    Bjorn Joosen

    @Anton, Thanks for your quick reply, I opened a forum post: https://talk.plesk.com/threads/microsoft-mail-servers-keep-blacklisting-server-ip.351225/

    0
    Comment actions Permalink
  • Avatar
    Justin Lnch (Edited )

    I set this up but when I do a test from Joomla on Centos to use Sendmail as the mailer nothing shows in the log and I receive the email.

    My sendmail points here
    /usr/sbin/sendmail -> /etc/alternatives/mta

    But I do see this
    /usr/sbin/sendmail.postfix -> /usr/sbin/sendmail.postfix-wrapper
    /usr/sbin/sendmail.postfix-bin -> /usr/lib64/plesk-9.0/sendmail/sendmail.postfix

    I get this when checking alternatives
    # alternatives --display mta |grep sendmail
    link currently points to /usr/lib64/plesk-9.0/postfix-sendmail-wrapper
    /usr/sbin/sendmail.postfix - priority 30
    slave mta-sendmail: /usr/lib/sendmail.postfix
    slave mta-sendmailman: /usr/share/man/man1/sendmail.postfix.1.gz
    /usr/lib64/plesk-9.0/postfix-sendmail-wrapper - priority 90
    slave mta-sendmail: /usr/lib64/plesk-9.0/postfix-sendmail-wrapper
    slave mta-sendmailman: /usr/share/man/man1/sendmail.postfix.1.gz
    Current `best' version is /usr/lib64/plesk-9.0/postfix-sendmail-wrapper.

    Any ideas?

    1
    Comment actions Permalink
  • Avatar
    Anton Maslov

    Justin if message goes using Plesk server you should see entries in /var/log/maillog. I suggest to do this:

    1. Monitor log in real time:

    tail -fn0 /var/log/maillog

    2. Send message, you should see entries in maillog for any possible errors in attempt to save to /var/tmp/mail.send

    0
    Comment actions Permalink

Please sign in to leave a comment.

Have more questions? Submit a request