mirror of
https://bitbucket.org/jsuto/piler.git
synced 2024-12-24 18:40:13 +01:00
daily-report.php fix
This commit is contained in:
parent
e20af9d380
commit
74cd173eac
5
configure
vendored
5
configure
vendored
@ -4651,6 +4651,11 @@ if test "$have_icc_guide" = "yes" && test "$have_mysql" = "yes"; then
|
||||
sql_libs="$sql_libs -lguide"
|
||||
fi
|
||||
|
||||
if test "$have_psql" = "yes"; then
|
||||
defs="$defs -DNEED_PSQL"
|
||||
fi
|
||||
|
||||
|
||||
if test "$have_multitenancy" = "yes"; then
|
||||
echo "multitenancy support: yes"
|
||||
defs="$defs -DHAVE_MULTITENANCY"
|
||||
|
@ -400,6 +400,11 @@ if test "$have_icc_guide" = "yes" && test "$have_mysql" = "yes"; then
|
||||
sql_libs="$sql_libs -lguide"
|
||||
fi
|
||||
|
||||
if test "$have_psql" = "yes"; then
|
||||
defs="$defs -DNEED_PSQL"
|
||||
fi
|
||||
|
||||
|
||||
if test "$have_multitenancy" = "yes"; then
|
||||
echo "multitenancy support: yes"
|
||||
defs="$defs -DHAVE_MULTITENANCY"
|
||||
|
16
src/defs.h
16
src/defs.h
@ -8,15 +8,8 @@
|
||||
#ifdef NEED_MYSQL
|
||||
#include <mysql.h>
|
||||
#endif
|
||||
#ifdef NEED_SQLITE3
|
||||
#include <sqlite3.h>
|
||||
|
||||
/* for older versions of sqlite3 do not have the sqlite3_prepare_v2() function, 2009.12.30, SJ */
|
||||
|
||||
#if SQLITE_VERSION_NUMBER < 3006000
|
||||
#define sqlite3_prepare_v2 sqlite3_prepare
|
||||
#endif
|
||||
|
||||
#ifdef NEED_PSQL
|
||||
#include <libpq-fe.h>
|
||||
#endif
|
||||
#ifdef HAVE_TRE
|
||||
#include <tre/tre.h>
|
||||
@ -202,8 +195,9 @@ struct session_data {
|
||||
#ifdef NEED_MYSQL
|
||||
MYSQL mysql;
|
||||
#endif
|
||||
#ifdef NEED_SQLITE3
|
||||
sqlite3 *db;
|
||||
#ifdef NEED_PSQL
|
||||
PGconn *psql;
|
||||
char conninfo[SMALLBUFSIZE];
|
||||
#endif
|
||||
};
|
||||
|
||||
|
@ -97,6 +97,7 @@ $mail = new ModelMailMail();
|
||||
$averagesqlsizeraw = $sqlsizeraw / $counters['rcvd'];
|
||||
$averagesphinxsizeraw = $sphinxsizeraw / $counters['rcvd'];
|
||||
$averagesizedayraw = ($averagemessagesizeraw+$averagesqlsizeraw+$averagesphinxsizeraw) * $averagemessagesweekraw;
|
||||
$datapart = 0;
|
||||
foreach($shortdiskinfo as $part) {
|
||||
if( $part['partition'] == DATA_PARTITION ) { $datapart = $part['freespace']*1024; }
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user