Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to enable phpmyadmin to connect to the database remotely

2025-01-16 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >

Share

Shulou(Shulou.com)06/01 Report--

Xiaobian to share with you how to make phpmyadmin can connect to the database remotely, I believe most people still do not know how to share this article for your reference, I hope you have a lot of harvest after reading this article, let's go to understand it together!

First of all, you need to establish a remote user (root account only allows local connection, considering security, generally set up a remote login account)

Log in to mysql with root account

#mysql -u root -p root password mysql> GRANT ALL ON *.* TO admin@'%' IDENTIFIED BY 'admin' WITH GRANT OPTION;

This sentence means that any computer with IP address ( % above means this) is allowed to access this MySQL Server with admin account and password (admin).

Then configure the phpmyadmin profile

vim ./ phpMyAdmin/libraries/config.default.php

It's about 125 lines.

Change $cfg <$'Servers '][$i]<$'host'] = 'localhost'

Change to $cfg <$'Servers '][$i]<$'host'] = 'Remote database server IP address', usually localhost can

Log in to phpMyAdmin on the web now

Enter the account and password for the remote database, here admin and admin (depending on the account password for the remote user you created in the previous step)

And inside is the database of the remote server.

The above is "how to make phpmyadmin can connect to the database remotely" all the contents of this article, thank you for reading! I believe that everyone has a certain understanding, hope to share the content to help everyone, if you still want to learn more knowledge, welcome to pay attention to the industry information channel!

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Database

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report