Saturday, September 6, 2014

Configuring the Samsung N150+ for sending emails

I've been experimenting with attempting to send emails from the command line but realized that I had never configured the laptop to do so.

A short search revealed this blog which had simple steps to help configure email. I've copied those here too.

su
yum install sendmail-cf
cd /etc/mail
cp sendmail.mc sendmail.mc.original
cp sendmail.cf sendmail.cf.original
vi sendmail.mc

Remove dnl from the beginning of  these lines: (Copy and comment out the original line for safety)
  • LOCAL_DOMAIN (‘localhost.localdomain’) dnl
  • FEATURE (masquerade_envelope) dnl
  • FEATURE (masquerade_entire_domain) dnl
Enter my domain name "<machine>.<domain>.home" at these two lines:
  • MASQUERADE_AS (‘machine.domain.home’) dnl 
  • MASQUERADE_DOMAIN (machine.domain.home) dnl

su
cd /etc/mail
m4 /etc/mail/sendmail.mc > /etc/sendmail.cf
service sendmail restart
 
Finally a short test:

sendmail -s "Testing" testEmail@test.domain < /dev/null

I realized that I also had to check my spam email for this mail :-)