diff --git a/pandora_server/lib/PandoraFMS/DiscoveryServer.pm b/pandora_server/lib/PandoraFMS/DiscoveryServer.pm index 70abab5d2a..797190a259 100644 --- a/pandora_server/lib/PandoraFMS/DiscoveryServer.pm +++ b/pandora_server/lib/PandoraFMS/DiscoveryServer.pm @@ -494,9 +494,16 @@ sub PandoraFMS::Recon::Base::create_agents($$) { # Add modules. if (ref($modules) eq "ARRAY") { foreach my $module (@{$modules}) { - pandora_process_module( - $pa_config, {'data' => $module->{'value'}}, $current_agent, $module, - $module->{'type'}, '', time(), $server_id, $dbh + my %data_translated = map { $_ => [ $module->{$_} ] } keys %{$module}; + + # Translate fields. + PandoraFMS::DataServer::process_module_data ( + $pa_config, \%data_translated, + $server_id, $current_agent, + $module->{'name'}, $module->{'type'}, + $agent->{'interval'}, + strftime ("%Y/%m/%d %H:%M:%S", localtime()), + $dbh, $force_processing ); } } diff --git a/pandora_server/lib/PandoraFMS/Recon/Base.pm b/pandora_server/lib/PandoraFMS/Recon/Base.pm index 9612599aa7..39c3bf0ba2 100644 --- a/pandora_server/lib/PandoraFMS/Recon/Base.pm +++ b/pandora_server/lib/PandoraFMS/Recon/Base.pm @@ -1488,7 +1488,7 @@ sub db_scan($) { 'interval' => $self->{'task_data'}->{'interval_sweep'}, 'id_group' => $self->{'task_data'}->{'id_group'}, 'address' => $dbObj->get_host(), - + 'description' => '', }, 'module_data' => \@modules, }