Limit sending to no more than 100 emails per hour

Start here! No need to ask twice :)

Re: how to send emails to 100 users per time?

Postby Balitas » 11:23pm, Thu 04 Nov, 2010

booyeeka wrote:i need to send only 100 emails per day.

how can i send only 100 emails per one action of sending? !

# no more than 100 mails in batch size
define("MAILQUEUE_BATCH_SIZE",100);

# 3600 seconds is 1 hour so 24 hours (1 day) is 86400:
define("MAILQUEUE_BATCH_PERIOD",86400);

# Pause between messages (in seconds) to send no more than 100 messages per hour:
define('MAILQUEUE_THROTTLE',864);
Balitas
PL Geek
 
Posts: 82
Joined: 2:17am, Mon 13 Feb, 2006

Need Advice for Throttling Settings and Auto Sending

Postby Cubski » 7:24pm, Fri 21 Jan, 2011

Hi everyone,

I am fairly new to Phplist. I have encountered several issues with it, but I have solved most of it thanks to this helpful community.

I want to hear some advice about how to set throttling and batch processing for this scenario:

- Send 500 emails per hour for 10 hours per day

Since my hosting allows me to send 5000 emails per day (did not specify how many emails per hour).

I also want to know how to set this batch processing automatically using either cron or commandline (whichever is best suited for my situation). I do not want to run the batch process using a browser since I have a large email list to send to. I have a VPS hosted at myhosting.com using Plesk Panel.

If anyone could help me with this, that would be very much appreciated. This is the last issue I need to solve before I continue with my campaign.

Thank you very much to all.
Cubski
phpLister
 
Posts: 7
Joined: 7:48pm, Sun 16 Jan, 2011

Re: Need Advice for Throttling Settings and Auto Sending

Postby H2B2 » 2:05am, Fri 28 Jan, 2011

Cubski wrote:Since my hosting allows me to send 5000 emails per day (did not specify how many emails per hour).

A message limit of 5000 msgs/day (24 hrs), equals 208 msgs/hour. Allow for a safe margin and set it to 180 or 190 msgs/hr.

The simplest way to deal with this is probably by using the mailqueue throttle setting and insert a 20 seconds pause between each message. You can keep the process going by using a cron job.
ref: http://docs.phplist.com/PhpListConfigSendRate
H2B2
Moderator
 
Posts: 7188
Joined: 1:51am, Wed 15 Mar, 2006

host limits number relays to day, set up to resume

Postby DeepSpace » 7:11pm, Sun 06 Feb, 2011

I am sorry if my first post is one already covered but in my searching I did not come up with a answer.
My host allows 250 smtp relays, I would like to set up so at midnight the next 250 in the queue go out and so forth until all have gone. Thanks
DeepSpace
phpList newbie
 
Posts: 3
Joined: 7:04pm, Sun 06 Feb, 2011

Re: host limits number relays to day, set up to resume

Postby H2B2 » 2:23am, Mon 07 Feb, 2011

DeepSpace wrote:My host allows 250 smtp relays, I would like to set up so at midnight the next 250 in the queue go out and so forth until all have gone.

A limit of 250 messages per day doesn't sound like a good hosting choice. However, if you cannot switch to another host you might try these settings in config.php:
Code: Select all
#disable batch processing
define("MAILQUEUE_BATCH_SIZE",0);

# Batch period not relevant if batch processing is disabled
define("MAILQUEUE_BATCH_PERIOD",3600);

# Pause 360 seconds (6 minutes) between messages to send no more than 240 messages per day:
define('MAILQUEUE_THROTTLE',360);

Since the script is likely to time out in, it is probably best to run a cron job (or some pseudo cron job) to process the message queue at regular intervals. How short these intervals should be on your server is something you need to find by practice.

The above settings only allow a margin of 10 messages per day, i.e. if you send private messages using your email client, make sure you do not send more than 10 messages while phpList is sending its 240 messages a day. Else you'd be breaking your message limits.

I also suggest you disable notification emails in your configuration page (lists/admin/?page=configure&id=send_admin_copies): Set "Does the admin get copies of subscribe, update and unsubscribe messages" to false

Refs:
http://docs.phplist.com/PhpListConfigSendRate
http://docs.phplist.com/ConfigurePhplistInfo

See also: viewtopic.php?p=83457#p83457
H2B2
Moderator
 
Posts: 7188
Joined: 1:51am, Wed 15 Mar, 2006

Re: Limit sending to no more than 100 emails per hour

Postby gabster » 8:10pm, Wed 02 Mar, 2011

Hi Gang!

My host allows me to send 750 emails per hour. What would be my optimal throttle settings for this?

Thanks a lot!
Gabstero
gabster
phpList newbie
 
Posts: 3
Joined: 5:26pm, Tue 22 Feb, 2011

Re: Limit sending to no more than 100 emails per hour

Postby H2B2 » 9:21am, Fri 04 Mar, 2011

A throttle value of 5 seconds will send 720 msgs per hour:
define('MAILQUEUE_THROTTLE',5);
H2B2
Moderator
 
Posts: 7188
Joined: 1:51am, Wed 15 Mar, 2006

Re: Limit sending to no more than 100 emails per hour

Postby gabster » 3:51pm, Fri 04 Mar, 2011

[quote="H2B2"]A throttle value of 5 seconds will send 720 msgs per hour:
[i]define('MAILQUEUE_THROTTLE',5);[/i][/quote]

Thanks for the reply! It this case what values should I have set for MAILQUEUE_BATCH_SIZE and MAILQUEUE_BATCH_PERIOD?

Thanks a lot!

Gabster
gabster
phpList newbie
 
Posts: 3
Joined: 5:26pm, Tue 22 Feb, 2011

Re: Limit sending to no more than 100 emails per hour

Postby H2B2 » 9:43pm, Sun 06 Mar, 2011

Since the throttle is ensuring you keep below the 750 msgs/hr limit, you don't need to use batch processing, and therefore you should disable batch processing;
    #disable batch processing
    define("MAILQUEUE_BATCH_SIZE",0);

    # Batch period not relevant if batch processing is disabled
    define("MAILQUEUE_BATCH_PERIOD",3600);

If you have timeout problems. you can use a cron job to maintain the sending process.
Ref http://docs.phplist.com/PhpListConfigSendRate
H2B2
Moderator
 
Posts: 7188
Joined: 1:51am, Wed 15 Mar, 2006

Previous

Return to Frequently Asked Questions

Who is online

Users browsing this forum: No registered users and 2 guests