<?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: Splunk Query in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Splunk-Query/m-p/557541#M158338</link>
    <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/163730"&gt;@venkatasri&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;Just found the&amp;nbsp;&lt;SPAN&gt;logs associated to User.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;index=main sourcetype="activedirectory". I want to add IP Address column as well but couldn't find in interesting fields. please help us to do this.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="rahul2gupta_0-1624949423985.png" style="width: 400px;"&gt;&lt;img src="https://community.splunk.com/t5/image/serverpage/image-id/14870i70D435ED8A5BF2DE/image-size/medium?v=v2&amp;amp;px=400" role="button" title="rahul2gupta_0-1624949423985.png" alt="rahul2gupta_0-1624949423985.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;We can only fetch last 14 days events but I checked the configuration of index=main and the retention period was 6 months . Also, please help me to understand this.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Tue, 29 Jun 2021 06:53:45 GMT</pubDate>
    <dc:creator>rahul2gupta</dc:creator>
    <dc:date>2021-06-29T06:53:45Z</dc:date>
    <item>
      <title>Splunk Query</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Splunk-Query/m-p/556647#M158093</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/161352"&gt;@gcusello&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Can you please help me to design a Splunk query to show whether a particular user has been coming into the office at Mascot (and/ or Erskine Park), or otherwise working from home (or elsewhere).&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;I'd like to structure the results to show a table listing logon time and IP address - like this:&lt;/SPAN&gt;&lt;/P&gt;&lt;PRE&gt; Workstation&amp;nbsp;&amp;nbsp;&amp;nbsp; Last Login&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; User&lt;/PRE&gt;&lt;PRE&gt; 10.11.12.13&amp;nbsp;&amp;nbsp;&amp;nbsp; 15-11-01 10:00:00&amp;nbsp;&amp;nbsp; user1&lt;/PRE&gt;&lt;PRE&gt; 10.12.13.14&amp;nbsp;&amp;nbsp;&amp;nbsp; 15-11-01 15:34:02&lt;/PRE&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Rahul&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 22 Jun 2021 09:06:28 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Splunk-Query/m-p/556647#M158093</guid>
      <dc:creator>rahul2gupta</dc:creator>
      <dc:date>2021-06-22T09:06:28Z</dc:date>
    </item>
    <item>
      <title>Re: Splunk Query</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Splunk-Query/m-p/556651#M158095</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/222802"&gt;@rahul2gupta&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;I'd like to help you, but youshould explain how can we define the location of a user, the only way I can see (tell me if there's something helpful else ) is the IP address:&lt;/P&gt;&lt;P&gt;e.g.&lt;/P&gt;&lt;P&gt;if IP address is 10.11.*.* the location is&amp;nbsp;&lt;SPAN&gt;Mascot &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;if IP address is 10.12.*.* the location is Erskine Park,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;otherwise is outside&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;can this condition to be correct?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;if this is the condition to define the user location, you can use a simple if or case condition in an eval command, something like this:&lt;/SPAN&gt;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;your_search
| eval location=if(substr(Workstation,1,5)="10.11","Mascot",if(substr(Workstation,1,5)="10.12","Erskine Park","Outside")), "Last Login"=strftime(_time,"%Y-%m-%d %H:%M:%S")
| table Workstation "Last Login" User&lt;/LI-CODE&gt;&lt;P&gt;Ciao.&lt;/P&gt;&lt;P&gt;Giuseppe&lt;/P&gt;</description>
      <pubDate>Tue, 22 Jun 2021 09:21:24 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Splunk-Query/m-p/556651#M158095</guid>
      <dc:creator>gcusello</dc:creator>
      <dc:date>2021-06-22T09:21:24Z</dc:date>
    </item>
    <item>
      <title>Re: Splunk Query</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Splunk-Query/m-p/557496#M158331</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/161352"&gt;@gcusello&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;You mentioned Your_search in the query that you provided but I'm not sure what to use in my search as user&amp;nbsp; has just asked &lt;SPAN&gt;to show a user’s working location. Can you please me on this.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;I used index = security sourcetype=history* but it didn't helped me.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="rahul2gupta_0-1624932475318.png" style="width: 400px;"&gt;&lt;img src="https://community.splunk.com/t5/image/serverpage/image-id/14858iA8C8832176D77DC8/image-size/medium?v=v2&amp;amp;px=400" role="button" title="rahul2gupta_0-1624932475318.png" alt="rahul2gupta_0-1624932475318.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Rahul Gupta&lt;/P&gt;</description>
      <pubDate>Tue, 29 Jun 2021 02:08:13 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Splunk-Query/m-p/557496#M158331</guid>
      <dc:creator>rahul2gupta</dc:creator>
      <dc:date>2021-06-29T02:08:13Z</dc:date>
    </item>
    <item>
      <title>Re: Splunk Query</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Splunk-Query/m-p/557501#M158333</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/222802"&gt;@rahul2gupta&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;As&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/161352"&gt;@gcusello&lt;/a&gt;&amp;nbsp;mentioned there should be some data in your logs associated to User being already logged in from a place. You have to dig through logs under the index you mentioned to find the location/address/IP from the user logged in. Alternatively you can provide the sample events how they looks like as we do not have insights into your data.&lt;/P&gt;&lt;P&gt;The data could be sensitive to your company confidential then you have to mask/alter it before you share here for your confidentiality.&lt;/P&gt;</description>
      <pubDate>Tue, 29 Jun 2021 02:17:40 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Splunk-Query/m-p/557501#M158333</guid>
      <dc:creator>venkatasri</dc:creator>
      <dc:date>2021-06-29T02:17:40Z</dc:date>
    </item>
    <item>
      <title>Re: Splunk Query</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Splunk-Query/m-p/557541#M158338</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/163730"&gt;@venkatasri&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;Just found the&amp;nbsp;&lt;SPAN&gt;logs associated to User.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;index=main sourcetype="activedirectory". I want to add IP Address column as well but couldn't find in interesting fields. please help us to do this.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="rahul2gupta_0-1624949423985.png" style="width: 400px;"&gt;&lt;img src="https://community.splunk.com/t5/image/serverpage/image-id/14870i70D435ED8A5BF2DE/image-size/medium?v=v2&amp;amp;px=400" role="button" title="rahul2gupta_0-1624949423985.png" alt="rahul2gupta_0-1624949423985.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;We can only fetch last 14 days events but I checked the configuration of index=main and the retention period was 6 months . Also, please help me to understand this.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 29 Jun 2021 06:53:45 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Splunk-Query/m-p/557541#M158338</guid>
      <dc:creator>rahul2gupta</dc:creator>
      <dc:date>2021-06-29T06:53:45Z</dc:date>
    </item>
  </channel>
</rss>

