Innodb模糊检查点的痛苦

Innodb Fuzzy checkpointing woes
Innodb模糊检查点的痛苦

As you might know Innodb storage engines uses Fuzzy Checkpointing technique as part of it recovery strategy. It is very nice approach which means database never needs to “stall” to perform total modified pages flush but instead flushing of dirty pages happens gradually in small chunks so database load is very even.

技术相关:

降序索引和减轻索引扫描

Descending indexing and loose index scan
降序索引和减轻索引扫描

Comments to my previous posts, especially this one by Gokhan inspired me to write a bit about descending indexes and about loose index scan, or what Gokhan calls “better range” support. None of these are actially related to Innodb tables in general - these are features MySQL should get for all storage engines at some point.

创建了一个MSN群

创建了一个专门用于讨论MySQL技术的MSN群,群号码:msn15268@imqun.com,主页:http://www.imqun.com/quns/15268/,欢迎加入。

个人涂鸦:

分组提交和实时fsync

Group commit and real fsync
分组提交和实时fsync

During the recent months I’ve seen few cases of customers upgrading to MySQL 5.0 and having serious performance slow downs, up to 10 times in certain cases. What was the most surprising for them is the problem was hardware and even OS specific - it could show up with one OS version but not in the other. Even more interesting performance may be dramatically affected by –log-bin settings, which usually has just couple of percent overhead. So what is going on?

选择合适的innodb_log_file_size

Choosing proper innodb_log_file_size

选择合适的innodb_log_file_size

If you’re doing significant amount of writes to Innodb tables decent size of innodb_log_file_size is important for MySQL Performance. However setting it too large will increase recovery time, so in case of MySQL crash or power failure it may take long time before MySQL Server is operational again.

寻双线(南北互通)的php主机

朋友的服务器可能不再续费了,因此需要再找新的主机放我的网站。
需求:100-200M(web) + 50-100M(MySQL) + Linux(最好是) + Apache(最好是),能支持南北互通的虚拟主机。

个人涂鸦:

本站开放权限

所有注册用户都可以建立自己的blog了,同时开放了论坛,方便网友讨论,欢迎注册成为本站用户。

Taxonomy upgrade extras:

MySQL 存储过程的字符集问题

由于存储过程中定义参数时,无法定义其字符集,因此调用存储过程的时候,会默认读取全局变量character_set_server,而且还是只读取mysqld启动时该全局变量的值作为存储过程中默认的传输字符集。因此,如果数据表/字段使用系统默认的字符集(比如latin1)的话,调用存储过程更新一些非英文的字符串字段时,就不会发生问题;但是,如果数据表/字段的字符集不是系统默认的字符集(比如默认是latin1,数据表使用的是utf8),就会出现问题了。解决办法是:在my.cnf(windows下是my.ini),增加一行:

default-character-set=utf8

或者

升级 MySQL

1、概述

通常,从一个发布版本升级到另一个版本时,我们建议按照顺序来升级版本。例如,想要升级 MySQL 3.23 时,先升级到 MySQL 4.0,而不是直接升级到 MySQL 4.1 或 MySQL 5.0。

以下是在升级 MySQL 时需要注意的事项:

  • 仔细阅读一下升级的目标版本的新特性和改变的特性,以及2个版本之间的不同特性
  • 升级前一定要备份所有的数据
  • 如果是在Windows平台上升级MySQL,请阅读附录 "在Windows平台上升级MySQL"
  • 有些不同版本间的升级可能会涉及对授权表的修改,请尤其注意这个问题,详情请阅读附录 "升级授权表"

技术相关:

如何设置MySQL同步(Replication)

MySQL 提供了数据库的同步功能,这对我们实现数据库的冗灾、备份、恢复、负载均衡等都是有极大帮助的。本文描述了常见的同步设置方法。

一、准备服务器

由于MySQL不同版本之间的(二进制日志)binlog格式可能会不一样,因此最好的搭配组合是Master的MySQL版本和Slave的版本相同或者更低,Master的版本肯定不能高于Slave版本。

本文中,我们假设主服务器(以下简称Master)和从服务器(以下简称Slave)的版本都是5.0.15,操作系统是Linux Ubuntu 5.0.x。

假设同步Master的主机名为:rep1,Slave主机名为:rep2,2个MySQL的basedir目录都是/usr/local/mysql,datadir都是:/usr/local/mysql/data。

技术相关:

页面

Subscribe to iMySQL | 老叶茶馆 - Oracle MySQL ACE Director,专注MySQL RSS