Fully support PHP mail() function.
Here is a chat with a support tech that I had recently, name has been removed. I suggest that rackspace either find a way to make sure that the php mail() function will guarantee delivery, or find a way to wrap the PHP mail function in an SMTP wrapper allowing us to set a default outgoing account on a per-domain basis.
Currently the only way around the default open mail queue is to use the Pear SMTP library which is not practical if you are hosting many wordpress, phpbb, or drupal sites.
Thank you for your patience. A representative will be with you shortly..
Welcome to the Rackspace Cloud! My name is Support Tech, how may I help you?
Support Tech: Hey Travis
Travis: Hi Mike
Travis: I'm having some trouble sending mail with PHP from one of my domains, can you check if it has been flagged or something? Messages don't seem to be going out at all.
Travis: The domain is domainname.com
Support Tech: Thanks Travis, give me a few moments while I look into your issue
Support Tech: Thank you for your patience, please give me a few more moments.
Travis: No problem!
Support Tech: Are you authenticating your sent mail?
Travis: just sending out using the php mail() function
Support Tech: Does your code looking something like this?
Support Tech: http://cloudsites.rackspacecloud.com/index.php/How_do_I_test_PHP_SMTP_functionality%3F
Travis: not using SMTP
Travis: just mail("firstname.lastname@example.org","test","test")
Support Tech: Well, this means your not authenticating your sending mail.
Support Tech: When you don't authenticate your sent mail then it goes to our open mail pipe which can take much longer to get to the destination
Support Tech: If you authenticate the mail being sent, then it will move much faster.
Travis: Yeah, the problem isn't that its slow right now though, its not going at all, there was some mail that was sent out days ago.
Support Tech: Well, when our open relays get to congested then they will flush the queue. This could be an example of why your mail never reached the destination
Travis: So... what your saying is that basically theres no guarantee that the php mail function will work?
Support Tech: Well, you are subject to delays when using our open relays. If you authenticate your mail, then we can check and see where the issue maybe and usually don't have any issues.
Travis: Yeah, I'm not talking about the PEAR Mail class though, just the standard PHP mail() function, if it flushes the queue does that mean the message is lost?
Support Tech: Yep, once the queue is flushed then the message is lost. I can understand your frustration with just the standard mail function, but when you don't authenticate the mail, then it is forced through our open relays. You can imagine that we may have a lot of customers also doing the same thing. This is why it gets a bit congested sometimes.
Travis: Yeah, I'm not frustrated, I just need to know if my mail is going to get there or not :) ... but not supporting the PHP mail function is a big deal, 99% of PHP applications that send email will send it using the mail function, WordPress, PHPBB, etc etc, all would need to be patched to use the PEAR Mail class like the example that you linked me to.
Support Tech: I see what your saying Travis. It definitely works, and I know for sure that we do support that functionality. It is just that lots of people using the mail function at one time can congest our open relays. This is the reason why we may have to flush out the mail sometimes. Using the article I gave you will make you specify the server to send mail out on, and you can bypass our open relays completely.
Travis: I know you have to cover yourself here and not say something that would compromise your job, or make rackspace look bad, and I get that, believe me, I don't hold you responsible for that :) I get put in the same situation lots of times. But lets face it, if I call the mail() function, and there is no guarantee that it is going to send the mail, then the function is not supported, period. I don't want you to think that I blame you for this, it is not your job to design the rackspace infrastructure, it just sucks that its not supported. Isn't there a board or something I think I saw before where people can make feature requests? If you could link me to that I would appreciate it :)
Support Tech: Absolutely, you can always go to vet.rackspace.com to provide feedback or suggestions to us.
Travis: Hmm, that domain seems to be down.
Support Tech: HAHA I am sorry. It is feedback.rackspacecloud.com
Support Tech: We really take what you say to heart, so feel free to put whatever you like on there.
Travis: Understood, thanks :) You guys in the support team are still the best, no question about that.
Support Tech: I really appreciate that! We do try and give you the best experience possible!
Michael @ Mailgun commented
Have you tried Mailgun yet? Mailgun was acquired by Rackspace in August of 2012 to solve this problem with email in the cloud. Mailgun is integrated in the Rackspace Cloud control panel and Rackspace customers get 50,000 emails per month for free. You can read the details here: http://www.rackspace.com/blog/get-mailgun-now-directly-through-the-cloud-control-panel/ Try it and see what you think. (BTW, I work at Mailgun)
Jason Schmidt commented
I agree - mail() should run better!
For me, I can easily swap a contact form for an SMTP authenticated one, but the problem is not everyone is going to do this. CMSs like Wordpress, Drupal, etc. are going to likely use mail() because it is native to PHP and really simple. This really needs to be supported more thoroughly instead of placing these emails in a queue.
You should look into using a PHP library like swiftmailer (http://swiftmailer.org). I believe it can be installed via PEAR, but I like to include it in my lib folders.
It has great documentation and works like a charm with sendgrid, google, or anywhere.
Paul Hayes commented
You took out the support guy's name, but then the first line you go "Hey Mike".
Romy Blystone commented
SendGrid is an excellent option if you are only going to be using it for your own websites... but as a reseller, you'll need to upgrade to a Silver account ($79.99/month) which allows you to create sub user accounts. You can use a Bronze account (Free for Rackspace Cloudsite customers - single user) for multiple websites... but that would pose a security risk as anyone using that user/pass would then be able to access everyone's email statistics on SendGrid.
Damien McKenna commented
Try using the SMTP module on Drupal sites, it lets you pass outbound email messages to an SMTP server, inc gmail. There's also the Amazon_SES module for using Amazon's commercial mail service if you'd prefer to go that route.
Have you looked into sendgrid which has a free offer for RS customers? I've switched to them and everything has worked great.
mayur aahir commented