# ActionMailer not working correctly

**URL:** <https://www.ruby-forum.com/t/actionmailer-not-working-correctly/81723>\
**Category:** Rails\
**Created:** [March 14, 2006, 3:36pm UTC](https://www.ruby-forum.com/t/actionmailer-not-working-correctly/81723 "2006-03-14T15:36:18Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![yetanothergeek](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/y/8e8cbc/32.png) [@yetanothergeek](https://www.ruby-forum.com/u/yetanothergeek)\
**Post date:** [March 14, 2006, 3:36pm UTC](https://www.ruby-forum.com/t/actionmailer-not-working-correctly/81723/1 "2006-03-14T15:36:18Z")

</div>

Anyone know why this wouldn’t work? I’m using acts\_as\_authenticated for  
my login, and the mail is not getting sent. I’m using dreamhost. Here’s  
my settings:

ActionMailer::Base.delivery\_method = :smtp  
ActionMailer::Base.server\_settings = {  
:address =\> “[mail.mydomain.com](http://mail.mydomain.com)”,  
:port =\> 25,  
:domain =\> ‘[mydomain.com](http://mydomain.com)’,  
:user\_name =\> “blah”,  
:password =\> “password”,  
:authentication =\> :login  
}  
ActionMailer::Base.perform\_deliveries = true  
ActionMailer::Base.raise\_delivery\_errors = true  
ActionMailer::Base.default\_charset = “utf-8”

And the error from production.log:

Net::SMTPAuthenticationError (535 Error: authentication failed):  
/usr/lib/ruby/1.8/net/smtp.rb:586:in ‘auth login’

I’ve checked the user/pass and they are correct.

---

<div class="post-metadata">

**Author:** ![yetanothergeek](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/y/8e8cbc/32.png) [@yetanothergeek](https://www.ruby-forum.com/u/yetanothergeek)\
**Post date:** [March 14, 2006, 4:56pm UTC](https://www.ruby-forum.com/t/actionmailer-not-working-correctly/81723/2 "2006-03-14T16:56:46Z")

</div>

Chris S. wrote:

> Anyone know why this wouldn’t work? I’m using acts\_as\_authenticated for  
> my login, and the mail is not getting sent. I’m using dreamhost. Here’s  
> my settings:
> 
> ActionMailer::Base.delivery\_method = :smtp  
> ActionMailer::Base.server\_settings = {  
> :address =\> “[mail.mydomain.com](http://mail.mydomain.com)”,  
> :port =\> 25,  
> :domain =\> ‘[mydomain.com](http://mydomain.com)’,  
> :user\_name =\> “blah”,  
> :password =\> “password”,  
> :authentication =\> :login  
> }  
> ActionMailer::Base.perform\_deliveries = true  
> ActionMailer::Base.raise\_delivery\_errors = true  
> ActionMailer::Base.default\_charset = “utf-8”
> 
> And the error from production.log:
> 
> Net::SMTPAuthenticationError (535 Error: authentication failed):  
> /usr/lib/ruby/1.8/net/smtp.rb:586:in ‘auth login’
> 
> I’ve checked the user/pass and they are correct.

Does the server support that auth mechanism ?

If you telnet to the server on port 25 and type ‘EHLO myrailsbox.tld’ do  
you see something like 250-AUTH LOGIN PLAIN in the response ?

A.

---

<div class="post-metadata">

**Author:** ![yetanothergeek](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/y/8e8cbc/32.png) [@yetanothergeek](https://www.ruby-forum.com/u/yetanothergeek)\
**Post date:** [March 14, 2006, 5:47pm UTC](https://www.ruby-forum.com/t/actionmailer-not-working-correctly/81723/3 "2006-03-14T17:47:42Z")

</div>

I am seeing:

250-AUTH PLAIN LOGIN  
250-AUTH=PLAIN LOGIN

Does this mean :authentication =\> :login won’t work?
