Advertisement
Guest User

nxlog

a guest
May 26th, 2015
221
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.05 KB | None | 0 0
  1. ## This is a sample configuration file. See the nxlog reference manual about the
  2. ## configuration options. It should be installed locally and is also available
  3. ## online at http://nxlog.org/nxlog-docs/en/nxlog-reference-manual.html
  4.  
  5. ## Please set the ROOT to the folder your nxlog was installed into,
  6. ## otherwise it will not start.
  7.  
  8. #define ROOT C:\Program Files\nxlog
  9. define ROOT C:\Program Files (x86)\nxlog
  10.  
  11. Moduledir %ROOT%\modules
  12. CacheDir %ROOT%\data
  13. Pidfile %ROOT%\data\nxlog.pid
  14. SpoolDir %ROOT%\data
  15. LogFile %ROOT%\data\nxlog.log
  16.  
  17. <Extension json>
  18. Module xm_json
  19. </Extension>
  20.  
  21. <Extension w3c>
  22. Module xm_csv
  23. Fields $date, $time, $s-ip, $cs-method, $cs-uri-stem, $cs-uri-query, $s-port, $cs-username, $c-ip, $csUser-Agent, $cs-Referer, $sc-status, $sc-substatus, $sc-win32-status, $time-taken
  24. FieldTypes string, string, string, string, string, string, integer, string, string, string, string, integer, integer, integer, integer
  25. Delimiter ' '
  26. QuoteChar '"'
  27. EscapeControl FALSE
  28. UndefValue -
  29. </Extension>
  30.  
  31. <Extension fileop>
  32. Module xm_fileop
  33. </Extension>
  34.  
  35. <Input internal>
  36. Module im_internal
  37. Exec to_json();
  38. </Input>
  39.  
  40. <Input eventlog>
  41. Module im_msvistalog
  42. Query <QueryList>\
  43. <Query Id="0">\
  44. <Select Path="Application">*</Select>\
  45. <Select Path="System">*</Select>\
  46. </Query>\
  47. </QueryList>
  48. Exec to_json();
  49. </Input>
  50.  
  51. <Input iis_1>
  52. Module im_file
  53. File "D:\\RT\\Logs\\Web Pages\\W3SVC1\\u_ex*"
  54. Exec file_write("C:\\Program Files (x86)\\nxlog\\data\\nxlog_output.log",$raw_event);
  55. Exec if $raw_event =~ /^#/ drop(); \
  56. else \
  57. { \
  58. w3c->parse_csv(); \
  59. $EventTime = parsedate($date + " " + $time); \
  60. to_json (); \
  61. }
  62.  
  63. </Input>
  64.  
  65. <Input iis_2>
  66. Module im_file
  67. File "D:\\RT\\Logs\\Web Pages\\W3SVC2\\u_ex*"
  68. Exec file_write("C:\\Program Files (x86)\\nxlog\\data\\nxlog_output.log",$raw_event);
  69. Exec if $raw_event =~ /^#/ drop(); \
  70. else \
  71. { \
  72. w3c->parse_csv(); \
  73. $EventTime = parsedate($date + " " + $time); \
  74. to_json (); \
  75. }
  76. </Input>
  77.  
  78. <Output out>
  79. Module om_tcp
  80. Host 172.16.1.119
  81. Port 3515
  82. </Output>
  83.  
  84. <Output out_iis>
  85. Module om_tcp
  86. Host 172.16.1.119
  87. Port 3518
  88. </Output>
  89.  
  90. <Route 1>
  91. Path eventlog, internal => out
  92. </Route>
  93.  
  94. <route 2>
  95. path iis_1,iis_2 => out_iis
  96. </route>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement