Error: Invalid response code received from server - when trying to send email to contacts.If you get an error of "Invalid response code received from server" when trying to send email(s) to CiviCRM contact(s), OR after submitting the Confirmation page when making an online contribution, OR after submitting the Confirmation page when registering for an event:
NOTE: This error is generally displayed in a big "dump" on the page like this: error
Array
(
\[callback\] => Array
(
\[0\] => CRM_Core_Error
\[1\] => handle
)
\[code\] =>
\[message\] => Invalid response code received from server
\[mode\] => 16
\[debug_info\] =>
\[type\] => pear_error
\[user_info\] =>
\[to_string\] => \[pear_error: message="Invalid response code received from
server" code=0 mode=callback callback=CRM_Core_Error:
:handle prefix=""
info=""\]
)
|
Labels

1 Comment
Hide/Show CommentsNov 17, 2008
Dave Jenkins
I have found another scenario where this error can occur: if the recipient domain has no valid MX record. You can investigate what's happening by setting $_debug to true in civicrm/packages/Net/SMTP.php . Here's an example, with addresses disguised:
DEBUG: Send: MAIL FROM:<me@valid.domain>
DEBUG: Recv: 250 2.1.0 Ok
DEBUG: Send: RCPT TO:<them@invalid.domain>
DEBUG: Recv: 450 4.1.2 <them@invalid.domain>: Recipient address rejected: Domain not found
The problem is that Civi aborts the whole mailout at this point so if you're sending to multiple contacts, it will fall over at the first invalid domain. This is with Civi 1.8.11248, mail server is Postfix 2.3.3 .