Subject Re: Can't connect to DB
Author rrokytskyy
> Will do. One question though. I already use log4j for some other apps
> like JGenerator. Each of my sites has a log4j.properties file that I
> place in each sites WEB-INF/classes folder.
> Along with the main prop file that lives with JGenerator in it's
> install dir.
>
> I am not very familiar with log4j yet, so without holding my hand to
> much. :)
>
> How do I use/initialize it with the JDBC driver.
>
> I have not seen any prop files so far, so I assume they are in the
> jar or something?

Yes, in firebirdsql.jar. However I suspect that log4j will pick up the
first one from classpath, so that might be one you already have.

If you want driver's log messages to go into one file and your
JGenerator & Co. to another, you need to put into your log4j.properties:

log4j.category.org.firebirdsql=debug,fbsql

log4j.appender.fbsql=org.apache.log4j.FileAppender
log4j.appender.fbsql.File=/var/log/firebirdsql.log
log4j.appender.fbsql.layout=org.apache.log4j.PatternLayout
log4j.appender.fbsql.layout.ConversionPattern=[%c{1},%p] %m%n
log4j.appender.Dfbsql.Append=true

Best regards,
Roman Rokytskyy