Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

UTL_MAIL: ORA-29279..... 501 badly formatted MAIL FROM user - no "<"

770728May 3 2010 — edited May 6 2010
Hi guys,

I’m trying to redesign a current process that requires a large amount of manual intervention. As such I’d like to utilise UTL_MAIL to send notifications of system events but have been unable to get it to execute on my dev database (installed on my local PC).

O/S ver:
Windows XP SP3

Oracle ver:

BANNER
Oracle Database 10g Enterprise Edition Release 10.2.0.3.0 - Prod
PL/SQL Release 10.2.0.3.0 - Production
CORE 10.2.0.3.0 Production
TNS for 32-bit Windows: Version 10.2.0.3.0 - Production
NLSRTL Version 10.2.0.3.0 - Production

I’ve configured the smtp_out_server parameter:

SQL> sho parameter smtp_out_server;

NAME TYPE VALUE
smtp_out_server string XXX.XXX.XXX.80:25

And installed the required Oracle built in packages:

SQL> @C:\oracle_builtins\utlmail.sql

Package created.
Synonym created.

SQL> @C:\oracle_builtins\prvtmail.plb

Package body created.
No errors.

I’ve compiled a simple test version of the code:

CREATE OR REPLACE PROCEDURE test_email IS
BEGIN
UTL_MAIL.send(sender => 'oracle.alerts@xyz.com',
recipients => 'operator@xyz.com',
subject => 'UTL_MAIL test subject',
message => 'UTL_MAIL test body');
END;
+/+

SQL> @C:\procs\email_proc.sql

Procedure created.

However when I execute it I get the attached error(s):

SQL> execute test_email ;
BEGIN test_email ; END;

*+
ERROR at line 1:
ORA-29279: SMTP permanent error: 501 badly formatted MAIL FROM user - no <
ORA-06512: at "SYS.UTL_SMTP", line 21
ORA-06512: at "SYS.UTL_SMTP", line 99
ORA-06512: at "SYS.UTL_SMTP", line 222
ORA-06512: at "SYS.UTL_MAIL", line 397
ORA-06512: at "SYS.UTL_MAIL", line 608
ORA-06512: at "SYS.TEST_EMAIL", line 3
ORA-06512: at line 1

I’ve also confirmed with our mail team that the sender is included in our firewall config and should not be being blocked……
Any ideas? Does the package produce any log files / alerts that I could check or is it possible to execute in a verbose mode so I can debug?

Thanks,
Chris
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Jun 3 2010
Added on May 3 2010
10 comments
3,684 views