当前位置: 首页 > 图文教程 > 数据库 > MYSQL > MySQL性能调整之my.cnf文件的配置方法

MYSQL
怎样可以在Windows上安装多个Mysql
详细讲解MySQL数据库中的安全配置步骤
解析mysql 8小时空闲后连接超时的问题
一起从基础入手来打开MySQL数据库之门
MySQL数据库中的Show命令具体用法
怎样在MySQL的数据库中定义外键详解
MySQL数据库用户帐号管理基础知识详解
MySQL从旧的版本升级为新的版本全攻略
用Tomcat和MySQL生成动态内容详解
讲解查看MySQL数据库错误码的三个方法
数据库经验:如何简单安装MySQL数据库
MySQL数据库双机热备的配置方法详解
在SUSE10下安装和配置MySQL数据库
MySQL数据库本地备份和双机相互备份
MySQL数据库常见的出错代码及出错信息
带你轻松玩转MySQL数据库的异常处理
用实例管理器轻松管理多个MySQL实例
MySQL性能调整之my.cnf文件的配置方法
Replace INTO与INSERT INTO的不同之处
循序渐进讲解MySQL数据库的性能调整

MYSQL 中的 MySQL性能调整之my.cnf文件的配置方法


出处:互联网   整理: 软晨网(RuanChen.com)   发布: 2009-10-17   浏览: 48 ::
收藏到网摘: n/a

MySQL性能调整之my.cnf文件的配置方法:

[mysqld]

datadir=/var/lib/mysql

socket=/var/lib/mysql/mysql.sock

skip-locking

set-variable = key_buffer=16M

set-variable = max_allowed_packet=1M

set-variable = thread_stack=64K

set-variable = record_buffer=1M

set-variable = table_cache=1024

set-variable = sort_buffer=4M

set-variable = net_buffer_length=8K

set-variable = max_connect_errors=100

set-variable = max_connections=1024

server-id = 1

[mysqldump]

quick

set-variable = max_allowed_packet=16M


[mysql]

no-auto-rehash

# Remove the next comment character if you are not familiar with SQL

#safe-updates


[isamchk]

set-variable = key_buffer=20M

set-variable = sort_buffer=20M


[myisamchk]

set-variable = key_buffer=20M

set-variable = sort_buffer=20M


[mysqlhotcopy]

interactive-timeout


[mysql.server]

user=mysql

basedir=/var/lib


[safe_mysqld]

err-log=/var/log/mysqld.log

pid-file=/var/run/mysqld/mysqld.pid