Can't connect to MySQL server on '' (10060)
远程连接服务器出现以上错误
主要有三个原因:
1、mysql授权表里没有远程机器的权限,及需要在授权表mysql.user添加
grant all privileges on *.* to 'root'@'远程登陆IP' identified by '远程登陆密码'
flush privileges;
2、网络不通,这个就不说了。
3、防火墙禁止3306端口,以iptable为例
vi /etc/sysconfig/iptables
-A RH-Firewall-1-INPUT -m state --state NEW -m tcp -p tcp --dport 3306-j ACCEPT
service iptables restart
ps: iptables设置
1) 重启后生效
开启: chkconfig iptables on
关闭: chkconfig iptables off
2) 即时生效,重启后失效
开启: service iptables start
关闭: service iptables stop
相关文档:
If you set it in the cnf(it may be my.ini file) you will likely need to restart the server. Optionally, that is a dynamic variable and can be SET GLOBAL or SET SESSION from the command line as well.So just do as follows.
mysql>show variables like’max_allowed_packet’;
......
在linux下面安装mysql,首相要根据操作系统的版本,选择对应的mysql的版本,官方网站上有非常明确的分类
http://dev.mysql.com/downloads/
在这里我实验的操作系统是redhat linux
mysql 用了两个安装包,一个是server端,一个是client,我用的是rpm包,安装的指令比较简单。
MySQL-server-community-5.1.42-0.rhel4.i38 ......
MySQL索引
MySQL查询优化最重要的当属建立正确的索引,没有索引,面对海量数据,一切的优化纯属空话。什么是索引?索引为什么那么重要呢?这些问题这里就不谈了,还是先写下我首次优化MySQL查询海量数据的心得吧,数据库表类型是MyISAM。
如果简单的一个查询语句,MySQL查询速度还 ......
This section is a “How-To
” that describes the basics
for how to plan, install, configure, and run a MySQL Cluster.
Whereas the examples in
Chapter 3, MySQL Cluster Configuration
provide more in-depth
information on a variety of clustering options and co ......