Skip to content
Permalink
Browse files

logging to file

  • Loading branch information...
ivangiangreco committed Aug 17, 2018
1 parent aa15017 commit 21e3f17b1d24586a2770de803a73064b00d1b0e4
Showing with 7 additions and 1 deletion.
  1. +7 −1 conf/log4j.properties
@@ -16,12 +16,18 @@
#

# Set everything to be logged to the console
log4j.rootCategory=ERROR, console
log4j.rootCategory=ERROR, console, file
log4j.appender.console=org.apache.log4j.ConsoleAppender
log4j.appender.console.target=System.err
log4j.appender.console.layout=org.apache.log4j.PatternLayout
log4j.appender.console.layout.ConversionPattern=%d{yy/MM/dd HH:mm:ss} %p %c{1}:%m%n

log4j.appender.file=org.apache.log4j.RollingFileAppender
log4j.appender.file.File=/var/log/adampro/log
log4j.appender.file.maxFileSize=20MB
log4j.appender.file.layout=org.apache.log4j.PatternLayout
log4j.appender.file.layout.ConversionPattern=%d{yy/MM/dd HH:mm:ss} %p %c{1}:%m%n

# Set the default spark-shell log level to WARN. When running the spark-shell, the
# log level for this class is used to overwrite the root logger's log level, so that
# the user can have different defaults for the shell and regular Spark apps.

0 comments on commit 21e3f17

Please sign in to comment.
You can’t perform that action at this time.