Reports

Report Plugins

You can easily write your own custom reports by extending the Model_Report class.

Report plugins are located in the following directory:

/usr/local/psa/admin/plib/modules/juggernaut/library/application/classes/Model/Report/Plugin/

Report plugins all extend the following base class:

<?php defined('SYSPATH') or die('No direct script access.');
/**
 * Model_Report
 * @package          modules/report
 * @category         Models
 * @author           Danami
 * @copyright    (c) 2018 Danami http://www.danami.com
 */
class Model_Report extends Automodeler
{
    /**
     * Model data
     * @access    protected
     * @var    array
     */
    protected $_data = array(

        // plugin data
        'enabled'     => TRUE,
        'id'          => '',
        'title'       => '',
        'description' => '',
        'author'      => '',
        'image'       => '',
        'url'         => '',

        // report data
        'start_time'  => '',
        'end_time'    => '',
        'timespan'    => '',
        'domain_id'   => '',
        'renderer'    => '',
        'renderers'   => array(),
        'options'     => array(),
        'theme'       => array(),
        'series'      => array(),
        'output'      => '',
        'refresh'     => 0
    );

    /**
     * Loads the reports series data based of a passed in query
     * @access    public
     * @return    array
     */
    public function load_series(Database_Query_Builder_Select $query = NULL){}

    /**
     * loads the plot options based on the renderer type
     * @access    public
     * @return    void
     */
    public function options(){}

    /**
     * Get the model output
     * @access    public
     * @param     string    $id           element id
     * @param     string    $width        width of the chart (in px or %)
     * @param     string    $height       height of the chart (in px)
     * @return    string
     */
    public function output($id='chart', $width='100%', $height='325px'){} 

)
?>

Statistics

The statistics area allows you to view basic server system statistics.

• Both statistical data ST_ENABLE and system gathering ST_SYSTEM must be enabled in /etc/csf/csf.conf. Restart the firewall and login failure daemon after enabling.
• The graphs require the Perl module GD::Graph is installed.

The following graphs are available when system statistics gathering is enabled ST_SYSTEM:

  • Load average
  • CPU
  • Memory
  • Network
  • Disk
  • Email
  • Temperature

The following graphs are available when Apache statistics gathering is enabled ST_APACHE. You must enable Apache mod_status and allow local connections to it:

  • Apache CPU
  • Apache workers
  • Apache connections

The following graphs are available when MySQL statistics gathering is enabled ST_MYSQL:

  • MySQL queries
  • MySQL data
  • MySQL connections
  • MySQL slow queries

The following graphs are available when disk write statistics gathering is enabled ST_DISKW:

  • Disk write performance