diff --git a/pandora_agents/unix/DEBIAN/control b/pandora_agents/unix/DEBIAN/control index 53ff61d468..227dc3a7cc 100644 --- a/pandora_agents/unix/DEBIAN/control +++ b/pandora_agents/unix/DEBIAN/control @@ -1,5 +1,5 @@ package: pandorafms-agent-unix -Version: 6.0dev-150604 +Version: 6.0dev-150607 Architecture: all Priority: optional Section: admin diff --git a/pandora_agents/unix/DEBIAN/make_deb_package.sh b/pandora_agents/unix/DEBIAN/make_deb_package.sh index 77dd822a2c..5cf94ff833 100644 --- a/pandora_agents/unix/DEBIAN/make_deb_package.sh +++ b/pandora_agents/unix/DEBIAN/make_deb_package.sh @@ -14,7 +14,7 @@ # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. -pandora_version="6.0dev-150604" +pandora_version="6.0dev-150607" echo "Test if you has the tools for to make the packages." whereis dpkg-deb | cut -d":" -f2 | grep dpkg-deb > /dev/null diff --git a/pandora_agents/unix/pandora_agent b/pandora_agents/unix/pandora_agent index 37c28dae6f..1294ee5f6e 100644 --- a/pandora_agents/unix/pandora_agent +++ b/pandora_agents/unix/pandora_agent @@ -41,7 +41,7 @@ my $Sem = undef; my $ThreadSem = undef; use constant AGENT_VERSION => '6.0dev'; -use constant AGENT_BUILD => '150604'; +use constant AGENT_BUILD => '150607'; # Commands to retrieve total memory information in kB use constant TOTALMEMORY_CMDS => { diff --git a/pandora_agents/unix/pandora_agent.redhat.spec b/pandora_agents/unix/pandora_agent.redhat.spec index 28787ec257..1314e4672c 100644 --- a/pandora_agents/unix/pandora_agent.redhat.spec +++ b/pandora_agents/unix/pandora_agent.redhat.spec @@ -3,7 +3,7 @@ # %define name pandorafms_agent_unix %define version 6.0dev -%define release 150604 +%define release 150607 Summary: Pandora FMS Linux agent, PERL version Name: %{name} @@ -51,11 +51,6 @@ cp -aRf $RPM_BUILD_ROOT%{prefix}/pandora_agent/pandora_agent_daemon $RPM_BUILD_R cp -aRf $RPM_BUILD_ROOT%{prefix}/pandora_agent/man/man1/pandora_agent.1.gz $RPM_BUILD_ROOT/usr/share/man/man1/ cp -aRf $RPM_BUILD_ROOT%{prefix}/pandora_agent/man/man1/tentacle_client.1.gz $RPM_BUILD_ROOT/usr/share/man/man1/ -# Checking old config file (if exists) -if [ -f /etc/pandora/pandora_agent.conf ] ; then - mv /etc/pandora/pandora_agent.conf /etc/pandora/pandora_agent.conf.backup -fi - cp -aRf $RPM_BUILD_ROOT%{prefix}/pandora_agent/Linux/pandora_agent.conf $RPM_BUILD_ROOT/usr/share/pandora_agent/pandora_agent.conf.rpmnew if [ -f $RPM_BUILD_ROOT%{prefix}/pandora_agent/pandora_agent.spec ] ; then diff --git a/pandora_agents/unix/pandora_agent.spec b/pandora_agents/unix/pandora_agent.spec index 0288178e72..2661854769 100644 --- a/pandora_agents/unix/pandora_agent.spec +++ b/pandora_agents/unix/pandora_agent.spec @@ -3,7 +3,7 @@ # %define name pandorafms_agent_unix %define version 6.0dev -%define release 150604 +%define release 150607 Summary: Pandora FMS Linux agent, PERL version Name: %{name} @@ -51,16 +51,11 @@ cp -aRf $RPM_BUILD_ROOT%{prefix}/pandora_agent/pandora_agent_daemon $RPM_BUILD_R cp -aRf $RPM_BUILD_ROOT%{prefix}/pandora_agent/man/man1/pandora_agent.1.gz $RPM_BUILD_ROOT/usr/share/man/man1/ cp -aRf $RPM_BUILD_ROOT%{prefix}/pandora_agent/man/man1/tentacle_client.1.gz $RPM_BUILD_ROOT/usr/share/man/man1/ -# Checking old config file (if exists) -if [ -f /etc/pandora/pandora_agent.conf ] ; then - mv /etc/pandora/pandora_agent.conf /etc/pandora/pandora_agent.conf.backup -fi - cp -aRf $RPM_BUILD_ROOT%{prefix}/pandora_agent/Linux/pandora_agent.conf $RPM_BUILD_ROOT/usr/share/pandora_agent/pandora_agent.conf.rpmnew -if [ -f $RPM_BUILD_ROOT%{prefix}/pandora_agent/pandora_agent.spec ] ; then - rm $RPM_BUILD_ROOT%{prefix}/pandora_agent/pandora_agent.spec -fi +#if [ -f $RPM_BUILD_ROOT%{prefix}/pandora_agent/pandora_agent.spec ] ; then +# rm $RPM_BUILD_ROOT%{prefix}/pandora_agent/pandora_agent.spec +#fi %clean rm -Rf $RPM_BUILD_ROOT diff --git a/pandora_agents/win32/installer/pandora.mpi b/pandora_agents/win32/installer/pandora.mpi index 08e0866de7..26cda437a7 100644 --- a/pandora_agents/win32/installer/pandora.mpi +++ b/pandora_agents/win32/installer/pandora.mpi @@ -186,7 +186,7 @@ UpgradeApplicationID {} Version -{150604} +{150607} ViewReadme {Yes} diff --git a/pandora_agents/win32/pandora.cc b/pandora_agents/win32/pandora.cc index cbef625819..7f8506d8e8 100644 --- a/pandora_agents/win32/pandora.cc +++ b/pandora_agents/win32/pandora.cc @@ -30,7 +30,7 @@ using namespace Pandora; using namespace Pandora_Strutils; #define PATH_SIZE _MAX_PATH+1 -#define PANDORA_VERSION ("6.0dev(Build 150604)") +#define PANDORA_VERSION ("6.0dev(Build 150607)") string pandora_path; string pandora_dir; diff --git a/pandora_agents/win32/versioninfo.rc b/pandora_agents/win32/versioninfo.rc index fab6b3336a..f1e5a7f513 100644 --- a/pandora_agents/win32/versioninfo.rc +++ b/pandora_agents/win32/versioninfo.rc @@ -11,7 +11,7 @@ BEGIN VALUE "LegalCopyright", "Artica ST" VALUE "OriginalFilename", "PandoraAgent.exe" VALUE "ProductName", "Pandora FMS Windows Agent" - VALUE "ProductVersion", "(6.0dev(Build 150604))" + VALUE "ProductVersion", "(6.0dev(Build 150607))" VALUE "FileVersion", "1.0.0.0" END END diff --git a/pandora_console/DEBIAN/control b/pandora_console/DEBIAN/control index f7c9923ab7..570b123cf6 100644 --- a/pandora_console/DEBIAN/control +++ b/pandora_console/DEBIAN/control @@ -1,5 +1,5 @@ package: pandorafms-console -Version: 6.0dev-150604 +Version: 6.0dev-150607 Architecture: all Priority: optional Section: admin diff --git a/pandora_console/DEBIAN/make_deb_package.sh b/pandora_console/DEBIAN/make_deb_package.sh index cb1e4c8ca9..3516716486 100644 --- a/pandora_console/DEBIAN/make_deb_package.sh +++ b/pandora_console/DEBIAN/make_deb_package.sh @@ -14,7 +14,7 @@ # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. -pandora_version="6.0dev-150604" +pandora_version="6.0dev-150607" package_pear=0 package_pandora=1 diff --git a/pandora_console/include/config_process.php b/pandora_console/include/config_process.php index 7398b99ad6..5b5eeccc7b 100644 --- a/pandora_console/include/config_process.php +++ b/pandora_console/include/config_process.php @@ -22,7 +22,7 @@ /** * Pandora build version and version */ -$build_version = 'PC150604'; +$build_version = 'PC150607'; $pandora_version = 'v6.0dev'; // Do not overwrite default timezone set if defined. diff --git a/pandora_console/include/functions_events.php b/pandora_console/include/functions_events.php index bdde8f7463..86d3a47683 100644 --- a/pandora_console/include/functions_events.php +++ b/pandora_console/include/functions_events.php @@ -2817,7 +2817,7 @@ function events_get_count_events_validated ($filter, $period, $date, global $config; - $sql_filter = ' AND 1=1 '; + $sql_filter = ' 1=1 '; if (isset($filter['id_group'])) { $id_group = groups_safe_acl ($config["id_user"], $filter['id_group'], "AR"); @@ -2862,11 +2862,10 @@ function events_get_count_events_validated ($filter, $period, $date, $sql = sprintf ('SELECT estado, COUNT(*) AS count - FROM tevento - WHERE utimestamp > %d AND utimestamp <= %d + FROM tevento WHERE %s ' . $sql_where . ' GROUP BY estado', - $datelimit, $date, $sql_filter); + $sql_filter); $rows = db_get_all_rows_sql ($sql); diff --git a/pandora_console/include/functions_modules.php b/pandora_console/include/functions_modules.php index 2700eb46e2..f1905d43db 100755 --- a/pandora_console/include/functions_modules.php +++ b/pandora_console/include/functions_modules.php @@ -2144,6 +2144,8 @@ function modules_get_count_datas($id_agent_module, $date_init, $date_end) { function modules_get_count_data_with_value($id_agent_module, $date_init, $date_end, $value) { + global $config; + if (!is_numeric($date_init)) { $date_init = strtotime($date_init); } diff --git a/pandora_console/install.php b/pandora_console/install.php index 6a6ff35c67..5c70d15872 100644 --- a/pandora_console/install.php +++ b/pandora_console/install.php @@ -63,7 +63,7 @@
$RPM_BUILD_ROOT%{_sysconfdir}/sudoers.d/pandora -Defaults:pandora !requiretty +Defaults:root !requiretty EOF chmod 0440 $RPM_BUILD_ROOT%{_sysconfdir}/sudoers.d/pandora diff --git a/pandora_server/pandora_server.spec b/pandora_server/pandora_server.spec index 7c6d4c4b00..9f252e19bd 100644 --- a/pandora_server/pandora_server.spec +++ b/pandora_server/pandora_server.spec @@ -3,7 +3,7 @@ # %define name pandorafms_server %define version 6.0dev -%define release 150604 +%define release 150607 Summary: Pandora FMS Server Name: %{name} diff --git a/pandora_server/util/pandora_db.pl b/pandora_server/util/pandora_db.pl index bb9c207afd..031f18ed4f 100644 --- a/pandora_server/util/pandora_db.pl +++ b/pandora_server/util/pandora_db.pl @@ -33,7 +33,7 @@ use PandoraFMS::Tools; use PandoraFMS::DB; # version: define current version -my $version = "6.0dev PS150604"; +my $version = "6.0dev PS150607"; # Pandora server configuration my %conf; diff --git a/pandora_server/util/pandora_manage.pl b/pandora_server/util/pandora_manage.pl index 80492ee849..ea2308abf4 100644 --- a/pandora_server/util/pandora_manage.pl +++ b/pandora_server/util/pandora_manage.pl @@ -35,7 +35,7 @@ use Encode::Locale; Encode::Locale::decode_argv; # version: define current version -my $version = "6.0dev PS150604"; +my $version = "6.0dev PS150607"; # save program name for logging my $progname = basename($0);