[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.ruby

Problem with SMTP mail program

Dhiraj Girdhar

7/9/2007 9:15:00 AM

Hi,

I took following very simple mail program from one of Ruby site, it is
working fine on my system, but not on other system. The only difference
which i Observed is that on other machine Microsoft Outlook is not
installed.

Please tell me the reason?


msgstr = <<END_OF_MESSAGE
From: Dhiraj Girdhar <dhiraj@samplemail.com>
To: Dhiraj Girdhar <dhiraj@samplemail.com>
Subject: test message
Date: Sat, 14 Jun 2007 16:26:43 +0900
Message-Id: <1dhiraj@samplemail.com>

This is a test message.
END_OF_MESSAGE

require 'net/smtp'
Net::SMTP.start('samplemailexchangeserver.arcot.com', 25) do |smtp|
smtp.send_message msgstr,
'dhiraj@samplemail.com',
'dhiraj@samplemail.com'
end

Regards:
Dhiraj

--
Posted via http://www.ruby-....

3 Answers

Damjan Rems

7/9/2007 9:26:00 AM

0


How about some error description?

by
TheR

--
Posted via http://www.ruby-....

Dhiraj Girdhar

7/9/2007 10:27:00 AM

0

Damjan Rems wrote:
>
> How about some error description?
>
> by
> TheR

I am getting following error message..

d:/ruby/lib/ruby/1.8/net/protocol.rb:206:in `initialize': getaddrinfo:
no address associated with hostname. (S
ocketError)
from d:/ruby/lib/ruby/1.8/net/protocol.rb:206:in `new'
from d:/ruby/lib/ruby/1.8/net/protocol.rb:206:in `old_open'
from d:/ruby/lib/ruby/1.8/timeout.rb:56:in `timeout'
from d:/ruby/lib/ruby/1.8/timeout.rb:76:in `timeout'
from d:/ruby/lib/ruby/1.8/net/protocol.rb:206:in `old_open'
from d:/ruby/lib/ruby/1.8/net/smtp.rb:393:in `do_start'
from d:/ruby/lib/ruby/1.8/net/smtp.rb:378:in `start'
from d:/ruby/lib/ruby/1.8/net/smtp.rb:316:in `start'

--
Posted via http://www.ruby-....

SonOfLilit

7/9/2007 11:31:00 AM

0

Sounds like a DNS error.

Do you get DNS to that address? I don't.


Aur

On 7/9/07, Dhiraj Girdhar <dgirdhar@arcot.com> wrote:
> Damjan Rems wrote:
> >
> > How about some error description?
> >
> > by
> > TheR
>
> I am getting following error message..
>
> d:/ruby/lib/ruby/1.8/net/protocol.rb:206:in `initialize': getaddrinfo:
> no address associated with hostname. (S
> ocketError)
> from d:/ruby/lib/ruby/1.8/net/protocol.rb:206:in `new'
> from d:/ruby/lib/ruby/1.8/net/protocol.rb:206:in `old_open'
> from d:/ruby/lib/ruby/1.8/timeout.rb:56:in `timeout'
> from d:/ruby/lib/ruby/1.8/timeout.rb:76:in `timeout'
> from d:/ruby/lib/ruby/1.8/net/protocol.rb:206:in `old_open'
> from d:/ruby/lib/ruby/1.8/net/smtp.rb:393:in `do_start'
> from d:/ruby/lib/ruby/1.8/net/smtp.rb:378:in `start'
> from d:/ruby/lib/ruby/1.8/net/smtp.rb:316:in `start'
>
> --
> Posted via http://www.ruby-....
>
>