Tips & Tricks: Run Now Reports

Tips & Tricks: Run Now Reports

25105
Created On 09/25/18 18:55 PM - Last Modified 06/05/23 09:20 AM


Resolution


Let's talk about reports—ones you'd like to run now. Scheduled reports run once per day. But you can also generate and display reports on demand by clicking the 'Run Now' option in the window where you define the report queries. It's easy to do, and with a few tricks of the trade, you'll master 'Run Time' reports in no time at all.

 

You will find the 'Run Now' option under the Monitor tab > Manage Custom Reports > Select your report. In the example below, you see a custom report, 'test-report,' as an example.

 

Custom Report

 

Just click the report to open it and you will notice the 'Run Now' option at the top left:

 

run now

 

To use the 'Run Now' option, you will have to have at least one Custom Report.

 

This option generates the runtime report based on the criteria configured in the custom report. Note that generating the report can take a long time and affect the device's performance! For large reports, 'Run Now' is not recommended because the reports can timeout.

 

For large reports, we recommend using the scheduled reports option. To prevent timeouts, make the reports smaller by reducing the 'Time Frame' or reducing the reports with the 'Top' and 'Group' options. Alternatively, you can select a different database in the corresponding drop-down menu (Summary Databases are created much faster):

 

database

 

The 'Run Now' option is especially useful because it contains more data and is more accurate than the scheduled report. For a scheduled report, you have to wait at least the specified period to let the scheduled xml file be accurate.

 

After running the report, the result is presented in an extra tab next to the Report Settings, where you can then export the report in the format you prefer (PDF, CSV or XML):

 

report

 

If you are having trouble getting the results, you can run php-debug in the WebGUI.

To enable php-debug, simply browse to your firewall's address : https://X.X.X.X/debug and check the Debug option:

 

php debug

 

By doing so, you will get more data on the report you are running. If you run the report again, then return to the debug page, you will find more information on the report in question:

 

<response status="success"><result>off</result></response>
[2015/12/07 08:24:25] user=0265467315480725
<report-request cmd="generate" name="custom-dynamic-report" dynamic="yes" async="yes" cookie="0265467315480725">
  <entry name="custom-dynamic-report">
    <type>
      <appstat>
        <aggregate-by>
          <member>category-of-name</member>
          <member>subcategory-of-name</member>
          <member>risk-of-name</member>
        </aggregate-by>
        <values>
          <member>nsess</member>
        </values>
      </appstat>
    </type>
    <period>last-30-calendar-days</period>
    <topn>500</topn>
    <topm>50</topm>
    <caption>test-report</caption>
    <runnow>yes</runnow>
  </entry>
</report-request>
[2015/12/07 08:24:25] user=0265467315480725
<response status="success"><result>
    <msg>
      <line>Report job enqueued with jobid 4</line>
    </msg>
    <job>4</job>
  </result></response>

 

Also, in ms.log, will you find information on the report you are running.  

As always, you can increase the debug level to get more verbose logging information.

 

> debug management-server on debug   #will increase the debug level of the management-server process

> less mp-log ms.log #allows you to go through the ms.log

> tail follow yes mp-log ms.log #will show you live output of ms.log

 

I hope this helps you understand the 'Run Now' option better.

 

As always, please feel free to post feedback or comments below. Please also Like this article if it has helped you in any way.

 

Thanks for reading.
Kim Wens

 



Actions
  • Print
  • Copy Link

    https://knowledgebase.paloaltonetworks.com/KCSArticleDetail?id=kA10g000000ClRgCAK&lang=en_US&refURL=http%3A%2F%2Fknowledgebase.paloaltonetworks.com%2FKCSArticleDetail

Choose Language