当前位置:网站首页>linux中的mysql有10061错误怎么解决
linux中的mysql有10061错误怎么解决
2022-06-25 07:07:00 【亿速云】
linux中的mysql有10061错误怎么解决
这篇文章主要介绍“linux中的mysql有10061错误怎么解决”的相关知识,小编通过实际案例向大家展示操作过程,操作方法简单快捷,实用性强,希望这篇“linux中的mysql有10061错误怎么解决”文章能帮助大家解决问题。
解决方法:1、root用户登录到mysql命令行,并利用“vi /etc/mysql/mysql.conf.d/mysqld.cnf”命令将“bind-address”字段内容修改为“0.0.0.0”;2、利用“grant all on *.* to 账户@'%' identified by '密码' with grant option”给指定ip地址授权并重启mysql即可。
本教程操作环境:linux7.3系统、Dell G3电脑。
linux中的mysql有10061错误解决方法
mysql 10060错误一般因为防火墙
ufw allow 3306; //允许外部访问3306端口ufw allow from 192.168.1.115; //允许此IP访问所有的本机端口ufw status; //查看防火墙状态ufw disable/enable; //关闭或打开防火墙
没装ufw就执行安装既可:apt-get install ufw;
mysql 10061错误为配置原因
解决办法
第一步:
先查看mysql运行状态
netstat -ntlp | grep -v tcp6; //查看端口状态mysql -V; //查看mysql版本号find / -name mysqld.cnf; // 查找mysqld.cnf 的位置
如果端口为127.0.0.1:3306,解决办法
vi /etc/mysql/mysql.conf.d/mysqld.cnf; //将bind-address = 127.0.0.1 修改成 bind-address = 0.0.0.0
service mysql restart; //重启mysqlnetstat -ntlp | grep -v tcp6; //查看端口状态为0.0.0.0:3306即可
第二步:
grant all on *.* to 此处替换为你要登录的账户@'%' identified by '此处替换为该账户的密码' with grant option;
示例如下:

关于“linux中的mysql有10061错误怎么解决”的内容就介绍到这里了,感谢大家的阅读。如果想了解更多行业相关的知识,可以关注亿速云行业资讯频道,小编每天都会为大家更新不同的知识点。
边栏推荐
- Static web server
- TCP and UDP
- What is SKU and SPU? What is the difference between SKU and SPU
- A solution to slow startup of Anaconda navigator
- 打新债的安全性 有风险吗
- 在二叉树(搜索树)中找到两个节点的最近公共祖先(剑指offer)
- Nodehandle common member functions
- 使用pytorch搭建MobileNetV2并基于迁移学习训练
- What about the exponential smoothing index?
- How to calculate the positive and negative ideal solution and the positive and negative ideal distance in TOPSIS method?
猜你喜欢

Use Adobe Acrobat pro to resize PDF pages

How to calculate the independence weight index?

VOCALOID notes

How to analyze the coupling coordination index?

在二叉树(搜索树)中找到两个节点的最近公共祖先(剑指offer)

Self made ramp, but it really smells good

leetcode.13 --- 罗马数字转整数

STM32CubeMX 学习(5)输入捕获实验

With the beauty of technology enabled design, vivo cooperates with well-known art institutes to create the "industry university research" plan

Modeling and fault simulation of aircraft bleed system
随机推荐
Log in to MySQL 5.7 under ubuntu18 and set the root password
How to calculate critical weight indicators?
使用pytorch搭建MobileNetV2并基于迁移学习训练
Luogu p2048 [noi2010] super Piano (rmq+ priority queue)
股票网上开户安全吗?小白求指导
How to calculate the D value and W value of statistics in normality test?
Rank sum ratio (RSR) index calculation
InfluxDB时序数据库
在网上股票开户安全吗?证券账户可以给别人用吗?
Use pytorch to build mobilenetv2 and learn and train based on migration
Paper:Generating Hierarchical Explanations on Text Classification via Feature Interaction Detection
想转行学软件测试担心哪些问题?
企业全面云化的时代——云数据库的未来
五分钟快速搭建一个实时人脸口罩检测系统(OpenCV+PaddleHub 含源码)
Scanpy(七)基于scanorama整合scRNA-seq实现空间数据分析
Modeling and fault simulation of aircraft bleed system
Allgero reports an error: program has encoded a problem and must exit The design will be saved as a . SAV file
RMQ interval maximum subscript query, interval maximum
Websocket understanding and application scenarios
[QT] qtcreator shortcut key and QML introduction