|
From: Leif M. <le...@ta...> - 2004-06-21 02:34:03
|
Martin, Chow, Martin wrote: > I am trying to configure a couple of things here. But it does not seem > to take effect when I restart the service. I try different > combinations to see if which properties will take effect after I > restart the service. > > 1) I try to change the log file wrapper.logfile=../log/wrapper.log to > try to tell the wrapper to write the log file in the directory called > “log”. Every time I run the service, the wrapper creates a default log > file in the same directory as my wrapper executable. > If the Wrapper is unable to write to the specified log file for any reason then it will fall back to writing to a file called wrapper.log in the same directory as the Wrapper.exe is located. This is the correct behavior. There are a number of reasons why the Wrapper may not be able to write to the ../log/ directory. 1) Make sure the directory exists. This relative location should be relative to the location of the Wrapper.exe 2) Does this work correctly when you are running in console mode rather than as a service? If so, it is possible that this is a permission problem. Make sure that you have not configured the log directory in such a way that the user running the Wrapper is not able to write to. By default, the Wrapper runs as the SYSTEM user when running as a service. > 2) Second, I try to limit the maximum size of my log file before a > roll over occurs. For example, wrapper.logfile.maxsize=285k. After the > default wrapper log is over 285kb, no new log file is created. The > size of my wrapper log will keep increasing until I decrease the > wrapper log. > This is actually the correct behavior given #1. The Wrapper will not attempt to do any log rolling of the fall back log file. That only works on the configured log file. > I did however, successfully configure the wrapper.console.format => > from wrapper.console.format=LPTM to wrapper.console.format=PM. The > format did change after I restart the service. > This format change works in the fall back file. > Therefore, I am sure my configuration is correct. Please suggest how I > can configure the rolling of the wrapper log (Problem 2), and also how > we can tell the wrapper to create the wrapper log in where we specify > (Problem 1). > > I have attached my configuration file for reference. > I only got the section where you are defining the logging. But from what I can see, everything looks ok. Once you solve #1, everything should start working correctly. Cheers, Leif |