From 4142f13c51fbfccb2effcbb0fed8fbbab3421def Mon Sep 17 00:00:00 2001 From: vogelor <vogelor@ispconfig3> Date: Tue, 04 May 2010 08:00:28 -0400 Subject: [PATCH] small improvement of the updater --- install/update.php | 26 ++++++++++++++++++++------ 1 files changed, 20 insertions(+), 6 deletions(-) diff --git a/install/update.php b/install/update.php index 627a72b..d37c2a0 100644 --- a/install/update.php +++ b/install/update.php @@ -124,6 +124,19 @@ //** Database update is a bit brute force and should be rebuild later ;) +/* + * Try to read the DB-admin settings + */ +$clientdb_host = ''; +$clientdb_user = ''; +$clientdb_password = ''; +include_once("/usr/local/ispconfig/server/lib/mysql_clientdb.conf"); +$conf["mysql"]["admin_user"] = $clientdb_user; +$conf["mysql"]["admin_password"] = $clientdb_password; +$clientdb_host = ''; +$clientdb_user = ''; +$clientdb_password = ''; + //** Ask user for mysql admin_password if empty if( empty($conf["mysql"]["admin_password"]) ) { @@ -219,12 +232,13 @@ $inst->configure_database(); if($conf['mysql']['master_slave_setup'] == 'y') { - //** Update master database rights - $reconfigure_master_database_rights_answer = $inst->simple_query('Reconfigure Permissions in master database?', array('yes','no'),'no'); - - if($reconfigure_master_database_rights_answer == 'yes') { - $inst->grant_master_database_rights(); - } + /* + * Because of security updates and because of new functions in den new Version it is + * better to ALWAYS reconfigure the rights and never ask! + * (for example if we add some new tables to the monitor and the old rights don't have the + * permission to read this tables the monitor always returns a error) + */ + $inst->grant_master_database_rights(); } //** empty all databases -- Gitblit v1.9.1