English 中文(简体)
在WSS 3.0服务器上记录到ULS日志
原标题:
  • 时间:2009-03-30 13:59:45
  •  标签:

I have a scenario where I have WSS 3.0 only on a server and I would like to be able to log to the ULS log. In most cases, I have MOSS 2007 installed on the same server and can use the class/method Microsoft.Office.Server.Diagnostics.PortalLog.LogString but that is not an option in this case.

Have anyone else been able to successfully log to the ULS log on a WSS-only server? If not, do you use a logging component instead like log4net etc or how do you log? Logging to the ULS log would be strongly preferred.

TIA, Magnus

最佳回答

Microsoft has documented it with this example on MSDN

问题回答

I use log4net with the ULS LogAppender fromCodeplex: http://splog4net.codeplex.com/

The details on that are here: Link

And the log4net is here: http://logging.apache.org/log4net/index.html

我认为这是最好的解决方案,仅仅是因为我记录日志的位置和方式会因客户而异,而 log4net 让我能够轻松地重新配置。





相关问题
热门标签