Re: ActionMailer - Sent but no mail?


#1

okay, okay, okay…so, I had it disabled (unknowingly) in the
development environment config file.

So now that it is enabled there, I have a different problem:

502 Command is locally disabled

Any ideas? Here is the development log info:

Net::SMTPSyntaxError (502 Command is locally disabled
):
c:/ruby/lib/ruby/1.8/net/smtp.rb:680:in check_response' c:/ruby/lib/ruby/1.8/net/smtp.rb:582:inauth_login’
c:/ruby/lib/ruby/1.8/net/smtp.rb:581:in critical' c:/ruby/lib/ruby/1.8/net/smtp.rb:581:inauth_login’
c:/ruby/lib/ruby/1.8/net/smtp.rb:571:in __send__' c:/ruby/lib/ruby/1.8/net/smtp.rb:571:inauthenticate’
c:/ruby/lib/ruby/1.8/net/smtp.rb:411:in do_start' c:/ruby/lib/ruby/1.8/net/smtp.rb:378:instart’
c:/ruby/lib/ruby/1.8/net/smtp.rb:316:in start' c:/ruby/lib/ruby/gems/1.8/gems/actionmailer-1.1.2/lib/action_mailer/base.rb:437:inperform_delivery_smtp’
c:/ruby/lib/ruby/gems/1.8/gems/actionmailer-1.1.2/lib/action_mailer/base.rb:327:in
send' c:/ruby/lib/ruby/gems/1.8/gems/actionmailer-1.1.2/lib/action_mailer/base.rb:327:indeliver!’
c:/ruby/lib/ruby/gems/1.8/gems/actionmailer-1.1.2/lib/action_mailer/base.rb:254:in
deliver' /app/controllers/main_controller.rb:40:inupdate’
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.10.2/lib/action_controller/base.rb:834:in
send' c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.10.2/lib/action_controller/base.rb:834:inperform_action_without_filters’
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.10.2/lib/action_controller/filters.rb:295:in
perform_action_without_benchmark' c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.10.2/lib/action_controller/benchmarking.rb:69:inperform_action_without_rescue’
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.10.2/lib/action_controller/benchmarking.rb:69:in
measure' c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.10.2/lib/action_controller/benchmarking.rb:69:inperform_action_without_rescue’
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.10.2/lib/action_controller/rescue.rb:82:in
perform_action' c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.10.2/lib/action_controller/base.rb:365:insend’
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.10.2/lib/action_controller/base.rb:365:in
process_without_session_management_support' c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.10.2/lib/action_controller/session_management.rb:116:inprocess’
c:/ruby/lib/ruby/gems/1.8/gems/rails-0.14.2/lib/dispatcher.rb:36:in
dispatch' c:/ruby/lib/ruby/gems/1.8/gems/rails-0.14.2/lib/webrick_server.rb:117:inhandle_dispatch’
c:/ruby/lib/ruby/gems/1.8/gems/rails-0.14.2/lib/webrick_server.rb:83:in
service' c:/ruby/lib/ruby/1.8/webrick/httpserver.rb:104:inservice’
c:/ruby/lib/ruby/1.8/webrick/httpserver.rb:65:in run' c:/ruby/lib/ruby/1.8/webrick/server.rb:155:instart_thread’
c:/ruby/lib/ruby/1.8/webrick/server.rb:144:in start' c:/ruby/lib/ruby/1.8/webrick/server.rb:144:instart_thread’
c:/ruby/lib/ruby/1.8/webrick/server.rb:94:in start' c:/ruby/lib/ruby/1.8/webrick/server.rb:89:ineach’
c:/ruby/lib/ruby/1.8/webrick/server.rb:89:in start' c:/ruby/lib/ruby/1.8/webrick/server.rb:79:instart’
c:/ruby/lib/ruby/1.8/webrick/server.rb:79:in start' c:/ruby/lib/ruby/gems/1.8/gems/rails-0.14.2/lib/webrick_server.rb:69:indispatch’
c:/ruby/lib/ruby/gems/1.8/gems/rails-0.14.2/lib/commands/server.rb:59
c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:18:in
require__' c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:18:inrequire’
c:/ruby/lib/ruby/gems/1.8/gems/activesupport-1.2.2/lib/active_support/dependencies.rb:213:in
`require’
script/server:5

Michael

Michael removed_email_address@domain.invalid wrote:
Ettore,

I have the same settings - but still no luck. In fact, I have gone so
far as to provide invalid credentials just to see if I can get an error
to show up and I don’t get anything indicating invalid credentials.

Does anyone have any other input for this? Or possibly other things I
can try? Is there any way to capture any error messages that may take
place?

Thanks for any input or experiences you may have!

Michael

Ettore B. removed_email_address@domain.invalid wrote:
Hi, my settings are like this:

ActionMailer::Base.delivery_method = :smtp
ActionMailer::Base.server_settings = {
:address => “mail.mydomain.org”,
:port => 25,
:domain => “www.mydomain.org”,
:authentication => :login,
:user_name => “xxxxxx”,
:password => “xxxxx”}
ActionMailer::Base.perform_deliveries = true
ActionMailer::Base.raise_delivery_errors = true
ActionMailer::Base.default_charset = “utf-8”

it works fine

hope it helps

Ettore

Il giorno 14/nov/05, alle ore 22:38, Michael ha scritto:

Hi,

I am attempting to use ActionMailer to send out an email (SMTP) and am
having an issue. The log files show that the email is sent, but the
email is not making it to my inbox.

I have followed the documentation both on the Wiki and in the AWD
book. I’m not sure which setting I have incorrect and need some
pointers.

:authentication - should this be set to true, or :login, :plain,
etc…??? I’m finding conflicting documentation.

:domain - Not quite sure what to put here. I have tried cox.net,
www.cox.net, etc… I even took the HELO domain from one of the headers
generated from my email client and I still didn’t get the email to come
into my account.

Is there any way to get error messages from failed emails? The
development log file doesn’t show anything other than "Sent mail: "
followed by the email I submitted. This should not be a relay issue
because I’m attempting to use the actual smtp server of my ISP.

Any guidance is greatly appreciated.

Regards,

Michael


Yahoo! FareChase - Search multiple travel sites in one click.


Rails mailing list
removed_email_address@domain.invalid
http://lists.rubyonrails.org/mailman/listinfo/rails


Rails mailing list
removed_email_address@domain.invalid
http://lists.rubyonrails.org/mailman/listinfo/rails


Yahoo! FareChase - Search multiple travel sites in one click.


#2

Does your smtp server require a login? Mine didn’t and I think I was
getting a 502 like you when I tried to send credentials. I had to
actually remove the authentication, username & password options to get
it to work.

Shad

On 11/14/05, Michael removed_email_address@domain.invalid wrote:

):

`deliver’

`perform_action’
c:/ruby/lib/ruby/gems/1.8/gems/rails-0.14.2/lib/dispatcher.rb:36:in
c:/ruby/lib/ruby/1.8/webrick/server.rb:155:in
c:/ruby/lib/ruby/gems/1.8/gems/rails-0.14.2/lib/webrick_server.rb:69:in
c:/ruby/lib/ruby/gems/1.8/gems/activesupport-1.2.2/lib/active_support/dependencies.rb:213:in

:domain => “www.mydomain.org”,

Hi,

Any guidance is greatly appreciated.
removed_email_address@domain.invalid
Yahoo! FareChase - Search multiple travel sites in one click.
http://lists.rubyonrails.org/mailman/listinfo/rails


http://www.ShadReynolds.com


#3

On 11/14/05, Michael removed_email_address@domain.invalid wrote:

okay, okay, okay…so, I had it disabled (unknowingly) in the development
environment config file.

So now that it is enabled there, I have a different problem:

502 Command is locally disabled

This sounds very much like the pain I went through when I was trying
an authentication setting that wasn’t supported by the SMTP server
(coincidentally Cox, when I’m working on this stuff from home).

Try removing the :authentication, :login and :password lines from your
settings.

  • Chris

#4

WOW…unbelievable…you are correct. I had no idea my outbound mail
didn’t require authentication! :frowning: Sure enough, I took those lines out
and all is well. That is good, because it tells me I have my settings
correct now.

However, I need to achieve something a little different. It is good
that I was able to get this working via cox with my personal address,
but now I want to send through an email account hosted at godaddy. I
understand relaying can be problematic, but within Thunderbird, I can
send and receive through the hosted account address from my home
computer w/o a problem.

Within Rails, however, I get the following error: Errno::EINVAL.
Based on the log, I am pretty sure it is timing out for some reason. I
have tried with and w/o credentials. Does anyone know about this error?

c:/ruby/lib/ruby/1.8/net/protocol.rb:197:in sysread' c:/ruby/lib/ruby/1.8/net/protocol.rb:197:inrbuf_fill’
c:/ruby/lib/ruby/1.8/net/protocol.rb:196:in timeout' c:/ruby/lib/ruby/1.8/timeout.rb:55:intimeout’
c:/ruby/lib/ruby/1.8/net/protocol.rb:196:in rbuf_fill' c:/ruby/lib/ruby/1.8/net/protocol.rb:160:inreaduntil’
c:/ruby/lib/ruby/1.8/net/protocol.rb:171:in readline' c:/ruby/lib/ruby/1.8/net/smtp.rb:664:inrecv_response’
c:/ruby/lib/ruby/1.8/net/smtp.rb:396:in do_start' c:/ruby/lib/ruby/1.8/net/smtp.rb:396:incritical’
c:/ruby/lib/ruby/1.8/net/smtp.rb:396:in do_start' c:/ruby/lib/ruby/1.8/net/smtp.rb:378:instart’
c:/ruby/lib/ruby/1.8/net/smtp.rb:316:in start' c:/ruby/lib/ruby/gems/1.8/gems/actionmailer-1.1.2/lib/action_mailer/base.rb:437:inperform_delivery_smtp’
c:/ruby/lib/ruby/gems/1.8/gems/actionmailer-1.1.2/lib/action_mailer/base.rb:327:in
send' c:/ruby/lib/ruby/gems/1.8/gems/actionmailer-1.1.2/lib/action_mailer/base.rb:327:indeliver!’
c:/ruby/lib/ruby/gems/1.8/gems/actionmailer-1.1.2/lib/action_mailer/base.rb:254:in
deliver' #{RAILS_ROOT}/app/controllers/main_controller.rb:40:inupdate’

Thanks,

Michael

Chris C. removed_email_address@domain.invalid wrote:
On 11/14/05, Michael wrote:

okay, okay, okay…so, I had it disabled (unknowingly) in the development
environment config file.

So now that it is enabled there, I have a different problem:

502 Command is locally disabled

This sounds very much like the pain I went through when I was trying
an authentication setting that wasn’t supported by the SMTP server
(coincidentally Cox, when I’m working on this stuff from home).

Try removing the :authentication, :login and :password lines from your
settings.

  • Chris