Using WordPress 5.4 and CiviCRM Version 5.18.4. CiviMail has been working fine, mostly, using Mail(). This problem is seen when sending mail to an individual from their contact page, or when sending a test mail of what will hopefully be a bulk mailing.

One particular email message fails to send. It is fairly long, and the content is fairly complex, with lots of links and some standard html formatting.

When sending, I get either "An error occurred when CiviCRM attempted to send an email (via SMTP). ... The mail library returned the following error message: mail() returned failure" OR (if a "test" mailing) "Could not identify any recipients. Perhaps the group is empty?"

I searched the html source for anything weird, but found nothing. I can send the entire content in small pieces, but when I put them all together, it fails. I can send the entire content as plain text. It's possible that there is some other reason for the odd pattern of failures, but "too much content" or "too many links" seems like a possible one. But I don't see anything about it in documentation.

Has anyone seen something like this? Any other troubleshooting steps you can suggest to pinpoint the problem? Thanks!

  • "I can send the entire content in small pieces" do you mean you successfully sent part of mailing out to the group? just to rule out the problem relating to the Group itself
    – petednz - fuzion
    Apr 30 '20 at 20:41
  • No, I mean broke the text of the message into pieces. Well, actually I deleted large portions of the email before sending the test message, and it sent the smaller version ok to the test recipient(s). I would try again, removing a different portion of the content, and it would still go out OK, until I had sent every word of the message successfully. But send the whole message? Error.. Apr 30 '20 at 22:26
  • so the error is even when sending Test msg?
    – petednz - fuzion
    May 1 '20 at 2:07
  • Yes, either when sending the message to individuals from their Contact screen, OR when preparing a draft bulk mailing and sending a test message (to one person or a small test group. For what it is worth, I eventually gave up and edited down the message until it was smaller and had fewer links, and now it seems to send out ok. I would still very much like to know if this limitation is known to exist. Could it be a "timing out" issue? May 2 '20 at 2:10
  • and you are sure it is the number of links rather than the overall length? ie if you send out a msg with just as many actually characters but with fewer links does it work? (as in count the characters of the 'source' of the mail so it includes all the html characters too)
    – petednz - fuzion
    May 3 '20 at 5:10

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.