Solved

Automatic Email

Posted on 1998-12-21
2
261 Views
Last Modified: 2010-04-21
Hi,
I want to know how the automatic email is implemented
in UNIX and especially how I can change the email
sender's name from "web server" to whoever issues
the sending action.
Does someone know this? Please help me!
Thanks in advance!

hx
0
Comment
Question by:hx
2 Comments
 
LVL 1

Accepted Solution

by:
ramshakal earned 200 total points
ID: 2008478
The mail utility comes with almost all UNIX operating system. The UNIX provides
SMTP (Simple mail transfer protocol). Suppose UNIXHOST is your unix server then
You can see it by doing
telnet  UNIXHOST 25
Here for sending mail you can specify different option
To specify senders name do
mail from: <nameof sender>
To specify recipient do
rcpt to: <Recipient>
finally to send the data do
data
after it you can enter your message

So this is simple protocol. Using it you can implemnt your own mail transfer utility.
For example to change the email senders name simply pick the name and find a way
to use it in
mail from: <senders name>

0
 

Expert Comment

by:bcn
ID: 2008479
I think you want it:

you need a file where email destination. for exemple:

file_emails:
email1@dom.com
email2@dom.com
email3@dom.com
....
emailn@dom.com

And then you need a shell, that read from this file, and send
mail. For exemple.

shell_sendmail.sh it contains.

for i in `cat file_emails`
do
    echo "send....." $i
    /usr/lib/sendmail -F "Title" -f 'adress' $i < mail_send.txt

    if [ $? -ne 0 ]
    then
        echo "Error" $i
    fi

done

where send_mail.txt has the message from send.
I think hopes you.

0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Let's say you need to move the data of a file system from one partition to another. This generally involves dismounting the file system, backing it up to tapes, and restoring it to a new partition. You may also copy the file system from one place to…
A metadevice consists of one or more devices (slices). It can be expanded by adding slices. Then, it can be grown to fill a larger space while the file system is in use. However, not all UNIX file systems (UFS) can be expanded this way. The conca…
This video shows how to set up a shell script to accept a positional parameter when called, pass that to a SQL script, accept the output from the statement back and then manipulate it in the Shell.
In a previous video, we went over how to export a DynamoDB table into Amazon S3.  In this video, we show how to load the export from S3 into a DynamoDB table.

911 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

22 Experts available now in Live!

Get 1:1 Help Now