need help with mailserver
hey,
i've posted before trying to get help with this but ill give a little recap anyway.
basically we send out newsletters to clients. i'm writing the software for the actual sending of the newsletters.
the backend is php/mysql/fastcgi/iis
i have absolutely NO control over fastcgi, the admin on the server isn't willing to change any of the settings at all no matter how we ask or what we tell him.
basically this is what happens.
send to 1 email address, everything works fine
send to 10 email addresses, everything works fine
100 - great
400 - great
800 - great
>1000 - starts to fail with a fastcgi timeout
i've tried everything i can think of.
first i was sending individual emails using the mail() function. so every client was getting their own function.
that doesn't work because either the smtp gets backlogged or because it was just taking too long for individual emails to go out.
so then i tried sending all the clients at one time in the bcc field. now this works perfectly except for the fact that it takes absolutely forever for the email to be sent to some people for some reason. have no idea why.
so then i tried sending to 20, 30, or 40 people in one shot. this works great for small amounts of email address (ie <1000) but for larger amounts it timesout. but before it times out it actually sends to those people it gets to.
i thought maybe flushing what the server was doing would help but the admin simply refuses to activate the ability to flush whats happening.
i've tried increasing the time to 900 at the beginning of the script and tried resetting the time every time we send an email. neither seem to do anything and i keep getting those fastcgi timeout errors.
i've asked him to increase the time in fcgi.ini or whatever, and he simply refuses to do so.
now the admin was also the old programmer for the old system we were using here and he's "lost business" because of me. so i think it has something to do with sabotage that he doesn't want to anything.
it's at the point where i'm thinking about writing the script in asp to do the actual sends.
before i go about doing this, am i missing anything? is there something i overlooked or some way around sending out more than 1000 emails at once?
i'm at the end of my rope here and whats worse is my boss is looking at me like i'm the problem even though i never thought it was a good idea to go with this guy's server.
******UPDATE*********
thanks to everyone's help and support i've temporarily solved the issue, here's how.
pretty much going with topbit's idea, i made a new table in mysql for 'things to send'. when someone wanted to send an email they would go through all the steps of making said email and then it would get the addresses and divid them up by 1000 and insert them into the db.
then i created a page that would have to stay open, it checks the db for stuff to be sent, finds it and then sends it using the same mail() script i created before, but now only needs to deal with 1000 or less at a time
thanks again for the help and letting me vent a bit.
i've posted before trying to get help with this but ill give a little recap anyway.
basically we send out newsletters to clients. i'm writing the software for the actual sending of the newsletters.
the backend is php/mysql/fastcgi/iis
i have absolutely NO control over fastcgi, the admin on the server isn't willing to change any of the settings at all no matter how we ask or what we tell him.
basically this is what happens.
send to 1 email address, everything works fine
send to 10 email addresses, everything works fine
100 - great
400 - great
800 - great
>1000 - starts to fail with a fastcgi timeout
i've tried everything i can think of.
first i was sending individual emails using the mail() function. so every client was getting their own function.
that doesn't work because either the smtp gets backlogged or because it was just taking too long for individual emails to go out.
so then i tried sending all the clients at one time in the bcc field. now this works perfectly except for the fact that it takes absolutely forever for the email to be sent to some people for some reason. have no idea why.
so then i tried sending to 20, 30, or 40 people in one shot. this works great for small amounts of email address (ie <1000) but for larger amounts it timesout. but before it times out it actually sends to those people it gets to.
i thought maybe flushing what the server was doing would help but the admin simply refuses to activate the ability to flush whats happening.
i've tried increasing the time to 900 at the beginning of the script and tried resetting the time every time we send an email. neither seem to do anything and i keep getting those fastcgi timeout errors.
i've asked him to increase the time in fcgi.ini or whatever, and he simply refuses to do so.
now the admin was also the old programmer for the old system we were using here and he's "lost business" because of me. so i think it has something to do with sabotage that he doesn't want to anything.
it's at the point where i'm thinking about writing the script in asp to do the actual sends.
before i go about doing this, am i missing anything? is there something i overlooked or some way around sending out more than 1000 emails at once?
i'm at the end of my rope here and whats worse is my boss is looking at me like i'm the problem even though i never thought it was a good idea to go with this guy's server.
******UPDATE*********
thanks to everyone's help and support i've temporarily solved the issue, here's how.
pretty much going with topbit's idea, i made a new table in mysql for 'things to send'. when someone wanted to send an email they would go through all the steps of making said email and then it would get the addresses and divid them up by 1000 and insert them into the db.
then i created a page that would have to stay open, it checks the db for stuff to be sent, finds it and then sends it using the same mail() script i created before, but now only needs to deal with 1000 or less at a time
thanks again for the help and letting me vent a bit.
