0

Hi I am trying to send mail using mutt command as below,

mutt -s "test" madk@mycompany.com </dev/null

This fails with following error,

sendmail: Cannot open mail:25
Error sending message, child exited 1 ().
Could not send the message.

This issue happens in fedora 22 and fedora 23 machines. I used to run the same in fedora 12 and it works fine

Tried to modify following value in file "/etc/ssmtp/ssmtp.conf"

mailhub=mail

to

mailhub=fqdn_of_my_machine

Still I get similar error as below,

sendmail: Cannot open fqdn_of_my_machine:25
Error sending message, child exited 1 ().
Could not send the message.

Even sendmail I get same error as above,

sendmail user@example.com  < /tmp/file1
sendmail: Cannot open fqdn_of_my_machine:25
  • it sounds like you do not have a smtp daemon listening in port 25. Fedora does not ship with one by default, you should install and configure one. After that, verify you can telnet to port 25/tcp on the localhost. Configuring the smtp server is another matter ... – natxo asenjo Feb 19 '16 at 07:13
  • Thanks i have installed smtp package and now its working fine – Naggappan Ramukannan Feb 19 '16 at 09:15

1 Answers1

0

As natxo mentioned above we need to install smtp package and configure it. So I tried following commands and it worked,

# smtp --> it will ask that package not install [Yes]
dnf install sendmail # (install few other dep)
dnf install sendmail-cf # (its used to configure automatically)