SSMTP로데몬으로 실행되지 않습니다그 자체,어떻게 테스트해?작동 되나요?
nicholas@mordor:~$
nicholas@mordor:~$ telnet localhost 25
Trying 127.0.0.1...
telnet: Unable to connect to remote host: Connection refused
nicholas@mordor:~$
nicholas@mordor:~$ telnet mordor.saundersconsulting.tech 25
Trying 127.0.1.1...
telnet: Unable to connect to remote host: Connection refused
nicholas@mordor:~$
nicholas@mordor:~$ swaks --to [email protected] --from [email protected] --server mordor.saundersconsulting.tech
=== Trying mordor.saundersconsulting.tech:25...
*** Error connecting to mordor.saundersconsulting.tech:25:
*** IO::Socket::INET6: connect: Connection refused
nicholas@mordor:~$
nicholas@mordor:~$ sudo cat /etc/ssmtp/ssmtp.conf
[sudo] password for nicholas:
#
# Config file for sSMTP sendmail
#
# The person who gets all mail for userids < 1000
# Make this empty to disable rewriting.
[email protected]
# The place where the mail goes. The actual machine name is required no
# MX records are consulted. Commonly mailhosts are named mail.domain.com
mailhub=smtp.gmail.com:587
[email protected]
AuthPass=fdsfdsfdsf
UseTLS=YES
UseSTARTTLS=YES
# Where will the mail seem to come from?
#rewriteDomain=
rewriteDomain=gmail.com
# The full hostname
#hostname=mordor.saundersconsulting.tech
[email protected]
# Are users allowed to set their own From: address?
# YES - Allow the user to specify their own From: address
# NO - Use the system generated From: address
FromLineOverride=YES
nicholas@mordor:~$
nicholas@mordor:~$ sudo cat /etc/ssmtp/revaliases
# sSMTP aliases
#
# Format: local_account:outgoing_address:mailhub
#
# Example: root:[email protected]:mailhub.your.domain[:port]
# where [:port] is an optional port number that defaults to 25.
root:[email protected]:smtp.gmail.com:587
nicholas@mordor:~$
nicholas@mordor:~$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 23.10
Release: 23.10
Codename: mantic
nicholas@mordor:~$
이 경우 무엇을 테스트해야 할지 잘 모르겠습니다.
명령을 직접 시도하면 다음이 생성됩니다.
nicholas@mordor:~$
nicholas@mordor:~$ ssmtp [email protected]
to:[email protected]
from:[email protected]
subject:ping
testingssmtp: Cannot open smtp.gmail.com:587
nicholas@mordor:~$
/var/log/mail.err 로그에는 다음 링크가 표시됩니다.
HELO/EHLO 이메일 오류
이메일을 보내려고 하는데 "잘못된 HELO/EHLO 매개변수"라는 반송 메시지를 받은 경우 다음 단계를 수행할 수 있습니다.
Contact your email administrator. You should have an administrator if you’re using Gmail for a work, school, or organization account.
그렇지 않은 경우에는 이메일 제공업체에 문의하세요. Gmail 서버에 접속할 때 관리자에게 전송 서버의 정규화된 도메인 이름이나 IP 주소를 보내달라고 요청하세요.
이 오류는 일반적으로 프린터, 스캐너, 팩스 등 메일을 보내는 장치에서 발생합니다.
이런 식으로:
nicholas@mordor:~$
nicholas@mordor:~$ cat /var/log/mail.err
2023-12-19T09:37:13.183560+00:00 mordor sSMTP[11658]: Invalid response: 501 5.5.4 https://support.google.com/mail/?p=helo s17-20020a170902b19100b001d366f8cfd7sm7380648plr.182 - gsmtp ([email protected])
2023-12-19T09:37:13.184272+00:00 mordor sSMTP[11658]: Cannot open smtp.gmail.com:587
2023-12-19T13:10:01.378049+00:00 mordor sSMTP[14174]: Invalid response: 501 5.5.4 https://support.google.com/mail/?p=helo y20-20020a056a00191400b00688435a9915sm20054254pfi.189 - gsmtp ([email protected])
2023-12-19T13:10:01.378702+00:00 mordor sSMTP[14174]: Cannot open smtp.gmail.com:587
2023-12-19T13:10:36.241185+00:00 mordor sSMTP[14186]: Invalid response: 501 5.5.4 https://support.google.com/mail/?p=helo b18-20020a170902d51200b001cf511aa772sm20973353plg.145 - gsmtp ([email protected])
2023-12-19T13:10:36.241851+00:00 mordor sSMTP[14186]: Cannot open smtp.gmail.com:587
2023-12-19T13:11:49.694632+00:00 mordor sSMTP[14213]: Invalid response: 501 5.5.4 https://support.google.com/mail/?p=helo l15-20020a170902f68f00b001c9c5a1b477sm21000470plg.169 - gsmtp ([email protected])
2023-12-19T13:11:49.695296+00:00 mordor sSMTP[14213]: Cannot open smtp.gmail.com:587
nicholas@mordor:~$