Author Topic: Integrated auto-resume  (Read 4406 times)

kirkham99

  • Posts: 2
    • View Profile
Integrated auto-resume
« on: January 10, 2008, 03:11:39 pm »
Dean,

I dropped(fwd) an email I got back from my server people....They have a limit of 60 seconds before it kills a PHP script so it can get a max of around 2,500 emails out before it bombs....Thing is emailing to large lists this is a real hassle, Can you think of a way around this so it can Restart itself after processing "nnnn" rows etc, similar to the PF5 REFRESH, some way to automate that on a coun t of 'nnnn' if required should do it.....What do you think.

At the moment it took me hours monitoring and having to manually restart the mailing, must be able to automate a restart under the 60second server rule etc

see there email below.....

>>> Hi Martin,
>>>
>>> I can't remove the 60 second limit as this poses a security issue to the
>>> server, we do have many people with large lists with no issues. Most
>>> scripts have a robust system to prevent them from failing. They have a
>>> system where they use cron to look after the list etc... Instead of one
>>> script running constantly as if we restart the web server it would get
>>> killed so it would never be reliable. There are many other mailing list
>>> system out there you might want to
>>> take a look at http://www.phplist.com. Many Thanks
>>>
>>> Nick Byng
>>> Support Executive
>>> B&P Interactive Ltd

Martin

DW

  • Administrator
  • Posts: 3787
    • View Profile
    • https://legacy.listmailpro.com
Integrated auto-resume
« Reply #1 on: January 10, 2008, 05:54:58 pm »
Hi Martin,

Your host could disable PHP "Safe mode" just for your domain to allow your scripts to run as long as necessary, but it looks like they don't want to do this.  I agree with their point about web server restarts causing an interruption.  To prevent such problems and to get around your server's time limit you could setup auto-resume to run every minute or two:

http://www.listmailpro.com/help/autoresume.html

Regards
Dean Wiebe
ListMailPRO Author & Developer - Help | Support | Hosting

kirkham99

  • Posts: 2
    • View Profile
LISTMAIL sending messages FAIL with a large list
« Reply #2 on: January 12, 2008, 01:56:08 am »
Dean,

Yes that's good and a robust "backend" solution to handle any mailing failures etc and restart automatically

What I was on about INSTEAD of leeting the script fail on the target server due to 60 second timeout, If I watch the DOMAIL running I can say press PF5(resume) at anystage and it starts again so If I do this every 600 rows then the script wont fail as it restarts again from scartch BUT cleanly, There must be a way to update the configuration screen in listmail with a parameter denoting when to refresh the messages after every 'xx'

DW

  • Administrator
  • Posts: 3787
    • View Profile
    • https://legacy.listmailpro.com
Integrated auto-resume
« Reply #3 on: January 12, 2008, 09:25:55 am »
A hack for this would have unpredictable consequences.  I suppose something similar to this code could output some javascript to load resume.php instead of the sleep command, ie to refresh every 500 messages:
Code: [Select]
if(($y % '500')==0 && $y <> sizeof($sendq)){ echo "<script>\nwindow.location='./resume.php?batid=$batch';\n</script>"; flush(); }
Add that after:
Code: [Select]
} else {
     // use php mail()

Regards
Dean Wiebe
ListMailPRO Author & Developer - Help | Support | Hosting

DW

  • Administrator
  • Posts: 3787
    • View Profile
    • https://legacy.listmailpro.com
Integrated auto-resume
« Reply #4 on: January 14, 2008, 10:24:10 am »
There are many other web hosts out there that do not have this limitation.  You might want to take a look at http://listmailpro.com/forum/index.php?topic=1699.0

Regards
Dean Wiebe
ListMailPRO Author & Developer - Help | Support | Hosting