Use the below command to send mail from a Linux server to a user email-id:
# echo “this is the body of the email” | mailx -s “test mail” -r “From” -S smtp=”your-smtp” xyz@domain123.com
-s = Specifies the subject.
-r = Email sent from.
-S = Specifies the smtp server.
We can also add the configuration in mailx config file /etc/mail.rc
set smtp=your.smtp.server
set from=”from email address”
Then run the mailx command and then enter the body of the email, hit enter, and finally press Ctrl+D to deliver it.
# mailx -vvv -s “email subject” external-email-address
<Body of the email>
Ctrl D to deliver the message
Good post! We will be linking to this particularly great post on our site. Keep up the great writing
Hi there to all, for the reason that I am genuinely keen of reading this website’s post to be updated on a regular basis. It carries pleasant stuff.
This is my first time pay a quick visit at here and i am really happy to read everthing at one place
This was beautiful Admin. Thank you for your reflections.
This is really interesting, You’re a very skilled blogger. I’ve joined your feed and look forward to seeking more of your magnificent post. Also, I’ve shared your site in my social networks!
I appreciate the effort put into this post.
Just what I was looking for.
Impressive clarity and structure.
This should be a required read.