+1

That could be nice if that configuration option could be included in the 
distribution, because when you run OpenSim in something like "production" mode, 
your log files are growing so fast that you could get some performances issues 
writing in them.

I'm using such configuration options for a very very long time and it's very 
useful.

Regards.
Ursula.

----- Mail Original -----
De: "Mic Bowman" <[email protected]>
À: [email protected], [email protected]
Envoyé: Mercredi 20 Janvier 2010 09h03:01 GMT +01:00 Amsterdam / Berlin / Berne 
/ Rome / Stockholm / Vienne
Objet: [Opensim-users] configuring the log files


a discussion on the opensim IRC today left me wondering if most people are 
missing information on configuring the logging in OpenSim. if you're running a 
simulator you've probably run across the OpenSim.exe.config file. and possibly 
even changed the logging level from Debug to something less verbose. i thought 
i'd pass on another tip... you can set up log file rotation by adding another 
appender to the configuration (this gets around the problem of having *really* 
big OpenSim.log files lying around). add the following just after the close tag 
("</appender>") for the "LogFileAppender": 

<appender name="LogFileRotate" type="log4net.Appender.RollingFileAppender"> 
<file value="OpenSim.log-" /> 
<rollingstyle value="Date" /> 
<appendToFile value="true" /> 
<maximumFileSize value="500KB" /> 
<maxSizeRollBackups value="5" /> 
<staticlogfilename value="false" /> 
<datePattern value="yyyy-MM-dd" /> 
<layout type="log4net.Layout.PatternLayout"> 
<conversionPattern value="%date{HH:mm:ss} %-5level - %logger %message%newline" 
/> 
</layout> 
</appender> 

and then add change the root tag like this: 

<root> 
<level value="DEBUG" /> 
<appender-ref ref="Console" /> 
<appender-ref ref="LogFileRotate" /> 
</root> 

that will create the log files of the form OpenSim.log-yyyy-mm-dd with a 
maximum size of 500KB. we run multiple simulators & put all our logs into a 
single directory by changing the <file> tag to point to the log directory. 

this configuration was inspired by the examples in the log4net wiki: 
http://logging.apache.org/log4net/release/config-examples.html 

--mic 


_______________________________________________
Opensim-users mailing list
[email protected]
https://lists.berlios.de/mailman/listinfo/opensim-users
_______________________________________________
Opensim-users mailing list
[email protected]
https://lists.berlios.de/mailman/listinfo/opensim-users

Reply via email to