non interactive mail command

Asked by Lewis Frazee

I would like to be able to send an email at the end of a script - non interactively.
On another flavor of linux I simply type: mail <email address hidden> < /home/logs/file
And, it works.
I cannot get the same thing to work in Ubuntu.
Please help.

Question information

Language:
English Edit question
Status:
Answered
For:
Ubuntu sendemail Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:
Revision history for this message
marcobra (Marco Braida) (marcobra) said :
#1

Please install and use sendemail package (NOTE: sendemail and not sendmail)

Revision history for this message
marcobra (Marco Braida) (marcobra) said :
#2

Please first enable the universe repository:

Open System → Administration → Software sources → [ Tab Ubuntu software ]
enable "Community Maintained open source software (universe)"
Close and confirm the repository reload.

Here some repositories details: https://help.ubuntu.com/community/Repositories/Ubuntu

Then open a Terminal from the menu Applications → Accessories → Terminal and type:

sudo apt-get update
sudo apt-get dist-upgrade
sudo apt-get install sendemail

give your user password when requested, you don't see nothing when you type it, then press enter.

Can you help with this problem?

Provide an answer of your own, or ask Lewis Frazee for more information if necessary.

To post a message you must log in.