Creating a centralized exception logging system
I'm planning to create a centralized log system for my application. My application contains several separate applications what work on different client machines. I was planning to start using Exception Handling block from Enterprise Library. It's looks really great and does exactly what I need by creating event logs from the exceptions. The question now is that I would like to create these logs into one place. So when the client computers are in the same domain then 开发者_Go百科they would create the logs into the domain controller event logs. Has anybody seen any good articles about this or have any other good ideas about creating a centralized log system?
EDIT: Im talking about C# and the Windows OS-s.
With ELMAH, I found this article which talks about logging from multiple app into one single place in SQL Server.
If you're willing to use log4net, then you can use RemotingAppender or UDPAppender to log to a central server.
You can also setup a Syslog server, Kiwi is one for windows.
Also, some more third party solutions like Exceptioneer which integrates with ELMAH or services offering such as BugCollect
It would probably be helpful to know what OS and programming language you're using. Rails apps, for example, can use services like Airbrake and Exceptional to track exceptions. There may be a service like this for whatever language you're using as well.
If your application is set up to log to syslog, there are lots of interesting ways to set up various system loggers to log to a central host. FreeBSD's syslog can be easily configured to log to a remote host, as can Debian's. Most Unixes probably have information about this; this article discusses many options and alternatives under Linux. I have heard very good things about Splunk. It's not intended for exception logging specifically, but it is supposed to apply some intelligence in categorizing problems and giving you aggregate data about how frequently certain types of problems occur and that kind of thing.
Hope this helps!
If you could narrow your OS'es to Win7 and Win 2008 R2 ... ;-)
There is a built-in functionality of forwarding and collecting events (Win7, Win2008 R2 and probably: Win 2008 R1, Vista): http://www.sysadminlab.net/windows/forward-event-log-from-several-server-to-a-central-windows-2008-server
There are some differences for Win 2008 R1 here (in community comment): http://technet.microsoft.com/en-us/library/cc748890.aspx
BTW. I didn't try it in in practice but in general I see HUGE improvements in Windows 2008 R2 logging, diagnostics and the like. Microsoft does much good in these areas lately.
精彩评论