Sending many e-mails

Hello,

I am interested in sending many e-mails to users on my website at
once. I would like these e-mails to be personalized, and they should
depend on the account settings of the users in the website.

What would be a good strategy for doing so? Would spawning a sendmail
process for each e-mail reasonable, or should I do something else?

Thanks.
jerrro [ Do, 27 September 2007 14:38 ] [ ID #1831158 ]

Re: Sending many e-mails

On 09/27/07 07:38, Jerr wrote:
> I am interested in sending many e-mails to users on my website at
> once. I would like these e-mails to be personalized, and they should
> depend on the account settings of the users in the website.
>
> What would be a good strategy for doing so? Would spawning a sendmail
> process for each e-mail reasonable, or should I do something else?

Use a mailing list manager that supports full personalization.

Note: Just because people are a user of your web site, you do not
implicitly have permission to email thin with out prior established
permission and / or some sort of business relationship.

Usually mailing lists need to be double opt in to not be sources of spam
/ abuse.



Grant. . . .
gtaylor [ Do, 27 September 2007 16:11 ] [ ID #1831159 ]

Re: Sending many e-mails

On 27 , 10:11, Grant Taylor <gtay... [at] riverviewtech.net> wrote:
> On 09/27/07 07:38, Jerr wrote:
>
> > I am interested in sending many e-mails to users on my website at
> > once. I would like these e-mails to be personalized, and they should
> > depend on the account settings of the users in the website.
>
> > What would be a good strategy for doing so? Would spawning a sendmail
> > process for each e-mail reasonable, or should I do something else?
>
> Use a mailing list manager that supports full personalization.
>
> Note: Just because people are a user of your web site, you do not
> implicitly have permission to email thin with out prior established
> permission and / or some sort of business relationship.
>
> Usually mailing lists need to be double opt in to not be sources of spam
> / abuse.
>
> Grant. . . .

Can you recommend on any good mailing list program with fully
personalization that could do that and is widely used with web sites
and sendmail (preferably open source...)? There seems to be so many...

About the permission to send e-mails, you should not worry. Those are
e-mails that users *expect* to be sent to them.
jerrro [ Fr, 28 September 2007 17:10 ] [ ID #1832064 ]

Re: Sending many e-mails

On 09/28/07 10:10, Jerr wrote:
> Can you recommend on any good mailing list program with fully
> personalization that could do that and is widely used with web sites
> and sendmail (preferably open source...)? There seems to be so
> many...

I am presently using MailMan mailing list manager for the few mailing
lists that I have. I do have a subdomain set up for my mailing lists
and Sendmail configured to relay for said subdomain. I am using
MailerTable to tell Sendmail what mailer to use to relay for my
subdomain. I also have a new mailer defined that uses the mm-handler to
pass messages in to MailMan.

To recap:
- Use a separate (sub)domain(s) for the mailing list(s).
- Have Sendmail relay for said (sub)domain(s).
- Create a new mailer for the MailMan handler (mm-handler).
- Use MailerTable to direct Sendmail to use the new mailer for said
(sub)domain(s).

If you need any more help, just ask.

Be aware that I'm not jumping up and down advocating MailMan, rather
just stating that I'm using it. I've had good luck with it and no
problems through various upgrades either. Though I do have a concern
about the perceived load that it puts on my system while it's processing
messages (badly formed html as they are) for a list that is close to
2500 subscribers. I do not have any numbers / tests confirming that the
load is from MailMan (*cough* Python *cough*) but just what I think I
have experienced on a system that is now a few years old with multiple
databases, web sites, mail boxes, and other various things on it. Let's
just say that I don't think a 25 MHz 486 DX2 with 32 MB of RAM will not
make a good MailMan system. All that being said, I probably would very
seriously consider using MailMan again on new systems, just being sure
to configure the system with some load in mind.

> About the permission to send e-mails, you should not worry. Those are
> e-mails that users *expect* to be sent to them.

Ok. Please understand that most of my job is trying to fight spam and
educate clients that want to send mass mailings out to their customers.
Sorry for the knee jerk reaction / statement.



Grant. . . .
gtaylor [ Fr, 28 September 2007 18:12 ] [ ID #1832065 ]

Re: Sending many e-mails

Uh, I just read a little about MailMan... It seems like its
personalization is not what I am looking for. It has a very rough
persoanlization, where you can substitute tokens with the user name /
e-mail or something of that sort.

I actually need to be able to send a completely different e-mail to a
specific user at a very specific time, and there might be a lot of
users who need to get a (different) e-mail at the same time.

That's what I am worried about - the load of the server if I spawned a
process of sendmail for each mail sent, but I don't see any way to
avoid that method when using sendmail.

A program that could queue e-mails according to time to be sent and
send them exactly at that time *efficiently*, without spawning a
process of sendmail, is what I really need.

Alternatively, I would settle for a way to send an e-mail immediately
when it is asked to be sent, and I will do the time handling...

Thanks.



> > Can you recommend on any good mailing list program with fully
> > personalization that could do that and is widely used with web sites
> > and sendmail (preferably open source...)? There seems to be so
> > many...
>
> I am presently using MailMan mailing list manager for the few mailing
> lists that I have. I do have a subdomain set up for my mailing lists
> and Sendmail configured to relay for said subdomain. I am using
> MailerTable to tell Sendmail what mailer to use to relay for my
> subdomain. I also have a new mailer defined that uses the mm-handler to
> pass messages in to MailMan.
>
> To recap:
> - Use a separate (sub)domain(s) for the mailing list(s).
> - Have Sendmail relay for said (sub)domain(s).
> - Create a new mailer for the MailMan handler (mm-handler).
> - Use MailerTable to direct Sendmail to use the new mailer for said
> (sub)domain(s).
>
> If you need any more help, just ask.
>
> Be aware that I'm not jumping up and down advocating MailMan, rather
> just stating that I'm using it. I've had good luck with it and no
> problems through various upgrades either. Though I do have a concern
> about the perceived load that it puts on my system while it's processing
> messages (badly formed html as they are) for a list that is close to
> 2500 subscribers. I do not have any numbers / tests confirming that the
> load is from MailMan (*cough* Python *cough*) but just what I think I
> have experienced on a system that is now a few years old with multiple
> databases, web sites, mail boxes, and other various things on it. Let's
> just say that I don't think a 25 MHz 486 DX2 with 32 MB of RAM will not
> make a good MailMan system. All that being said, I probably would very
> seriously consider using MailMan again on new systems, just being sure
> to configure the system with some load in mind.
>
> > About the permission to send e-mails, you should not worry. Those are
> > e-mails that users *expect* to be sent to them.
>
> Ok. Please understand that most of my job is trying to fight spam and
> educate clients that want to send mass mailings out to their customers.
> Sorry for the knee jerk reaction / statement.
>
> Grant. . . .
jerrro [ Fr, 28 September 2007 18:50 ] [ ID #1832067 ]

Re: Sending many e-mails

On 09/28/07 11:50, Jerr wrote:
> Uh, I just read a little about MailMan... It seems like its
> personalization is not what I am looking for. It has a very rough
> persoanlization, where you can substitute tokens with the user name /
> e-mail or something of that sort.

Ok, what you are wanting to do is a fair bit out side of the scope of
normal mailing list management software. Most mailing list management
software takes in a single message and distributes it to all subscribed
users. No personalization means that the message is just sent to one
address and blind carbon copied to all the other addresses. Full
personalization means that the message is sent to each individual
subscribed address one at a time by the mailing list management software.

> I actually need to be able to send a completely different e-mail to a
> specific user at a very specific time, and there might be a lot of
> users who need to get a (different) e-mail at the same time.

Now it sounds like you will be needing some other sort of software that
will generate the individual messages and send them out.

What do you really mean by "... at the same time."? If you want all the
messages to go out at the same second, you will more than likely need to
initiate multiple parallel SMTP transactions all at the same time. I
think that it is very unlikely that this is really what you mean. I'm
betting that you mean that when you say "Go" you want your software to
start processing the messages with all of them eventually leaving your
system over the next few minutes to hours depending on how many messages
need to be sent.

> That's what I am worried about - the load of the server if I spawned
> a process of sendmail for each mail sent, but I don't see any way to
> avoid that method when using sendmail.

If you try to send multiple email messages vis SMTP in parallel at the
same time to very many recipients at the same time, you will load the
server down no matter what. Be it memory, CPU, disk, or network
bandwidth, you will run out of resources if the list is very large at
all, say 50 - 100, or possibly even 25 concurrent SMTP connections. You
will be far better off streaming the messages from your program that
generates the individual messages in to Sendmail (or what ever else) and
have it queue the messages and let its queue scheduling empty the queue
for you.

You can even deliver messages to Sendmail in queued delivery mode. Thus
telling Sendmail to queue the messages and let the queue runners deliver
the messages out of the queue as it sees fit.

> A program that could queue e-mails according to time to be sent and
> send them exactly at that time *efficiently*, without spawning a
> process of sendmail, is what I really need.

Ok, now you are talking about something that will pause delivery until a
specified time with either pre-generated messages or messages generated
at that point in time.

I still think you are going to run in to a resource problem on your
system no matter what program you use to send the messages if you are
trying to send more than a small number of messages at the same time.
Sure you could write a program that would open multiple SMTP
transactions in parallel and process one command in each before going to
a subsequent command starting at the top of the list. I mean this can
theoretically be done, but man, that is a lot of concurrent streams to
keep track of and will use a fair bit of memory. If your list grows too
big, you could very well end up with things timing out on you before you
got back to the front of the line. There is also the fact that the
streams would receive commands in a fairly linear order. Well I suppose
you could write it so that all streams would send their commands at the
same time, but you would be looking at a load burst on the system again.

> Alternatively, I would settle for a way to send an e-mail immediately
> when it is asked to be sent, and I will do the time handling...

Sending a message to a single recipient on demand is not that difficult.
I have written SMTP state engines in Perl and PHP with little trouble.
I'm sure it would be trivial to implement one in just about any
language that can initiate network connections.

Chew on this and let me know what you think.



Grant. . . .
gtaylor [ Fr, 28 September 2007 21:13 ] [ ID #1832069 ]
Miscellaneous » comp.mail.sendmail » Sending many e-mails

Vorheriges Thema: Sendmail To and CC are not filled error
Nächstes Thema: Sizing MX servers: examples required + One quest. on maillog entries