码迷,mamicode.com
首页 > Web开发 > 详细

phpmyadmin4.4多ip选择

时间:2016-05-19 13:26:46      阅读:269      评论:0      收藏:0      [点我收藏+]

标签:phpmyadmin4.4多ip选择

phpMyAdmin允许定义输入的MySQL服务器IP地址,用户名和密码

修改/libraries/config.default.php为真即可,简单安全省事

$cfg[‘AllowArbitraryServer‘] = true;


phpMyAdmin修改config.inc.php,服务器地址为下拉列表可选登录多个服务器

增加config.sample.inc.php文件,参考下面配置或者访问setup手动生成

<?php
/*
* Generated configuration file
* Generated by: phpMyAdmin 4.4.11 setup script
* Date: Fri, 10 Jul 2015 15:54:42 +0800
*/


/* Servers configuration */
$i = 0;

/* Server: 10.4.14.64 [1] */
$i++;
$cfg[‘Servers‘][$i][‘verbose‘] = ‘10.10.6.64‘;
$cfg[‘Servers‘][$i][‘host‘] = ‘10.10.6.64‘;
$cfg[‘Servers‘][$i][‘port‘] = ‘‘;
$cfg[‘Servers‘][$i][‘socket‘] = ‘‘;
$cfg[‘Servers‘][$i][‘connect_type‘] = ‘tcp‘;
$cfg[‘Servers‘][$i][‘auth_type‘] = ‘cookie‘;
$cfg[‘Servers‘][$i][‘user‘] = ‘root‘;
$cfg[‘Servers‘][$i][‘password‘] = ‘‘;
/* Server: 10.10.1.172 [2] */
$i++;
$cfg[‘Servers‘][$i][‘verbose‘] = ‘10.10.1.172‘;
$cfg[‘Servers‘][$i][‘host‘] = ‘10.10.1.172‘;
$cfg[‘Servers‘][$i][‘port‘] = ‘‘;
$cfg[‘Servers‘][$i][‘socket‘] = ‘‘;
$cfg[‘Servers‘][$i][‘connect_type‘] = ‘tcp‘;
$cfg[‘Servers‘][$i][‘auth_type‘] = ‘cookie‘;
$cfg[‘Servers‘][$i][‘user‘] = ‘root‘;
$cfg[‘Servers‘][$i][‘password‘] = ‘‘;

/* End of servers configuration */

$cfg[‘blowfish_secret‘] = ‘559f78c86f22d8.48481095‘;
$cfg[‘DefaultLang‘] = ‘zh_CN‘;
$cfg[‘ServerDefault‘] = 1;
$cfg[‘UploadDir‘] = ‘‘;
$cfg[‘SaveDir‘] = ‘‘;
?>

如果mysql是5.1的这个版本php会报错(

您应升级到 MySQL 5.5.0 或更高版本

),解决方案:

技术分享

vi /var/www/html/phpmyadmin/libraries/common.inc.php
#查找
if (PMA_MYSQL_INT_VERSION < 50500) {
#更换为
if (PMA_MYSQL_INT_VERSION < 50100) {


本文出自 “Android/Linux@HeFei” 博客,请务必保留此出处http://liang3391.blog.51cto.com/178205/1774992

phpmyadmin4.4多ip选择

标签:phpmyadmin4.4多ip选择

原文地址:http://liang3391.blog.51cto.com/178205/1774992

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!