I found that only fatal and error priority constaints generate an e-mail.
It does not matter that you have log4j.rootCategory=INFO, SMTPTest, info and
warn priority constraints will not generate an e-mail.  Try generating a
fatal or error priority constraint message.

> -----Original Message-----
> From: Pounder, Anthony [SMTP:[EMAIL PROTECTED]]
> Sent: Friday, April 19, 2002 9:49 AM
> To:   'Log4J Users List'
> Subject:      RE: log4j.properties file
> 
> Pardon me for jumping in but.......
> 
> Hi All
> I've been lurking on this mailing list from some time but have just got
> around to making use of Log4J.  Can anyone help me with this problem:
> 
> After receiving the earlier email about setting up email notification I
> have
> my log4j.properties file set to:
> log4j.rootCategory=INFO, SMTPTest
> 
> log4j.appender.SMTPTest=org.apache.log4j.net.SMTPAppender
> log4j.appender.SMTPTest.layout=org.apache.log4j.PatternLayout
> log4j.appender.SMTPTest.layout.ConversionPattern=%d %-5p [%t] - %m%n
> [EMAIL PROTECTED]
> log4j.appender.SMTPTest.SMTPHost=10.173.250.58
> log4j.appender.SMTPTest.Subject=SMTP Test
> [EMAIL PROTECTED]
> log4j.appender.SMTPTest.BufferSize=1
> 
> and using log4j.debug=true
> 
> shows me:
> 
> log4j: Parsing appender named "SMTPTest".
> log4j: Parsing layout options for "SMTPTest".
> log4j: Setting property [conversionPattern] to [%d %-5p [%t] - %m%n].
> log4j: End of parsing for "SMTPTest".
> log4j: Setting property [SMTPHost] to [10.173.250.58].
> log4j: Setting property [subject] to [SMTPTest].
> log4j: Setting property [from] to [[EMAIL PROTECTED]].
> log4j: Setting property [to] to [[EMAIL PROTECTED]].
> log4j: Setting property [bufferSize] to [1].
> log4j: Parsed "SMTPTest" options.
> 
> so my configuration is being picked, however no email.
> 
> My platform is Solaris 8 and I can telnet to my host in port 25 and use
> MAIL
> FROM:, RCPT TO etc. to send an email.
> 
> Do I need to specify a port to Log4j, append smtp to the ip address?
> 
> Cheers
> 
> Anthony Pounder
> Nottingham - UK
> 
> -----Original Message-----
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
> Sent: 18 April 2002 20:26
> To: Log4J Users List
> Cc: [EMAIL PROTECTED]
> Subject: Re: log4j.properties file
> 
> 
> Good Luck.  Just replace the To, Host, and From with your valid entries.
> 
> log4j.rootCategory=info, A1, SMTPTest
> 
> # A1 writes to the file "ldh".
> log4j.appender.A1=org.apache.log4j.DailyRollingFileAppender
> log4j.appender.A1.File=e:\\ldh\\ldh.log
> log4j.appender.A1.layout=org.apache.log4j.PatternLayout
> log4j.appender.A1.layout.ConversionPattern=%d %-5p [%t] - %m%n
> 
> # SMTP appender
> log4j.appender.SMTPTest=org.apache.log4j.net.SMTPAppender
> log4j.appender.SMTPTest.layout=org.apache.log4j.PatternLayout
> log4j.appender.SMTPTest.layout.ConversionPattern=%d %-5p [%t] - %m%n
> log4j.appender.SMTPTest.To=[email address]
> log4j.appender.SMTPTest.SMTPHost=[smtp mail server address]
> log4j.appender.SMTPTest.Subject=Branch Loan Printing System Error
> log4j.appender.SMTPTest.From=[from address]
> log4j.appender.SMTPTest.BufferSize=1
> 
> 
> =======================================================================
> Information in this email and any attachments are confidential, and may
> not be copied or used by anyone other than the addressee, nor disclosed
> to any third party without our permission.  There is no intention to
> create any legally binding contract or other commitment through the use
> of this email.
> 
> Experian Limited (registration number 653331).  
> Registered office: Talbot House, Talbot Street, Nottingham NG1 5HF
> 
> --
> To unsubscribe, e-mail:
> <mailto:[EMAIL PROTECTED]>
> For additional commands, e-mail:
> <mailto:[EMAIL PROTECTED]>

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to