Reset recon task progress at startup.

(cherry picked from commit a5c9da2a569dc4c8645e82f1c7e07325eb09cb9c)
This commit is contained in:
Ramon Novoa 2016-10-27 15:31:51 +02:00
parent 9c291fe82b
commit 6a98ac8288

View File

@ -70,6 +70,9 @@ sub new ($$$$$$) {
$Sem = Thread::Semaphore->new;
$TaskSem = Thread::Semaphore->new (0);
db_do ($dbh, 'UPDATE trecon_task SET utimestamp = 0 WHERE id_recon_server = ? AND status <> -1',
get_server_id ($dbh, $config->{'servername'}, RECONSERVER));
# Call the constructor of the parent class
my $self = $class->SUPER::new($config, RECONSERVER, \&PandoraFMS::ReconServer::data_producer, \&PandoraFMS::ReconServer::data_consumer, $dbh);