in reply to Re: email through Exchange server using StrawberryPerl
in thread email through Exchange server using StrawberryPerl

Thank you roboticus, that solved the "method" problem. Now I get

'connect() failed:

Does this mean the code couldn't get through port 25? Do I now need to talk to my company's mail server IT people to find out the parameters to get out?

  • Comment on Re^2: email through Exchange server using StrawberryPerl

Replies are listed 'Best First'.
Re^3: email through Exchange server using StrawberryPerl
by soonix (Chancellor) on Sep 30, 2014 at 21:58 UTC
    'connect() failed:

    The more important part of the error message is probably after the colon...

    Exchange can speak SMTP on port 25. Might be requiring authentication (user name and password). Depends on how it is configured.

    Might as well be a typo in the host name or something completely different...

    Read the complete error message - at least the part of it that consists of words :-)

    Even if you overcome this connect error, the next hurdle might be "relaying denied", and after you solved that, maybe comes "unknown recipient". So, at least in the "relaying denied" case, you will have to ask your IT people.

      I'm sorry, How do I read anything after the :? The error message is -3 which is "connect() failed:" Is there another command to see the rest of the message?

      Thanks,

      Steve

        That's tough. I had expected that $Mail::Sender::Error would be more informative.

        However, if I read Mail::Sender right, you could
        die $sender->{'error_msg'}
        or alternatively add
        debug => 'c:/temp/mailsendertest.log'
        into your constructor. (Attention: the doc says it will be overwritten, not appended)
Re^3: email through Exchange server using StrawberryPerl
by roboticus (Chancellor) on Oct 01, 2014 at 00:04 UTC

    sgmansell:

    Yes, that's what it means. As soonix states, the message after the colon should give you (or your EMail administrator) some further information on it. Because of the spam problem, many places lock out port 25, require authentication and/or alternate protocols. You'll definitely want to talk with your mail server IT team to help figure out what you need to do.

    ...roboticus

    When your only tool is a hammer, all problems look like your thumb.