Review your favorite Linux distribution.
Go Back > Forums > Linux Forums > Linux - Software
User Name
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.


  Search this Thread
Old 11-20-2004, 02:46 PM   #1
Registered: Jul 2004
Posts: 90

Rep: Reputation: 15
sending email

What all do I have to nave enabled and or installed to be able to send mail to an internet address from the command line? I've been trying: mail -s test msg text, but it doesn't get received. Sendmail's running, but I"m not familiar enough with the mail server stuff to know what needs to be running for this to work. Help me learn!

PS- i'm just doing this to send me a text message on my cell phone for certain events.
Old 11-20-2004, 07:02 PM   #2
Senior Member
Registered: Nov 2001
Location: Budapest, Hungary
Distribution: SuSE 6.4-11.3, Dsl linux, FreeBSD 4.3-6.2, Mandrake 8.2, Redhat, UHU, Debian Etch
Posts: 1,126

Rep: Reputation: 58
Suppose that you have some text in message.txt. A possible way to send that text in a mail to is this:

cat message.txt | formail -A "To:" | sendmail -oi -t

This requires that you have procmail installed; and sendmail should be correctly configured to be able to send mails.
If you do not operate your own mail server (which would require an own domain name), then you should configure sendmail to send mails via your ISP's smtp server (enter its name in line "smartrelayhost" line in sendmail.conf).


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
sending email to an ip pyu7 Linux - Software 4 10-08-2004 03:46 PM
Sending email with PHP jacksmash Programming 7 03-10-2004 06:10 PM
sending email GraemeK Linux - Networking 1 08-24-2003 06:14 PM
sending email csDraco_ Slackware 5 08-22-2003 06:50 PM
sending an email to a email address after a perl operation meluser Programming 9 04-07-2003 02:26 PM > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 05:28 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration