Below is a configuration file for log4j. Log4j2 can use the same syntax, but there are different appender classes:
log4j.rootLogger=INFO, FOO
## ConsoleAppender
log4j.appender.CA=org.apache.log4j.ConsoleAppender
log4j.appender.CA.layout=org.apache.log4j.PatternLayout
log4j.appender.CA.layout....