Re: UTL_SMTP???

From: Rauf Sarwar <rsarwar_at_ifsna.com>
Date: 3 Jul 2002 08:33:36 -0700
Message-ID: <c2d690f2.0207030733.36afb4c4_at_posting.google.com>


"REM" <ilica.brnadic_at_zg.hinet.hr> wrote in message news:<aft2au$dos6$1_at_as201.hinet.hr>...
> I have started some procedure with using UTL_SMTP package on WIN2000.
> I put "localhost" for smtp_server but what I need to put for mail name. I
> always have next error messages:
> SQL> exec mail_files(from_name => 'oracle', to_name =>
> 'ilica.brnadic_at_zg.hinet.hr', subject => '
> A test', message => 'A test message', filename1 => 'g:\oracle\logs\1.txt',
> filename2 => 'g:\oracle
> \logs\2.txt');
> BEGIN mail_files(from_name => 'oracle', to_name =>
> 'ilica.brnadic_at_zg.hinet.hr', subject => 'A te
>
> *
> ERROR at line 1:
> ORA-20002: 550 5.7.1 Unable to relay for ilica.brnadic_at_zg.hinet.hr
> ORA-06512: at "SYS.UTL_SMTP", line 86
> ORA-06512: at "SYS.UTL_SMTP", line 223
> ORA-06512: at "SYSTEM.MAIL_FILES", line 140
> ORA-06512: at line 1
>
> --
> with regards,
>
> ilica
>
> _________
>
> "If A is a success in life, then A equals x plus y plus z. Work is x; y is
> play; and z is keeping your mouth shut."

I would suggest that you familiarize yourself with SMTP protocol (RFC 2821) and the return codes before using UTL_SMTP. Generally the return code that you recieved 550

> ORA-20002: 550 5.7.1 Unable to relay for ilica.brnadic_at_zg.hinet.hr

means that the address specified in RCPT: or TO: field is invalid. There could also be other reasons for this error. i.e. Your SMTP server mail relaying settings, In domain out of domain delivery etc. Before anything else, use a valid email address in FROM: field. Maybe your SMTP server is trying to authenticate a sender and cannot do so with "oracle". Read more about SMTP (RFC 2821) at http://www.cis.ohio-state.edu/cgi-bin/rfc/rfc2821.html#sec-3.5

HTH
//Rauf Sarwar Received on Wed Jul 03 2002 - 17:33:36 CEST

Original text of this message