logging-log4cxx-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Lennart Goedhart" <lenn...@omnibase.com.au>
Subject ODBCAppender on Linux
Date Tue, 18 May 2004 23:52:52 GMT
I'm using log4cxx on both Windows and Linux.
Here's my conf file:
------------------------------------------------
log4j.rootLogger=INFO, logFile, database

# Local log file settings for the application
log4j.appender.logFile=org.apache.log4j.RollingFileAppender
log4j.appender.logFile.File=server.log
log4j.appender.logFile.MaxFileSize=100KB
# Keep one backup file
log4j.appender.logFile.MaxBackupIndex=1
log4j.appender.logFile.layout=org.apache.log4j.PatternLayout
log4j.appender.logFile.layout.ConversionPattern=%5p %d [%t] - %m%n

# Database appender (using PostgreSQL ODBC)
log4j.appender.database=org.apache.log4j.ODBCAppender
log4j.appender.database.URL=postgresql
log4j.appender.database.layout=org.apache.log4j.PatternLayout
log4j.appender.database.layout.ConversionPattern=%5p %d %m%n
log4j.appender.database.sql=INSERT INTO events ( level, date, message )
VALUES ('%5p', '%d', '%m%n' )
------------------------------------------------

This works perfectly under Windows.
On Linux, I get the following output when I run my app:

Class 'org.apache.log4j.ODBCAppender' not found
Could not instantiate appender named "database"

When I configured on Linux, I ran:
# ./configure --prefix=/usr --enable-unicode -with-ODBC=unixODBC
When configure runs, it finds the unixODBC headers okay.

Am I missing something else?

Regards
Lennart


Mime
View raw message