如何为ASP.NET应用程序创建应用程序日志 [英] How to create an Application Log for ASP.NET Application

查看:85
本文介绍了如何为ASP.NET应用程序创建应用程序日志的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述



我需要为我的ASP.NET应用程序创建日志,其中包括所有详细信息,例如谁登录服务器,他执行的所有事件是什么,他可用多长时间...等

我是否需要将用户的每个动作都输入到DATABASE中?
否则
还有其他简单的方法可以维护它吗?


请提出您的建议....



I need to Create Log for my ASP.NET application that includes all details like who is log on into server, what are all the events he does, how long he is available...etc

Am i need to make entry for each and every action of user into DATABASE ??
or else
Is there any other simple method to maintain it ?


Please give your suggestions....

推荐答案

是.
如果您没有输入适当的条目,您希望由谁来做?
Yes.
If you do not make the appropriate entries, who do you expect to do it?


您还可以使用log4Net之类的第三方工具在客户端进行登录.
You could also use a third party tool like log4Net to do logging on the client side.


对于数据库方面,在CP中可以找到许多文章.在这里你
用于Microsoft SQL的审核跟踪生成器 [使用触发器实施审计跟踪 [审核SQL Server 2008上的事件 [审核跟踪–跟踪数据库中的数据更改 [ MS SQL Server 2008上的审核 [五种记录方法 [
For Database side, In CP you can find many articles. Here you go
Audit Trail Generator for Microsoft SQL[^]
Implementing Audit Trail using Trigger[^]
Auditing events on SQL Server 2008[^]
Audit Trail – Tracing Data Changes in Database[^]
Audits on MS SQL Server 2008[^]

For application side you may use the below one
Five methods to Logging[^]


这篇关于如何为ASP.NET应用程序创建应用程序日志的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆