Hi Erick, 1> how did you install/run your Solr? As a service or "regular"? See the reference guide, "Permanent Logging Settings" for some info on the difference there.
What is the difference between "regular" or "service"? 2> what does your log4j.properties file look like? Here are the contents in the log4j.properties file: # Logging level solr.log=logs log4j.rootLogger=INFO, file, CONSOLE log4j.appender.CONSOLE=org.apache.log4j.ConsoleAppender log4j.appender.CONSOLE.layout=org.apache.log4j.PatternLayout log4j.appender.CONSOLE.layout.ConversionPattern=%-4r [%t] %-5p %c %x [%X{collection} %X{shard} %X{replica} %X{core}] \u2013 %m%n #- size rotation with log cleanup. log4j.appender.file=org.apache.log4j.RollingFileAppender log4j.appender.file.MaxFileSize=4MB log4j.appender.file.MaxBackupIndex=9 #- File to log to and log format #log4j.appender.file.File=${solr.log}/solr.log log4j.appender.file.File=C:/solr_logs/solr.log log4j.appender.file.layout=org.apache.log4j.PatternLayout log4j.appender.file.layout.ConversionPattern=%-5p - %d{yyyy-MM-dd HH:mm:ss.SSS}; [%X{collection} %X{shard} %X{replica} %X{core}] %C; %m\n log4j.logger.org.apache.zookeeper=WARN log4j.logger.org.apache.hadoop=WARN # set to INFO to enable infostream log messages log4j.logger.org.apache.solr.update.LoggingInfoStream=OFF I am not sure how best I can limit the size of the solr_logs directory. Does log4j come with a feature to remove old log files with a given retention period? Best regards, Adrian Liew -----Original Message----- From: Erick Erickson [mailto:erickerick...@gmail.com] Sent: Monday, August 10, 2015 11:36 PM To: solr-user@lucene.apache.org Subject: Re: Solr old log files are not archived or removed automatically. 1> how did you install/run your Solr? As a service or "regular"? See the reference guide, "Permanent Logging Settings" for some info on the difference there. 2> what does your log4j.properties file look like? Best, Erick On Mon, Aug 10, 2015 at 12:13 AM, Adrian Liew <adrian.l...@avanade.com> wrote: > Hi there, > > I am using Solr v.5.2.1 on my local machine. I realized that old log files > are not removed in a timely manner by log4j. The logs which I am referring to > are the log files that reside within solr_directory\server\logs. So far I > have previous two months' worth of log files accumulated in the log > directory. Consequently, this causes my directory grow to such large sizes. I > will need to manually remove the old log files which is undesirable. > > Is this is a bug with Solr or a missing configuration that needs to be set? > > As far as I know, all Solr Logging configuration is done in the > solr_directory\server\resources\log4j.properties > > Appreciate the soonest reply. > > Thanks.