");
// TODO : trouver et afficher les anomalies
$r = pg_query("SELECT idinterface, ifname, ifdescription, ifadminstatus, ifoperstatus,
ifvlan, ifvoicevlan, portsecenable, portsecstatus, i.idmateriel AS idm, hostname FROM interface i, materiel m WHERE i.idmateriel = m.idmateriel ORDER BY ifnumber");
fputs($fp, "
Interfaces en ERR-DIS :
\n");
while($a = pg_fetch_array($r)) {
if ($errdisable = (($a[7] == 't') && ($a[8] == 3) && (! $a[3]==0)))
{
fputs($fp, "- ${a[10]} / ${a[1]}
\n");
}
}
fputs($fp, "
Incohérence DHCP-ARP :
\n");
// pg_query arpcache and compare with dhcp entries
fputs($fp, "
Incohérence DHCP-Sticky :
\n");
// vérifions que les stickies sont tous sur le DHCP
$r = pg_query("SELECT mac, type FROM fdb WHERE type <> 0 and datelast = (SELECT MAX(datelast) FROM fdb)");
while($a = pg_fetch_array($r)) {
$a2 = SearchMACinDHCP($a[0]);
if(! $a2) {
fputs($fp, "- ".$a[0]."
\n");
}
}
fputs($fp, "
\n");
fclose ($fp);
}
?>
Rapport d'anomalies :
600)
{
report();
echo "";
}
include "inc/inc.footer.php"; ?>