Files
librenms-librenms/includes/polling/os/iosxr.inc.php
Adam Amstrong bd243db6dc potentially break all cisco versioning :P
git-svn-id: http://www.observium.org/svn/observer/trunk@2912 61d68cd4-352d-0410-923a-c4978735b2b8
2012-03-20 16:50:16 +00:00

17 lines
346 B
PHP

<?php
if (preg_match('/^Cisco IOS XR Software \(Cisco ([^\)]+)\),\s+Version ([^\[]+)\[([^\]]+)\]/', $poll_device['sysDescr'], $regexp_result))
{
$hardware = $regexp_result[1];
$features = $regexp_result[3];
$version = $regexp_result[2];
}
else
{
# It is not an IOS-XR ... What should we do ?
}
echo("\n".$poll_device['sysDescr']."\n");
?>