设为首页 收藏本站
查看: 1064|回复: 0

[经验分享] 用AWStats分析WMS服务器日志

[复制链接]

尚未签到

发表于 2015-11-27 13:42:57 | 显示全部楼层 |阅读模式
  1- If your Windows Media / Darwin streaming Server version allows it, setup your log format to write the following fields:
  如果你的WMS版本允许设置日志的格式,可以把日专设为下列格式:

  • c-ip
  • date
  • time
  • cs-uri-stem
  • c-starttime
  • x-duration
  • c-rate
  • c-status
  • c-playerid
  • c-playerversion
  • c-playerlanguage
  • cs(User-Agent)
  • cs(Referer)
  • c-hostexe
  • c-hostexever
  • c-os
  • c-osversion
  • c-cpu
  • filelength
  • filesize
  • avgbandwidth
  • protocol
  • transport
  • audiocodec
  • videocodec
  • channelURL
  • sc-bytes
  To make the change effective, stop your server, remove old log files and restart the server.
  为了使设置生效,把WMS服务停止,删除旧的日志文件,然后重新启动服务器   
Listen to streaming files and check that your new log file looks like this:
  查看一个流媒体文件,然后看一下新的日志文件,它看起来是下面这样:

  • 80.223.91.37 2002-10-08 14:18:58 mmst://mydomain.com/mystream 0 106 1 200 {F4A826EE-FA46-480F-A49B-76786320FC6B} 8.0.0.4477 fi-FI - - wmplayer.exe 8.0.0.4477 Windows_2000 5.1.0.2600 Pentium 0 0 20702 mms TCP Windows_Media_Audio_9 - - 277721
  If your Windows Media/Darwin Streaming Server version does not allow to define your log format:
  如果你的WMS的版式本不允许你自定义日志格式:
Just follow instructions in step 2 directly but use the log format string found in first lines of your log files (Just after the "#Fields:" string) as value for AWStats LogFormat parameter. For example, you could have a LogFormat defined like this:
  那你就直接进入第二步,分析器将使用日志文件的第一行内容(在"#Fields:"之后的内容)作为日志格式参数,例如你可能在配置文件中的LogFormat有下面这样定义:
  LogFormat="c-ip date time c-dns cs-uri-stem c-starttime x-duration c-rate c-status c-playerid c-playerversion c-playerlanguage cs(User-Agent) cs(Referer) c-hostexe c-hostexever c-os c-osversion c-cpu filelength filesize avgbandwidth protocol transport audiocodec videocodec channelURL sc-bytes c-bytes s-pkts-sent c-pkts-received c-pkts-lost-client c-pkts-lost-net c-pkts-lost-cont-net c-resendreqs c-pkts-recovered-ECC c-pkts-recovered-resent c-buffercount c-totalbuffertime c-quality s-ip s-dns s-totalclients s-cpu-util"
  This means you don't use the AWStats tags but AWStats can often also understand all the IIS and/or Windows Media Server tags.
这就代表你不使用awstats标记,但awstats通常能理解所有的IIS和WMS标记。
  2- Then setup AWStats to analyze your Media Server log:
Copy config awstats.model.conf file to "awstats.mediaserver.conf".
Modify this new config file:
  下面就来设置配置文件来分析WMS日志:
  从awstats.model.conf 文件复制一个新的文件,可以起名为"awstats.mediaserver.conf"
  修改新的配置文件:

  • LogFile="/pathtomediaserver/mediaserverlog"
  • LogType=S
  • LogFormat="c-ip date time cs-uri-stem c-starttime x-duration c-rate c-status c-playerid c-playerversion c-playerlanguage cs(User-Agent) cs(Referer) c-hostexe c-hostexever c-os c-osversion c-cpu filelength filesize avgbandwidth protocol transport audiocodec videocodec channelURL sc-bytes"
  • DecodeUA=1
  • ShowMenu=1
  • ShowSummary=UHB
  • ShowMonthStats=UHB
  • ShowDaysOfMonthStats=HB
  • ShowDaysOfWeekStats=HB
  • ShowHoursStats=HB
  • ShowDomainsStats=HB
  • ShowHostsStats=HBL
  • ShowAuthenticatedUsers=0
  • ShowRobotsStats=0
  • ShowEMailSenders=0
  • ShowEMailReceivers=0
  • ShowSessionsStats=0
  • ShowPagesStats=PB
  • ShowFileTypesStats=HB
  • ShowFileSizesStats=0
  • ShowBrowsersStats=1
  • ShowOSStats=1
  • ShowOriginStats=H
  • ShowKeyphrasesStats=0
  • ShowKeywordsStats=0
  • ShowMiscStats=0
  • ShowHTTPErrorsStats=1
  • ShowSMTPErrorsStats=0
  Now you can use AWStats as usual (run the update process and read statistics).
现在你就可以使用AWStats来分析WMS日志了
  
原文参见:http://awstats.sourceforge.net/docs/awstats_faq.html#MEDIASERVER
  
  

  
  

运维网声明 1、欢迎大家加入本站运维交流群:群②:261659950 群⑤:202807635 群⑦870801961 群⑧679858003
2、本站所有主题由该帖子作者发表,该帖子作者与运维网享有帖子相关版权
3、所有作品的著作权均归原作者享有,请您和我们一样尊重他人的著作权等合法权益。如果您对作品感到满意,请购买正版
4、禁止制作、复制、发布和传播具有反动、淫秽、色情、暴力、凶杀等内容的信息,一经发现立即删除。若您因此触犯法律,一切后果自负,我们对此不承担任何责任
5、所有资源均系网友上传或者通过网络收集,我们仅提供一个展示、介绍、观摩学习的平台,我们不对其内容的准确性、可靠性、正当性、安全性、合法性等负责,亦不承担任何法律责任
6、所有作品仅供您个人学习、研究或欣赏,不得用于商业或者其他用途,否则,一切后果均由您自己承担,我们对此不承担任何法律责任
7、如涉及侵犯版权等问题,请您及时通知我们,我们将立即采取措施予以解决
8、联系人Email:admin@iyunv.com 网址:www.yunweiku.com

所有资源均系网友上传或者通过网络收集,我们仅提供一个展示、介绍、观摩学习的平台,我们不对其承担任何法律责任,如涉及侵犯版权等问题,请您及时通知我们,我们将立即处理,联系人Email:kefu@iyunv.com,QQ:1061981298 本贴地址:https://www.yunweiku.com/thread-144146-1-1.html 上篇帖子: AWStats 7.0 发布, Linux下的安装配置使用备忘 下篇帖子: Linux---AWStats日志挖掘
您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

扫码加入运维网微信交流群X

扫码加入运维网微信交流群

扫描二维码加入运维网微信交流群,最新一手资源尽在官方微信交流群!快快加入我们吧...

扫描微信二维码查看详情

客服E-mail:kefu@iyunv.com 客服QQ:1061981298


QQ群⑦:运维网交流群⑦ QQ群⑧:运维网交流群⑧ k8s群:运维网kubernetes交流群


提醒:禁止发布任何违反国家法律、法规的言论与图片等内容;本站内容均来自个人观点与网络等信息,非本站认同之观点.


本站大部分资源是网友从网上搜集分享而来,其版权均归原作者及其网站所有,我们尊重他人的合法权益,如有内容侵犯您的合法权益,请及时与我们联系进行核实删除!



合作伙伴: 青云cloud

快速回复 返回顶部 返回列表