diff --git a/.gitattributes b/.gitattributes index c5efc330..e29e9f14 100644 --- a/.gitattributes +++ b/.gitattributes @@ -312,6 +312,7 @@ install/upgrades/0.9.4.sql -text install/upgrades/0.9.5.sh -text install/upgrades/0.9.5.sql -text install/upgrades/0.9.6.sql -text +install/upgrades/0.9.7.sql -text install/upgrades/README -text man/alternc-admintools.8 -text man/alternc-admintools.fr.8 -text diff --git a/install/mysql.sql b/install/mysql.sql index 63214a13..b7d56156 100644 --- a/install/mysql.sql +++ b/install/mysql.sql @@ -438,18 +438,6 @@ PRIMARY KEY ( `login` ) ) COMMENT = 'Allowed account for secondary mx managment'; --- -------------------------------------------------------- --- TABLES de mémorisation de la taille des dossiers web/mail/db - -CREATE TABLE IF NOT EXISTS `size_db` ( - `db` varchar(255) NOT NULL default '', - `size` int(10) unsigned NOT NULL default '0', - `ts` timestamp(14) NOT NULL, - PRIMARY KEY (`db`), - KEY `ts` (`ts`) -) TYPE=MyISAM COMMENT='MySQL Database used space'; - - -- -------------------------------------------------------- CREATE TABLE IF NOT EXISTS `size_mail` ( `alias` varchar(255) NOT NULL default '', diff --git a/install/upgrades/0.9.7.sql b/install/upgrades/0.9.7.sql new file mode 100644 index 00000000..b357f316 --- /dev/null +++ b/install/upgrades/0.9.7.sql @@ -0,0 +1 @@ +DROP TABLE IF EXISTS `size_db`; diff --git a/src/spoolsize.php b/src/spoolsize.php index f76d6e1d..5791cb20 100644 --- a/src/spoolsize.php +++ b/src/spoolsize.php @@ -14,15 +14,6 @@ while ($c=mysql_fetch_array($r)) { echo " done ($size KB)\n"; flush(); } -echo "---------------------------\n Generating size-cache for db accounts\n\n"; -$r=mysql_query("SELECT db FROM db;"); -while ($c=mysql_fetch_array($r)) { - echo $c["db"]; flush(); - $size=$mysql->get_db_size($c["db"]); - mysql_query("REPLACE INTO size_db SET db='".addslashes($c["db"])."',size='$size';"); - echo " done ($size KB) \n"; flush(); -} - echo "---------------------------\n Generating size-cache for web accounts\n\n"; $r=mysql_query("SELECT uid,login FROM membres;"); while ($c=mysql_fetch_array($r)) {