2013-02-04 Sergio Martin <sergio.martin@artica.es>

* lib/PandoraFMS/Core.pm: Fix a broken query of my last 
	commit



git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@7581 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
This commit is contained in:
slerena 2013-02-05 09:02:39 +00:00
parent 31ea02f4ad
commit 4e87e8c2a5
2 changed files with 12 additions and 1 deletions

View File

@ -1,3 +1,8 @@
2013-02-05 Sancho Lerena <slerena@artica.es>
* util/pandora_db.pl: Added deletion for extended session
data (was missing and table grows to infinite!).
2013-02-05 Sergio Martin <sergio.martin@artica.es> 2013-02-05 Sergio Martin <sergio.martin@artica.es>
* lib/PandoraFMS/Core.pm: Set ack utimestamp when create * lib/PandoraFMS/Core.pm: Set ack utimestamp when create

View File

@ -30,7 +30,7 @@ use PandoraFMS::Tools;
use PandoraFMS::DB; use PandoraFMS::DB;
# version: define current version # version: define current version
my $version = "5.0dev PS121217"; my $version = "5.0dev PS130205";
# Pandora server configuration # Pandora server configuration
my %conf; my %conf;
@ -110,6 +110,12 @@ sub pandora_purgedb ($$) {
print "[PURGE] No data in tagente_datos\n"; print "[PURGE] No data in tagente_datos\n";
} }
# Delete extended session data
if (enterprise_load (\%conf) != 0) {
db_do ($dbh, "DELETE FROM tsesion_extended WHERE id_sesion NOT IN ( SELECT id_sesion FROM tsesion );");
print "[PURGE] Deleting old extended session data. \n";
}
# Delete inventory data, only if enterprise is enabled # Delete inventory data, only if enterprise is enabled
# We use the same value than regular data purge interval # We use the same value than regular data purge interval