Sunday , May 9 2021
Trang chủ / Database / How to Add Multiple Hosts in phpMyAdmin

How to Add Multiple Hosts in phpMyAdmin

phpMyAdmin default configuration allows to connect to local mysql server only, But if we have multiple database server running, then it would be great if we can choose to which server we need to connect from single phpMyAdmin installation. This how to guide will help you to add multiple database hosts in phpMyAdmin, So we can select to which database server we need to connect from web interface.

After installing phpMyAdmin on your Linux/Windows systems, lets use this to manage multiple hosts from one phpMyAdmin install.

First navigate to your phpMyAdmin installation directory. Directory location may be differ with your installation method. In most case we can found it on /usr/share/phpMyAdmin or /usr/share/phpmyadmin directory.

# cd /usr/share/phpmyadmin
# cp
# vim

Now add the following entries at the end of file.

$cfg['Servers'][$i]['verbose'] = 'Database Server 2';
$cfg['Servers'][$i]['host'] = '';
$cfg['Servers'][$i]['port'] = '';
$cfg['Servers'][$i]['socket'] = '';
$cfg['Servers'][$i]['connect_type'] = 'tcp';
$cfg['Servers'][$i]['extension'] = 'mysqli';
$cfg['Servers'][$i]['auth_type'] = 'cookie';
$cfg['Servers'][$i]['AllowNoPassword'] = false;

After adding the above entries in configuration file and access phpMyAdmin in web browser and you will get an option of server choice. Select server name to which you need to connect.


About Ngo Thang

Check Also

Hướng dẫn backup full user trong VPS DirectAdmin

Với dịch vụ vps bạn có thể chủ động việc backup dữ liệu của các …

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Đăng Ký Nhận Tin Qua Email

Nhận thông tin bổ ích về WordPress, Hosting, Thủ thuật website, Download miễn phí....và các phần quà hấp dẫn qua email.

* là bắt buộc