<?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: Create a Splunk alert when a file size is below 10 bytes from a log file. in Alerting</title>
    <link>https://community.splunk.com/t5/Alerting/How-to-create-a-Splunk-alert-when-a-file-size-is-below-10-bytes/m-p/591539#M13697</link>
    <description>&lt;P&gt;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/163730"&gt;@venkatasri&lt;/a&gt;&amp;nbsp;Hope you got my requirement? Any suggestions on how to write the query? Please advise.&lt;/P&gt;</description>
    <pubDate>Wed, 30 Mar 2022 14:45:52 GMT</pubDate>
    <dc:creator>Vin</dc:creator>
    <dc:date>2022-03-30T14:45:52Z</dc:date>
    <item>
      <title>How to create a Splunk alert when a file size is below 10 bytes from a log file?</title>
      <link>https://community.splunk.com/t5/Alerting/How-to-create-a-Splunk-alert-when-a-file-size-is-below-10-bytes/m-p/591359#M13687</link>
      <description>&lt;P&gt;I'm trying to write a Splunk query to find out a file size below 10 bytes from a log file. I have the index and log location but unable to find the exact query. Please help me out in a writing a query and creating an alert out of it.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 29 Mar 2022 23:26:32 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Alerting/How-to-create-a-Splunk-alert-when-a-file-size-is-below-10-bytes/m-p/591359#M13687</guid>
      <dc:creator>Vin</dc:creator>
      <dc:date>2022-03-29T23:26:32Z</dc:date>
    </item>
    <item>
      <title>Re: Create a Splunk alert when a file size is below 10 bytes from a log file.</title>
      <link>https://community.splunk.com/t5/Alerting/How-to-create-a-Splunk-alert-when-a-file-size-is-below-10-bytes/m-p/591362#M13688</link>
      <description>&lt;P&gt;Hi &lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/242595"&gt;@Vin&lt;/a&gt;&amp;nbsp; You could try this. Restrict the timerange to the window that you want to check the log file size.&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;index=_internal sourcetype=splunkd Metrics host="&amp;lt;your_host&amp;gt;"  group=per_source_thruput series="&amp;lt;your_log_path_or_name&amp;gt;" | stats sum(kb) as total_kbytes | where (total_kbytes*1000) &amp;lt; 10&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 29 Mar 2022 23:10:45 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Alerting/How-to-create-a-Splunk-alert-when-a-file-size-is-below-10-bytes/m-p/591362#M13688</guid>
      <dc:creator>venkatasri</dc:creator>
      <dc:date>2022-03-29T23:10:45Z</dc:date>
    </item>
    <item>
      <title>Re: Create a Splunk alert when a file size is below 10 bytes from a log file.</title>
      <link>https://community.splunk.com/t5/Alerting/How-to-create-a-Splunk-alert-when-a-file-size-is-below-10-bytes/m-p/591367#M13690</link>
      <description>&lt;P&gt;Thanks Venkatasri..But I need to pull the size using file name *.imp extension from the logs. How to add the file name .imp in the query and get the output?&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 30 Mar 2022 00:08:15 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Alerting/How-to-create-a-Splunk-alert-when-a-file-size-is-below-10-bytes/m-p/591367#M13690</guid>
      <dc:creator>Vin</dc:creator>
      <dc:date>2022-03-30T00:08:15Z</dc:date>
    </item>
    <item>
      <title>Re: Create a Splunk alert when a file size is below 10 bytes from a log file.</title>
      <link>https://community.splunk.com/t5/Alerting/How-to-create-a-Splunk-alert-when-a-file-size-is-below-10-bytes/m-p/591369#M13691</link>
      <description>&lt;P&gt;series="*.imp" might work , you have to find out what else been included here. There could be other files with same name.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 30 Mar 2022 00:33:06 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Alerting/How-to-create-a-Splunk-alert-when-a-file-size-is-below-10-bytes/m-p/591369#M13691</guid>
      <dc:creator>venkatasri</dc:creator>
      <dc:date>2022-03-30T00:33:06Z</dc:date>
    </item>
    <item>
      <title>Re: Create a Splunk alert when a file size is below 10 bytes from a log file.</title>
      <link>https://community.splunk.com/t5/Alerting/How-to-create-a-Splunk-alert-when-a-file-size-is-below-10-bytes/m-p/591370#M13692</link>
      <description>&lt;P&gt;This is the query I tried and got zero results. From the file.log, I need to search for .imp files which are below 10 bytes and give us the output.&amp;nbsp;&lt;/P&gt;&lt;P&gt;index="servers"&amp;nbsp; source="/opt/apps/log.root/file.log"&amp;nbsp; |&amp;nbsp; stats sum(kb) as total_kbytes | where (total_kbytes*1000) &amp;lt; 10&lt;/P&gt;</description>
      <pubDate>Wed, 30 Mar 2022 00:35:30 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Alerting/How-to-create-a-Splunk-alert-when-a-file-size-is-below-10-bytes/m-p/591370#M13692</guid>
      <dc:creator>Vin</dc:creator>
      <dc:date>2022-03-30T00:35:30Z</dc:date>
    </item>
    <item>
      <title>Re: Create a Splunk alert when a file size is below 10 bytes from a log file.</title>
      <link>https://community.splunk.com/t5/Alerting/How-to-create-a-Splunk-alert-when-a-file-size-is-below-10-bytes/m-p/591371#M13693</link>
      <description>&lt;P&gt;How is file.log contents look like? redact the ip's username etc before posting. Paste few sample events.&lt;/P&gt;</description>
      <pubDate>Wed, 30 Mar 2022 00:39:00 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Alerting/How-to-create-a-Splunk-alert-when-a-file-size-is-below-10-bytes/m-p/591371#M13693</guid>
      <dc:creator>venkatasri</dc:creator>
      <dc:date>2022-03-30T00:39:00Z</dc:date>
    </item>
    <item>
      <title>Re: Create a Splunk alert when a file size is below 10 bytes from a log file.</title>
      <link>https://community.splunk.com/t5/Alerting/How-to-create-a-Splunk-alert-when-a-file-size-is-below-10-bytes/m-p/591372#M13694</link>
      <description>&lt;P&gt;It's the regular java server output log. Sorry I cannot post them. In file.log, we need to look for Name: CONFIRM.LLPC2345.imp&amp;nbsp; &amp;nbsp; &amp;nbsp;Path: &lt;SPAN&gt;/opt/apps/log.root/file.log/&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;If the .imp file is less than 10 bytes then we need to get an alert.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 30 Mar 2022 00:46:05 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Alerting/How-to-create-a-Splunk-alert-when-a-file-size-is-below-10-bytes/m-p/591372#M13694</guid>
      <dc:creator>Vin</dc:creator>
      <dc:date>2022-03-30T00:46:05Z</dc:date>
    </item>
    <item>
      <title>Re: Create a Splunk alert when a file size is below 10 bytes from a log file.</title>
      <link>https://community.splunk.com/t5/Alerting/How-to-create-a-Splunk-alert-when-a-file-size-is-below-10-bytes/m-p/591373#M13695</link>
      <description>&lt;P&gt;java server log doesn't have bytes related to .imp file so Splunk can not find that to Alert.&lt;/P&gt;&lt;P&gt;Splunk can only query the data exist in logs .&lt;/P&gt;</description>
      <pubDate>Wed, 30 Mar 2022 00:49:24 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Alerting/How-to-create-a-Splunk-alert-when-a-file-size-is-below-10-bytes/m-p/591373#M13695</guid>
      <dc:creator>venkatasri</dc:creator>
      <dc:date>2022-03-30T00:49:24Z</dc:date>
    </item>
    <item>
      <title>Re: Create a Splunk alert when a file size is below 10 bytes from a log file.</title>
      <link>https://community.splunk.com/t5/Alerting/How-to-create-a-Splunk-alert-when-a-file-size-is-below-10-bytes/m-p/591375#M13696</link>
      <description>&lt;P&gt;I think I conveyed the scenario wrongly. So on the Linux server we have the log location opt/apps/file.log. From the file.log we need to look for name which have &amp;nbsp;.imp extension and which are below 10 bytes. Hope I didn’t confuse you this time.&lt;/P&gt;</description>
      <pubDate>Wed, 30 Mar 2022 01:04:28 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Alerting/How-to-create-a-Splunk-alert-when-a-file-size-is-below-10-bytes/m-p/591375#M13696</guid>
      <dc:creator>Vin</dc:creator>
      <dc:date>2022-03-30T01:04:28Z</dc:date>
    </item>
    <item>
      <title>Re: Create a Splunk alert when a file size is below 10 bytes from a log file.</title>
      <link>https://community.splunk.com/t5/Alerting/How-to-create-a-Splunk-alert-when-a-file-size-is-below-10-bytes/m-p/591539#M13697</link>
      <description>&lt;P&gt;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/163730"&gt;@venkatasri&lt;/a&gt;&amp;nbsp;Hope you got my requirement? Any suggestions on how to write the query? Please advise.&lt;/P&gt;</description>
      <pubDate>Wed, 30 Mar 2022 14:45:52 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Alerting/How-to-create-a-Splunk-alert-when-a-file-size-is-below-10-bytes/m-p/591539#M13697</guid>
      <dc:creator>Vin</dc:creator>
      <dc:date>2022-03-30T14:45:52Z</dc:date>
    </item>
    <item>
      <title>Re: Create a Splunk alert when a file size is below 10 bytes from a log file.</title>
      <link>https://community.splunk.com/t5/Alerting/How-to-create-a-Splunk-alert-when-a-file-size-is-below-10-bytes/m-p/592305#M13735</link>
      <description>&lt;P&gt;if the event doesn't have the bytes associated to the file splunk can not provide that detail.&lt;/P&gt;&lt;P&gt;for example if the event is,&lt;/P&gt;&lt;P&gt;file: temp.txt, 45 bytes, created today, file closed.&lt;/P&gt;&lt;P&gt;Then in this scenario that contains knowledge about file temp.txt of size 45 bytes and it's closed. Then Splunk can retrieve and Alert/report etc can be created.&lt;/P&gt;&lt;P&gt;What we need to retrieve in this case bytes must exist in 'events' / _raw data.&lt;/P&gt;&lt;P&gt;Hope this clarifies.&lt;/P&gt;</description>
      <pubDate>Tue, 05 Apr 2022 01:33:41 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Alerting/How-to-create-a-Splunk-alert-when-a-file-size-is-below-10-bytes/m-p/592305#M13735</guid>
      <dc:creator>venkatasri</dc:creator>
      <dc:date>2022-04-05T01:33:41Z</dc:date>
    </item>
  </channel>
</rss>

