mirror of
https://github.com/librenms/librenms.git
synced 2024-10-07 16:52:45 +00:00
add Thompson speedtouch
git-svn-id: http://www.observium.org/svn/observer/trunk@543 61d68cd4-352d-0410-923a-c4978735b2b8
This commit is contained in:
@@ -631,7 +631,7 @@ function createHost ($host, $community, $snmpver, $port = 161){
|
||||
$device = array('hostname' => $host, 'community' => $community, 'snmpver' => $snmpver, 'port' => $port);
|
||||
$host_os = getHostOS($device);
|
||||
if($host_os) {
|
||||
$sql = mysql_query("INSERT INTO `devices` (`hostname`, `sysName`, `community`, `port`, `os`, `status`) VALUES ('$host', '$host', '$community', '$port', '$host_os', '1')");
|
||||
$sql = mysql_query("INSERT INTO `devices` (`hostname`, `sysName`, `community`, `port`, `os`, `status`,`snmpver`) VALUES ('$host', '$host', '$community', '$port', '$host_os', '1','$snmpver')");
|
||||
if(mysql_affected_rows()) {
|
||||
$device_id = mysql_result(mysql_query("SELECT device_id FROM devices WHERE hostname = '$host'"),0);
|
||||
mysql_query("INSERT INTO devices_attribs (attrib_type, attrib_value, device_id) VALUES ('discover','1','$device_id')");
|
||||
|
||||
Reference in New Issue
Block a user