Return-Path: Delivered-To: apmail-logging-log4j-user-archive@www.apache.org Received: (qmail 19209 invoked from network); 14 Jul 2005 17:44:10 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 14 Jul 2005 17:44:09 -0000 Received: (qmail 1017 invoked by uid 500); 14 Jul 2005 17:44:04 -0000 Delivered-To: apmail-logging-log4j-user-archive@logging.apache.org Received: (qmail 984 invoked by uid 500); 14 Jul 2005 17:44:04 -0000 Mailing-List: contact log4j-user-help@logging.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Help: List-Post: List-Id: "Log4J Users List" Reply-To: "Log4J Users List" Delivered-To: mailing list log4j-user@logging.apache.org Received: (qmail 961 invoked by uid 99); 14 Jul 2005 17:44:03 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 14 Jul 2005 10:44:03 -0700 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_HELO_PASS X-Spam-Check-By: apache.org Received-SPF: neutral (asf.osuosl.org: local policy) Received: from [128.32.61.106] (HELO calmail-fe2.berkeley.edu) (128.32.61.106) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 14 Jul 2005 10:44:01 -0700 Received: from [169.229.240.84] (account rusty@calmail.berkeley.edu [169.229.240.84] verified) by calmail-fe2.berkeley.edu (CommuniGate Pro SMTP 4.2.6) with ESMTP-TLS id 121292920 for log4j-user@logging.apache.org; Thu, 14 Jul 2005 10:44:02 -0700 Message-ID: <42D6A461.6020507@grunt.berkeley.edu> Date: Thu, 14 Jul 2005 10:44:01 -0700 From: Rusty Wright Reply-To: rusty+commons@grunt.berkeley.edu Organization: UC Berkeley User-Agent: Mozilla Thunderbird 1.0 (Windows/20041206) X-Accept-Language: en-us, en MIME-Version: 1.0 To: log4j-user@logging.apache.org Subject: SMTPAppender help needed Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N I'm trying to use SMTPAppender but it's not sending me the email. I figured out that I need to add Sun's jaf.jar and activation.jar, so now it runs without any error. This is a standalone program that's packaged as a jar file. My smtp server is postfix. The CONS and FILE appenders are working. The program is using Commons net to do an ftp file upload. I'm running it with the command /usr/java/bin/java -Dlog4j.debug -jar /usr/local/cars/bin/cars.jar Following the config file is the debug output. Thanks. Here's my log4j.xml config file: Here's the output: log4j: Trying to find [properties/log4j.xml] using context classloader sun.misc.Launcher$AppClassLoader@133056f. log4j: Trying to find [log4j.xml] using context classloader sun.misc.Launcher$AppClassLoader@133056f. log4j: Trying to find [log4j.xml] using sun.misc.Launcher$AppClassLoader@133056f class loader. log4j: Trying to find [log4j.xml] using ClassLoader.getSystemResource(). log4j: Trying to find [log4j.properties] using context classloader sun.misc.Launcher$AppClassLoader@133056f. log4j: Trying to find [log4j.properties] using sun.misc.Launcher$AppClassLoader@133056f class loader. log4j: Trying to find [log4j.properties] using ClassLoader.getSystemResource(). log4j: Could not find resource: [null]. log4j: System property is :null log4j: Standard DocumentBuilderFactory search succeded. log4j: DocumentBuilderFactory is: com.sun.org.apache.xerces.internal.jaxp.DocumentBuilderFactoryImpl log4j: debug attribute= "null". log4j: Ignoring debug attribute. log4j: Threshold ="null". log4j: Retreiving an instance of org.apache.log4j.Logger. log4j: Setting [props.PropsBase] additivity to [true]. log4j: Level value for props.PropsBase is [warn]. log4j: props.PropsBase level set to WARN log4j: Class name: [org.apache.log4j.RollingFileAppender] log4j: Setting property [file] to [/var/tmp/cars.log]. log4j: Setting property [maxFileSize] to [300kb]. log4j: Setting property [maxBackupIndex] to [9]. log4j: Parsing layout of class: "org.apache.log4j.PatternLayout" log4j: Setting property [conversionPattern] to [%p: %d [%C %M] %m%n]. log4j: setFile called: /var/tmp/cars.log, true log4j: setFile ended log4j: Adding appender named [FILE] to category [props.PropsBase]. log4j: Level value for root is [debug]. log4j: root level set to DEBUG log4j: Class name: [org.apache.log4j.ConsoleAppender] log4j: Parsing layout of class: "org.apache.log4j.PatternLayout" log4j: Setting property [conversionPattern] to [%M %m%n]. log4j: Adding appender named [CONS] to category [root]. log4j: Adding appender named [FILE] to category [root]. log4j: Class name: [org.apache.log4j.net.SMTPAppender] log4j: Setting property [SMTPHost] to [localhost]. log4j: Setting property [from] to [CARS-Uploader]. log4j: Setting property [to] to [rusty]. log4j: Setting property [subject] to [CARS upload mail log]. log4j: Parsing layout of class: "org.apache.log4j.PatternLayout" log4j: Setting property [conversionPattern] to [%p: %d [%C %M] %m%n]. log4j: Adding appender named [MAIL] to category [root]. main start getting entries from db main finished getting entries from db main uploadName: 'rbs.q.carcyin.d050713.test1' connect 220-FTPD1 IBM FTP CS V1R4 at ironwood.Berkeley.EDU, 23:36:07 on 2005-07-13. connect 220 Connection will close if idle for more than 5 minutes. connect 230 WSS0RCW is logged on. Working directory is "WSS0RCW.". sendCarsData 200 Representation type is Ascii NonPrint sendCarsData 200 SITE command was accepted sendCarsData 125 Storing data set RBS.Q.CARCYIN.D050713.TEST1 sendCarsData sending file 'rbs.q.carcyin.d050713.test1' sendCarsData sent 1419 lines sendCarsData 125 Storing data set RBS.Q.CARCYIN.D050713.TEST1 disconnect logout disconnect disconnect --------------------------------------------------------------------- To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org For additional commands, e-mail: log4j-user-help@logging.apache.org