当前位置:网站首页>Let others connect to their own MySQL database and share the MySQL database
Let others connect to their own MySQL database and share the MySQL database
2022-04-22 03:15:00 【Happy border town】
hold mysql Sharing to others can be divided into two types
1. Share all databases with others
First connect to... Through a terminal mysql
mysql -u root -p
Select database to use
use mysql;
Modify the required for the connection host For any
// The format is update user set host="%" where user=' user name ';
update user set host="%" where user='root';
Finally, remember to refresh
flush privileges;

2. Share some databases with others
Create user
The format is : create user’ user name ’@‘ Connected hosts ’ indentified by ‘ password ’;
create user'test1'@'%' identified by '123456';
to grant authorization
Grant operation permission to all tables of a database test1 user
grant all on Database name .* to 'test1'@'%';
// Refresh
flush privileges;

版权声明
本文为[Happy border town]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/04/202204211350243439.html
边栏推荐
- C language daily question -- [noip2008] ISBN number (question 76 of niuke.com)
- twenty-five. Module / built-in module / module installation
- jupyter代码无法运行
- STL learning
- 内置函数123
- nacos访问报404
- Ros2 learning notes (III) -- collect and release images of virtual simulation environment
- Record your first web automation test case
- C language daily question - xiaolele alarm clock (niuke.com)
- Leetcode dictionary order
猜你喜欢

The first day of C language daily question

72. Edit distance

Alipay two faces: how to use UDP to achieve reliable transmission?

Use xamarin to write a beautiful app login and registration interface

C language constant, string, escape character, initial level of annotation
![[WUSTCTF2020]朴实无华](/img/7f/db81436e898dd2e5af08e57a5024bf.png)
[WUSTCTF2020]朴实无华

Comparison of hex, Base64 and URLEncode coding schemes

Rest assured obtains logs to files and displays them in combination with the allure report

China Database ranking in April 2022: the spring breeze blows the face, the spring is warm, and the score rises in April

Record your first web automation test case
随机推荐
An article takes you to play with C language variables and data types
Redis事件驱动框架(上):何时使用select、poll、epoll?
OneFlow 的 Global Tensor 学习笔记和实习总结
kerberos認證協議
nacos访问报404
Can I go to my account? Is it safe?
Ali II: can the main method be inherited?
Record your first web automation test case
Flutter04-Widget初体验
Sword finger offer special breakthrough version 92, flipped characters
leetcode-字典序
职场礼仪.外企邮件怎么用
Interview with those stereotyped and boring interviewers
The original test engineers who were promoted and raised were good at interface testing
jupyter代码无法运行
824. Goat Latin (string segmentation + string substitution)
ESP32_GPIO输入、输出和中断
Evolution and construction of data warehouse architecture
[BJDCTF2020]Cookie is so stable(漏洞原理详解)
Wechat jsapi payment method and error (the URL of the current page is not registered, and the payment verification signature fails)