14.6.2 Configuring InnoDB for Read-Only Operation
14.6.2 Configuring InnoDB for Read-Only Operation 配置InnoDB只读操作 你可以查询InnoDB 表MySQL 数据目录是一个只读介质,通过启用 --innodb-read-only 配置选项在服务启动前 mysql> show variables like '%innodb-read-only%';
Empty set (0.00 sec) mysql> show variables like '%innodb_read_only%';
+------------------+-------+
| Variable_name | Value |
+------------------+-------+
| innodb_read_only | OFF |
+------------------+-------+
1 row in set (0.00 sec) 如何启用: 为了准备一个实例用于只读操作,确保所有的需要的信息是刷新到数据文件在存储到只读介质上, 让整个MySQL 实例启用只读模式, 指定下面的培训选项在启动时: --innodb-read-only=1 如果实例是在只读介质上的比如DVD或者CD,或者 /var目录根本不可写, --pid-file= 在可写设备上 Usage Scenarios 这个操作的模式是使用这些情况比如: 1. 分配一个MySQL 应用,或者MySQL数据集,在一个只读介质 比如DVD或者CD 2.多个MySQL 实例同时查询相同的数据目录,典型的在一个数据仓库配置。 你可能使用这个技术来避免瓶颈 当一个负载沉重的MySQL实例, 或者你可能使用不同的配置选项 对于各个实例来调整特定的查询 3.查询数据已经放放入到一个只读状态 对于安全或者数据的完整性的原因,比如归档的数据备份 它是如何工作的: 当服务器是运行在只读模式通过 --innodb-read-only选项, 某些InnoDB 功能和组件是被关闭或者完全关闭的 1,没有 change buffering,特别是没有合并从change buffer. 2. 没有crash recovery 节点在启动时, 实例必须执行一个缓慢的关闭在进入只读模式前 3.因为redo log 在只读操作是不使用的,你可以设置innodb_log_file_size 到最小值 4.除了I/O thread 线程外所有的后台进程都会被关闭,作为一个结果,只能实例不会遇到任何死锁 5.信息关于死锁,监控输出,不写到临时文件,作为一个结果, SHOW ENGINE INNODB STATUS 不产生任何输出 6.MVCC 处理是强制隔离级别被关闭。所有的查询读取最新的记录的版本,因为Update和delete 是不允许的
14.6.2 Configuring InnoDB for Read-Only Operation的更多相关文章
- 14.6.5 Configuring InnoDB Change Buffering 配置InnoDB Change Buffering
14.6.5 Configuring InnoDB Change Buffering 配置InnoDB Change Buffering 当插入,更新,和删除操作在表上执行, 索引列的值(特别是 se ...
- 14.4.5 Configuring InnoDB Change Buffering 配置InnoDB Change Buffering
14.4.5 Configuring InnoDB Change Buffering 配置InnoDB Change Buffering 当INSERT,UPDATE,和删除操作在表上操作, 索引列的 ...
- 14.4.2 Configuring InnoDB for Read-Only Operation 配置InnoDB 永于只读操作:
14.4.2 Configuring InnoDB for Read-Only Operation 配置InnoDB 永于只读操作: 你可以查询InnoDB 表 MySQL 数据目录是在只读介质里,通 ...
- 14.6.11 Configuring Optimizer Statistics for InnoDB 配置优化统计信息用于InnoDB
14.6.11 Configuring Optimizer Statistics for InnoDB 配置优化统计信息用于InnoDB 14.6.11.1 Configuring Persisten ...
- 14.6.8 Configuring the InnoDB Master Thread IO Rate 配置InnoDB 主线程IO 速率:
14.6.8 Configuring the InnoDB Master Thread IO Rate 配置InnoDB 主线程IO 速率: 主线程 在InnoDB 是一个线程 执行各种任务在后台. ...
- 14.6.7 Configuring the Number of Background InnoDB IO Threads 配置InnoDB IO Threads的数量
14.6.7 Configuring the Number of Background InnoDB IO Threads 配置InnoDB IO Threads的数量 InnoDB 使用后台线程来服 ...
- 14.6.6 Configuring Thread Concurrency for InnoDB 配置线程并发
14.6.6 Configuring Thread Concurrency for InnoDB 配置线程并发 InnoDB 使用操作系统线程来处理请求(用户事务) 事务可能执行很多次在它们提交或者回 ...
- 14.6.4 Configuring the Memory Allocator for InnoDB 配置InnoDB 内存分配器
14.6.4 Configuring the Memory Allocator for InnoDB 配置InnoDB 内存分配器 当InnoDB 被开发时,内存分配提供了操作系统和 run-time ...
- 14.6.3.5 Configuring InnoDB Buffer Pool Flushing
14.6.3.5 Configuring InnoDB Buffer Pool Flushing InnoDB 执行某些任务在后台, 包括脏叶的刷新(那些已经发生改变的pages 但是没有写入到数据文 ...
随机推荐
- C# 序列化和反序列
1.对象序列化的介绍 (1).NET支持对象序列化的几种方式 二进制序列化:对象序列化之后是二进制形式的,通过BinaryFormatter类来实现的,这个类位于System.Runtime.Seri ...
- 借鉴网上的winform模仿QQ窗口停靠功能稍作改动
2015-07-11 15:24:04 1 using System; using System.Collections.Generic; using System.ComponentModel; u ...
- sql 删除表数据truncate delete drop的区别
已下内容为转载内容:学习之用 1.truncate和不带where子句的delete.以及drop都会删除表内的数据. 2.drop.truncate都是DDL语句(数据定义语言),执行后会自动提交. ...
- centos 彻底卸载mysql
yum remove mysql mysql-server mysql-libs compat-mysql51rm -rf /var/lib/mysqlrm /etc/my.cnf查看是否还有mysq ...
- C++Primer学习笔记
一.开始 二.基础 三.常用库 四.其他 五.附录
- XML解析(转)
非原创,转载自http://my.oschina.net/khakiloveyty/blog/396671 xml解析主要可以使用CData,libxml2以及NSXMLParser,以下对各个方法给 ...
- jQuery 遍历祖先
祖先是父.祖父或曾祖父等等. 通过 jQuery,您能够向上遍历 DOM 树,以查找元素的祖先. 向上遍历 DOM 树 这些 jQuery 方法很有用,它们用于向上遍历 DOM 树: parent() ...
- 使用Ubuntu 新建vpn过程
1.更新软件源 sudo apt-get update 2.安装pip sudo apt-get install python-pip 3.安装shadowsocks s ...
- POJ 1159 Palindrome(LCS)
题目链接:http://poj.org/problem?id=1159 题目大意:给定一串字符,添加最少的字符,使之成为回文串. Sample Input 5 Ab3bd Sample Output ...
- Oracle中Long类型的使用与不可使用
ORA-01754 表只能包含一个LONG类型的列alter table 表名 add 字段名 long raw错误原因:数据表中同时建立了LONG RAW类型和LONG类型.------------ ...