By default, the module collects bandwidth data from NOC-PS. If you are not using NOC-PS for bandwidth measurement, it is possible to include external sources into the module, for example a query via SNMP or via the API of your data center. The possibility of own measurement can be used parallel to the standard measurement via NOC-PS. So you can measure the bandwidth data from servers in datacenter A via NOC-PS and the bandwidth data from servers in datacenter B via your own integration.

Some details about the feature:

  • Bandwidth details are collected every 24 hours and are triggered by the WHMCS daily cronjob.
  • You must return the amout of used bandwidth in bytes.
  • Only return the amount of used bandwidth within the last 24 hours.
  • If no value is returned, or the value is not numeric, the module will query NOC-PS to get the bandwidth data.

The above details, and other information, are also available as comments in the customconfig.php file.

How to integrate external bandwidth collectors

The function can be activated via customconfig.php, which can be found in the directory "/modules/servers/dedicated/"

  • Navigate into the directory /modules/servers/dedicated/
  • Open the file customconfig.example.php and copy the function "nocpsforwhmcs_customBandwidthData". Also copy the function_exists check.
  • Open the file customconfig.php, or create the file if it does not exist and insert the copied code.
  • Modify the code to receive bandwidth datas.

  • No labels