Exim4: “Conexão esgotada”, qualquer que seja o servidor SMTP de encaminhamento

1

O Exim é configurado em uma VM recém-provisionada de um provedor de nuvem pública com IPs públicos (scaleway.net)

Propósito:

Ser capaz de enviar e-mails da CLI (ou scripts) para destinatários de destino público (gmail, yahoo, ...)

Resultados:

O arquivo de log Exim4 / var / log / exim4 / mainlog mostra "Tempo limite de conexão" com todos os servidores testados (gmail, free.fr, online.net)

Detalhes da configuração:

lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 16.04.5 LTS
Release:    16.04
Codename:   xenial
  • Nenhum firewall configurado no servidor e nenhuma regra do provedor de nuvem.
  • Os endereços IP dos servidores smtp resolvidos (do arquivo de log exim) são pingáveis.

Testado com diferentes servidores smtp: (gmail, free.fr, online.net)

cat /etc/exim4/update-exim4.conf.conf

# /etc/exim4/update-exim4.conf.conf
#
# Edit this file and /etc/mailname by hand and execute update-exim4.conf
# yourself or use 'dpkg-reconfigure exim4-config'
#
# Please note that this is _not_ a dpkg-conffile and that automatic changes
# to this file might happen. The code handling this will honor your local
# changes, so this is usually fine, but will break local schemes that mess
# around with multiple versions of the file.
#
# update-exim4.conf uses this file to determine variable values to generate
# exim configuration macros for the configuration file.
#
# Most settings found in here do have corresponding questions in the
# Debconf configuration, but not all of them.
#
# This is a Debian specific file

dc_eximconfig_configtype='smarthost'
dc_other_hostnames=''
dc_local_interfaces='127.0.0.1 ; ::1'
dc_readhost=''
dc_relay_domains=''
dc_minimaldns='false'
dc_relay_nets=''
dc_smarthost='smtp.online.net::587'
CFILEMODE='644'
dc_use_split_config='false'
dc_hide_mailname='false'
dc_mailname_in_oh='true'
dc_localdelivery='mail_spool

Contas e senhas configuradas corretamente para cada teste com o servidor smtp:

cat /etc/exim4/passwd.client

#gmail-smtp.1.google.com:[email protected]:pass1
#smtp.online.net:[email protected]:pass2
smtp.free.fr:[email protected]:pass2

root @ scw-5c50c6: ~ # tail -f / var / log / exim4 / mainlog

root@scw-5c50c6:~# tail -f /var/log/exim4/mainlog
2018-10-27 17:32:47 1gGSDM-0002ib-5Y == [email protected] R=smarthost T=remote_smtp_smarthost defer (-53): retry time not reached for any host
2018-10-27 17:32:47 1gGSKT-0002sr-C6 == [email protected] R=smarthost T=remote_smtp_smarthost defer (-53): retry time not reached for any host
2018-10-27 17:32:47 1gGSF6-0002ij-UA == [email protected] R=smarthost T=remote_smtp_smarthost defer (-53): retry time not reached for any host
2018-10-27 17:32:47 1gGSJs-0002no-EM == [email protected] R=smarthost T=remote_smtp_smarthost defer (-53): retry time not reached for any host
2018-10-27 17:32:47 1gGSHC-0002is-0H == [email protected] R=smarthost T=remote_smtp_smarthost defer (-53): retry time not reached for any host
2018-10-27 17:32:47 End queue run: pid=12074
2018-10-27 17:32:53 1gGSQA-00038q-A1 H=smtpauth-dc2.online.net [62.210.16.40] Connection timed out
2018-10-27 17:32:53 1gGSQA-00038q-A1 == [email protected] R=smarthost T=remote_smtp_smarthost defer (110): Connection timed out

2018-10-27 17:47:12 1gGSg4-00039P-CW <= root@localhost U=root P=local S=369
2018-10-27 17:47:12 1gGSg4-00039P-CW == [email protected] R=smarthost T=remote_smtp_smarthost defer (-53): retry time not reached for any host


2018-10-27 18:02:34 1gGSst-0003JZ-5k H=smtp.free.fr [212.27.48.4] Connection timed out
2018-10-27 18:02:34 1gGSst-0003JZ-5k == [email protected] R=smarthost T=remote_smtp_smarthost defer (110): Connection timed out
2018-10-27 18:03:09 1gGSvV-0003KT-9k <= root@localhost U=root P=local S=369
2018-10-27 18:03:09 1gGSvV-0003KT-9k == [email protected] R=smarthost T=remote_smtp_smarthost defer (-53): retry time not reached for any host

Estou faltando alguma coisa nas configurações?

    
por AJN 27.10.2018 / 20:34

1 resposta

4

O Scaleway bloqueia o SMTP de saída por padrão. Você precisa desbloqueá-lo de dentro do seu painel de controle . O acesso a esta opção requer uma conta validada; se você não puder ativá-lo, abra um ticket com o Scaleway para obter mais instruções.

    
por 28.10.2018 / 02:41