<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: capturing windows failed login in Getting Data In</title>
    <link>https://community.splunk.com/t5/Getting-Data-In/capturing-windows-failed-login/m-p/68582#M13873</link>
    <description>&lt;P&gt;Hey,&lt;/P&gt;

&lt;P&gt;Can you post what your actual logs look like? I wrote the same report but used mvindex instead of coalesce as i was having an issue where the Account name field was listed more than once and i had to specify which one i needed.&lt;/P&gt;

&lt;P&gt;It looks like you are trying to combine two fields into one using coalesce. Try using case instead, example:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;eval UserName=case(k8cname!="", k8cname, User_Name!="", User_Name)
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;This takes field k8cname and User_Name and combines them into one field UserName. A little roundabout but works.&lt;/P&gt;

&lt;P&gt;I-Man&lt;/P&gt;</description>
    <pubDate>Mon, 28 Mar 2011 21:06:57 GMT</pubDate>
    <dc:creator>I-Man</dc:creator>
    <dc:date>2011-03-28T21:06:57Z</dc:date>
    <item>
      <title>capturing windows failed login</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/capturing-windows-failed-login/m-p/68581#M13872</link>
      <description>&lt;P&gt;I have been trying with the below query to capture the failed login attempts made on the windows servers.&lt;/P&gt;

&lt;P&gt;source="WinEventLog:Security" EventCode="4625" OR EventCode="539" OR EventCode="529" OR EventCode="531" eval User_Name=coalesce(User_Name,Account_Name) | stats count,list(User_Name)by host&lt;/P&gt;

&lt;P&gt;But the above query will give output as below-&lt;/P&gt;

&lt;P&gt;&lt;/P&gt;&lt;HR /&gt;&lt;P&gt;&lt;/P&gt;

&lt;P&gt;host           count     list(User_Name)   &lt;/P&gt;

&lt;P&gt;&lt;/P&gt;&lt;HR /&gt;&lt;P&gt;&lt;/P&gt;

&lt;P&gt;dc1server01      1       john 
                         john             &lt;/P&gt;

&lt;P&gt;It says count as 1 but in the list it gives username twice(john). I used dedup but i still i am not able to fix the issue.&lt;/P&gt;

&lt;P&gt;Can anyone please let me know the solution for this?      &lt;/P&gt;</description>
      <pubDate>Sun, 27 Mar 2011 13:30:33 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/capturing-windows-failed-login/m-p/68581#M13872</guid>
      <dc:creator>npandith</dc:creator>
      <dc:date>2011-03-27T13:30:33Z</dc:date>
    </item>
    <item>
      <title>Re: capturing windows failed login</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/capturing-windows-failed-login/m-p/68582#M13873</link>
      <description>&lt;P&gt;Hey,&lt;/P&gt;

&lt;P&gt;Can you post what your actual logs look like? I wrote the same report but used mvindex instead of coalesce as i was having an issue where the Account name field was listed more than once and i had to specify which one i needed.&lt;/P&gt;

&lt;P&gt;It looks like you are trying to combine two fields into one using coalesce. Try using case instead, example:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;eval UserName=case(k8cname!="", k8cname, User_Name!="", User_Name)
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;This takes field k8cname and User_Name and combines them into one field UserName. A little roundabout but works.&lt;/P&gt;

&lt;P&gt;I-Man&lt;/P&gt;</description>
      <pubDate>Mon, 28 Mar 2011 21:06:57 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/capturing-windows-failed-login/m-p/68582#M13873</guid>
      <dc:creator>I-Man</dc:creator>
      <dc:date>2011-03-28T21:06:57Z</dc:date>
    </item>
  </channel>
</rss>

