Hello Everybody!
My roundcube installation (1.2.4) was running fine for a very long time, but I thought an update would be in order, so I upgraded to 1.4.1.
Now SMTP refuses to work. I understand that Roundcube now uses SMTP instead of the old php-Mail function. However, after searching through half the internet, I can't get it to work and always get "SMTP Error (-1): Connection to server failed."
- SMTP is working on the machine (Debian 10, running postfix on localhost as the IMAP server is, too), and accepts mail, from localhost even without authentification. There are no errors in the mail log.
- Roundcube is working, just not sending mail.
I added this to config.inc.php:
$config['smtp_server'] = '127.0.0.1';
No success. As some report it working, I experimented with additional settings:
$config['smtp_port'] = 25;
$config['smtp_user'] = '%u';
$config['smtp_server'] = '%p';
No success, though. The error the Roundcube log gives me is:
[25-Nov-2019 19:38:38 America/Chicago] PHP Warning: count(): Parameter must be an array or an object that implements Countable in /var/www/roundcube/vendor/pear-pear.php.net/Mail_Mime/Mail/mimePart.php on line 314
[25-Nov-2019 19:38:38 -0600]: <lucombsr> PHP Error: php_network_getaddresses: getaddrinfo failed: Name or service not known (POST /roundcube/?_task=mail&_unlock=loading1574732319717&_framed=1&_action=send)
[25-Nov-2019 19:38:38 -0600]: <lucombsr> PHP Error: Failed to connect socket: php_network_getaddresses: getaddrinfo failed: Name or service not known (POST /roundcube/?_task=mail&_unlock=loading1574732319717&_framed=1&_action=send)
[25-Nov-2019 19:38:38 -0600]: <lucombsr> SMTP Error: Connection failed: Failed to connect socket: php_network_getaddresses: getaddrinfo failed: Name or service not known in /var/www/roundcube/program/lib/Roundcube/rcube.php on line 1689 (POST /roundcube/?_task=mail&_unlock=loading1574732319717&_framed=1&_action=send)
Searching for those error messages did not yield much useful, either. It somehow fails on a network lookup (that's why I replaced 'localhost' with the IP), but did not change anything. Is there a php module missing or something?
Any ideas where I might have to look for?
Thanks!