Fedora 27 and Outgoing Email
-
@dustinb3403 said in Fedora 27 and Outgoing Email:
I think it has mailx installed by default
mailx is the client, not the mailer. But most people actually want to use this and don't realize it and so don't ask what they mean. So chances are, he wants to use mailx but technically he is set to send emails without it.
-
@aaronstuder said in Fedora 27 and Outgoing Email:
Just want to email out a log file.
From what application?
-
@scottalanmiller bash script, via command line is fine.
-
@aaronstuder said in Fedora 27 and Outgoing Email:
@scottalanmiller bash script, via command line is fine.
If you want to do it from BASH, you need to add a command to send. mailx is the one to use.
dnf install mailx
-
@scottalanmiller said in Fedora 27 and Outgoing Email:
If you want to do it from BASH, you need to add a command to send. mailx is the one to use.
Null message body; hope that's ok
/usr/sbin/sendmail: No such file or directory
"/root/dead.letter" 9/243
. . . message not sent. -
@aaronstuder said in Fedora 27 and Outgoing Email:
@scottalanmiller said in Fedora 27 and Outgoing Email:
If you want to do it from BASH, you need to add a command to send. mailx is the one to use.
Null message body; hope that's ok
/usr/sbin/sendmail: No such file or directory
"/root/dead.letter" 9/243
. . . message not sent.Is there really no MTA by default? Is this one of Jared's minimal installs instead of server? That might do it.
dnf install postfix systemctl start postfix systemctl enable postfix
-
@scottalanmiller postfix installed, running and enabled.
The command just hangs:
mail -s "Test" [email protected]
-
@aaronstuder said in Fedora 27 and Outgoing Email:
@scottalanmiller postfix installed, running and enabled.
The command just hangs:
mail -s "Test" [email protected]
It's not hung, it's waiting for the body of the email. Try this...
mail -s "Test" [email protected] < /etc/passwd
-
@scottalanmiller said in Fedora 27 and Outgoing Email:
mail -s "Test" [email protected] < /etc/passwd
Bingo, Gmail thinks it's spam, but that makes since
-
@scottalanmiller so do I even need postfix?
-
@aaronstuder said in Fedora 27 and Outgoing Email:
@scottalanmiller said in Fedora 27 and Outgoing Email:
mail -s "Test" [email protected] < /etc/passwd
Bingo, Gmail thinks it's spam, but that makes
sincesenseFtfy
-
@aaronstuder said in Fedora 27 and Outgoing Email:
@scottalanmiller so do I even need postfix?
Yes, mailx is only a client, it's telling Postfix to send it. if you wanted to send through Postfix by hand, you could.
-
@scottalanmiller said in Fedora 27 and Outgoing Email:
@aaronstuder said in Fedora 27 and Outgoing Email:
@scottalanmiller so do I even need postfix?
Yes, mailx is only a client, it's telling Postfix to send it. if you wanted to send through Postfix by hand, you could.
Fun = telnet to postfix and send E-mail that way
-
@eddiejennings said in Fedora 27 and Outgoing Email:
@scottalanmiller said in Fedora 27 and Outgoing Email:
@aaronstuder said in Fedora 27 and Outgoing Email:
@scottalanmiller so do I even need postfix?
Yes, mailx is only a client, it's telling Postfix to send it. if you wanted to send through Postfix by hand, you could.
Fun = telnet to postfix and send E-mail that way
Right, it's a standard thing to have to learn to do, but once you learn how, you never want to do it again. But it's standard for students to have to do it to learn how network protocols work and it is a great demonstration of "you don't need a client."
-
@scottalanmiller said in Fedora 27 and Outgoing Email:
<snip>... and it is a great demonstration of "you don't need a client."
It is also demonstrates a reason to appreciate having a decent client app.