Lost Device DNS setting in previous refactor

This commit is contained in:
Oliver Gorwits
2015-07-19 11:47:45 +01:00
parent 54676ca0ea
commit d6af3b4244
2 changed files with 4 additions and 0 deletions

View File

@@ -3,6 +3,7 @@
[BUG FIXES] [BUG FIXES]
* [#234] Cisco voice vlan conflicts with same number normal vlan on DB INSERT * [#234] Cisco voice vlan conflicts with same number normal vlan on DB INSERT
* [#xxx] Lost Device DNS setting in previous refactor
2.032005 - 2015-05-18 2.032005 - 2015-05-18

View File

@@ -139,6 +139,9 @@ sub store_device {
$device->set_column( vtp_domain => (values %$vtpdomains)[-1] ); $device->set_column( vtp_domain => (values %$vtpdomains)[-1] );
} }
my $hostname = hostname_from_ip($device->ip);
$device->set_column( dns => $hostname ) if $hostname;
my @properties = qw/ my @properties = qw/
snmp_ver snmp_ver
description uptime contact name location description uptime contact name location