I am new in Raspberry Pi and I am trying to send mails without using SMTP. I had used SMTP before and it worked perfectly fine. But recently the same code is not working, though it compiles without any error. I have added the error message below. I want to know are there any ways besides SMTP?
2 Answers 2
SMTP, or Simple Mail Transport Protocol is the mail delivery mechanism in use currently on the Internet.
You can't send email without using SMTP in one way or another, either directly, or via a script or program that accesses a tool (for example an API or email-based website) that ties directly with SMTP on its back end.
-
Okay, now let me explain the main problem. I have used smtplib before without any issue. But recently the same code is not working. The code do compile without any error but it shows Network Unreachable issue. Previously many people posted this issue but no clear solution is not available.opu 웃– opu 웃2019年11月15日 14:59:43 +00:00Commented Nov 15, 2019 at 14:59
-
@opu웃 You should edit your question to add this new information. Many people don't read comments thoroughly and may miss this information.stevieb– stevieb2019年11月15日 16:18:45 +00:00Commented Nov 15, 2019 at 16:18
-
I have edited the question. Thank you for the suggestion.opu 웃– opu 웃2019年11月16日 10:18:40 +00:00Commented Nov 16, 2019 at 10:18
You don't say what OS or list any code, but do tag ssmtp
which is deprecated in Buster and hasn't been updated in years.
There are replacements. I use msmtp
(although not Python). See https://raspberrypi.stackexchange.com/a/100704/8697
Explore related questions
See similar questions with these tags.
smtplib
.