mirror of
https://github.com/librenms/librenms.git
synced 2024-10-07 16:52:45 +00:00
Add fortigate support, many thanks to Matthias Cramer (matthias dot cramer at iway dot ch)
git-svn-id: http://www.observium.org/svn/observer/trunk@2986 61d68cd4-352d-0410-923a-c4978735b2b8
This commit is contained in:
15
includes/polling/mempools/fortigate.inc.php
Normal file
15
includes/polling/mempools/fortigate.inc.php
Normal file
@@ -0,0 +1,15 @@
|
||||
<?php
|
||||
|
||||
## Simple hard-coded poller for Fortinet Fortigate
|
||||
## Yes, it really can be this simple.
|
||||
|
||||
echo "Fortigate MemPool";
|
||||
|
||||
$mempool['perc'] = snmp_get($device, "FORTINET-FORTIGATE-MIB::fgSysMemUsage.0", "-OvQ");
|
||||
$mempool['total'] = snmp_get($device, "FORTINET-FORTIGATE-MIB::fgSysMemCapacity.0", "-OvQ");
|
||||
$mempool['used'] = $mempool['total'] * ($mempool['perc']/100);
|
||||
$mempool['free'] = $mempool['total'] - $mempool['used'];
|
||||
|
||||
echo "(U: ".$mempool['used']." T: ".$mempool['total']." F: ".$mempool['free'].") ";
|
||||
|
||||
?>
|
||||
Reference in New Issue
Block a user