php Python Android Windows apache centos linux Ubuntu shell 开源 nginx mysql Firefox 微软 java 程序员 google linux命令 wordpress HTML5

phpMyAdmin管理mysql多实例或多个mysql服务器

修改phpmyadmin根目录下的config.inc.PHP文件,例如这里我新增了一个localhost:3308

/* Servers configuration */
$i = 0;

/* Server: localhost [1] */
$i++;
$cfg['Servers'][$i]['verbose'] = '';
$cfg['Servers'][$i]['host'] = 'localhost';
$cfg['Servers'][$i]['port'] = '3307';
$cfg['Servers'][$i]['socket'] = '/tmp/mysql3307.sock';
$cfg['Servers'][$i]['connect_type'] = 'tcp';
$cfg['Servers'][$i]['extension'] = 'mysql';
$cfg['Servers'][$i]['auth_type'] = 'cookie';
$cfg['Servers'][$i]['user'] = '';
$cfg['Servers'][$i]['password'] = '';
$cfg['Servers'][$i]['hide_db'] = '';

$i++;
$cfg['Servers'][$i]['verbose'] = '';
$cfg['Servers'][$i]['host'] = 'localhost';
$cfg['Servers'][$i]['port'] = '3308';
$cfg['Servers'][$i]['socket'] = '/tmp/mysql3308.sock';
$cfg['Servers'][$i]['connect_type'] = 'tcp';
$cfg['Servers'][$i]['extension'] = 'mysql';
$cfg['Servers'][$i]['auth_type'] = 'cookie';
$cfg['Servers'][$i]['user'] = '';
$cfg['Servers'][$i]['password'] = '';
$cfg['Servers'][$i]['hide_db'] = '';


/* End of servers configuration */

$cfg['DefaultLang'] = 'en-utf-8';
$cfg['blowfish_secret'] = '';
$cfg['ServerDefault'] = 1;
$cfg['UploadDir'] = '';
$cfg['SaveDir'] = '';
$cfg['LoginCookieValidity'] = 18000; // ³¬ʱʱ¼ä>
?>

延伸阅读

评论