• Post Reply Bookmark Topic Watch Topic
  • New Topic

log4j Output to Console and File

 
JLS Steff
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
log4j runs great and builds a log flie.
I want the same log entries to echo to the screen as well as have them written to a file.

I can't find a way to do this.
 
Manuel DeAngelo
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Just create 2 appenders (1 file, 1 stdout), this should be working fine.

If you need more help, it will be useful to know how you configure log4j (property file, xml file, in Java code).

regards, Manuel
 
Don't get me started about those stupid light bulbs.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!